Repository navigation
fix(email): stream the email agent's /query answer - #5767
Conversation
`/v1/email/query` ran with streaming off, so a relayed turn showed "Waiting on the model" until the whole answer landed, Stop could not cut a model call short, and a stopped turn kept no text -- the symptoms amd#5567 removed from the flagship, still present in a package published to npm. The route now turns streaming on where it already sets the console, which covers both the per-turn and the session-scoped agent. Refs amd#5728
|
Verdict: Approve with suggestions The email agent's query endpoint now streams the model's answer as it's written, the way the flagship has since #5567. Users get live text instead of "Waiting on the model", Stop can cut a model call short, and a stopped turn keeps the text produced so far. The fix is one line in the right place: it covers both the one-shot and session agents, and it matches the flagship. The package's SPEC already promises Two small follow-ups:
Real-world evidenceN/A: no evidence bundle was produced for this run. The change is in a streaming HTTP route whose live behaviour needs a real model (Lemonade) and a connected mailbox, so it would fall to the strix-halo lane. The verdict rests on static review and on the red/green unit test the PR body describes. A live 🔍 Technical detailsIssues 🟢 No CHANGELOG entry ( 🟢 Comment is history-tagged and long ( Checked and fine
Strengths
|
Both points from the review: the `[Unreleased]` section names the behaviour change, and the comment beside the flag is one WHY line instead of a paragraph of history. Refs amd#5728
|
Both are in. The
|
## Why this matters v0.25.2 is a bug-fix release on top of v0.25.1: setup and install no longer stop at the first failed step, shell and file access handle Windows paths and text encodings, the Agent UI and desktop app stop showing misleading states, and document search, email and skills each lose a handful of rough edges. 55 commits since v0.25.1; notes are in `docs/releases/v0.25.2.mdx` and credit 15 outside contributors. ## Test plan - [x] `python util/validate_release_notes.py docs/releases/v0.25.2.mdx --tag v0.25.2` passes - [x] `mintlify validate` (from `docs/`) passes - [x] `python util/check_doc_links.py --internal-only`, `python util/check_doc_versions.py` and `node installer/version/bump-ui-version.mjs --check` pass - [x] `python util/check_component_core_api.py --release-version 0.25.2` passes - [x] `pytest tests/unit/test_docs_json_release.py tests/unit/test_check_component_core_api.py tests/unit/test_release_tag.py tests/unit/test_hub_core_version_gate.py`: 156 passed - [ ] CI green on the merge commit - [ ] `release_train_dryrun.yml` passes on that commit before the RC tag ## Evals to re-run on the RC tag LLM-affecting PRs merged without per-PR evals; run these on `v0.25.2-rc1`: - `gaia_shell` and shell/safety (amd#5794, amd#5751, amd#5768) - `gaia_honesty` (amd#5753) - `gaia_skills_tasks` and `gaia_skills_lifecycle` (amd#5422, amd#5755) - `rag_retrieval` and `rag_quality` (amd#5742, amd#5754, amd#5761, amd#5817, amd#5812) - email scenarios (amd#5767, amd#5811) - `tool_selection` and `error_recovery` (amd#5732) - Claude provider thinking replay (amd#5072) - memory categories (amd#5818 merged; amd#5756 has not) ## Release checklist - [ ] Freeze main, wait for green CI on the exact commit, pass `release_train_dryrun.yml`, then push `v0.25.2-rc1` - [ ] Extend the changelog if main gains commits before the tag
The email agent's
/v1/email/queryran with streaming off, so a relayed turn showed "Waiting on the model" until the whole answer landed, Stop could not cut a model call short, and a stopped turn kept no text — the symptoms #5567 removed from the flagship, still present in a package published to npm.What changed
query_routes.pynow setsagent.streaming = Truewhere it already setsagent.console, which is where the flagship sets it. That covers both agent paths in this route: the per-turn agent and the session-scoped one.test_query_route.pydrives the real route with the fake agent and asserts the flag reached it; the fake starts at the config default (False).hub/agents/email/npm/CHANGELOG.mdnames the behaviour change under[Unreleased], per the review.🔍 Technical details
hub/agents/email/python/gaia_agent_email/query_routes.py, in the block that prepares the agent before the worker thread starts. The flagship does this athub/agents/gaia/python/gaia_agent/server.py:1298.streamingis a base-agent attribute (src/gaia/agents/base/agent.py:2423), default off inGaiaAgentConfig, read at the step and streaming boundaries.Test plan
PYTHONPATH=src:hub/agents/email/python pytest hub/agents/email/python/tests/test_query_route.py -q→ 42 passed.1 failed—assert False is Truefor the fake'sstreaming. With the fix:1 passed. That is the red/green pair.black --checkandflake8 --select=E9,F63,F7,F82clean on both Python files.Closes #5728