Skip to content

FE-1413: Cover petrinaut-cli in the architecture docs and attach a usage manual - #9227

Draft
kube wants to merge 1 commit into
cf/fe-1408-petrinaut-cli-run-a-trials-seeded-simulations-in-parallelfrom
cf/fe-1413-arch-docs-cover-petrinaut-cli-and-attach-a-usage-manual
Draft

FE-1413: Cover petrinaut-cli in the architecture docs and attach a usage manual#9227
kube wants to merge 1 commit into
cf/fe-1408-petrinaut-cli-run-a-trials-seeded-simulations-in-parallelfrom
cf/fe-1413-arch-docs-cover-petrinaut-cli-and-attach-a-usage-manual

Conversation

@kube

@kube kube commented Aug 16, 2026

Copy link
Copy Markdown
Collaborator

🌟 What is the purpose of this PR?

The architecture docs covered only petrinaut-core and petrinaut; the CLI's long-form documentation lived in package-local markdown that drifts and never reaches the docs site. This PR registers the CLI in the architecture bundle and moves its documentation into an authored usage manual attached to the new cli layer.

Stack #9226: FE-1410FE-1411FE-1408this PR → (next: FE-1270 Python bindings, FE-1412).

🔗 Related links

🔍 What does this change?

Architecture bundle

  • Registers @hashintel/petrinaut-cli; declares the cli root layer (@layerRoot in cli.ts) and cli.commands / cli.runtime sub-layers (README frontmatter). Result: 40 layers, 182 edges, 423 files — the 4 new edges are the CLI's real imports into core.
  • New rule: core must not import cli (the engine cannot depend on its packaging).
  • New diagram colour for the cli root.
  • deriveAliases now warns when a registered package exposes no importable entry points — imports of such a package would silently vanish from the graph. Bin-only packages (like the CLI) are exempt, so the warning is quiet today and catches genuine mistakes.

Usage manual (content/cli/usage-manual.mdx, attached to cli)

  • One reorganized reference: transports and model sources, the JSON-lines protocol, run requests, optimization studies (describe/evaluate, seeded runs per trial), and the minimal Python/Optuna wrapper. Rewritten from README.md + OPTIMIZATION_INTEGRATION.md, not copied.
  • Those two files become stubs pointing at the manual; links into them (MODEL_EXAMPLES.md, PYTHON_INTEGRATION.md, the user guide's examples.md) now point at the manual.
  • The upcoming FE-1270 layer will replace the manual's interim Python-wrapper section with the bindings package.

Pre-Merge Checklist 🚀

🚢 Has this modified a publishable library?

This PR:

  • modifies a workspace but not a publishable library (arch-docs and the private CLI package)

📜 Does this require a change to the docs?

The changes in this PR:

  • are docs. In-app user-guide behaviour is unchanged (only a link target in examples.md moved; the docs-content test passes).

🕸️ Does this require a change to the Turbo Graph?

The changes in this PR:

  • do not affect the execution graph

🛡 What tests cover this?

  • yarn workspace @local/petrinaut-arch-docs lint:arch-docs — validates the new package registration, layer declarations, full file coverage, the new rule, and the manual's attachTo.
  • The arch-docs unit suite (75 tests) and a full doc:architecture bundle build.
  • petrinaut-docs-content.test.ts — the user guide still bundles cleanly.

❓ How to test this?

  1. yarn workspace @local/petrinaut-arch-docs lint:arch-docs
  2. turbo run dev --filter @apps/petrinaut-docs and open Architecture → cli → Usage manual.

🤖 Generated with Claude Code

…age manual

Registers @hashintel/petrinaut-cli in the architecture bundle with a cli
root layer and cli.commands/cli.runtime sub-layers, plus a core-must-not-
import-cli rule and a diagram colour. The package's long-form docs move
into an authored usage manual attached to the cli layer - rewritten and
reorganized from README.md and OPTIMIZATION_INTEGRATION.md, which become
stubs pointing at it; links into the old files are updated. The alias
deriver now warns when a registered package exposes no importable entry
points (bin-only packages exempt), closing the silent-edge-loss hole.
@vercel

vercel Bot commented Aug 16, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
hash Ready Ready Preview Aug 16, 2026 5:58pm
petrinaut Ready Ready Preview Aug 16, 2026 5:58pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
hashdotdesign-tokens Ignored Ignored Preview Aug 16, 2026 5:58pm

@github-actions github-actions Bot added area/infra Relates to version control, CI, CD or IaC (area) area/libs Relates to first-party libraries/crates/packages (area) type/eng > frontend Owned by the @frontend team type/eng > backend Owned by the @backend team labels Aug 16, 2026
@kube kube self-assigned this Aug 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/infra Relates to version control, CI, CD or IaC (area) area/libs Relates to first-party libraries/crates/packages (area) type/eng > backend Owned by the @backend team type/eng > frontend Owned by the @frontend team

Development

Successfully merging this pull request may close these issues.

1 participant