docs: refresh demo GIF with a real cognit-generated quiz (high-res) - #21
Merged
Conversation
The old demo used a hand-authored stand-in quiz. This replaces it with a quiz cognit actually generated — captured by running the live engine against a real PR (#20, the retry-with-backoff change) — so the GIF shows genuine, model-authored questions, including a true before/after mermaid flow comparison of the retry exception path. - `scripts/capture_demo_quiz.py`: runs the real generation engine against a PR and records the generated quiz + activity feed into `scripts/demo_data/`. - `scripts/record_demo.py`: replays the captured quiz and feed. The Playwright driver is now data-driven — it computes and clicks the correct answer for each question from the quiz itself, so it adapts to whatever mix/order the model produced (no hard-coded option indices). Recording is higher resolution: Playwright records at the CSS-viewport resolution (device_scale_factor and an oversized record size don't add pixels), so the viewport is bumped to 1440x900 and the GIF is emitted 1:1 at 1440px, 16fps — no downscale softening. - `scripts/demo_data/{quiz.json,feed.json}`: the captured artifacts, so the demo stays offline and deterministic on re-record while the content is genuine. - README alt-text updated to match (five questions: three MCQ, a mermaid-pick flow diagram, true/false). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Replaces the README demo GIF. The old one played a hand-authored stand-in quiz; this one plays a quiz cognit actually generated — captured by running the live engine against a real PR (#20, the retry-with-backoff change). So the GIF now shows genuine, model-authored questions, including a real before/after mermaid flow comparison of the retry exception path (pick the flowchart that matches
_draft_with_retry; the distractors vary the branch condition and the notify/sleep order).The content is real; playback stays offline and deterministic.
How
scripts/capture_demo_quiz.py(new) — runs the real generation engine (ClaudeAgentLLM→ theclaudebinary) against a PR and records the generated quiz + activity feed intoscripts/demo_data/.scripts/record_demo.py— replays the captured quiz/feed. The Playwright driver is now data-driven: it computes and clicks the correct answer for each question from the quiz itself, so it adapts to whatever question mix/order the model produced (no hard-coded option indices).device_scale_factorand an oversized record size don't add pixels — they pad). So the viewport is bumped to 1440×900 and the GIF is emitted 1:1 at 1440px / 16fps, no downscale softening (was a 1000px downscale).scripts/demo_data/{quiz.json,feed.json}(new) — the captured artifacts, committed so re-recording after a UI change needs no Claude call.Note
Depends on nothing in #20 at runtime — the captured quiz is static JSON — but the questions are about #20's diff, so the two read best together.
🤖 Generated with Claude Code