planr 1.4.0 → 1.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (60) hide show
  1. package/README.md +21 -61
  2. package/docs/ARCHITECTURE.md +4 -4
  3. package/docs/CLAUDE_CODE.md +2 -2
  4. package/docs/CLI_REFERENCE.md +6 -14
  5. package/docs/CODEX.md +6 -6
  6. package/docs/CURSOR.md +2 -2
  7. package/docs/EXAMPLE_WEBAPP.md +63 -97
  8. package/docs/GOALS.md +8 -25
  9. package/docs/INSTALL.md +3 -3
  10. package/docs/MCP_CONTRACT.md +6 -9
  11. package/docs/MODEL_ROUTING.md +20 -177
  12. package/docs/RELEASE.md +1 -1
  13. package/docs/ROUTING_BUNDLES.md +32 -0
  14. package/docs/SKILLS.md +35 -50
  15. package/docs/documentation/CONTRACT.md +164 -0
  16. package/docs/documentation/COVERAGE.md +91 -0
  17. package/docs/documentation/INFORMATION_ARCHITECTURE.md +147 -0
  18. package/docs/fixtures/mcp-contract.json +3 -11
  19. package/npm/native/darwin-arm64/planr +0 -0
  20. package/npm/native/darwin-x86_64/planr +0 -0
  21. package/npm/native/linux-arm64/planr +0 -0
  22. package/npm/native/linux-x86_64/planr +0 -0
  23. package/package.json +25 -14
  24. package/plugins/planr/.claude-plugin/plugin.json +1 -1
  25. package/plugins/planr/.codex-plugin/plugin.json +2 -2
  26. package/plugins/planr/skills/planr-loop/SKILL.md +1 -1
  27. package/docs/PRESET_COMPOSITION.md +0 -109
  28. package/docs/PRESET_EVALUATION.md +0 -118
  29. package/docs/PRESET_REGISTRY.md +0 -61
  30. package/evaluations/preset-suite-v1.toml +0 -127
  31. package/evaluations/sol-luna-codex-v1.toml +0 -42
  32. package/plugins/planr/skills/planr-loop/agents/planr-reviewer.toml +0 -23
  33. package/plugins/planr/skills/planr-loop/agents/planr-worker.toml +0 -21
  34. package/presets/bindings/claude-native.toml +0 -52
  35. package/presets/bindings/codex-openai.toml +0 -56
  36. package/presets/bindings/cursor-fable-grok.toml +0 -49
  37. package/presets/bindings/cursor-openai.toml +0 -49
  38. package/presets/bindings/mixed-host.toml +0 -64
  39. package/presets/policies/balanced.toml +0 -50
  40. package/presets/policies/low-usage.toml +0 -50
  41. package/presets/policies/max-quality.toml +0 -50
  42. package/presets/policies/read-only-audit.toml +0 -50
  43. package/website/README.md +0 -79
  44. package/website/_headers +0 -7
  45. package/website/alchemy-runtime.test.mjs +0 -21
  46. package/website/app.mjs +0 -216
  47. package/website/build-catalog.mjs +0 -135
  48. package/website/build-site.test.mjs +0 -69
  49. package/website/catalog-model.mjs +0 -185
  50. package/website/catalog-model.test.mjs +0 -124
  51. package/website/cloudflare-launcher.test.mjs +0 -38
  52. package/website/data/catalog.json +0 -307
  53. package/website/index.html +0 -122
  54. package/website/registry/manifest.toml +0 -48
  55. package/website/registry/report.md +0 -33
  56. package/website/registry/trusted-maintainers.toml +0 -6
  57. package/website/registry/verification.json +0 -7258
  58. package/website/serve.mjs +0 -41
  59. package/website/styles.css +0 -201
  60. package/website/test-fixtures/recommended.json +0 -72
