Skip to content

docs(contracts): add agent session interface v1 - #79

Merged
wstein merged 1 commit into
mainfrom
docs/71-agent-session-contract
Oct 14, 2026
Merged

wstein merged 1 commit into
mainfrom
docs/71-agent-session-contract

Conversation

@wstein

@wstein wstein commented Oct 14, 2026

Copy link
Copy Markdown
Owner

Versioned contract for the in-container agent session interface (agent-session/1.0): contracts/agent-session-v1.md, contracts/agent-session-v1.schema.json, and the contracts/README.md entry (owner decisions H9:a, H16:b). Operations: hello, list, status, attach, send, stop. Operation-scoped grants (attach grant consumed atomically; control grants reusable until expiry). Errors by category name only; exit-code numbers live in ADR 0013.

Evidence (exact head 46b6c57, one commit on origin/main)

  • Independent review: Opus (claude-opus-5-5) CLEAR (full review of the earlier head a6d52b0 after two fix rounds; diff-only rebase check on 46b6c57, contract files byte-identical).
  • make check: exit 0, 818 tests, 0 raw failures, 0 errors, manifest-qualified GREEN (clean pinned checkout, python -I -B, HEAD unmoved).

Author proposals needing owner review (labelled in the file): all bounds (send 64 KiB decoded, control 16 KiB, frame 16 KiB, list 256, tail 64 KiB, deadline 30 s, resize max 500x200); control-grant reuse until expiry; a session grant does not authorize list; needs-human returned by send; attach marked mutating. Owner H38:a/H39:a pending: accept as v1 proposals, refine in speckit-plan.

Open questions (in the contract, decided in the plan): grant verification (key vs control-plane callback), transport/path in the container, idempotency key for send (removed from v1), whether the console is listed as a session.

Non-blocking nits for speckit-plan input: category-name mapping to ADR 0013 (conflict, incompatible names); grant failure vs unauthenticated; needs-human breadth; link ADR 0013 and exit-codes.json at md:160; stale wording md:80-81; name reserved fields; closed enums vs minor-version additions.

Refs #71

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@wstein
wstein merged commit 9bc0009 into main Oct 14, 2026
0 of 2 checks passed
@wstein
wstein deleted the docs/71-agent-session-contract branch October 14, 2026 03:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant