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

# Quickstart

> From install to a real code change in about a minute.

<Steps>
  <Step title="Install and sign in">
    ```bash theme={null}
    npm install -g @9thprotocol/cli
    9p login
    ```

    Approve the code in the browser. See [Installation](/installation).
  </Step>

  <Step title="Open a project">
    ```bash theme={null}
    cd ~/code/your-project
    9p
    ```

    9p always works in the current directory — there is no project to create or
    index first.
  </Step>

  <Step title="Ask for something small">
    ```
    9p ❯ what does the auth middleware do?
    ```

    9p searches, reads what it needs, and answers. Read-only work like this
    routes to a cheap model automatically.
  </Step>

  <Step title="Make a change">
    ```
    9p ❯ add a --verbose flag to the CLI and document it in the README
    ```

    Before anything is written or run, 9p asks:

    ```
    ● permission write src/cli.ts — allow? [y/N]
    ```

    Approve per action, or switch modes with `/mode accept-edits` once you trust
    the direction. See [Permissions](/permissions).
  </Step>

  <Step title="Watch the cost">
    Every turn ends with what it used:

    ```
    ◆ auto → moonshotai/kimi-k2.7-code (normal task)
    ⏺ 6 calls · 41.2k in (36.8k cached) · 1.1k out
    ```

    The `auto →` line is the [router](/models) telling you which model it picked
    and why.
  </Step>
</Steps>

## A first real task

A good opening task is one where you can check the result yourself:

```
9p ❯ find every place we parse dates by hand and list them with file:line.
     don't change anything yet.
```

Then, once you agree with the list:

```
9p ❯ replace those with the date helper in src/lib/date.ts. run the tests after.
```

Working in two steps — investigate, then act — is the single biggest quality
lever with any coding agent.

## Useful in-session commands

| Command         | What it does                                              |
| --------------- | --------------------------------------------------------- |
| `/mode plan`    | Read-only. 9p can look but not touch.                     |
| `/model`        | Show the current model; `/model auto` hands routing back. |
| `/bias economy` | Push Auto toward cheaper models.                          |
| `/usage`        | Credits and tokens for this session.                      |
| `/clear`        | Fresh context, same session.                              |

Full list in [CLI reference](/cli).

## Next

<CardGroup cols={2}>
  <Card title="Give it standing instructions" icon="brain" href="/memory">
    A `9P.md` it reads every session.
  </Card>

  <Card title="Package a workflow" icon="wand-magic-sparkles" href="/skills">
    Turn a repeated task into `/deploy`.
  </Card>
</CardGroup>
