docs/workspaces-beta/agent-cli-playbook.md
Beta note: workspace and initiative flows are usable, but still small. Prefer plain commands, clear paths, and short status reports.
Use JSON when you need exact paths.
openspec context-store list --json
openspec initiative list --json
openspec initiative show <store>/<initiative> --json
openspec workspace doctor --json
When the user is working from an opened workspace, treat the workspace as the
local view. Use workspace doctor --json to read linked repos/folders and the
selected initiative. Do not assume the current directory is the repo that should
own implementation artifacts.
Humans can run openspec context-store setup and answer prompts. Agents should
pass the setup inputs explicitly.
openspec context-store setup team-context --no-init-git --json
openspec context-store setup team-context --path /path/to/team-context --init-git --json
Use context-store unregister <id> --json to forget a local registration while
leaving files alone. Use context-store remove <id> --yes --json only when the
user explicitly asks to delete the local context-store folder.
Create shared coordination context in a context store.
openspec initiative create billing-launch --store team-context --title "Billing Launch" --summary "Get billing live without losing the plot."
Then edit the initiative files in the context store:
requirements.mddesign.mddecisions.mdquestions.mdtasks.mdWhen the user asks to explore or draft work from a workspace:
openspec workspace doctor --json.openspec initiative show <store>/<initiative> --json.The workspace is the cockpit for the conversation. It is not the durable home for implementation plans.
Repo-local changes belong in the repo that owns the work.
openspec new change add-billing-api --initiative team-context/billing-launch
Run this command with the owning repo as the current working directory. Do not ask the user to type it and do not run initiative-linked change creation from a workspace root. If you only know the workspace, resolve linked repo paths first.
After creating a change, report the absolute paths of the created files and the initiative link you used.
openspec workspace doctor --workspace billing-launch --json
openspec context-store doctor --json