feat: deep research demo with live terminal helix visualisation#19
Conversation
Showcases the Felix SDK's helical agent orchestration with a real-time ASCII visualiser — agents spiral from exploration to synthesis on screen. Zero new dependencies, runs offline with a rich phase-aware mock provider. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Fix ruff lint warnings and format all files - Extract _process_agent helper to reduce cognitive complexity - Add rich structured synthesis response to mock provider - Add 4 integration tests (mock provider, full workflow, synthesis, visualizer) - Add GIF recording instructions (VHS, asciinema, ttygif) to README Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
CalebisGross
left a comment
There was a problem hiding this comment.
Nice work -- the mock provider with phase-aware rotating responses is a smart design, makes the demo instantly usable without keys.
A few things:
Should fix:
- PR description could be trimmed down -- the "What's in the box" / "Demo highlights" sections read a bit like a press release. Just bullets on what's in the PR is fine.
- Redundant condition in
helix_visualizer.pyaround line 609:if canvas[explore_row][col].strip() == "" or canvas[explore_row][col] == " ":
" ".strip() == ""is always true, so the second branch is dead code. Same thing on the analysis_row check below it. - No
Closes #Nin the PR body -- is there a tracking issue?
Worth discussing:
sys.path.insert(0, _example_dir)in bothrun.pyand the test file is a bit fragile. For the test file, aconftest.pyintests/integration/that handles the path setup would be cleaner than each test file managing it. For the example script it's more acceptable.
Minor / take it or leave it:
_resolve_providersilently falls back to mock on typos (--provider anthrpic-> mock with a print). Could be worth erroring out instead so users don't accidentally run with mock when they meant to use a real provider._USE_COLOURis evaluated once at import time -- fine for the demo, just means tests always run in no-colour mode. Not a problem, just noting it.
The _RoundContext dataclass, NO_COLOR/FORCE_COLOR support, Windows UTF-8 handling, and the try/finally shutdown pattern are all solid.
Address review feedback from @CalebisGross: - Remove dead-code branches in helix_visualizer phase dividers - Extract sys.path setup into tests/integration/conftest.py - Trim PR description, link to epic issue #1 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
@CalebisGross — addressed all your review feedback:
All 4 integration tests pass, ruff lint/format clean. Ready for re-review when you get a chance. |
CalebisGross
left a comment
There was a problem hiding this comment.
Fixes look good -- dead code removed, conftest extraction is clean, PR description is tidy.
One thing: commits ea78c01 and e0a6717 have identical messages ("polish: lint fixes, smoke tests, improved synthesis, GIF instructions"). Probably a rebase artifact -- worth squashing before merge.
Summary
examples/05_deep_research_live/) — real-time ASCII helix visualiser showing agents spiral from exploration to synthesis--provider anthropic/openai/localfor real runsRelates to #1
Test plan
ruff checkandruff formatpass on all new filespytest tests/integration/test_deep_research_demo.py -v)--faston Windows🤖 Generated with Claude Code