Repository navigation
fix(dream): keep person voice data out of every model-facing view - #24309
Conversation
Sets DREAM_STATE_PASS_MODE=shadow on backend-sync and backend-sync-backfill. Shadow stages, verifies and renders only, on reserved capacity. Co-Authored-By: Claude Opus 5.5 <[email protected]>
A person cited only as evidence sent speaker_embedding and speech sample fields to the verifiers. Strip them in minimal_context, after staging has judged protection, and pass has_voice_profile instead. Failure-Class: none Co-Authored-By: Claude Opus 5.5 <[email protected]>
A prefix filter missed the nested person_voice_base and person_voice_confirmations, which hold embeddings, sample paths and transcripts. An allowlist also keeps later voice fields out by default. Failure-Class: none Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ne/dream-voice-narrow
The read tool, seed records and question quotes could all carry a person's embeddings and sample transcripts to a model. Give models an allowlisted view; the session keeps the full row for protection checks. Failure-Class: none Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
…ne/dream-voice-narrow
There was a problem hiding this comment.
2 issues found across 10 files
Confidence score: 3/5
- The prod overlay enables the state pass for
backend-sync-backfill, though the rollout admits onlybackend-sync; planner/verifier work could run on a service outside the rollout. Remove the backfill binding. - In
evidence.py,model_viewmisses auto-enroll-backed voice profiles, so those people are scrubbed without the promisedhas_voice_profilesignal. Includespeaker_auto_enroll_pooland equivalent stored voice-profile markers.
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="backend/utils/agent_capabilities/evidence.py">
<violation number="1" location="backend/utils/agent_capabilities/evidence.py:39">
P2: `model_view` misses auto-enroll-backed voice profiles, so those people are scrubbed without the promised `has_voice_profile` signal. Include `speaker_auto_enroll_pool` (and any equivalent stored voice-profile marker) when deriving the indicator.</violation>
</file>
<file name="backend/deploy/runtime_env/prod.overlay.yaml">
<violation number="1" location="backend/deploy/runtime_env/prod.overlay.yaml:1006">
P2: This also enables the state pass on `backend-sync-backfill`, although the rollout plan admits only `backend-sync`. Remove the backfill binding so the weekly planner/verifier work cannot run on an unadmitted service.</violation>
</file>
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
| 'created_at', | ||
| 'updated_at', | ||
| ) | ||
| VOICE_MARKERS = ('speaker_embedding', 'speech_samples', 'person_voice_base', 'person_voice_confirmations') |
There was a problem hiding this comment.
P2: model_view misses auto-enroll-backed voice profiles, so those people are scrubbed without the promised has_voice_profile signal. Include speaker_auto_enroll_pool (and any equivalent stored voice-profile marker) when deriving the indicator.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At backend/utils/agent_capabilities/evidence.py, line 39:
<comment>`model_view` misses auto-enroll-backed voice profiles, so those people are scrubbed without the promised `has_voice_profile` signal. Include `speaker_auto_enroll_pool` (and any equivalent stored voice-profile marker) when deriving the indicator.</comment>
<file context>
@@ -7,3 +7,43 @@ class EvidenceRecords(dict):
+ 'created_at',
+ 'updated_at',
+)
+VOICE_MARKERS = ('speaker_embedding', 'speech_samples', 'person_voice_base', 'person_voice_confirmations')
+
+
</file context>
| VOICE_MARKERS = ('speaker_embedding', 'speech_samples', 'person_voice_base', 'person_voice_confirmations') | |
| VOICE_MARKERS = ( | |
| 'speaker_embedding', | |
| 'speech_samples', | |
| 'person_voice_base', | |
| 'person_voice_confirmations', | |
| 'speaker_auto_enroll_pool', | |
| ) |
| DREAM_AGENT_PASSES_PER_DAY: | ||
| value: '48' | ||
| category: rollout | ||
| DREAM_STATE_PASS_MODE: |
There was a problem hiding this comment.
P2: This also enables the state pass on backend-sync-backfill, although the rollout plan admits only backend-sync. Remove the backfill binding so the weekly planner/verifier work cannot run on an unadmitted service.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At backend/deploy/runtime_env/prod.overlay.yaml, line 1006:
<comment>This also enables the state pass on `backend-sync-backfill`, although the rollout plan admits only `backend-sync`. Remove the backfill binding so the weekly planner/verifier work cannot run on an unadmitted service.</comment>
<file context>
@@ -1003,6 +1003,9 @@ overlay:
DREAM_AGENT_PASSES_PER_DAY:
value: '48'
category: rollout
+ DREAM_STATE_PASS_MODE:
+ value: shadow
+ category: rollout
</file context>
A model could have copied sample transcript words into its notes and keep carrying them forward. Mark new notes and ignore unmarked ones. Failure-Class: none Co-Authored-By: Claude Opus 5.5 <[email protected]>
Why
Dream's main loop could put a person's voice data in front of a model. A review of the state pass (#24293) found these paths. The state pass doesn't use them; the live main loop does.
A person record read in full includes
speaker_embedding, the speech sample fields (paths and transcripts) and the nestedperson_voice_baseandperson_voice_confirmations. All of it stayed on the reserved Gemini model and in the owner's scope, but the model has no need for it.How often this happened in prod is not measured.
What
model_viewinagent_capabilities/evidence.pygives a model only an allowlist of person fields, plushas_voice_profile: truewhen real voice data exists. A voice field added to person rows later stays out by default. It now covers every path below:Session.readreturns the model view. The read budget charges what the model sees.dream_verify.minimal_contextuses the same function, replacing the copy from fix(dream): keep voice fields out of verifier evidence and run the state pass in shadow #24293.The session keeps the full row in
Session.records. Staging and the protection checks (require_unprotected_person) read that, so a person with voice data stays protected.Sessionis shared, so this applies to every authority it serves, not only Dream.Depends on #24293, whose commits appear in this diff until it merges. The lead has it queued.
Behaviour change
notes_voice_free), anddream_seed.loadignores unmarked notes, so each owner's next pass after deploy starts without its previous notes, once.Rollout
The voice narrowing has no flag, because it only narrows what a model sees; rollback is reverting the PR. Until #24293 merges, this PR's diff also contains that PR's
DREAM_STATE_PASS_MODE=shadowrollout, which has its own ramp plan and rollback. Merge #24293 first.Metric that must stay clean: applied edits per complete pass and the second-check agreement rate, with no rise in
dream_lever_erroror failed passes. The Dream owner reads back after the train.David has not ruled on this. The rollout lead ruled to proceed without waiting because it only narrows data (bus, 21:17Z); David was told.
Product invariants affected
runtime_env.yamlmatches its path glob, through fix(dream): keep voice fields out of verifier evidence and run the state pass in shadow #24293's commits in this diff. This PR adds no memory intake or promotion route.Review
Luna R1 returned BLOCK on old notes carrying voice text. Luna R2 showed my first answer, that the path drains by itself, was wrong, because a model can copy notes forward. Fixed in code as above. Luna R3 cleared the code and returned BLOCK only on this PR body's rollout wording, corrected above.
Tests
New
tests/unit/test_dream_voice_narrow.py, 8 tests, plus one intest_dream_verify_hold.py. Reverting each of the read output, seed prompt, read charge, quote, notes marker and notes filter changes fails its matching test. Alltest_dream*.py,test_agent_tool_rules.pyandtest_review_stale_answers.pypass undertest.shviaomi-heavy.Failure-Class: none
Line-Count-Exception: backend/utils/dream_agent.py | 1606 -> 1607 | one field marking notes beside the notes it describes; splitting the pass loop is out of scope for this fix
🤖 Generated with Claude Code