Today, we're launching two agent skills for Liveblocks and Yjs, enabling AI
coding assistants to follow best practices more consistently.

<InstallCommand
  options={[
    { label: "npm", command: "npx skills add liveblocks/skills" },
    { label: "yarn", command: "yarn dlx skills add liveblocks/skills" },
    { label: "pnpm", command: "pnpm dlx skills add liveblocks/skills" },
    { label: "bun", command: "bunx skills add liveblocks/skills" },
  ]}
/>

## Agent skills

Agent Skills are folders of instructions, scripts, and resources that agents can
use to generate more accurate responses—they often consist of short markdown
files filled with domain-specific knowledge.

We’ve created two different agent skills for Liveblocks and Yjs, designed to
help AI coding assistants follow best practices more consistently. Once
installed, skills are automatically triggered by agents when they feel they’re
relevant.

<Figure
  caption={
    <>
      Claude Code using the{" "}
      <code className="text-xs">liveblocks-best-practices</code> skill
    </>
  }
>
  <MuxVideo
    playbackId="B7gNzZe01fGCqS02MzX549ZRN027hdRIbGYKVoNYXxXTEM"
    alt="Agent skills in Claude Code"
    static={true}
  />
</Figure>

Above you can see an agent loading a skill and recommending the perfect answer
to the question. The agent’s response is significantly more concise and precise
with the skill installed. Learn more in our
[agent skills documentation](/docs/tools/agent-skills).

### Liveblocks best practices

The `liveblocks-best-practices` skill is comprehensive, featuring 40+ reference
files related to every part of Liveblocks. Each reference details how to solve a
difficult or obscure problem, for example:

- How do I handle Wi-Fi connections dropping?
- How do I add a custom avatar component into `<Thread />`?
- How do I solve a `z-index` issue with dropdowns in Comments?

### Yjs best practices

The `yjs-best-practices` skill is based on our
[Yjs best practices and tips guide](/docs/guides/yjs-best-practices-and-tips),
and details how to avoid common pitfalls when working with Yjs, such as:

- How to get better performance with V2 encoding.
- When to use subdocuments, and better alternatives to using them.
- Why `Y.Map` is inefficient for key-value data and how to solve it.

## Install

Install our new skills into Cursor, Claude Code, and more, with the
[skills.sh](https://skills.sh) CLI.

<InstallCommand
  options={[
    { label: "npm", command: "npx skills add liveblocks/skills" },
    { label: "yarn", command: "yarn dlx skills add liveblocks/skills" },
    { label: "pnpm", command: "pnpm dlx skills add liveblocks/skills" },
    { label: "bun", command: "bunx skills add liveblocks/skills" },
  ]}
/>

## Contributors

<Contributors gitHubUsernames={["ctnicholas"]} />