# Source Mappings

This is the manifest the `sync-rails-team-content` skill reads to check this site's embedded excerpts for drift against `~/Work/mrgrampz-marketplace/agentic-teams/teams/rails-agentic-engineering-team/` (the `rails-agentic-engineering-team` source repo, GitHub remote `https://github.com/revans/rails-agentic-engineering-team`, branch `master`).

Every row below is one place this site quotes real content from that repo. Each row names: the site file, the exact JS object/field holding the content, the source repo file and section header it was copied from, and the GitHub URL (with anchor) currently embedded as that entry's `sourceUrl`. When the source repo changes, this file is what tells a sync pass exactly what to re-check — do not re-derive this mapping by scanning the site's JS.

## Architecture page — artifact ledger modals

Site file: `architecture/index.html` (trigger buttons) + `assets/architecture.js` (content object `artifactAnatomyData`)

| Row key | Ledger row | Source file | Source section | Excerpt style | `sourceUrl` |
|---|---|---|---|---|---|
| `dis` | 01 Discovery brief | `agents/discovery.md` | Brief Format | Full section, verbatim | `agents/discovery.md#brief-format` |
| `arc` | 02 Architecture spec | `agents/architect.md` | Specification Format | Every header (14), one-line summary each — full section is too long for the modal | `agents/architect.md#specification-format` |
| `des` | 03 Design spec | `agents/design.md` | Design Specification Format | Every header (9), one-line summary each | `agents/design.md#design-specification-format` |
| `eng` | 04 Engineer report · round 1 | `agents/engineer.md` | Engineer Report Format | Full section, verbatim | `agents/engineer.md#engineer-report-format` |
| `cr` | 05 Code review | `agents/code-review.md` | Report Format | Full section, verbatim | `agents/code-review.md#report-format` |
| `sec` | 06 Security review | `agents/security-review.md` | Report Format | Full section, verbatim | `agents/security-review.md#report-format` |
| `perf` | 07 Performance review | `agents/performance-review.md` | Report Format | Full section, verbatim | `agents/performance-review.md#report-format` |
| `fid` | 08 Fidelity review | `agents/fidelity-review.md` | Report Format | Full section, verbatim | `agents/fidelity-review.md#report-format` |
| `eng2` | 09 Engineer report · round 2 | `agents/engineer.md` (format) + `agents/orchestrator.md` (sequencing) | Engineer Report Format (headers only, reused) + Artifact Paths (sequence-tracker text, verbatim) | Headers list + verbatim mechanics excerpt | `agents/orchestrator.md#artifact-paths` |
| `reviews2` | 10–13 Four reviews · round 2 | `agents/code-review.md`, `agents/security-review.md`, `agents/performance-review.md`, `agents/fidelity-review.md` (formats, headers only) + `agents/orchestrator.md` (round math / escalation) | Each reviewer's own Report Format (headers only) + Round Tracking (escalation mechanics, verbatim) | Headers list per reviewer + verbatim mechanics excerpt | `agents/orchestrator.md#round-tracking` |

Note on `eng2` and `reviews2`: these two rows each cite two source locations (a format definition + orchestrator mechanics) because the row itself represents "the same document format as an earlier row, plus what's genuinely new about round 2." If a sync pass finds the *format* changed, go fix the earlier row (`eng` for `eng2`, `cr`/`sec`/`perf`/`fid` for `reviews2`) — these two rows only need re-checking against `orchestrator.md`'s sequencing/escalation text specifically.

## Architecture page — completion-flow diagram

Site file: `architecture/index.html` (`.completion-flow` article steps, static markup — not JS-driven, no content-data object)

| Row key | Step | Source file | Source section | Excerpt style | `sourceUrl` |
|---|---|---|---|---|---|
| `stage9` | 09 Learning loop check | `agents/orchestrator.md` | Stage 9 — Learning Loop Check | Paraphrased summary, not verbatim — one sentence capturing the "nudge in the final report, never a gate, never invokes log-analyst itself" behavior | `agents/orchestrator.md#stage-9--learning-loop-check` |

Steps 07 (Synthesis), 07b (Issue filing), 07c (Pull request), and 08 (Outcome recording) in the same diagram are not yet tracked here — they predate this table and should be added on a future sync pass rather than backfilled speculatively in this one.

## Agents page — contract-question modals

Site file: `agents/index.html` (trigger buttons) + `assets/agents.js` (content object `agentAnatomyData`)

All 7 rows are grounded in a single source file, `agents/architect.md`, deliberately — one consistent "reference implementation" narrative across all 7 questions, matching how the Skills mast page frames scope-capture as its own single reference implementation.

