Skip to content

Add frontmatter and sidebar ordering to docs/ for the new docs site - #558

Merged
HappyDevs1 merged 3 commits into
mainfrom
docs-frontmatter
Sep 8, 2026
Merged

Add frontmatter and sidebar ordering to docs/ for the new docs site#558
HappyDevs1 merged 3 commits into
mainfrom
docs-frontmatter

Conversation

@HappyDevs1

@HappyDevs1 HappyDevs1 commented Sep 7, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Adds title/description YAML frontmatter to every file in docs/, required by the new Automators docs site (Fumadocs-based, see automators-com/docs) — without it, next build there fails outright.
  • Removes each file's leading # Heading line since the site renders the title separately; left in, it would show twice on every page.
  • Splits three very long single-file pages into focused, topic-grouped folders — inspired by loopedautomation/agent-framework's docs structure (many short single-topic files + "---Section---" separators in meta.json for sidebar grouping):
    • authoring.md (1682 lines) → authoring/ (13 pages)
    • getting-started.md (1426 lines) → getting-started/ (13 pages)
    • agent-testing.md (1185 lines) → agent-testing/ (8 pages)
  • Adds meta.json to each new folder and reorganizes the root docs/meta.json with ---Introduction---, ---Testing agents---, ---Guides---, ---Reference---, ---Behind the scenes--- section headers.
  • Follow-up commit: fixes every internal link that pointed at the old single-file paths/anchors (e.g. multi-surface.mdauthoring.md#multi-surface-flows-apps-and-in-blocks is now authoring/multi-surface-flows.md), adjusting relative path depth where a link now crosses folders.

Not touched — needs a decision

docs/loop/ (corpus.yaml, ledger.yaml, milestones/m2-falsifiability.md) looks like internal planning content, not documentation. It has no frontmatter, so it's excluded from the site by the same rule as any other file missing a title — but flagging that it may be worth moving docs/loop/ out of docs/ entirely, since that folder is now effectively public-facing.

Test plan

  • Verified locally against the docs site: next build succeeds, 152 pages generated (up from the previous flat structure)
  • Confirmed docs/loop/milestones/m2-falsifiability.md correctly does not publish (404s)
  • Spot-checked rendered pages in a browser: correct title/description, sidebar order and grouping matches meta.json, no duplicate heading, no leaked frontmatter
  • Verified fixed internal links resolve to their new routes in the compiled HTML
  • Maintainer: confirm titles/descriptions, page groupings, and docs/loop/ disposition

The new Automators docs site (docs.automators.com, see
automators-com/docs) renders each product's docs/ folder with Fumadocs,
which requires title (and reads description) from YAML frontmatter, and
uses a meta.json for sidebar ordering. Neither existed here yet, so the
site's build failed outright on every one of these 17 files
("title: Invalid input: expected string, received undefined").

- Added `title`/`description` frontmatter to every docs/*.md file, and
  removed each file's leading `# Heading` line since the site renders
  the title separately (DocsTitle) — left in place it would have shown
  twice.
- Added docs/meta.json ordering pages by what a first-time reader needs:
  getting-started, authoring, recording, self-help, agent-testing,
  capture, multi-surface first, then the rest.

Not touched: docs/loop/ (corpus.yaml, ledger.yaml,
milestones/m2-falsifiability.md) looks like internal planning content
rather than documentation, and now that files need frontmatter to
publish, it's excluded from the site by the same rule rather than a
special case — flagging here in case docs/loop/ should move out of
docs/ entirely so it doesn't sit inside what's now a public-facing
folder.
Copilot AI lite review requested due to automatic review settings September 7, 2026 15:00

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

authoring.md (1682 lines), getting-started.md (1426 lines), and
agent-testing.md (1185 lines) were each a single page covering many
subtopics — on the new docs site that meant one very long page per
sidebar entry, with the reader scrolling past unrelated sections to
find the next topic.

Inspired by loopedautomation/agent-framework's docs/ structure (many
short, single-topic files plus "---Section---" separators in meta.json
for sidebar grouping, rather than deep folder nesting):

- authoring.md -> authoring/ (13 pages: index, actions, assertions,
  variables-and-exports, iframes-and-cookies, repeating, desktop-apps,
  multi-surface-flows, out-of-band-assertions, visual-and-network,
  agent-steps, security-controls, troubleshooting)
- getting-started.md -> getting-started/ (13 pages, one per surface/
  concern: record-and-replay, python-api, live-app-tests, web-flows,
  test-context-seeding, sap-flows, vision-flows, api-flows, agent-flows,
  resilience, secrets-and-config, roadmap)
- agent-testing.md -> agent-testing/ (8 pages: index, concept,
  spec-shape, running-agent-flows, phasing, security, review-notes,
  status-and-scope)

Each new page keeps title/description frontmatter split from the
original file's headings, and each folder gets its own meta.json for
page order. Root docs/meta.json now groups the top-level pages under
---Introduction---, ---Testing agents---, ---Guides---, ---Reference---,
and ---Behind the scenes--- headers.

Verified against the docs site locally: next build succeeds (152 pages,
up from the previous flat structure), and the reorganized sidebar/pages
render correctly in a browser.

Known follow-up (next commit): some internal links still point at
anchors in the old mega-pages (e.g. multi-surface.md linking to
authoring.md#multi-surface-flows-apps-and-in-blocks, now
authoring/multi-surface-flows.md) and need updating to the new paths.
The previous commit split authoring.md, getting-started.md, and
agent-testing.md into per-topic folders, but left cross-references
elsewhere pointing at the old single-file paths and anchors (e.g.
multi-surface.md linking to
authoring.md#multi-surface-flows-apps-and-in-blocks, which is now
authoring/multi-surface-flows.md).

Rewrote every [text](old-file.md#anchor) link across docs/ to its new
location, adjusting the relative path prefix for files that moved
folder depth (e.g. a link from authoring/desktop-apps.md to
getting-started.md now needs ../getting-started/...).

Verified against the docs site: next build succeeds, and the compiled
HTML resolves the fixed links to their correct new routes (checked
multi-surface.md's link to authoring/multi-surface-flows and
authoring/desktop-apps.md's link to
getting-started/live-app-tests#deploying-a-uwp-app-on-a-ci-runner).
@HappyDevs1
HappyDevs1 merged commit 7ba587e into main Sep 8, 2026
9 checks passed
@HappyDevs1
HappyDevs1 deleted the docs-frontmatter branch September 8, 2026 08:23
HappyDevs1 added a commit that referenced this pull request Sep 8, 2026
Merging #558 (which split docs/authoring.md and docs/getting-started.md
into per-topic folders) broke CI on main: three tests still referenced
the old single-file paths, two of them via include_str!, which fails to
compile rather than fail at runtime.

- rules::no_documented_example_shows_a_shape_the_grammar_refuses
  (flowproof-agent): its PAGES list named docs/authoring.md and
  docs/getting-started.md directly via include_str!. Expanded it to
  list every file under docs/authoring/ and docs/getting-started/
  individually — a strict improvement, since a failure now names the
  specific split file rather than a huge merged one.
- the_quickstart_quotes_the_shipped_agent_example_verbatim
  (flowproof-cli): also used include_str! on docs/getting-started.md to
  verify the README and docs both quote the same shipped example
  verbatim. The quoted section moved to
  docs/getting-started/record-and-replay.md; updated the path.
- every_visible_cli_flag_is_mentioned_in_the_docs /
  every_visible_subcommand_is_mentioned_in_the_docs
  (flowproof-cli/documented_flags.rs): built its corpus with a
  non-recursive `read_dir(docs/)`, so it silently stopped seeing
  anything under the new docs/authoring/ and docs/getting-started/
  folders. 15 real flags (record --vars, run --strict, doctor
  --prompt, etc. — all still documented, just no longer in a page this
  test could see) started failing as "undocumented". Made the corpus
  builder recurse into subfolders.

Verified locally, not just by reasoning about it: `cargo clippy
--workspace --all-targets --all-features -- -D warnings` (CI's exact
command) is clean, and `cargo test --workspace --all-features` passes
except for doctor_ai_e2e, which fails in this sandbox because of
ambient AI credentials in the local environment (asserts "no key ->
model call fails" but a real call succeeds here) — unrelated to docs/
and confirmed not touching any docs path.
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.

2 participants