mirror of
https://gitee.com/zhangsken/opencode.git
synced 2026-10-16 10:30:01 +08:00
80241e9718
Keep user interactions tied to the current companion turn so stopping, typing, or reopening a retained session cannot revive stale speech or lose input. Limit status information to the main session and the companion's actual permission boundary.
V2 Specifications
These documents explain V2 behavior that is difficult to recover from one source file. They are not API reference or a backlog.
Authority
Authority follows the concern:
| Concern | Owner |
|---|---|
| HTTP operations and transport errors | Protocol endpoint definitions assembled by Server HttpApi |
| Public domain shapes and durable event payloads | Schema |
| Runtime behavior and persistence | Core |
| Contributor-critical regression guardrails | Root AGENTS.md |
Current specifications explain cross-module contracts without copying exact types. Decision records explain why a design was selected. Historical documents describe earlier states and may use obsolete names.
Generated clients follow the assembled public HttpApi. GitHub issues own active work; Git history preserves removed plans and scratchpads.
Current Contracts
| Document | Job |
|---|---|
| Session | Explain prompt admission, execution, instructions, compaction, and recovery boundaries. |
| Tools | Explain tool construction, registration, execution, and outcome laws. |
| Companion | Explain companion sessions, main-session tools, and the voice cascade. |
Decision Records
| Document | Status | Job |
|---|---|---|
| Event stream | Accepted and implemented | Record why public events use one encoded feed with independent queues. |
| Provider policy | Accepted and implemented | Allow or deny provider use and permission checks, with Console-managed statements having final authority. |
Historical Context
| Document | Job |
|---|---|
| Catalog/config/plugin lifecycle | Preserve the option comparison that led to replayable Location-scoped catalog transforms. |
Do not add implementation checklists here. Put actionable work in GitHub issues and package-specific contributor guidance next to the code it governs.