Skip to content

docs: make the user guide self-contained Starlight source - #79

Merged
davideimola merged 1 commit into
mainfrom
docs/guide-starlight-ready
Jul 30, 2026
Merged

docs: make the user guide self-contained Starlight source#79
davideimola merged 1 commit into
mainfrom
docs/guide-starlight-ready

Conversation

@davideimola

Copy link
Copy Markdown
Contributor

docs/guide/ becomes content source for a Starlight site living in a separate repository, rather than documentation meant to be read on GitHub. Where the two readers conflict, Starlight wins — that trade-off, and the reasoning behind it, is recorded in ADR 0022.

What changed

  • 18 relative links removed — 15 into docs/adr/, one to CONTEXT.md, one to a design doc, one to the Dockerfile. The rationale a user actually needs is absorbed into prose in their own language; the rest is cut. Nothing in the guide now points at an ADR, a design document or a source path.
  • Frontmatter on every page (title, description, sidebar.order), body <h1>s dropped since Starlight renders the heading from title. Ordering is all-or-nothing in an autogenerated sidebar — a page without order sinks to Number.MAX_VALUE — so all eight declare one.
  • README.mdindex.md, the section landing page.
  • 18 internal cross-references rewritten as absolute /guide/… paths, because Astro never rewrites relative .md links.
  • Blockquote callouts → typed asides: caution for security and spend, tip for recommendations, note for version and migration notes.
  • Domain vocabulary glossed inline (Person, SOUL, MEMORY) now that CONTEXT.md is unreachable from here, and Argus's Service principal disambiguated from the Kubernetes Service throughout the hosting guide.
  • Dropped a cp pkg/skill/builtin/... command that only worked for somebody who had cloned the repo.

AGENTS.md states the rule so it survives; the CONTEXT.md Service entry gains the Kubernetes disambiguation.

Requirements this places on the site repository

All three are load-bearing and none can be satisfied from this repo:

  1. Mount the folder at src/content/docs/guide/. Starlight's docsLoader() hard-codes its base to <srcDir>/content/docs and does not expose it, so the folder must physically appear there — submodule or CI sync. Mounted elsewhere, every internal link breaks silently.
  2. Relabel the sidebar groups in astro.config.mjs. An autogenerated group takes the directory name verbatim, so channels/ and deployment/ render lowercase. No _meta.json, no frontmatter override, no per-directory config can fix that from the content side.
  3. Serve from the domain root. The internal links are root-absolute and hand-written; Astro does not inject its base into those, so a site deployed under a sub-path breaks all of them.

The Starlight conventions relied on here were verified against Starlight 0.41.5 / Astro 7.1.6, with sources pinned to commit SHAs, in docs/research/starlight-content-conventions.md.

Known costs, accepted

  • docs/guide/ no longer reads well on GitHub: internal links point at site slugs, :::caution shows as literal text, and the folder has no landing page because GitHub does not render index.md.
  • Some rationale now exists twice — once in an ADR, once as guide prose — and the two can drift. Nothing enforces the rule but the AGENTS.md section; a CI check would be a grep and was deliberately left out to keep this change scoped to documentation.

Follow-ups, not addressed here

  • No documented way to fork a built-in skill. Removing the cp leaves a gap: argus skill ls shows only name and description, and the body is not exportable from the CLI. Closing it needs a command (argus skill export), not a doc change.
  • Two claims in skills.md contradict CONTEXT.md. The page states that skills are an analyst+ capability viewers cannot enumerate, and that RBAC is enforced at the tool layer. The glossary says list_skills/read_skill sit in every Session's registry whatever the Role, and calls Tool-layer RBAC a no-op today. Left untouched: correcting them means publicly documenting an unenforced control, which is a communication decision rather than a typo.

docs/guide/ becomes content source for a Starlight site living in a separate
repository, rather than documentation meant to be read on GitHub. Where the
two readers conflict, Starlight wins.

- Remove all 18 relative links leaving the folder (15 into docs/adr/, one to
  CONTEXT.md, one to a design doc, one to the Dockerfile). The rationale a
  user needs is absorbed into prose in their own language; the rest is cut.
- Add title/description/sidebar.order frontmatter to every page and drop the
  body H1s, which Starlight renders from the title. Ordering is all-or-nothing
  there, so all eight pages declare one.
- Rename README.md to index.md as the section landing page.
- Rewrite the 18 internal cross-references as absolute /guide/... paths, since
  Astro never rewrites relative .md links.
- Convert the blockquote callouts to typed asides: caution for security and
  spend, tip for recommendations, note for version and migration notes.
- Gloss domain vocabulary inline (Person, SOUL, MEMORY) now that CONTEXT.md is
  not reachable from here, and disambiguate Argus's Service principal from the
  Kubernetes Service in the hosting guide.
- Drop a `cp pkg/skill/builtin/...` command that only worked for someone who
  had cloned the repo.

ADR 0022 records the decision, the GitHub-versus-Starlight trade-off and the
requirements this places on the site repository. AGENTS.md states the rule so
it survives. The Starlight conventions it relies on were verified against
0.41.5 / Astro 7.1.6 and are cited under docs/research/.
@davideimola
davideimola merged commit 2c273b9 into main Jul 30, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant