docs: restructure docs into diataxis (#121)

This commit is contained in:
banteg
2026-01-13 15:59:27 +04:00
committed by GitHub
parent d0e9a51a0f
commit e292c99ab0
52 changed files with 1538 additions and 1255 deletions
+35
View File
@@ -0,0 +1,35 @@
# Invariants
These are the “dont break this” rules that keep Takopi reliable.
## Runner contract
The runner contract is enforced by `tests/test_runner_contract.py`:
- Exactly one `StartedEvent`
- Exactly one `CompletedEvent`
- `CompletedEvent` is last
- `CompletedEvent.resume == StartedEvent.resume`
See also the [Plugin API](../plugin-api.md) runner contract section.
## Per-thread serialization
At most one active run may operate on the same thread/session at a time.
This is enforced both by scheduling and by per-resume-token runner locks.
Normative details live in the [Specification](../specification.md) (§5.2).
## Resume lines
Resume lines embedded in chat are the engines canonical resume command (e.g. `claude --resume <id>`).
- The runner is authoritative for formatting and extraction.
- Transports/rendering must preserve the resume line reliably (even when trimming/splitting).
Normative details live in the [Specification](../specification.md) (§3).
## Local contribution hygiene
- Run `just check` before code commits.