@@ -0,0 +1,164 @@
1
+ # Planr Documentation Contract
2
+
3
+ Status: approved implementation contract for the Planr documentation site
4
+ Last audited: 2026-07-17
5
+ Scope owner: `apps/docs` (site and English product documentation)
6
+
7
+ This contract turns the current product, runtime, and repository documentation into one maintainable public documentation system. It is intentionally separate from the product specification package: `docs/planr-spec/` remains the product source of truth, while the site explains the released product to users and contributors.
8
+
9
+ ## Source hierarchy
10
+
11
+ When sources disagree, authors must use this order and disclose the disagreement instead of silently choosing convenient copy:
12
+
13
+ 1. **Product intent and invariants:** `AGENTS.md` and `docs/planr-spec/`, especially `PRODUCT_SPEC.md`, `TECH_ARCHITECTURE.md`, and `API_AND_DATA_MODEL.md`.
14
+ 2. **Released executable behavior:** compiled `planr --help` output, `src/cli.rs`, `src/app/mcp.rs`, `src/app/http.rs`, `src/model.rs`, and the tested fixture `docs/fixtures/mcp-contract.json`. Runtime sources decide whether a command, option, schema, endpoint, state, or error exists in the current release.
15
+ 3. **Distribution contract:** `Cargo.toml`, `package.json`, `pnpm-workspace.yaml`, release workflows, installers, and release tests. These decide supported versions, artifacts, operating systems, and install commands.
16
+ 4. **Existing explanatory material:** `README.md`, `docs/*.md`, `plugins/planr/skills/`, examples, and routing-package docs. These are migration inputs, not independent sources of truth.
17
+ 5. **External references:** official upstream documentation and inspected local projects may influence structure and implementation, but never define Planr behavior.
18
+
19
+ If product intent is ahead of runtime, the public page must label the behavior as planned or omit it from executable instructions. If runtime is ahead of an older specification sentence, the public page documents the tested runtime and the discrepancy is added to the conflict register below.
20
+
21
+ ## Canonical terminology
22
+
23
+ Use these terms exactly. Prefer the lowercase form in prose unless it starts a sentence.
24
+
25
+ | Term | Public definition | Do not substitute |
26
+ | --- | --- | --- |
27
+ | Planr | The local-first planning and execution coordination product. | project manager, cloud orchestrator |
28
+ | project | One repository or multi-root workspace tracked by Planr. | workspace when referring to the stored object |
29
+ | product plan | A Markdown specification package that captures product intent. | PRD when the broader package is meant |
30
+ | build plan | A focused Markdown implementation contract for a buildable slice. | task list |
31
+ | map | The authoritative live dependency graph. | board, checklist |
32
+ | item | A node in the map with status, work type, ownership, and evidence. | ticket, task when referring to the stored object |
33
+ | link | A directed relation between items, normally `blocks`. | dependency edge in introductory prose |
34
+ | pick | An atomic lease of one ready item to one worker. | assignment, claim unless explaining the concept |
35
+ | worker | The identity holding the active pick. | agent when ownership specifically matters |
36
+ | log | Durable evidence or progress attached to an item. | transcript |
37
+ | verification log | A log with kind `verification` that records a live oracle. | test result alone |
38
+ | review | A graph gate that checks evidence and can create fix/follow-up work. | approval; approvals are a separate human gate |
39
+ | approval | An explicit requested/approved/denied human decision on an item. | review |
40
+ | context | A durable discovery, decision, constraint, or goal contract. | memory |
41
+ | artifact | Item-linked or project evidence such as a report, screenshot, or review file. | attachment when referring to the stored object |
42
+ | recovery sweep | A preview/apply operation for stale, timed-out, and retryable work. | automatic retry loop |
43
+ | package | A reusable export/import bundle of graph and optional Planr artifacts. | backup unless that is the user's intent |
44
+ | routing bundle | A provider-neutral, validated set of repository-local routing artifacts. | model config |
45
+ | goal contract | Durable Planr context defining the completion oracle and stop condition. | prompt-only instruction |
46
+
47
+ The canonical lifecycle is always:
48
+
49
+ ```text
50
+ idea -> product plan -> build plan -> map -> pick -> log -> review/evidence -> recovery/package -> close
51
+ ```
52
+
53
+ ## Selected documentation stack
54
+
55
+ The docs worker must create `apps/docs` in the existing pnpm workspace and pin direct dependencies exactly. The lockfile remains the transitive dependency authority.
56
+
57
+ | Component | Selected version | Rationale and evidence |
58
+ | --- | --- | --- |
59
+ | Fumadocs Core | `16.11.5` | npm `latest` on 2026-07-17; supplies source loading and built-in Orama search. Its peers accept Next.js `16.x` and React `^19.2.0`. |
60
+ | Fumadocs UI | `16.11.5` | npm `latest` on 2026-07-17; supplies accessible layouts and docs components. Its peer contract requires Core exactly `16.11.5`, Next.js `16.x`, and React `^19.2.0`. |
61
+ | Fumadocs MDX | `15.2.0` | npm `latest` on 2026-07-17; its major version is independent from Core/UI. Its peers accept Core `^16.7.0`, Next.js `^15.3.0 || ^16.0.0`, and React `^19.2.0`. |
62
+ | Next.js | `16.2.10` | Current stable Next.js 16 line required by the official Fumadocs Next.js guide. |
63
+ | React and React DOM | `19.2.7` | npm `latest` on 2026-07-17; satisfies the selected Fumadocs packages' `^19.2.0` peer requirement and Next.js 16's React 19 range. |
64
+ | Tailwind CSS | `4.x`, exact patch chosen at scaffold time | Fumadocs UI supports Tailwind 4 only; record the resolved exact patch in `apps/docs/package.json`. |
65
+ | Node.js | `>=22` for the docs workspace | Official Fumadocs quickstart requires Node 22. This does not change the published Planr CLI npm wrapper's Node 18 runtime contract. |
66
+ | Package manager | repository-pinned pnpm `11.5.3` | Avoids a second package manager and keeps workspace scripts reproducible. |
67
+
68
+ Evidence captured from official upstream sources:
69
+
70
+ - Fumadocs quickstart and Node requirement: <https://www.fumadocs.dev/docs>
71
+ - Fumadocs manual Next.js setup: <https://www.fumadocs.dev/docs/manual-installation/next>
72
+ - Fumadocs UI themes and Tailwind 4 contract: <https://www.fumadocs.dev/docs/ui/theme>
73
+ - Fumadocs layout API: <https://www.fumadocs.dev/docs/ui/layouts/docs>
74
+ - Fumadocs deployment constraints: <https://www.fumadocs.dev/docs/deploying>
75
+ - Alchemy v2 Cloudflare setup: <https://alchemy.run/cloudflare/setup/>
76
+ - Alchemy v2 frontend resources: <https://alchemy.run/cloudflare/frontend/frontends/>
77
+ - Alchemy v2 domains and DNS: <https://alchemy.run/cloudflare/networking/domains/>
78
+ - Stable package versions and peer ranges were replayed from the npm registry with `npm view <package>@latest version peerDependencies --json` on the audit date. The selected Core/UI/MDX/Next.js set satisfies every declared peer range.
79
+
80
+ Do not use `latest`, caret, tilde, or wildcard ranges for direct docs dependencies. A later upgrade is an explicit, reviewed dependency change with build, search, and browser verification.
81
+
82
+ ## Architecture decisions
83
+
84
+ ### DOC-ADR-001: One first-class workspace app
85
+
86
+ Create one English documentation application at `apps/docs`. It owns the public landing page, guides, reference, search, metadata, and deployment. Existing `docs/*.md` files remain source/reference material during migration; once a topic has a canonical site page, the old file becomes either a concise pointer or a checked redirect source, not a second maintained copy.
87
+
88
+ ### DOC-ADR-002: Next.js App Router with local MDX
89
+
90
+ Use Next.js 16 App Router, Fumadocs MDX, and content under `apps/docs/content/docs`. This is the most direct officially documented Fumadocs path and gives Planr a conservative deployment surface. Use `source.config.ts`, a generated `.source` directory, `fumadocs-core/source`, the Fumadocs root provider, and the standard docs catch-all route.
91
+
92
+ Rejected for this scope:
93
+
94
+ - TanStack Start: AgentRig proves it is viable, but it adds routing/build decisions that Planr does not otherwise own and is not needed for a documentation-only app.
95
+ - A bespoke Rust-rendered site or the `planr-routing/website` static implementation: neither supplies the requested polished docs authoring/search system.
96
+
97
+ ### DOC-ADR-003: Deploy with Alchemy and OpenNext on Cloudflare Workers
98
+
99
+ Use an Alchemy v2 Effect stack and OpenNext as the committed deployment owner. `Cloudflare.Website.StaticSite` runs the OpenNext build, uploads its prebuilt Worker with `bundle: false`, and serves the generated assets. Bind `docs.planr.so` only when the Alchemy stage is `prod`; development and preview stages use generated URLs. The Cloudflare zone must already exist in the authenticated account. Local credentials live in the Alchemy profile, shared state uses `Cloudflare.state()`, and CI verifies the OpenNext Worker artifact without deploying it.
100
+
101
+ ### DOC-ADR-004: Use Fumadocs primitives before copying components
102
+
103
+ Adopt `DocsLayout`, page tree navigation, breadcrumbs, table of contents, built-in search, MDX components, theme support, and metadata APIs. Customize with documented props, slots, stable ids/data attributes, and Planr design tokens. Do not fork layout components on day one; Fumadocs explicitly warns that copied components stop receiving upstream UI updates.
104
+
105
+ ### DOC-ADR-005: Navigation is explicit and task-first
106
+
107
+ Use directory `meta.json` files to make the navigation order deliberate. The first paths are evaluation, installation, quickstart, and a complete lifecycle tutorial. Concepts explain the mental model; guides solve tasks; reference mirrors executable surfaces; contributor and operations pages explain maintenance.
108
+
109
+ ### DOC-ADR-006: Reference is generated or mechanically checked
110
+
111
+ The CLI and MCP inventories must be derived from compiled help and the tested MCP fixture/schema. Hand-authored explanations can enrich them, but CI must fail when a public command/tool/resource/prompt lacks a target page. HTTP routes must be extracted or checked against `src/app/http.rs`. JSON examples must be replayed by tests or fixtures.
112
+
113
+ ### DOC-ADR-007: AgentRig is structural inspiration, not a template dependency
114
+
115
+ The requested path `~/projects/agentrig-mono/agentrig/apps/docs` no longer exists. The active inspected reference is `~/projects/agentrig-mono/agentrig-public/apps/docs`.
116
+
117
+ Adopted patterns:
118
+
119
+ - an `apps/docs` workspace boundary;
120
+ - local MDX collections plus `meta.json` page trees;
121
+ - an overview with audience-specific cards and quick paths;
122
+ - compact installation, integration, guide, contribution, and reference sections;
123
+ - a shared layout options module, source loader, MDX component registry, search endpoint, explicit 404/error UI, and theme control.
124
+
125
+ Rejected patterns:
126
+
127
+ - direct dependencies set to `latest`;
128
+ - product-specific TanStack/Alchemy infrastructure;
129
+ - manually curated CLI pages without a drift check;
130
+ - copying AgentRig wording, branding, images, or product taxonomy.
131
+
132
+ ## Conflict and gap register
133
+
134
+ These findings are explicit inputs to implementation and content review.
135
+
136
+ | ID | Finding | Resolution in the site |
137
+ | --- | --- | --- |
138
+ | GAP-001 | `docs/CLI_REFERENCE.md` says it is generated from help but omits current commands including `project delete`, `plan list`, `map export/import`, `item show/cancel`, `link remove`, `log show/list`, `review request/list/show`, `note`, and `scrub`. | Replace the list with generated/mechanically checked reference data; retain editorial detail around it. |
139
+ | GAP-002 | `docs/planr-spec/PRODUCT_SPEC.md` still calls Rust and the HTTP server open decisions, but the repository ships a Rust binary and `planr serve`. | Document current released behavior; update product specs only in a separately scoped product-spec change. |
140
+ | GAP-003 | `docs/ARCHITECTURE.md` describes one crate and one deployable while the root Cargo workspace includes the independent `planr-routing` member/package. | The architecture page must describe Planr Core and optional `planr-routing` ownership separately. |
141
+ | GAP-004 | README leads with Homebrew, while `docs/INSTALL.md` calls GitHub Releases/repo installer canonical and Homebrew preferred day-to-day. | Say “Homebrew recommended on macOS”; GitHub Releases are the canonical artifact source; npm is the cross-package-manager native-binary path. |
142
+ | GAP-005 | The CLI npm wrapper supports Node 18, while latest Fumadocs requires Node 22. | Keep separate requirement callouts: Planr CLI Node 18; docs contributors Node 22. |
143
+ | GAP-006 | Product personas mention Gemini CLI and generic clients, but install helpers exist only for Codex, Claude Code, and Cursor. | Give the three supported clients first-class setup pages; route Gemini/opencode/other tools through clearly labeled generic CLI or stdio MCP instructions. Do not imply a native installer. |
144
+ | GAP-007 | `planr install` uses the subcommand `claude`, while product prose often says “Claude Code”. | Use “Claude Code” in headings and `planr install claude` in commands. |
145
+ | GAP-008 | Product specs mention optional HTTP/SSE and “streamable HTTP” in client expectations, but the implemented MCP transport is stdio; `planr serve` is a separate localhost HTTP/SSE API and review UI. | Keep MCP transport and local HTTP API separate. Do not advertise streamable-HTTP MCP support unless implemented and tested. |
146
+ | GAP-009 | Existing flat Markdown pages overlap heavily across README, install, skills, operating model, and client guides. | Assign one canonical site page per concept/task; other pages link to it instead of restating the procedure. |
147
+ | GAP-010 | The initial repository had no website package, search index, redirect policy, link checker, freshness owner, or browser accessibility gate. | Implemented in `apps/docs`: Fumadocs search, executable redirects, maintenance drift checks, governance ownership, and production-browser axe evidence. |
148
+ | GAP-011 | The requested AgentRig path is stale. | Use `agentrig-public/apps/docs` only as recorded prior art; never make it a build dependency. |
149
+ | GAP-012 | Windows native assets are not in the public install contract. | Installation clearly labels macOS/Linux native support and WSL/source alternatives; no unsupported Windows-native promise. |
150
+ | GAP-013 | `opencode` appears in README but is not a first-class install target. | Include it only as an example on the generic CLI/MCP page, with no plugin or installer guarantee. |
151
+ | GAP-014 | The optional `planr-routing` package has its own CLI, catalog, policies, bindings, and website artifacts outside the core CLI reference. | Give routing its own concept/guide/reference pages and label the package optional. |
152
+
153
+ ## Explicit exclusions
154
+
155
+ - No localization in the initial release; English is canonical. The content structure must remain localization-ready.
156
+ - No hosted account, analytics, feedback database, or cloud search service.
157
+ - No OpenAPI rendering until Planr exposes a maintained OpenAPI document.
158
+ - No documentation for unimplemented cloud sync, team dashboard, native Windows artifact, Gemini installer, or streamable-HTTP MCP transport.
159
+ - No automatic execution of destructive examples. Preview-first examples are mandatory for delete, cancellation, replan, recovery apply, scrub, and import.
160
+ - No copying of AgentRig assets, copy, or branding.
161
+
162
+ ## Definition of maintained documentation
163
+
164
+ A public surface is documented only when it has a target route in `COVERAGE.md`, a canonical owner, a tested example or schema source where applicable, and a link from the page tree. A page is release-ready only when it has a title, description, audience/purpose, prerequisites, safe runnable examples, expected outcomes, failure/recovery guidance, and next steps.
@@ -0,0 +1,91 @@
1
+ # Documentation Coverage Matrix
2
+
3
+ This is the canonical inventory that maps shipped public surfaces to repository owners and published routes. Every `/docs` target in this file must resolve to a current MDX page; `pnpm docs:verify-maintenance` enforces that rule. Retired aliases belong only in `apps/docs/redirects.mjs`, never in this current-route matrix.
4
+
5
+ ## Published route inventory
6
+
7
+ The site currently owns 59 MDX routes. Next.js also emits the landing page and framework support routes during the production build.
8
+
9
+ | Section | Published routes |
10
+ | --- | --- |
11
+ | Documentation | `/docs` |
12
+ | Getting started | `/docs/getting-started`, `/docs/getting-started/why-planr`, `/docs/getting-started/installation`, `/docs/getting-started/quickstart`, `/docs/getting-started/full-lifecycle`, `/docs/getting-started/choose-your-interface` |
13
+ | For Agents | `/docs/agents`, `/docs/agents/quickstart`, `/docs/agents/prompt-recipes`, `/docs/agents/skills` |
14
+ | Integrations | `/docs/integrations`, `/docs/integrations/codex`, `/docs/integrations/claude-code`, `/docs/integrations/cursor`, `/docs/integrations/generic-mcp`, `/docs/integrations/cli-only` |
15
+ | Concepts | `/docs/concepts`, `/docs/concepts/local-first-model`, `/docs/concepts/plans-and-map`, `/docs/concepts/graph-and-readiness`, `/docs/concepts/picks-and-leases`, `/docs/concepts/evidence-and-context`, `/docs/concepts/reviews-and-approvals`, `/docs/concepts/recovery-packages-and-closure` |
16
+ | Guides | `/docs/guides`, `/docs/guides/daily-worker-loop`, `/docs/guides/parallel-coordination`, `/docs/guides/handoff-and-resume`, `/docs/guides/review-and-fix-loops`, `/docs/guides/recover-interrupted-work`, `/docs/guides/packages-and-reuse`, `/docs/guides/recipes` |
17
+ | Reference | `/docs/reference`, `/docs/reference/cli`, `/docs/reference/cli-generated`, `/docs/reference/mcp`, `/docs/reference/mcp-schemas-generated`, `/docs/reference/http-api`, `/docs/reference/configuration-and-storage`, `/docs/reference/data-and-status`, `/docs/reference/outputs-and-errors`, `/docs/reference/support-matrix`, `/docs/reference/maintenance` |
18
+ | Contributing | `/docs/contributing`, `/docs/contributing/repository-setup`, `/docs/contributing/architecture`, `/docs/contributing/docs-authoring`, `/docs/contributing/testing`, `/docs/contributing/security-and-privacy` |
19
+ | Operations | `/docs/operations`, `/docs/operations/release`, `/docs/operations/versioning-and-migrations`, `/docs/operations/docs-deployment`, `/docs/operations/health-and-diagnostics`, `/docs/operations/rollback`, `/docs/operations/documentation-governance` |
20
+ | Help | `/docs/troubleshooting`, `/docs/faq` |
21
+
22
+ ## Product journeys and concepts
23
+
24
+ | Surface | Canonical owner | Published route(s) |
25
+ | --- | --- | --- |
26
+ | Promise, users, non-goals | `docs/planr-spec/PRODUCT_SPEC.md` | `/docs/getting-started/why-planr` |
27
+ | Install, first success, full lifecycle | manifests, installers, `src/cli.rs`, E2E tests | `/docs/getting-started/installation`, `/docs/getting-started/quickstart`, `/docs/getting-started/full-lifecycle` |
28
+ | Agent setup, public routing, and prompt recipes | typed client/prompt contracts and installed Planr skills | `/docs/agents`, `/docs/agents/quickstart`, `/docs/agents/prompt-recipes`, `/docs/agents/skills` |
29
+ | Local-first authority and boundaries | product/data specs, `src/storage/` | `/docs/concepts/local-first-model` |
30
+ | Product plans, build plans, maps | `src/planpack.rs`, `src/app/commands.rs` | `/docs/concepts/plans-and-map` |
31
+ | Items, links, statuses, readiness | `src/model.rs`, `src/app/repository/item.rs`, `src/app/lease.rs` | `/docs/concepts/graph-and-readiness` |
32
+ | Picks, leases, concurrency, progress | `src/app/lease.rs`, `src/app/flow.rs` | `/docs/concepts/picks-and-leases`, `/docs/guides/parallel-coordination` |
33
+ | Logs, contexts, artifacts, live evidence | `src/app/application.rs`, `src/app/inspection.rs` | `/docs/concepts/evidence-and-context` |
34
+ | Reviews, approvals, fix chains | `src/app/review.rs`, `src/app/flow.rs`, `src/app/application.rs` | `/docs/concepts/reviews-and-approvals`, `/docs/guides/review-and-fix-loops` |
35
+ | Recovery, conditions, packages, closure | `src/app/recovery.rs`, `src/app/packages.rs`, `src/app/flow.rs` | `/docs/concepts/recovery-packages-and-closure`, `/docs/guides/recover-interrupted-work`, `/docs/guides/packages-and-reuse` |
36
+ | Worker loop, handoff, recipes | application flow and lease owners | `/docs/guides/daily-worker-loop`, `/docs/guides/handoff-and-resume`, `/docs/guides/recipes` |
37
+
38
+ ## CLI, MCP, HTTP, and data contracts
39
+
40
+ The executable and schema sources decide exact inventory. Editorial pages explain usage; generated pages carry exhaustive command and schema detail.
41
+
42
+ | Surface | Canonical owner | Published route(s) |
43
+ | --- | --- | --- |
44
+ | CLI invocation and automation rules | `src/cli.rs`, compiled help | `/docs/reference/cli` |
45
+ | Every CLI group and subcommand | compiled recursive help, reference generator | `/docs/reference/cli-generated` |
46
+ | MCP transport, resources, prompts, results | `src/app/mcp.rs`, `src/integrations.rs`, fixture | `/docs/reference/mcp` |
47
+ | Every MCP tool input schema | live MCP discovery, schema generator | `/docs/reference/mcp-schemas-generated` |
48
+ | Local HTTP/SSE and review routes | `src/app/http.rs` | `/docs/reference/http-api` |
49
+ | Environment, installers, storage, repository files | CLI/install/storage owners | `/docs/reference/configuration-and-storage` |
50
+ | DTOs, IDs, statuses, links, SQLite tables, packages | `src/model.rs`, `src/storage/schema.rs` | `/docs/reference/data-and-status` |
51
+ | JSON output, error codes, exit/recovery behavior | application and surface adapters | `/docs/reference/outputs-and-errors` |
52
+ | Platforms, clients, transports | manifests, release and integration owners | `/docs/reference/support-matrix` |
53
+ | Reference generation and synchronization | generator/check scripts and CI | `/docs/reference/maintenance` |
54
+
55
+ ## Installation, clients, and safety
56
+
57
+ | Surface | Canonical owner | Published route(s) |
58
+ | --- | --- | --- |
59
+ | Homebrew, install script, npm, source build | release manifests, `scripts/install.sh`, npm wrapper | `/docs/getting-started/installation` |
60
+ | Interface selection and client differences | integration descriptors and installers | `/docs/getting-started/choose-your-interface`, `/docs/integrations` |
61
+ | Agent-led setup and autonomous handoff | typed onboarding prompts and Planr goal/loop contracts | `/docs/agents/quickstart`, `/docs/agents/prompt-recipes` |
62
+ | Codex | Codex manifest, generated role/install assets | `/docs/integrations/codex` |
63
+ | Claude Code | Claude manifest, generated role/install assets | `/docs/integrations/claude-code` |
64
+ | Cursor | Cursor manifest, role/skill/install assets | `/docs/integrations/cursor` |
65
+ | Generic stdio MCP | MCP server and fixture | `/docs/integrations/generic-mcp` |
66
+ | CLI-only and non-first-class hosts | prompt output and CLI | `/docs/integrations/cli-only` |
67
+ | Privacy, secret handling, localhost boundary | safety spec, `src/app/http.rs`, scrub behavior | `/docs/contributing/security-and-privacy` |
68
+ | User diagnosis and common questions | doctor/debug behavior and E2E tests | `/docs/troubleshooting`, `/docs/faq` |
69
+
70
+ ## Contributor and operations coverage
71
+
72
+ | Surface | Canonical owner | Published route(s) |
73
+ | --- | --- | --- |
74
+ | Repository setup and worktree safety | manifests and `AGENTS.md` | `/docs/contributing/repository-setup` |
75
+ | Code and docs architecture ownership | `docs/ARCHITECTURE.md`, compiled source, docs contract | `/docs/contributing/architecture` |
76
+ | MDX, components, navigation, preview | `apps/docs` source and component contract | `/docs/contributing/docs-authoring` |
77
+ | Rust, docs, semantic, browser, accessibility gates | tests, scripts, CI workflows | `/docs/contributing/testing` |
78
+ | Product release and publication | `scripts/release.sh`, release workflow, `docs/RELEASE.md` | `/docs/operations/release` |
79
+ | Version synchronization and SQLite upgrades | release script, manifests, `src/storage/schema.rs` | `/docs/operations/versioning-and-migrations` |
80
+ | Alchemy/OpenNext docs build and Cloudflare deployment | `apps/docs/alchemy.run.ts`, Next/OpenNext config, environment contract | `/docs/operations/docs-deployment` |
81
+ | Runtime diagnosis | docs scripts, source loader, deployment config | `/docs/operations/health-and-diagnostics` |
82
+ | Docs and product rollback boundaries | immutable deployment contract, schema owner, release policy | `/docs/operations/rollback` |
83
+ | Ownership, freshness, redirects, coverage | this matrix, docs contract, IA, redirect inventory, CI | `/docs/operations/documentation-governance` |
84
+
85
+ ## Audit completion checklist
86
+
87
+ - [x] All 59 current MDX routes are explicitly inventoried.
88
+ - [x] Every public product, CLI, MCP, HTTP, data, client, contributor, and operations surface has a current target and canonical source owner.
89
+ - [x] Generated CLI and MCP inventories are separated from editorial guidance and mechanically checked.
90
+ - [x] Retired aliases are isolated in `apps/docs/redirects.mjs` and resolve to a current route.
91
+ - [x] `pnpm docs:verify-maintenance` fails for missing coverage routes, missing anchors, undeclared pages, invalid redirects, dependency drift, or release-tag drift.
@@ -0,0 +1,147 @@
1
+ # Documentation Information Architecture
2
+
3
+ This file records the implemented route and navigation contract. Routes are public interfaces: rename one only after adding a tested legacy alias to `apps/docs/redirects.mjs`.
4
+
5
+ ## Audiences and required journeys
6
+
7
+ | Audience | Required path | Success signal |
8
+ | --- | --- | --- |
9
+ | evaluator | `/` -> `/docs` -> `/docs/getting-started/why-planr` | Understands the local-first map and evidence model. |
10
+ | first-time user | `/docs/getting-started/installation` -> `/docs/getting-started/quickstart` | Installs, initializes, inspects, and diagnoses Planr. |
11
+ | agent-led user | `/docs/agents/quickstart` -> `/docs/agents/prompt-recipes` | Completes safe setup, starts with `$planr`, and keeps autonomous execution plan-bound. |
12
+ | lifecycle user | `/docs/getting-started/full-lifecycle` | Completes plan, map, work, evidence, and review. |
13
+ | worker/operator | `/docs/guides/daily-worker-loop` -> `/docs/guides/parallel-coordination` | Picks without collisions and records durable evidence. |
14
+ | reviewer | `/docs/concepts/reviews-and-approvals` -> `/docs/guides/review-and-fix-loops` | Closes a complete gate or creates a bounded fix chain. |
15
+ | client integrator | `/docs/integrations` -> one client page | Connects through a supported CLI or stdio MCP path. |
16
+ | API toolsmith | `/docs/reference/mcp` or `/docs/reference/http-api` | Uses the current schema and transport boundary. |
17
+ | contributor | `/docs/contributing` -> setup/architecture/testing | Places and verifies a change without tribal knowledge. |
18
+ | maintainer | `/docs/operations` | Can release, deploy, diagnose, roll back, and review freshness. |
19
+
20
+ ## Implemented route tree
21
+
22
+ The 59 MDX files below are the current page tree and must agree with every `meta.json` file and `COVERAGE.md`.
23
+
24
+ ```text
25
+ /docs
26
+ ├── getting-started
27
+ │ ├── why-planr
28
+ │ ├── installation
29
+ │ ├── quickstart
30
+ │ ├── full-lifecycle
31
+ │ └── choose-your-interface
32
+ ├── agents (For Agents)
33
+ │ ├── quickstart
34
+ │ ├── prompt-recipes
35
+ │ └── skills
36
+ ├── integrations
37
+ │ ├── codex
38
+ │ ├── claude-code
39
+ │ ├── cursor
40
+ │ ├── generic-mcp
41
+ │ └── cli-only
42
+ ├── concepts
43
+ │ ├── local-first-model
44
+ │ ├── plans-and-map
45
+ │ ├── graph-and-readiness
46
+ │ ├── picks-and-leases
47
+ │ ├── evidence-and-context
48
+ │ ├── reviews-and-approvals
49
+ │ └── recovery-packages-and-closure
50
+ ├── guides
51
+ │ ├── daily-worker-loop
52
+ │ ├── parallel-coordination
53
+ │ ├── handoff-and-resume
54
+ │ ├── review-and-fix-loops
55
+ │ ├── recover-interrupted-work
56
+ │ ├── packages-and-reuse
57
+ │ └── recipes
58
+ ├── reference
59
+ │ ├── cli
60
+ │ ├── cli-generated
61
+ │ ├── mcp
62
+ │ ├── mcp-schemas-generated
63
+ │ ├── http-api
64
+ │ ├── configuration-and-storage
65
+ │ ├── data-and-status
66
+ │ ├── outputs-and-errors
67
+ │ ├── support-matrix
68
+ │ └── maintenance
69
+ ├── contributing
70
+ │ ├── repository-setup
71
+ │ ├── architecture
72
+ │ ├── docs-authoring
73
+ │ ├── testing
74
+ │ └── security-and-privacy
75
+ ├── operations
76
+ │ ├── release
77
+ │ ├── versioning-and-migrations
78
+ │ ├── docs-deployment
79
+ │ ├── health-and-diagnostics
80
+ │ ├── rollback
81
+ │ └── documentation-governance
82
+ ├── troubleshooting
83
+ └── faq
84
+ ```
85
+
86
+ Each named section also has its own index route. The application additionally owns `/`, `/api/search`, the custom not-found page, metadata routes, and static assets; those are application routes rather than MDX navigation nodes.
87
+
88
+ ## Navigation and page contracts
89
+
90
+ - Root and section `meta.json` files explicitly order every page.
91
+ - Guides state prerequisites, outcome, failure recovery, and next action.
92
+ - Reference pages name their generated or compiled source.
93
+ - The For Agents section owns the shared setup and prompt journey; integration pages own client-specific technical detail and render the same typed recipe rather than copying it.
94
+ - Getting Started remains the manual, CLI-first journey.
95
+ - Search indexes the same Fumadocs source tree used by navigation.
96
+ - English is canonical for this release.
97
+
98
+ ## Redirect policy
99
+
100
+ `apps/docs/redirects.mjs` is the one executable inventory of retired public site aliases. `apps/docs/next.config.mjs` returns that inventory from Next.js `redirects()`, so production serves permanent redirects. The maintenance verifier enforces unique sources, current destinations, absence of alias/source collisions, and documentation of both sides here.
101
+
102
+ The inventory covers these retired route families:
103
+
104
+ | Retired alias | Current destination |
105
+ | --- | --- |
106
+ | `/docs/concepts/mental-model` | `/docs/concepts/local-first-model` |
107
+ | `/docs/concepts/plans` | `/docs/concepts/plans-and-map` |
108
+ | `/docs/concepts/map-items-and-links` | `/docs/concepts/graph-and-readiness` |
109
+ | `/docs/concepts/statuses-and-readiness` | `/docs/concepts/graph-and-readiness` |
110
+ | `/docs/concepts/logs-and-artifacts` | `/docs/concepts/evidence-and-context` |
111
+ | `/docs/concepts/evidence-and-reviews` | `/docs/concepts/reviews-and-approvals` |
112
+ | `/docs/concepts/approvals` | `/docs/concepts/reviews-and-approvals` |
113
+ | `/docs/concepts/context-and-recall` | `/docs/concepts/evidence-and-context` |
114
+ | `/docs/concepts/recovery-and-packages` | `/docs/concepts/recovery-packages-and-closure` |
115
+ | `/docs/concepts/routing-and-policy` | `/docs/reference/configuration-and-storage` |
116
+ | `/docs/guides/new-product` | `/docs/getting-started/full-lifecycle` |
117
+ | `/docs/guides/existing-project-work` | `/docs/guides/recipes` |
118
+ | `/docs/guides/autonomous-goals` | `/docs/getting-started/full-lifecycle` |
119
+ | `/docs/guides/multi-agent-coordination` | `/docs/guides/parallel-coordination` |
120
+ | `/docs/guides/review-and-fix-loop` | `/docs/guides/review-and-fix-loops` |
121
+ | `/docs/guides/interruptions-and-recovery` | `/docs/guides/recover-interrupted-work` |
122
+ | `/docs/guides/import-export-and-templates` | `/docs/guides/packages-and-reuse` |
123
+ | `/docs/guides/local-review-workspace` | `/docs/guides/recipes` |
124
+ | `/docs/guides/host-hooks` | `/docs/integrations` |
125
+ | `/docs/guides/model-routing` | `/docs/reference/configuration-and-storage` |
126
+ | `/docs/reference/cli/index` | `/docs/reference/cli` |
127
+ | `/docs/reference/cli/project-and-plans` | `/docs/reference/cli-generated` |
128
+ | `/docs/reference/cli/map-items-and-links` | `/docs/reference/cli-generated` |
129
+ | `/docs/reference/cli/picks-logs-and-close` | `/docs/reference/cli-generated` |
130
+ | `/docs/reference/cli/reviews-and-approvals` | `/docs/reference/cli-generated` |
131
+ | `/docs/reference/cli/context-search-and-recovery` | `/docs/reference/cli-generated` |
132
+ | `/docs/reference/cli/agents-routing-and-policy` | `/docs/reference/cli-generated` |
133
+ | `/docs/reference/cli/install-prompt-and-server` | `/docs/reference/cli-generated` |
134
+ | `/docs/reference/cli/artifacts-events-and-packages` | `/docs/reference/cli-generated` |
135
+ | `/docs/reference/mcp/tools` | `/docs/reference/mcp-schemas-generated` |
136
+ | `/docs/reference/mcp/resources` | `/docs/reference/mcp` |
137
+ | `/docs/reference/mcp/prompts` | `/docs/reference/mcp` |
138
+ | `/docs/reference/configuration-and-environment` | `/docs/reference/configuration-and-storage` |
139
+ | `/docs/reference/storage-and-generated-files` | `/docs/reference/configuration-and-storage` |
140
+ | `/docs/reference/data-model-and-statuses` | `/docs/reference/data-and-status` |
141
+ | `/docs/reference/json-and-errors` | `/docs/reference/outputs-and-errors` |
142
+ | `/docs/reference/routing-bundles` | `/docs/reference/configuration-and-storage` |
143
+ | `/docs/reference/platform-support` | `/docs/reference/support-matrix` |
144
+
145
+ Repository files such as `docs/INSTALL.md` are not former website URLs. They remain GitHub-readable source material and must link to the current site rather than pretending a Next.js redirect can intercept a repository path.
146
+
147
+ To retire another route: add exactly one alias, choose the closest current outcome page, update this table, repair internal links, run the maintenance and browser gates, and retain the redirect while supported inbound links may exist. Never redirect an unknown path to a generic landing page merely to hide a 404.
@@ -20,12 +20,6 @@
20
20
  "planr_item_amend",
