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

# facet instructions

> Print CLI usage instructions for AI agents

## Usage

```sh theme={"theme":{"light":"github-light","dark":"github-dark"}}
facet instructions [topic]
```

`facet instructions` prints agent-oriented usage guidance for the CLI. It is **for AI agents**: workflow guidance that tells an autonomous agent how to author and use facets, rather than per-flag help (for that, use `facet <command> --help`).

The default topic is `overview`. It opens with a generated index of every instruction topic, then routes the agent to the right domain — authoring a facet, or using facets in a project. The index is generated from the CLI's own topic list, so it always lists exactly the topics the CLI serves.

<Note>
  Requires the facet CLI **v0.24.0 or newer**. If `facet instructions` reports *"Unknown command"*, update with [`facet self-update`](/cli/self-update).
</Note>

## Topics

<ResponseField name="overview" type="default">
  What facets are, the three artifact files, the two workflows (authoring vs. using), and a generated index of every topic.
</ResponseField>

<ResponseField name="manifest" type="topic">
  The `facet.json` structure — including top-level and per-skill supplementary `files` — plus the JSON Schema generated live from the schema definition.
</ResponseField>

<ResponseField name="authoring" type="topic">
  Writing facets: scaffold → modify → verify, including README and supplementary-file authoring and per-asset adapter configuration.
</ResponseField>

<ResponseField name="usage" type="topic">
  Project management: add/update/remove facets (registry-first), and install adapter tooling (including adapter API `0.1` recovery).
</ResponseField>

```sh theme={"theme":{"light":"github-light","dark":"github-dark"}}
facet instructions            # overview
facet instructions manifest   # facet.json structure + generated JSON Schema
facet instructions authoring  # how to author a facet non-interactively
facet instructions usage      # how to use facets in a project
```

## Exit codes

| Code | Meaning                                 |
| ---- | --------------------------------------- |
| `0`  | Instructions printed                    |
| `1`  | Unknown topic (valid topics are listed) |

## The manifest schema is generated

The `manifest` topic appends the `facet.json` **JSON Schema generated at runtime from the schema definition** — it is never a hand-maintained copy, so it always matches the CLI you are running. The narrow business rules the schema cannot express (at least one asset, single-segment asset names, a skill and command not sharing a name, exact and collision-free supplementary `files` paths, a valid facet name) are described in prose alongside it; run [`facet build --verify`](/cli/authoring/build) to check them against a real facet.

## Related commands

The instructions point agents at the non-interactive, machine-readable surfaces:

* [`facet create`](/cli/authoring/create) — scaffold a facet with headless flags.
* [`facet modify`](/cli/authoring/modify) — make scriptable edits to a facet.
* [`facet build`](/cli/authoring/build) — build, or `--verify` to validate without output.
* [`facet add`](/cli/add) — add facets to a project (registry-first).
* [`facet adapter`](/cli/adapters/install) — install and manage adapter tooling.