| Row key | Contract question | Source file | Source section | Excerpt style | `sourceUrl` |
|---|---|---|---|---|---|
| `identity` | Identity | `agents/architect.md` | Identity | Full section, verbatim (+ frontmatter name/description/model) | `agents/architect.md#identity` |
| `input` | Input | `agents/architect.md` | What You Do (step 1) + Codebase Audit | Full excerpt, verbatim | `agents/architect.md#codebase-audit` |
| `output` | Output | `agents/architect.md` | What You Do (step 6) + What You Cannot Do (file-write line) | Full excerpt, verbatim | `agents/architect.md#what-you-do` |
| `tools` | Tools | `agents/architect.md` | frontmatter `tools:` list | Full frontmatter block, verbatim | `agents/architect.md` (no anchor — frontmatter has no heading) |
| `skills` | Skills | `agents/architect.md` | frontmatter `skills:` list | Full frontmatter block, verbatim | `agents/architect.md` (no anchor) |
| `prohibitions` | Prohibitions | `agents/architect.md` | What You Cannot Do | Full section, verbatim | `agents/architect.md#what-you-cannot-do` |
| `evidence` | Evidence | `agents/architect.md` | Activity Logging | Partial — full section is long; kept the lifecycle start/end, three of nine "log a decision when" bullets, decision ID format, and the mandatory pre-close reflection rule | `agents/architect.md#activity-logging` |

Note on `evidence`: this is the one row in this whole manifest that's an intentional partial excerpt of a section rather than "full" or "every header" — `agents/architect.md`'s Activity Logging section has 9 "log a decision when" bullets and this excerpt keeps only 3, chosen as the most illustrative. If a future sync pass is expanding modals to a stricter completeness bar (as happened to Architecture's `arc`/`des` rows and the Skills page's `architect-spec-format` row), this row is the next candidate — Activity Logging has no natural "headers" to enumerate the way a 14-section spec format does, so "every header" doesn't directly apply; the analogous move would be listing all 9 decision-trigger bullets instead of 3.

## Skills page — skill-form example cards

Site file: `skills/index.html` (trigger buttons) + `assets/skills.js` (content object `skillAnatomyData`)

| Row key | Card | Source file | Source section | Excerpt style | `sourceUrl` |
|---|---|---|---|---|---|
| `rails-principles` | Domain policy | `skills/rails-principles/SKILL.md` | Whole file (frontmatter + Single Responsibility + Convention Is the Interface) | Full frontmatter + two sections, verbatim | `skills/rails-principles/SKILL.md` (no anchor — excerpt spans multiple sections from the top of the file) |
| `architect-spec-format` | Artifact schema | `skills/architect-spec-format/SKILL.md` | Whole file (frontmatter + Single Responsibility + The 14 Sections, all headers) | Full frontmatter + Single Responsibility verbatim; The 14 Sections shown as all 14 headers with a one-line summary each, matching the same completeness bar as the Architecture page's `arc` row | `skills/architect-spec-format/SKILL.md` (no anchor) |
| `scope-capture` | Workflow safeguard | `skills/scope-capture/SKILL.md` | Whole file (frontmatter + The Trigger + Which Bucket, partial + one real example) | Full frontmatter + Trigger + Which Bucket verbatim; one real "Scope ideas noticed" example reused from the skill's own doc | `skills/scope-capture/SKILL.md` (no anchor) |

The three Skills-page rows were built in an earlier session pass than the Architecture-page rows above. `architect-spec-format` has since been brought up to the same "every header, minimum" bar as Architecture's `arc` row. `rails-principles` and `scope-capture` were already reasonably grounded (real frontmatter, real headers, real body text) and have not been re-checked against this bar — worth a dedicated sync pass to confirm they're still current.

## Self-learning page — pattern laboratory tabs

Site file: `self-learning/index.html` (tab buttons) + `assets/self-learning.js` (content object `patterns`)

| Row key | Tab | Source file | Source section | Excerpt style | `sourceUrl` |
|---|---|---|---|---|---|
| `promotion` | Promotion | `agents/log-analyst.md` | Pattern Type 1: Promotion Candidates | Paraphrased summary | `agents/log-analyst.md#pattern-type-1-promotion-candidates` |
| `antipattern` | Anti-pattern | `agents/log-analyst.md` | Pattern Type 2: Anti-Pattern Candidates | Paraphrased summary | `agents/log-analyst.md#pattern-type-2-anti-pattern-candidates` |
| `gap` | Artifact gap | `agents/log-analyst.md` | Pattern Type 3: Upstream Artifact Gaps | Paraphrased summary | `agents/log-analyst.md#pattern-type-3-upstream-artifact-gaps` |
| `delta` | Outcome delta | `agents/log-analyst.md` | Pattern Type 4: Outcome Deltas | Paraphrased summary | `agents/log-analyst.md#pattern-type-4-outcome-deltas` |
| `quality` | Quality | `agents/log-analyst.md` | Pattern Type 5: Quality Correlators | Paraphrased summary | `agents/log-analyst.md#pattern-type-5-quality-correlators` |
| `skill` | Skill candidate | `agents/log-analyst.md` | Pattern Type 6: Skill Candidates from Findings | Paraphrased summary | `agents/log-analyst.md#pattern-type-6-skill-candidates-from-findings` |
| `inputquality` | Input quality | `agents/log-analyst.md` | Pattern Type 7: Input Quality Trends & Cross-Agent Reality Checks (both 7a and 7b) | Paraphrased summary covering both sub-patterns in one tab | `agents/log-analyst.md#pattern-type-7-input-quality-trends--cross-agent-reality-checks` |

