Skip to content

Commit 8db928e

Browse files
committed
Commit improvements doc following last run
1 parent 5c04f35 commit 8db928e

1 file changed

Lines changed: 169 additions & 0 deletions

File tree

docs/.curation/improvements.md

Lines changed: 169 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,175 @@ ones under a dated section. The most recent pass is at the top.
99

1010
---
1111

12+
# Update-mode pass — 2026-07-21 (6 sources)
13+
14+
This was an **update-mode** run. The engine re-documented exactly these 6 sources, and ONLY their
15+
distillation logs were curated as part of this run (the curator was handed the explicit source list —
16+
see the `.logs/` staleness item below, now confirmed mitigated):
17+
18+
- **`app-template`** (rails-template) — re-documented at new SHA `6cc2443…`.
19+
- **`documentai-api`** (application-template) — re-documented at new SHA `7c7f30c…`.
20+
- **`oscer`** (example-app) — materially drifted; re-documented at new SHA `c53e711…`.
21+
- **`platform-cli`** (platform-cli) — re-documented at new SHA `57d5d5c…`.
22+
- **`template-infra`** (infra-template) — re-documented at new SHA `80a7cc8…`.
23+
- **`template-infra-azure`** (infra-template) — re-documented at new SHA `e10a383…`.
24+
25+
**All 6 produced a distillation log. None were missing.** `.logs/` still holds 5 additional logs
26+
from prior runs (`strata-sdk`, `strata-template-rules-engine-catala`, `strata-unemployment`,
27+
`template-application-flask`, `template-application-nextjs`); those were NOT re-documented this run
28+
and were correctly excluded from this curation.
29+
30+
## Registry health this run: clean
31+
32+
Every cross-link key the 6 documenters used already existed; **no missing-key hard-fail, no new
33+
registry keys needed this run.** Notably `oscer` added a new `components` example doc, plus
34+
`attribute-types/array` (parity with `range`), `DocAiResult`, and `integrates_with: [documentai-api]`
35+
— all resolved against pre-seeded registry entries (oscer log lines 47-58, 81-92). The
36+
`platform-cli` `manages` edges to `template-application-nextjs`/`-flask` again surfaced as the
37+
intended `build_graph` `GAP:` lines (soft-deprecated canonical ids), not lint failures (platform-cli
38+
log lines 109-116) — consistent with the P3 below.
39+
40+
---
41+
42+
## P0 — Generated docs were silently corrupted by leaked tool-call XML; only caught by a documenter's eye
43+
44+
`template-infra-azure`'s documenter found that **all 5 pre-existing docs ended with stray
45+
`</content></invoke>` tags leaked from a prior write** and had to strip them during the rewrite
46+
(azure log lines 20-22). Separately, the **`oscer` distillation log itself ends with a stray
47+
`</content>` tag** (oscer log line 93). The engine's doc-write path is emitting literal tool-call
48+
markup (`</invoke>`, `</content>`, `<parameter …>`) into the files it writes.
49+
50+
This is a "never silently drop" violation: the corruption shipped in a prior cycle's output, sat
51+
undetected through lint + verify→fix + graph builds, and was only removed because *this* run happened
52+
to rewrite those files. A source that was skipped/unchanged would have kept the corruption
53+
indefinitely. `lint_docs` validates frontmatter but does not scan bodies for leaked markup.
54+
55+
**Action (two parts):**
56+
1. Add a `lint_docs` check that hard-fails on stray tool-call XML in any doc body or distillation log
57+
(`</invoke>`, `</content>`, `<parameter`, and a bare trailing `</...>` that isn't legitimate
58+
HTML/markdown). This turns a silent corruption into a pipeline stop, per the invariant.
59+
2. Harden the `source-doc.md` write step so the agent never serializes tool-call scaffolding into
60+
file content — the recurrence across azure (docs) and oscer (log) says this is systemic, not a
61+
one-off fat-finger.
62+
63+
## P1 — Update mode cannot diff: the prior `source_ref.ref` SHA is absent from the (shallow) clone
64+
65+
Three of the six re-document runs could not compare old→new because the previously-documented commit
66+
was not in the local checkout:
67+
68+
- **`template-infra`**: "the previously-documented SHA `d2b569e3…` is not present in this checkout's
69+
object history (shallow/updated clone), so a direct `git diff` … was not possible" (line 17-19).
70+
- **`template-infra-azure`**: "shallow clone (depth 1); the previously-documented SHA `f930f2ba…` is
71+
not present locally, so no upstream diff was possible" (lines 8-10).
72+
- **`oscer`**: material drift (exemption→exclusion rename, new three-step flow, expanded outcome
73+
enum, new form base class) forced a **full rewrite of every doc** rather than a scoped edit (lines
74+
22-44).
75+
76+
The fallback in each case was to **re-verify every load-bearing claim by hand** against the working
77+
tree — expensive, and it puts the burden of catching drift on exhaustive manual reading rather than a
78+
diff. Update mode's whole premise (only touch what changed) is undercut when the documenter can't see
79+
what changed.
80+
81+
**Action:** the setup/clone step should make the prior SHA diffable. Either clone with sufficient
82+
history (not `--depth 1`), or explicitly `git fetch` the prior `source_ref.ref` recorded in the
83+
existing docs before dispatching the documenter, so update-mode agents can run
84+
`git diff <prior-sha>..<new-sha> -- <subpaths>` to scope their re-verification. `source_delta`
85+
already reads the prior ref to classify drift; feed that same SHA into the clone so the documenter
86+
can act on it.
87+
88+
## P1 — `components` feature key flipped run-over-run on the SAME app (prior P1 now confirmed unstable)
89+
90+
The prior report (2026-06-29) flagged `components` as having no documented threshold, citing oscer
91+
DECLINING it for `CaseRowComponent`/`TaskRowComponent` as "incidental UI wiring." **This run oscer
92+
REVERSED that call** — it added a new `example-oscer-components` doc precisely for
93+
`CaseRowComponent`/`TaskRowComponent` (plus direct renders of `Strata::Cases::IndexComponent`,
94+
`Strata::US::AccordionComponent`, and `Strata::DateHelper` mix-ins) and wired it into the overview
95+
(oscer log lines 47-52, 92).
96+
97+
The same app, same symbols, opposite decision two runs apart. This upgrades the prior finding from
98+
"inconsistent across apps" to "unstable within one app across runs" — the cross-link
99+
(`example-of` edge to the SDK components doc) is not reproducible. The prior report's proposed
100+
`feature-keys.md` clarification for `components` is **still unapplied** (or ineffective); it should be
101+
prioritized. Reinforcing, not re-raising: apply the one-line threshold clarification from the
102+
2026-06-29 section.
103+
104+
## P1 — rails-template `integrates_with` also flip-flops on Azure; profile should settle it
105+
106+
`app-template` this run **added `template-infra-azure` to the guide's `integrates_with`**, explicitly
107+
**reversing the prior run's decision to omit Azure** (app-template log lines 70-77). The reversal is
108+
well-grounded — Azure is now a first-class deploy target (`config/initializers/database_auth.rb`
109+
implements Entra ID token auth; `Deployment.md` documents deploying via the Nava Azure infra
110+
template) — but it is exactly the kind of per-run judgment churn a profile should remove.
111+
112+
**Action:** state in `profiles/rails-template.md` that a Rails app template documenting shipped
113+
Entra/Azure DB-auth support should declare **both** `template-infra` and `template-infra-azure` in
114+
`integrates_with` (with the AWS-only walkthrough example free to name just `template-infra`). Stops
115+
the edge from oscillating between runs.
116+
117+
## P2 — Azure infra AWS-terminology drift STILL recurring; prior profile caution not visibly effective
118+
119+
The 2026-06-29 report recommended baking an "Azure docs carry AWS-terminology drift" caution into
120+
`profiles/infra-template.md`. This run's Azure documenter **again re-derived the same handling from
121+
scratch** — flagging `set-up-database.md`'s "Lambda function", the "ECS task definition"/"ECS task
122+
role" references, and `.s3.tfbackend` naming, and documenting the Azure reality (Container App Job,
123+
`azurerm` backends) inline instead (azure log lines 84-95, 96-107). It also again hit the missing
124+
`docs/decisions/` directory (line 98) the prior report's "ADRs if present" softening was meant to
125+
cover.
126+
127+
Either those profile edits were never applied, or they aren't preventing re-derivation. **Action:**
128+
verify `profiles/infra-template.md` actually carries the two prior notes (AWS-term caution; `docs/decisions/*`
129+
"if present"); if present, tighten the wording so the next Azure run reads it as authoritative rather
130+
than reasoning independently.
131+
132+
## P2 — New docs↔code mismatches worth filing to `upstream-issues.md`
133+
134+
This run surfaced source-side defects the documenters correctly grounded around; they belong in the
135+
existing `upstream-issues.md` follow-up ledger (curator is advisory — recommending, not editing that
136+
file):
137+
138+
- **documentai-api** (log lines 92-102): README "Installation" links to `…/demployment.md` (typo for
139+
`deployment.md`); README "Processing Flow" names a `bda_output_processor` job that does not exist
140+
(real entry point is `bda_result_processor`); `app.py create_document` defaults `timeout=180` while
141+
its docstring and README curl example say `120`; `deployment.md` references
142+
`aws_iam_policy.dynamodb_read_write.arn` where the declared resource is
143+
`documentai_api_dynamodb_read_write` (copy-paste mismatch).
144+
- **platform-cli** (log lines 122-136): README carries two conflicting uv version floors — `0.6.15+`
145+
(install) vs `0.5.8+` (development) — easy to conflate; `app update`'s `src_path` has no effect on
146+
updates (upstream `navapbc/platform-cli#5`).
147+
- **app-template** (log lines 92-98): `decisions/README.md` and `template-only-docs/README.md` are
148+
empty (ADRs expected, none ship); `code.json` has a malformed `…/strata/blob/…` URL path segment.
149+
- **template-infra-azure** (log lines 96-107): `background-jobs.md` documents a not-yet-implemented
150+
worker-queue path; the tenant-level Cloud Application Administrator requirement is expected to be
151+
removable by future work (issue #17). (Complements the AWS-terminology entries already filed.)
152+
153+
## P2 — Empty `template-only-docs/README.md` / `docs/README.md` is a copier-family pattern
154+
155+
Three of this run's copier-based sources note an empty template-author README: `app-template`
156+
(`template-only-docs/README.md`, line 94), `documentai-api` (`template-only-docs/README.md`, line
157+
78), and `template-infra-azure` (`docs/README.md`, line 97). Documenters skip them correctly, but
158+
each re-notes it as a "gap." **Action (minor):** add a one-liner to the `rails-template`,
159+
`application-template`, and `infra-template` profiles that an empty `template-only-docs/README.md` /
160+
`docs/README.md` is expected boilerplate — skip without flagging as a source gap.
161+
162+
## P3 — `.logs/` staleness mitigation from the prior run WORKED (confirming, not re-raising)
163+
164+
The 2026-06-29 report's P2 asked the skill to pass the curator the explicit list of sources
165+
re-documented this run (to avoid mis-attributing stale `.logs/` entries). **This run that mitigation
166+
was in effect** — the curator was handed the 6-source scope explicitly and correctly ignored the 5
167+
stale logs still sitting in `.logs/`. Recommend making this permanent in `SKILL.md` (document that
168+
`.logs/` is not run-scoped and the curator must receive/honor the re-documented source list), and
169+
optionally still prune obsolete logs for removed sources (flask/nextjs remain in `.logs/`).
170+
171+
## P3 — Update-mode drift detection held up (informational)
172+
173+
`oscer` is the strongest evidence the update path works end-to-end: it caught a material rename
174+
(`exemption``exclusion` ruleset), a new three-step automated flow, an expanded five-outcome
175+
determination enum, and a new `OscerApplicationForm` abstract base — all correctly re-grounded and
176+
re-pinned (oscer log lines 22-44). SHA-pinning at write time also held across all 6 sources (every
177+
doc re-pinned to its resolved SHA). No regression in the doc-write pinning discipline.
178+
179+
---
180+
12181
# Update-mode pass — 2026-06-29 (4 sources)
13182

14183
This was an **update-mode** run, not a full rebuild. The engine re-documented exactly these 4

0 commit comments

Comments
 (0)