21
21
  "planr_item_replan",
22
22
  "planr_agents_list",
23
- "planr_presets_list",
24
- "planr_preset_evaluate",
25
- "planr_preset_apply",
26
- "planr_preset_registry_verify",
27
- "planr_preset_registry_import",
28
- "planr_preset_registry_list",
29
23
  "planr_policy_show",
30
24
  "planr_policy_check",
31
25
  "planr_policy_admit",
@@ -109,11 +103,9 @@
109
103
  "planr recover sweep",
110
104
  "planr agents list",
111
105
  "planr agents check",
112
- "planr agents preset list",
113
- "planr agents preset apply",
114
- "planr agents preset registry verify",
115
- "planr agents preset registry import",
116
- "planr agents preset registry list",
106
+ "planr routing bundle inspect",
107
+ "planr routing bundle preview",
108
+ "planr routing bundle apply",
117
109
  "planr item route",
118
110
  "planr trace item",
119
111
  "planr serve --port"
Binary file
Binary file
Binary file
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "planr",
3
- "version": "1.4.0",
3
+ "version": "1.5.1",
4
4
  "description": "Local-first planning and execution coordination for coding agents.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -15,27 +15,38 @@
15
15
  "npm/bin/planr.js",
16
16
  "npm/native",
17
17
  "plugins",