Note on `inputquality`: this is the one tab that represents two named sub-patterns (7a trend analysis, 7b the engineer-rating-vs-review-outcome cross-agent check) rather than one Pattern Type. It was kept as a single tab, matching how the source file itself presents both under one `#### Pattern Type 7` header rather than as two separate numbered patterns — if a future pass wants to split it into two tabs, the source already gives each half its own `**7a —**` / `**7b —**` lead-in to key off.

## Agent logging page — unconditional-logging callout

Site file: `agent-logging/index.html` (`typed-callout key` box, "The one exception") — no companion JS object; this is static markup, not a JS-driven tab

| Row key | Callout | Source file | Source section | Excerpt style | `sourceUrl` |
|---|---|---|---|---|---|
| `input-quality-unconditional` | "The one exception" | `agents/discovery.md`, `agents/engineer.md`, `agents/fidelity-review.md` | Activity Logging — the "Always log, before closing — not conditional on anything going wrong" `input_quality` paragraph in each | Paraphrased synthesis across all three files' wording of the same unconditional rule | `agents/engineer.md#activity-logging` |

Note on `input-quality-unconditional`: three source files state the same unconditional-logging rule with agent-specific detail (discovery rates the brief-or-user-framing; engineer and fidelity-review each log one rating per upstream artifact rather than blending). The callout synthesizes across all three rather than quoting one verbatim, so `engineer.md` was picked as the single `sourceUrl` anchor because it's the row this callout leans on hardest (the "per-artifact, not blended" framing). If a sync pass wants per-file precision instead, this row should split into three.

## Install page

Site file: `install/index.html` (mast tabs, callouts, inspect-modal markup) + `assets/install.js` (content objects `installScripts` and `installAnatomyData`)

| Row key | Element | Source file | Source section | Excerpt style | `sourceUrl` |
|---|---|---|---|---|---|
| `five-scripts` | Mast "Five scripts, one contract" tab console | `docs/installer.md` | The Five Scripts | Full table content, restructured into one interactive panel per script — `does`/`why` fields are the table's own cell text, verbatim; the `statuses` field is a synthesis of the status-contract prose elsewhere in the doc, not a table cell | `docs/installer.md#the-five-scripts` |
| `graphql-callout` | "Why a GraphQL mutation" callout, 03 / centerpiece section | `docs/installer.md` | Status Field Options | Full section, verbatim | `docs/installer.md#status-field-options` |
| `project-status-modal` | Inspect-modal triggered by "Inspect bin/team-setup-project-status" | `bin/team-setup-project-status` | Header comment (whole file has no markdown sections) | Partial — file header comment (lines 1–15) verbatim, plus the read-existing-options/append-one/resend-full-list GraphQL logic (~lines 79–115) verbatim; omits argument parsing and the `sh()`/`report()` helpers, which are mechanical boilerplate | `bin/team-setup-project-status#L1-L15` (GitHub line-range anchor — no header anchor exists on a non-markdown file) |
| `idempotency-callout` | "Idempotency, verbatim from the docs" callout, 04 / boundary section | `docs/installer.md` | Idempotency | Full section, verbatim | `docs/installer.md#idempotency` |
| `manual-gap-callout` | "A different kind of gap" callout, 02 / automated-vs-manual section | `docs/installer.md` | Things to Know | Partial — first bullet only (the `bin/agent-log` vendoring gap), lightly reworded to read as a standalone sentence rather than quoted verbatim | `docs/installer.md#things-to-know` |
| `cannot-do-list` | "What it cannot do" list, 04 / boundary section | `agents/installer.md` | What You Cannot Do | Partial — 4 of 6 bullets kept (the directory-confirmation and team.yml-overwrite bullets are covered elsewhere on the page); two of the four combine adjacent bullets into one line rather than quoting each verbatim | `agents/installer.md#what-you-cannot-do` |

Note on `manual-gap-callout` and `cannot-do-list`: these two rows are the least strictly verbatim in this manifest — both reword source bullets into standalone sentences for the page's flow rather than quoting the exact source string. If a future sync pass is tightening excerpts to the stricter "verbatim or every-header" bar applied elsewhere (Architecture's `arc`/`des`, Skills' `architect-spec-format`), these two are the next candidates, alongside Agents page's `evidence` row noted above.

## What "drift" means for a row here

- **Text changed** — the cited section's wording changed but the header structure is the same. Update the embedded excerpt to match, keeping whatever excerpting style (full vs. headers-only) this table already records for that row.
- **Section renamed** — the header text changed. The GitHub anchor is derived from the header (lowercase, spaces → hyphens, punctuation stripped), so a rename always means the `sourceUrl` in this table (and in the site's JS) needs updating too.
- **Section moved** — same header, different file or different position. Update the "Source file" column here and the embedded `file:` field on the site.
- **Section removed** — the cited header no longer exists anywhere in the source. Do not invent a replacement. Flag it and leave the row's site content untouched until a human decides what the row should show instead.
