Skip to main content

Core Paths

AreaStart hereWhy
CLI and controllercmd/gc/Most user-visible behavior is wired here
Runtime provider contractinternal/runtime/runtime.goThe provider interface is the lowest-level agent runtime seam
Config and packsinternal/config/city.toml, pack composition, and override logic live here
Work storeinternal/beads/Tasks, molecules, waits, and mail all land on the store abstraction
Session lifecycleinternal/session/Session identity, wait helpers, and session bead metadata
Ordersinternal/orders/Order parsing and scanner logic
Convergenceinternal/convergence/Iterative refinement loops, gates, and convergence metadata
APIinternal/api/HTTP resources used by dashboards and external clients

Common Change Paths

Adding or changing a CLI command

  1. Add or edit the command in cmd/gc/.
  2. Update generated docs if config or CLI reference changed.
  3. Add user-facing coverage in tests or docsync where appropriate.

Changing runtime behavior

  1. Start at internal/runtime/runtime.go.
  2. Update the provider implementation package.
  3. Check session reconciliation in cmd/gc/ if wake, drain, or metadata semantics changed.

Changing config behavior

  1. Update internal/config/config.go.
  2. Follow through compose.go, pack.go, and patch/override helpers.
  3. Regenerate schema-backed reference docs if the schema changed.

Changing docs or onboarding

  1. Update the Mintlify nav in docs/docs.json if the IA changed.
  2. Run make check-docs.
  3. Keep tutorials and landing pages aligned with real commands and real files.
Last modified on March 19, 2026