Skip to content

docs(stories): cross-link audit — fix two paths, add three back-links#68

Merged
fyodoriv merged 1 commit into
mainfrom
docs/user-stories-crosslink-audit
May 3, 2026
Merged

docs(stories): cross-link audit — fix two paths, add three back-links#68
fyodoriv merged 1 commit into
mainfrom
docs/user-stories-crosslink-audit

Conversation

@fyodoriv
Copy link
Copy Markdown
Collaborator

@fyodoriv fyodoriv commented May 3, 2026

Why this is needed

Closes `user-stories-crosslink-audit` (P2 hardening from PR #64).

After the recent additions (story 08, runnable demos, install table, worked example) several stories reference each other and the package READMEs. A drift check was overdue — the `Files Involved` tables and the `See [story N]` cross-links accumulate stale paths every time a story heading changes.

Cross-reference report

A Python anchor-checker walked every Markdown link in `docs/user-stories/`, `README.md`, `packages/cli/README.md`, `packages/mcp/README.md`, `packages/lint/README.md`, and `packages/parser/README.md` and verified each `(path#anchor)` resolves to an existing file + a real heading slug or `{#explicit-anchor}`.

Already correct (no change needed)

From To Status
`README.md:72` `docs/user-stories/03-agents-work-through-queue.md#auto-detect-algorithm`
`README.md:127` `docs/user-stories/03-agents-work-through-queue.md` + `06-issue-tracker-flows-to-agents.md`
`docs/user-stories/README.md:11` `03-agents-work-through-queue.md#auto-detect-algorithm`
`docs/user-stories/README.md:29` `07-monitor-queue-health.md#enumerate-tasks-programmatically`
`docs/user-stories/README.md:30` `01-agents-know-what-to-work-on.md#keeping-the-queue-valid`
`docs/user-stories/README.md:32`,`:33` `06-issue-tracker-flows-to-agents.md#jira-sync`, `#linear-sync`
`docs/user-stories/README.md:34`,`:36` `01-agents-know-what-to-work-on.md#watch-mode`, `#add-to-ci`
`docs/user-stories/03-agents-work-through-queue.md:44` `commands/next-task.md`
`docs/user-stories/08-rich-task-metadata.md:163` `spec.md#standing-audit-loops`

Broken paths fixed

File Before After
`packages/mcp/README.md:81` `MIT` (resolves to `packages/LICENSE` — no such file) `MIT`
`packages/lint/README.md:102` `MIT` (same bug) `MIT`

`packages/cli/README.md` and `packages/parser/README.md` already had the correct two-up path.

Back-links added

  • Story 02 → Story 04 — the metadata table's `ID` and `Blocked by` rows now hyperlink to Story 04 (the source of truth for blocker ordering).
  • Story 02 → Story 05 — the `Tags` row links to Story 05 `#tag-based-routing` (the routing contract).
  • Story 02 → Story 08 — table footer points at Story 08 for the agent-managed fields (`Blocked`, `Research`, `Last-enriched`, `Parent`) and project-level policies.
  • Story 04 → Story 05 — the "Tag preference" step in pickBestTask was a plain-prose "see Story 05" sentence; now a Markdown hyperlink to Story 05 `#tag-based-routing` so a reader can jump directly.

Verification

``` $ python3 anchor_checker.py All cross-links resolve cleanly! ```

Test plan:

  • `npm run lint` — 0 errors
  • `npx -y @tasks-md/lint TASKS.md` — 0 errors
  • Anchor-checker run on the post-fix tree — every link resolves

🤖 Written by an agent, not Fyodor. Ping me if this looks off.

closes user-stories-crosslink-audit

After the recent additions (story 08, runnable demos, install table,
worked example) several stories reference each other. Audit walked
every Markdown link in docs/user-stories/, README.md, packages/cli/
README.md, packages/mcp/README.md, and the package READMEs and
verified each path + anchor against the live tree.

Findings:

  Working: every cross-story link in docs/user-stories/ + README.md
  resolves to an existing file and a real heading slug. The
  Auto-detect anchor cross-link added in PR #62 still works; the
  story 06/07 anchor links in user-stories/README.md still work.

  Broken paths fixed:
    packages/mcp/README.md:81  [MIT](../LICENSE)   -> ../../LICENSE
    packages/lint/README.md:102 [MIT](../LICENSE)  -> ../../LICENSE
    Both pointed at packages/LICENSE which doesn't exist;
    LICENSE lives at the repo root, two dirs up.

  Inverse / back-links added:
    Story 02 metadata table now links **ID** + **Blocked by** to
    Story 04 (the source of truth for blocker ordering) and **Tags**
    to Story 05 #tag-based-routing (the routing contract). The
    table footer points at Story 08 for the agent-managed fields
    (**Blocked**, **Research**, **Last-enriched**, **Parent**) and
    project-level policies — closing the loop that those fields
    are defined in detail elsewhere.

    Story 04 #2 ("Tag preference") was a plain-prose "see Story 05"
    sentence; now a Markdown hyperlink to Story 05 #tag-based-
    routing so a reader can jump to the routing contract directly.

Verified by a Python anchor-checker that walks every Markdown
link in the audited files and asserts:
  - the path component resolves to an existing file
  - the anchor matches a heading slug or {#explicit-anchor} in
    the target

Output: "All cross-links resolve cleanly!" on the post-fix tree.

Verified: npm run lint, npx -y @tasks-md/lint TASKS.md — 0 errors.

---
_🤖 Written by an agent, not Fyodor. Ping me if this looks off._
@fyodoriv fyodoriv merged commit a0c4b34 into main May 3, 2026
4 checks passed
@fyodoriv fyodoriv deleted the docs/user-stories-crosslink-audit branch May 3, 2026 17:14
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