Problem
The email agent's committed hub/agents/python/email/specification.html carries hand-edited sections (e.g. the #1892 context-window envelope block, the #1889 thread-handling sentence) that its generator hub/agents/python/email/gaia_agent_email/spec_html.py does not produce — a fresh render_endpoint_spec_html() run would silently DROP those sections. Recent PRs matched the established practice of editing both files in parallel, but the generator and the committed artifact have structurally drifted: regeneration is no longer safe.
Outcome
spec_html.py regenerates the committed specification.html faithfully (hand-maintained sections become generator-emitted), or the file is explicitly split into a generated part and a hand-maintained part with a drift guard, so regeneration cannot silently lose documentation.
Acceptance criteria
Scope & expectations
- Where:
hub/agents/python/email/gaia_agent_email/spec_html.py, hub/agents/python/email/specification.html, tests in hub/agents/python/email/tests/
- Out of scope: content changes to the spec;
openapi.email.json (already generator-guarded)
- Constraints: keep the rendered page's structure/anchors stable (external links may target section ids)
How to verify
Test run output showing the new drift guard passing on the synced pair and failing when either side is edited alone.
Problem
The email agent's committed
hub/agents/python/email/specification.htmlcarries hand-edited sections (e.g. the #1892 context-window envelope block, the #1889 thread-handling sentence) that its generatorhub/agents/python/email/gaia_agent_email/spec_html.pydoes not produce — a freshrender_endpoint_spec_html()run would silently DROP those sections. Recent PRs matched the established practice of editing both files in parallel, but the generator and the committed artifact have structurally drifted: regeneration is no longer safe.Outcome
spec_html.pyregenerates the committedspecification.htmlfaithfully (hand-maintained sections become generator-emitted), or the file is explicitly split into a generated part and a hand-maintained part with a drift guard, so regeneration cannot silently lose documentation.Acceptance criteria
specification.htmlbyte-identically (or the split/guard makes the hand-maintained region explicit and protected)Scope & expectations
hub/agents/python/email/gaia_agent_email/spec_html.py,hub/agents/python/email/specification.html, tests inhub/agents/python/email/tests/openapi.email.json(already generator-guarded)How to verify
Test run output showing the new drift guard passing on the synced pair and failing when either side is edited alone.