mit einem Klick
cg
// Use when a local agent needs to dispatch work to CommonGround, inspect turn or agent state, wait for a turn to close, or resume a suspended turn through the `cg` CLI instead of calling the CG HTTP API directly.
// Use when a local agent needs to dispatch work to CommonGround, inspect turn or agent state, wait for a turn to close, or resume a suspended turn through the `cg` CLI instead of calling the CG HTTP API directly.
| name | cg |
| description | Use when a local agent needs to dispatch work to CommonGround, inspect turn or agent state, wait for a turn to close, or resume a suspended turn through the `cg` CLI instead of calling the CG HTTP API directly. |
| metadata | {"nanobot":{"requires":{"bins":["cg"]}}} |
Use the local cg CLI as the stable CommonGround interaction surface.
If cg is not available on PATH, stop and fix the local CLI setup. Do not fall back to direct HTTP calls.
The host should provide CommonGround auth through CLI-managed profiles. Legacy direct Agent credential env/config may exist for operators, but prompt-level skills should prefer --profile and must not read credential tokens.
Do not write credential tokens into request payloads, prompts, semantic records, or skill notes.
For open-source local demos, assume the operator has already prepared the default project cg-demo. If cg profile ensure-agent returns project_not_seeded, project_bootstrap_conflict, admin_service_credential_required, or profile_auth_required, stop and report the setup error. Do not try to repair project setup from the skill.
If the local CLI config or profile is missing, do not inspect token files or run setup commands. Ask the user/operator for the non-secret client connection facts needed to run cg: project id, agent id/profile, CommonGround service URL, Admin Service URL, and either an already prepared Admin Service bearer token file path or confirmation that the operator has written those values into CLI config. Never ask for a bearer token value in chat.
cg dispatchcg turn getcg turn contextcg turn waitcg turn resumecg agent getcg profile ensure-agentcg report work-memoryWhen the task explicitly requires project-level discovery before choosing a CommonGround target, the skill may also use:
cg project agent listcg project offer listcg project offer getcg setup project seedcg setup project statuscg setup project client-configcg kernelcg worker claim nextcg worker claim renewcg worker claim runcg worker claim appendcg worker claim finishcg worker claim dispatch-childcg worker claim suspendcurl calls to CommonGround HTTP APIcurl calls to CommonGround Admin Service APIPG_DSN setup commandscg ... --payload-file <path>.stdout.error.code and error.message.stderr as non-contract logging.cg turn wait is only for waiting until the turn reaches terminal closed.suspended as terminal completion.cg turn resume only for explicit external approval or operator resume flows.result.final_record_role and result.final_payload as the terminal result fields.cg worker for prompt-level interaction logic.cg setup or cg kernel; project setup is an operator-only local action, not a prompt-level skill action.curl against the CommonGround HTTP API when cg covers the operation.cg report work-memory --manifest-file <path>.meta into a work-memory manifest.cg-work-memory when you need stricter work-memory manifest guidance; this base skill only defines the CLI safety contract.Dispatch work:
cg dispatch \
--project-id cg-demo \
--requested-by frontside \
--target-agent nanobot \
--turn-kind turn.conversation.v1 \
--request-id req-123 \
--payload-file /tmp/cg-payload.json
Wait for terminal close:
cg turn wait \
--project-id cg-demo \
--turn-id T-123 \
--timeout-seconds 120 \
--poll-interval-ms 500
Read status:
cg turn get --project-id cg-demo --turn-id T-123
cg turn context --project-id cg-demo --turn-id T-123
cg agent get --project-id cg-demo --agent-id nanobot
cg project agent list --project-id cg-demo
cg project offer list --project-id cg-demo
cg project offer get --project-id cg-demo --agent-id nanobot --turn-kind turn.conversation.v1
Resume a suspended turn:
cg turn resume --project-id cg-demo --turn-id T-123 --requested-by operator
Ensure a local Agent profile:
cg profile ensure-agent \
--profile cg-demo/local-agent \
--project-id cg-demo \
--requested-agent-id local-agent \
--runtime-kind codex.local.v1 \
--display-name "Local Agent"
Report local work memory:
cg report work-memory \
--profile cg-demo/local-agent \
--project-id cg-demo \
--agent-id local-agent \
--manifest-file /tmp/work-memory-report.json
Use when deterministic runtime code needs to execute CommonGround worker lifecycle steps through the local `cg worker` command namespace, including claim acquisition, renewal, progress append, terminal finish, child dispatch, and suspend flows.
Use when a local agent needs to submit a concise public work-memory report for its own completed local task through `cg report work-memory`.