Repository navigation
feat(demo): seed gemini-cli, antigravity, and hermes origins - #3182
Conversation
Problem: `polylogue demo seed` only populated five of the eight wired origins (claude-code-session, codex-session, chatgpt-export, claude-ai-export, aistudio-drive). The gemini-cli-session, antigravity-session, and hermes-session parsers were verified only by unit fixtures, never by the public demo archive, and `--origin gemini-cli-session read --all` (etc.) returned zero rows against a fresh demo seed. What changed: - polylogue/demo/seed.py: write hand-authored, realistic-but-synthetic fixture documents for each of the three origins, routed through the real dispatch/parse path (gemini-cli local-agent JSON with a tool call and a recorded thought, an Antigravity markdown-export document, and a Hermes exported-snapshot document with a tool call/result), the same mechanism already used for the claude-ai-temporary, browser-capture, and lineage fixture families. - polylogue/scenarios/corpus.py: add DEMO_GEMINI_CLI_SESSION_ID, DEMO_ANTIGRAVITY_SESSION_ID, DEMO_HERMES_SESSION_ID, extend DEMO_SESSION_IDS, and add three DemoCorpusFamily entries (synthetic=False, matching the existing hand-authored family pattern) so the corpus contract documents the new fixtures. - polylogue/demo/constructs.py: add gemini_cli_origin_rows, antigravity_origin_rows, and hermes_origin_rows declared constructs so `polylogue demo verify` positively asserts each new origin resolved a session, not just that overall counts increased. - polylogue/demo/tour.py: compute the "archive facets" narration's origin count from the seeded session ids instead of a hardcoded "five", so the tour transcript can't silently go stale again. - tests/unit/scenarios/test_corpus.py: extend the pinned DEMO_SESSION_IDS/DEMO_CORPUS_FAMILIES assertions. Verification: `devtools test tests/unit/sources tests/unit/demo tests/unit/scenarios` (1907 passed, 7 pre-existing failures in test_live_batch_support.py/test_live_cursor_persistence.py unrelated to this change -- a bulk_build TypeError from #3165, no files this change touches); a fresh scratch-root seed proves `polylogue --origin gemini-cli-session read --all` (and antigravity-session, hermes-session) each return rows and `polylogue demo verify --require-overlays` passes with 19 sessions/71 messages across 8 origins. Ref polylogue-b036
Problem: docs/plans/demo-corpus-construct-audit.md is generated from a
fresh seed/verify run and docs/examples/demo-tour/ is a committed copy
of a fresh `polylogue demo tour` run; both went stale the moment the
prior commit added gemini-cli-session, antigravity-session, and
hermes-session to the demo corpus (session/message/block counts and
the origin list all changed), and docs/demos.md / docs/proof-artifacts.md
still said "five origins" by hand.
What changed:
- devtools render demo-corpus-datasheet: regenerated
docs/plans/demo-corpus-construct-audit.md (19 sessions, 71 messages,
119 blocks, 8 origins, 3 new declared constructs, all ok).
- Regenerated docs/examples/demo-tour/{transcript.txt,report.md,
report.json,recording.tape,command-output/*.txt} via `polylogue demo
tour --out-dir polylogue-demo-tour --force`, per
`devtools lab policy demo-tour-freshness`'s own remediation
instructions.
- docs/demos.md, docs/proof-artifacts.md: replaced the hand-written
"five origins" claim and origin list with the current 8-origin
reality (or a origin-count-agnostic phrasing) so the claim can't
drift out of sync with the corpus again the same way.
Verification: `devtools render all --check` (no drift); `devtools lab
policy demo-tour-freshness` ("fresh tour output matches committed
docs/examples/demo-tour/"); `devtools lab policy docs-drift` ("zero
unhandled drift"); `devtools verify --quick` (all 16 steps ok).
Ref polylogue-b036
|
Warning Review limit reached
Next review available in: 33 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (14)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Problem: master's #3182 (rebased onto this branch) added gemini-cli, antigravity, and hermes origins to the demo fixture world, adding three new staged directories. This test's staged-directory assertion hardcoded the pre-#3182 six-directory list, so it failed unconditionally against the current demo world -- the exact class of staleness this PR's own integration-test rewrite was meant to fix. Solution: derive the expected staged-directory set from demo_source_specs() (the same source of truth demo_source_specs() already provides for materialize_demo_source()) instead of a literal list, mirroring the DEMO_SESSION_IDS approach already used for session identity -- a future demo-corpus addition changes source specs and this assertion together, by construction. Verification: pytest tests/integration/test_demo_daemon_convergence.py -q -p no:randomly --timeout=280 -- 1 passed (real daemon, real --wait, full current 9-origin demo world). mypy clean. devtools verify --quick exit 0.
) Ref polylogue-93cp demo program (runbook category A). ## Summary Refreshes the deterministic basic-usage walkthrough artifacts against current master — first refresh since #3178 (transcript crash fix), #3179 (import parity), #3182 (all-origins seeding) landed. ## Problem Committed walkthrough outputs predated three merged changes that alter demo-visible behavior: corpus grew 16→19 sessions / 62→71 messages across 8 origins, index schema v40→v42, embeddings v3→v4, and the MCP surface consolidation (#3056) renamed the tools the MCP walkthrough exercises. ## Solution Re-ran every walkthrough recorded command against a fresh scratch seed: 1-4 (find/read/search/resume) byte-identical — surface stability demonstrated; 5/8 (cost, status/debt) refreshed with expected corpus-growth deltas; 7 (MCP round-trip) refactored onto the query/read dispatchers preserving the search→summary pattern; README stamp + schema refs updated. Cold-reader gate re-answered from directory contents alone. Produced by a Haiku lane; branch harvested by coordinator. ## Verification Each walkthrough re-executed against a fresh `polylogue demo seed` in a scratch root; diffs classified per-artifact (table in lane report); `devtools verify --quick` 16/16 green. Co-authored-by: Claude <[email protected]>
Problem: `devtools test tests/unit/cli/test_import.py -k demo_wait` had two red tests reporting the entire ~40-construct demo corpus at zero (0/19 sessions, 0/31 messages). This looked like the demo seeder itself was broken, but bisecting to b473d92 (#3179, 2026-07-20) showed the production `import --demo --wait` flow changed to run `apply_demo_post_ingest_augmentation` and the real `_verify_demo_now` unconditionally after the wait step (previously `_verify_demo_now` only ran on the `--with-overlays` branch, and the success banner printed a hardcoded `sessions=3 messages=19`). tests/unit/cli/test_import.py was never updated for that call-sequence change, so both tests let the real augmentation/verifier hit the empty per-test archive (urlopen and the daemon wait are mocked; no real ingest ever runs in these unit tests) — one crashed on `no such table: sessions`, the other correctly reported the archive as empty. Also fixed a pre-existing, unrelated staleness in `test_import_demo_materializes_fixture_world_before_daemon_request`: its expected source-directory listing and JSON fixture count predate the gemini-cli/antigravity/hermes demo origins added in #3182/#2674, so it asserted 6 directories where 9 now exist and 4 fixture files where 7 now exist. What changed: - test_import_demo_wait_verifies_after_daemon_acceptance: mock `apply_demo_post_ingest_augmentation` and `_verify_demo_now` (matching the with-overlays test's existing pattern), assert the call sequence daemon -> wait -> augment -> verify, and assert the banner against the fake DemoVerifyResult's counts instead of hitting the real (unseeded) archive. - test_import_demo_wait_with_overlays_seeds_after_convergence: add the missing `apply_demo_post_ingest_augmentation` mock the production code already calls unconditionally; update the expected event order to daemon -> wait-base -> augment -> seed-overlays -> verify-overlays. - test_import_demo_materializes_fixture_world_before_daemon_request: update the expected directory listing (+antigravity, +gemini-cli, +hermes) and fixture-file count (4 -> 7) to match the current demo corpus. This is a test-only fix: no production seeder, daemon, or storage code changed. The declared demo-construct contract (`polylogue/demo/constructs.py`) is untouched and still enforced end-to-end by tests/unit/demo/test_demo_seed_verify.py and tests/integration/test_demo_daemon_convergence.py; nothing here weakens what those constructs require. Verification: - `devtools test tests/unit/cli/test_import.py -k demo_wait` -> 2 passed - `devtools test tests/unit/cli/test_import.py` -> 19 passed - `devtools verify --quick` -> exit 0 Co-Authored-By: Claude <[email protected]>
Summary
Extends
polylogue demo seedto populate all eight wired origins instead of five, and refreshes the generated demo-corpus evidence that depends on the corpus contents.Problem
polylogue demo seedonly populatedclaude-code-session,codex-session,chatgpt-export,claude-ai-export, andaistudio-drive. Thegemini-cli-session,antigravity-session, andhermes-sessionparsers were verified only by unit fixtures, never by the public demo archive —polylogue --origin gemini-cli-session read --all(and the other two) returned zero rows against a fresh demo seed, and the README carried a caveat about this gap (owned by a separate lane, not touched here). Operator: "why wouldn't we just generate stuff for all the origins?"Solution
polylogue/demo/seed.py: write hand-authored, realistic-but-synthetic fixture documents for each of the three origins, routed through the real dispatch/parse path — the same mechanism the existingclaude-ai-temporary,browser-capture, andagent-lineage-matrixfixture families already use (not hand-inserted rows):gemini-cli-session: a local-agent JSON document (sources/parsers/local_agent.py:parse_gemini_cli) with a tool call, a recorded thought, and per-message usage.antigravity-session: the Antigravity language-server markdown-export shape (sources/parsers/antigravity.py:parse_markdown_export), the real ingestion route real Antigravity exports use.hermes-session: the Hermes exported-snapshot JSON shape (sources/parsers/local_agent.py:parse_hermes, distinct from the livestate.dbacquisition path) with a system prompt, a tool call, and its tool result.polylogue/scenarios/corpus.py: newDEMO_GEMINI_CLI_SESSION_ID/DEMO_ANTIGRAVITY_SESSION_ID/DEMO_HERMES_SESSION_ID, extendedDEMO_SESSION_IDS, and three newDemoCorpusFamilyentries (synthetic=False, matching the existing hand-authored pattern) documenting the fixtures.polylogue/demo/constructs.py: three new declared constructs (gemini_cli_origin_rows,antigravity_origin_rows,hermes_origin_rows) sopolylogue demo verifypositively asserts each new origin resolved a session, not just that totals grew.polylogue/demo/tour.py: the "archive facets" tour narration now computes the origin count from the seeded session ids instead of a hardcoded "five" — it can't silently go stale again.docs/plans/demo-corpus-construct-audit.md(devtools render demo-corpus-datasheet) anddocs/examples/demo-tour/*(polylogue demo tour --out-dir polylogue-demo-tour --force, perdevtools lab policy demo-tour-freshness's own remediation instructions) since both are committed snapshots of a fresh seed/tour run and the new sessions change their counts.docs/demos.md,docs/proof-artifacts.md: replaced the hand-written "five origins" claim/list with current reality (README.mdis intentionally untouched — a separate lane owns its origin-coverage caveat).tests/unit/scenarios/test_corpus.py: updated the pinnedDEMO_SESSION_IDS/DEMO_CORPUS_FAMILIESassertions for the three new families/ids.Verification
POLYLOGUE_ARCHIVE_ROOT=/realm/tmp/... python3 -m polylogue.cli demo seed, then--origin gemini-cli-session read --all/antigravity-session/hermes-session): each origin returns rows (2, 2, and 5 messages respectively).python3 -m polylogue.cli demo verify --require-overlays:Demo archive verification: ok— 19 sessions, 71 messages, 8 origins, 0 problems.devtools test tests/unit/sources tests/unit/demo tests/unit/scenarios: 1907 passed. 7 pre-existing failures intest_live_batch_support.py/test_live_cursor_persistence.py(abulk_buildTypeErrorfrom the unrelated, already-merged perf(storage): productize empty-derived-state bulk-build lifecycle #3165) — none of those files are touched by this change.devtools render all --check: no drift (OK: site sources render and generated local links resolve.).devtools lab policy demo-tour-freshness: "fresh tour output matches committed docs/examples/demo-tour/ (masked)".devtools lab policy docs-drift: "zero unhandled drift across the reference-docs sweep."devtools verify --quick: all 16 stepsok(also re-ran automatically via the pre-push hook).Acceptance criteria (Ref polylogue-b036)
--origin gemini-cli-session read --all(and antigravity-session, hermes-session) each return rows against a fresh scratch-root seed: satisfied.polylogue demo verifypasses and covers the new origins: satisfied (three new declared constructs + the existing session-id/count assertions).tests/unit/demo/*,tests/unit/cli/test_demo_command.py,tests/unit/scenarios/test_corpus.pyall pass).Ref polylogue-b036
Co-Authored-By: Claude [email protected]