18
- "presets",
19
- "evaluations",
20
- "website",
21
18
  "README.md",
22
19
  "LICENSE.md",
23
20
  "docs"
24
21
  ],
25
22
  "scripts": {
26
- "alchemy:check-runtime": "node scripts/check-alchemy-runtime.mjs",
27
23
  "build:native": "cargo build --release",
28
24
  "test": "cargo test",
29
25
  "pack:check": "npm pack --dry-run",
30
- "deploy:test": "node scripts/cloudflare-test.mjs deploy",
31
- "destroy:test": "node scripts/cloudflare-test.mjs destroy",
32
- "site:build": "node scripts/build-site.mjs",
33
- "site:check": "pnpm site:test && pnpm site:build",
34
- "site:test": "node --test website/*.test.mjs",
35
- "site:serve": "node website/serve.mjs"
36
- },
37
- "devDependencies": {
38
- "alchemy": "0.93.7"
26
+ "routing": "cargo run --manifest-path planr-routing/Cargo.toml --",
27
+ "docs:dev": "pnpm --filter @planr/docs dev",
28
+ "docs:alchemy:dev": "pnpm --filter @planr/docs alchemy:dev",
29
+ "docs:build": "pnpm --filter @planr/docs build",
30
+ "docs:start": "pnpm --filter @planr/docs start",
31
+ "docs:deploy": "pnpm --filter @planr/docs run deploy",
32
+ "docs:destroy": "pnpm --filter @planr/docs run destroy",
33
+ "docs:content": "pnpm --filter @planr/docs content",
34
+ "docs:typecheck": "pnpm --filter @planr/docs typecheck",
35
+ "docs:lint": "pnpm --filter @planr/docs lint",
36
+ "docs:verify-shell": "pnpm --filter @planr/docs verify:shell",
37
+ "docs:verify-onboarding": "cargo build --bin planr && pnpm --filter @planr/docs verify:onboarding && pnpm --filter @planr/docs verify:agent-recipes",
38
+ "docs:verify-agent-recipes": "cargo build --bin planr && pnpm --filter @planr/docs verify:agent-recipes",
39
+ "docs:verify-agent-markdown": "pnpm docs:build && pnpm --filter @planr/docs verify:agent-markdown",
40
+ "docs:verify-agent-journey": "pnpm --filter @planr/docs verify:agent-journey",
41
+ "docs:verify-agent-landing": "pnpm --filter @planr/docs verify:agent-landing",
42
+ "docs:verify-concepts": "cargo build --bin planr && pnpm --filter @planr/docs verify:concepts",
43
+ "docs:verify-maintenance": "pnpm --filter @planr/docs verify:maintenance",
44
+ "docs:verify-deployment": "pnpm --filter @planr/docs verify:deployment",
45
+ "docs:verify-release": "pnpm --filter @planr/docs verify:release",
46
+ "docs:verify-release-live": "pnpm --filter @planr/docs verify:release-live",
47
+ "docs:verify-clean-install": "pnpm --filter @planr/docs verify:clean-install",
48
+ "docs:reference:generate": "cargo build --bin planr && pnpm --filter @planr/docs reference:generate",
49
+ "docs:verify-reference": "cargo build --bin planr && pnpm --filter @planr/docs reference:check && pnpm --filter @planr/docs verify:reference"
39
50
  },
