fix: wave 5b review blockers - suppressed memory key, finalizer merge, zero-image guard
Docker Release / build-and-push (push) Successful in 59s
Docker Release / release (push) Skipped

This commit is contained in:
2026-08-10 12:21:41 -05:00
parent 3df359500c
commit b174b531cd
5 changed files with 126 additions and 13 deletions
+14 -11
View File
@@ -173,28 +173,31 @@ def run_agent_pipeline(
]
orchestrator.stage("Agent wave 5b: evidence verification")
sheet_to_page = {s.get("sheet_number"): s.get("page_number") for s in sheets}
sheet_to_page = {str(s.get("sheet_number")): s.get("page_number")
for s in sheets}
verify_targets = select_findings(
specialist_findings, clusters,
max_checks=config.AGENT_VERIFY_MAX_CHECKS,
severities=config.AGENT_VERIFY_SEVERITIES,
)
target_indexes = {id(f): i for i, f in enumerate(specialist_findings)}
verify_scopes = [
AgentScope(
verify_scopes = []
for finding in verify_targets:
images = [
page_to_b64[sheet_to_page[str(name)]]
for name in (finding.get("sheets") or [])[:config.AGENT_CONFLICT_MAX_IMAGES]
if sheet_to_page.get(str(name)) in page_to_b64
]
if not images:
continue # never judge evidence against images we could not load
verify_scopes.append(AgentScope(
scope_id=f"verify:{target_indexes[id(finding)]}",
payload={
"finding_index": target_indexes[id(finding)],
"finding": finding,
"images_b64": [
page_to_b64[sheet_to_page[name]]
for name in (finding.get("sheets") or [])[:config.AGENT_CONFLICT_MAX_IMAGES]
if sheet_to_page.get(name) in page_to_b64
],
"images_b64": images,
},
)
for finding in verify_targets
]
))
verify_results = orchestrator.run_scopes(
EvidenceVerifierAgent(usage), verify_scopes, config.AGENT_VERIFY_CONCURRENCY)
suppressed = apply_verdicts(specialist_findings, verify_results)