> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fimo.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Skills & rules

> How Fimo's skills and per-agent rule files teach your coding agent to work with Fimo.

Fimo wires up to AI coding tools in three layers: **global skills**, **per-project rule files**, and the **project-scope `fimo` skill**. Two CLI namespaces manage all three — `fimo skills` for skill artifacts and `fimo rules` for rule files.

## The three layers

<CardGroup cols={3}>
  <Card title="Global skills" icon="globe">
    `fimo-cli`, `fimo-studio`, and `fimo-migration` — installed once per machine. They describe the CLI workflows, the Studio web app, and migrations, and load in any compatible AI tool.
  </Card>

  <Card title="Rule files" icon="file-lines">
    `AGENTS.md` (universal) plus per-agent variants (`CLAUDE.md`, `.cursor/rules/fimo.mdc`, `.windsurfrules`, `GEMINI.md`) generated for the tools each project supports.
  </Card>

  <Card title="Project fimo skill" icon="folder">
    The code-side skill — schemas, forms, `t()`, `fimo/ui` — installed into the project and **version-locked** to the project's installed `fimo` package.
  </Card>
</CardGroup>

## The project `fimo` skill vs the global `fimo-cli` skill

* The **global `fimo-cli` skill** covers *what the CLI does* — creating projects, building content, deploying, managing domains and analytics. It's machine-wide and the same for every project.
* The **project `fimo` skill** covers *how to write code in this project* — the exact package surface installed here. It's version-locked, so its shapes always match what your code can use.

## `fimo skills` — install, sync, uninstall

```bash theme={null}
fimo skills install                            # interactive: pick agents, install everything that applies
fimo skills install --agents=claude-code,cursor   # explicit list
fimo skills install --mode=copy                # copy instead of symlink (required under npx)
fimo skills sync                               # refresh installed skills (global + project)
fimo skills uninstall                          # remove the global skills
```

`fimo skills install` is context-aware: **outside** a project it installs only global skills; **inside** a project it also writes the project skill and generates each selected agent's rule file. It shows a preview of every path it will touch, and prints exactly what it wrote.

<Note>
  Skills mostly stay current on their own — global skills auto-refresh when a newer CLI runs, and the project skill auto-refreshes when the `fimo` package version bumps. Run `fimo skills sync` to force a refresh.
</Note>

## `fimo rules` — rule files only

```bash theme={null}
fimo rules sync                    # regenerate missing per-agent rule files from AGENTS.md
fimo rules sync --agents=cursor    # for a specific agent
```

`fimo rules sync` is **purely additive** — it creates missing variant files but never overwrites existing ones, so your project-specific edits are preserved. To regenerate a stale variant, delete it first, then re-run. Rules are generated config; skills are reusable knowledge artifacts — the split is deliberate.

## What's next

<Columns cols={3}>
  <Card title="Install skills" icon="plug" href="/docs/get-started/install-skills">
    The step-by-step setup.
  </Card>

  <Card title="Connect your coding agent" icon="plug" href="/docs/ai/connect-agents">
    Supported agents.
  </Card>

  <Card title="CLI reference" icon="terminal" href="/docs/reference/cli">
    Every `fimo` command.
  </Card>
</Columns>