40
51
  "engines": {
41
52
  "node": ">=18"
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "planr",
3
3
  "description": "Skill-driven planning and execution loop for coding agents: one planr entry point, an autonomous planr-loop, and evidence-backed task graph skills powered by the planr CLI.",
4
- "version": "1.4.0",
4
+ "version": "1.5.1",
5
5
  "author": {
6
6
  "name": "instructa"
7
7
  },
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "planr",
3
- "version": "1.4.0",
3
+ "version": "1.5.1",
4
4
  "description": "Skill-driven planning and execution loop for coding agents: one $planr entry point, an autonomous $planr-loop, and evidence-backed task graph skills powered by the planr CLI.",
5
5
  "author": {
6
6
  "name": "instructa",
@@ -19,7 +19,7 @@
19
19
  "category": "Productivity",
20
20
  "defaultPrompt": [
21
21
  "Use $planr to plan a production-ready app from my idea.",
22
- "Use $planr-loop to ship one feature with verification until done."
22
+ "Use $planr to prepare my next feature and tell me the verified next step."
23
23
  ]
24
24
  }
25
25
  }
@@ -67,7 +67,7 @@ A worker subagent may take several items sequentially instead of being respawned
67
67
 
68
68
  Host wiring:
69
69
 
70
- - Codex: project agents in `.codex/agents/*.toml` preload the skill via `[[skills.config]]` (TOML templates in `agents/` next to this skill). Spawn explicitly: "spawn the planr_worker agent for item X". Keep `[agents] max_depth = 1`.
70
+ - When a repository routing bundle supplies host roles, follow its generated routing skill exactly. Otherwise treat the profile in the pick packet as advisory and use the host's current dispatch contract. Never infer effective model or effort from a declaration alone.
71
71
  - Claude Code: subagents preload via the `skills:` frontmatter field. The Planr plugin registers `planr-worker` and `planr-reviewer` automatically from its `agents/` directory; standalone installs copy them to `.claude/agents/`. The reviewer subagent is read-only except for `planr review` commands.
72
72
  - Cursor: project subagents in `.cursor/agents/*.md` (Markdown templates in `agents/` next to this skill; `planr install cursor` provisions them). Dispatch explicitly: `/planr-worker implement item X`, `/planr-reviewer review item X`. Parallel dispatches are safe — the map's pick lease keeps one owner per item.
73
73
  - Single-agent hosts: run worker and checker as separate sequential dispatches with a fresh read of map state in between; never carry the worker's self-assessment into the review step. The mode is recorded automatically: `review close` derives `review_mode` (`single_agent`/`independent`) from worker identity.