Skip to content

# CLI Reference

## cce init

Section titled “cce init”

One-time setup for a project. Checks dependencies, indexes all code, installs git hooks, and connects AI coding agents via MCP.

Terminal window

    cce initcce init --agent claudecce init --agent copilotcce init --agent codexcce init --agent all

What it does:

- Downloads the embedding model (first run only, ~60 MB).
- Checks Ollama status and reports compression mode.
- Builds vector, FTS, and graph indexes.
- Installs `post-commit`, `post-checkout`, and `post-merge` git hooks.
- Writes MCP config for selected agents.
- Creates or updates agent instruction files.
- Adds per-machine files to `.gitignore`.

## cce index

Section titled “cce index”

Re-index files that have changed since the last run.

Terminal window

    cce index              # Incremental (changed files only)cce index --full       # Force full re-index of every filecce index --path src/  # Index a specific file or directorycce index -v           # Verbose output

The git hooks installed by `cce init` call `cce index` automatically after every commit.

## cce status

Section titled “cce status”

Show index health and token savings summary.

Terminal window

    cce status             # Full statuscce status --oneline   # Single line (used by SessionStart hook)cce status --json      # Machine-readable outputcce status -v          # Lists all indexed projects

## cce savings

Section titled “cce savings”

Token savings report with cost estimates.

Terminal window

    cce savings            # Current projectcce savings --all      # All indexed projectscce savings --json     # Machine-readable output

## cce search

Section titled “cce search”

Run a test query against the index and display results.

Terminal window

    cce search 'how does authentication work'cce search 'payment processing' --top-k 10

Also updates savings stats, useful for populating the dashboard before opening an agent session.

## cce dashboard

Section titled “cce dashboard”

Open the web dashboard in your browser.

Terminal window

    cce dashboardcce dashboard --port 8080cce dashboard --no-browser

The dashboard provides views for: overview, files, sessions, and savings.

## cce services

Section titled “cce services”

Manage Ollama and the dashboard as background processes.

Terminal window

    cce services                        # Show statuscce services start                  # Start Ollama + dashboardcce services start ollama           # Start only Ollamacce services start dashboard        # Start dashboardcce services start dashboard --port 9000cce services stop                   # Stop everything CCE startedcce services stop dashboard         # Stop only dashboard

## cce start / cce stop

Section titled “cce start / cce stop”

Shortcuts for `cce services start` and `cce services stop`.

Terminal window

    cce start              # Start all servicescce stop               # Stop all servicescce start ollama       # Start only Ollamacce stop dashboard     # Stop only dashboard

## cce commands

Section titled “cce commands”

Manage per-project rules, preferences, and shell hooks.

Terminal window

    cce commands list                          # Show all rules and hookscce commands add-rule 'Use UUID for PKs'   # Add a rulecce commands remove-rule 'Use UUID for PKs'cce commands set-pref database PostgreSQL   # Set a preferencecce commands remove-pref databasecce commands add before_push 'npm test'    # Add hook commandcce commands remove before_push 'npm test'cce commands add-custom deploy 'kubectl apply -f k8s/'

## cce clear

Section titled “cce clear”

Clear all index data for the current project.

Terminal window

    cce clear              # Asks for confirmationcce clear --yes        # Skip confirmation

After clearing, run `cce index --full` to rebuild.

## cce prune

Section titled “cce prune”

Remove index data for projects whose directories no longer exist on disk.

Terminal window

    cce prune              # Remove stale project datacce prune --dry-run    # Preview without deleting

## cce upgrade

Section titled “cce upgrade”

Upgrade CCE to the latest version. Detects your install method (uv, pipx, or pip) and runs the correct upgrade command. Refreshes project config afterwards.

Terminal window

    cce upgrade            # Upgrade and refresh configcce upgrade --check    # Show install method without upgrading

## cce uninstall

Section titled “cce uninstall”

Remove CCE from the current project. Reverses everything `cce init` did.

Terminal window

    cce uninstall

Removes: git hooks, MCP config entry, instruction file block, and `.cce/` directory. Index data in `~/.cce` is preserved (use `cce clear` to remove it).

## cce serve

Section titled “cce serve”

Start the MCP server. Called automatically by agents via `.mcp.json`. You do not need to run this manually.

Terminal window

    cce servecce serve --project-dir /path/to/project

## cce list

Section titled “cce list”

Show every available command grouped by category.

Terminal window

    cce list

## Other flags

Section titled “Other flags”
Terminal window

    cce --version          # Show versioncce --help             # Show help