Repository navigation
docs: restructure documentation and fold in the phase 7 notes - #34
Merged
Merged
Conversation
# Conflicts: # .gitignore
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Documentation restructure, batches 0 through 2. Imported documents keep their original text.
Batch 0 - rules and routing
AGENTS.md(new): reading order, the four documentation status levels, and the hard rules (contract changes need a decision record, research is not fact, keep core authoritative docs under ten, language policy, verification discipline).docs/README.md(new): bilingual router, per-reader paths, per-document index, and where new material belongs..gitignore: the previous rule ignoreddocs/*and allowlisted five files, so anything else dropped intodocs/silently disappeared. Documentation is now versioned by default; scratch material belongs in the ignoreddocs/_draft/.src/interfaces.ts: the source header claimed a frozen V0.1 projection whiledocs/INTERFACES.mdcalls the V0.1/FROZEN wording historical. The header now points atINTERFACES.mdas authoritative.Batch 1 - local-only documents move in
docs/research/phase1-codex-zcode-2026-09-26.mddocs/RESEARCH.mddocs/research/desktop-task-refresh-2026-09-28.mddocs/ZCODE_DESKTOP_TASK_REFRESH.mddocs/research/start-plan-headless-2026-09-27.md.tasks/notes/START_PLAN_HEADLESS_BLOCKER.mddocs/decisions/roadmap-decisions-2026-09-27.mddocs/ROADMAP_DECISIONS.mddocs/decisions/reliability-repair-plan-v2-2026-10-03.mddocs/BRIDGE_RELIABILITY_REPAIR_PLAN.mddocs/archive/appserver-capability-matrix-2026-09-27.mddocs/APPSERVER_CAPABILITY_MATRIX.mddocs/archive/mvp-v0.3-2026-09-27.mddocs/MVP_V0.3.mddocs/archive/mcp-sdk-v2-migration-2026-09-27.mddocs/MCP_SDK_V2_MIGRATION.mdPlus
docs/PROJECT_STATE.md(current snapshot with its own verification sources) anddocs/decisions/README.md.Batch 2 - decision records
Accepted: production execution uses the ZCode app-server; the historical CLI stays a legacy module.Accepted: the Manager owns the task lifecycle; workers enter through an attempt claim.Accepted: the execution directory is prepared by the calling host; the Bridge never creates or deletes it.Proposed: local metadata, rollout, logs and the Desktop index are observation, not a control plane. This is the only one that is not a straight carry-over: the repository had no explicit record of it, so it stays Proposed pending a decision.ADR-001 to ADR-003 each carry an Evidence section quoting
ARCHITECTURE.md/INTERFACES.md/ZCODE_RUNTIME.md.Batch 2b - Phase 7 notes folded in, then archived
docs/PHASE7_LIVE_PROGRESS.mdis nowdocs/archive/phase7-live-progress.md. Its still-valid content was verified against the current code before being folded in, not copied on trust:docs/ARCHITECTURE.mdgains the worker liveness and result-recovery paragraph: heartbeat written every 3 seconds bound to attempt and PID, the 15-second grace before a single negative PID probe counts, and the outcome checkpoint that lets the Manager recover a report when the worker exits before committing its result.docs/INTERFACES.mdgains the event-content and replay boundary: public events carry visible text, tool name/state and limited lifecycle metadata only; replay pollssession/eventsafter 10 seconds of silence, degrades to live-only subscription when the runtime rejects it or after three consecutive transient failures, and emits a visiblesession_event_replay_unavailableevent either way;session/readis not wired and native state query stays NOT RUN.src/worker/run-task.ts(3,000 ms heartbeat interval, heartbeat fields,outcome-checkpoint.json),src/manager/task-manager.ts(15,000 ms grace),src/adapters/zcode-app-server-adapter.ts(replayIdleMs = 10_000, poll interval, degradation path), and zerosession/readreferences insrc/.Three references outside the documentation were updated: the
package.jsonfiles list no longer ships the archived note, thesrc/adapters/zcode-app-server-adapter.tsheader comment points atINTERFACES.md/ZCODE_RUNTIME.md, and the archived capability matrix link was rewritten.docs/PROJECT_STATE.mdalso gained the real permission round trip to its NOT RUN list.Merge from master
masterwas merged in after #33 landed.docs/README.mdnow carries a real index row fordocs/research/native-cli-vs-appserver-2026-10-05/README.mdinstead of a placeholder. The only conflict was.gitignore: this branch replaces the allowlist policy, so the!docs/research/exceptions that #33 added are dropped as unnecessary under the new rule.Deliberately not in this batch
Splitting the current authoritative documents into per-topic files. Splitting is content-triggered: a document over roughly 15 KB, or one topic read independently by three or more readers. The authoritative set currently totals about 15 KB, so splitting now would produce stubs.
Local configuration note
docs/was additionally excluded by a local, unversioned rule in.git/info/exclude(/docs/). That rule is now commented out with an explanatory note. It is a local change and does not appear in this diff.Validation
npm run typecheck- passednpm test- passed: 261 tests, 260 passed, 0 failed, 1 skipped on Windows for POSIX permission bits (~10.8 minutes, includes the B3-05 scale case)npm run build- passed; generated bundles unchangednpm run validate:plugin- passedgit diff --check- cleanPHASE7_LIVE_PROGRESS.mdpath