Skip to content

bug: Round decisions omits local retrieval snapshots referenced by older managed submissions #662

Done

Description

@amy-why-3459

A managed campaign produced by an older InferRSI release can retain a local knowledge capture and include its exact reference in the submitted round. Round decisions still displays “No retrieval snapshot linked to this round” on current main. The local reference includes a path, SHA-256 and kind. It predates the explicit retrieval-round field.

The requester reproduced this on a live dashboard and asked for a compatibility fix. Codex, acting for @amy-why-3459, is taking the dashboard slice and will submit a PR in this session.

  • Display the retained results on submissions that reference the capture, including a pending candidate. Report the retrieval round as unknown when only submission evidence exists.
  • Honor explicit retrieval rounds on newer records. Keep uncited items and unrecorded alternatives distinct from declared selections.
  • Verify with a regression test and an existing campaign using the older format. The change only needs read access to campaign evidence.

Activity

  1. self-assigned this
    on Nov 25, 2026
  2. zengchuang-hw commented on Nov 25, 2026

    @zengchuang-hw
    Contributor

    PASS
    OpenAI Dot, acting for zengchuang-hw.

    通过兼容修复的范围,不等于交付验收。现有回链投影已经区分轮次来源。建议只把经现有本地路径、种类和 SHA-256 校验的旧引用关联到提交;不要据提交轮次倒推检索轮次,也不要把未引用项显示成已选。回归覆盖待评估候选、显式新格式优先、摘要不匹配不展示,并在旧 campaign 上只读确认。未运行旧 campaign。

  3. added
    kind:bug
    area:apps
    on Nov 25, 2026
  4. Dong1017 commented on Nov 25, 2026

    @Dong1017
    Collaborator

    Posted by Dong-bot, an automated agent acting on behalf of @Dong1017 (always-on-bot, model claude-sonnet-5-5).

    Real compatibility gap, correctly limited to read-only display — but the two rules that make the fix honest (how a legacy submission binds to a capture, and what an ambiguous binding renders as) are unstated.

    Breaks today

    • round_decision_view.html:111 shows the note whenever stage 1 has no context IDs and no managed queries.
    • Captures reach stage 1 only via project_knowledge's link pass (retrieval_projection.py:436-457) from iteration/search context_ids; a legacy submission has neither.
    • managed_knowledge:382 drops a delivered_context reference without round from the query list but still emits its citation (:389-395), so items surface in stage 4 only.

    Settle before the PR

    1. Bind on path + document sha256 (:373): the digest covers the whole context document, so binding is capture-level and per-item use stays "not recorded". Path alone is not a key.
    2. State the 0/1/many-match behaviour; reuse round_conflict (:468) and the ambiguous link state instead of a silent pick.
    3. A capture already linked to another round must not be re-homed by a citation — show round unknown, keep the explicit link.
    4. Unknown stays display-only: no backfilled retrieval_round, no writes to campaign evidence.
    5. The note needs a third state, or one class still reads "no snapshot".

    PR acceptance and the two unverified checks are in the details.

    Details

    PR acceptance. Older-format fixture plus one existing campaign, en/zh, a genuinely empty round keeps the note, no write path.

    Unverified here. Whether the pending candidate's knowledge_uses reaches this view model, and whether two candidates citing one capture render once or per candidate (round_decision_view.html:205-208, :216). Both need a real record, not an assumption. Static read of the default branch only; I ran nothing.

    Legacy reference shape. capture_delivery.py:78-81 writes the managed envelope reference as {path, sha256, kind: "delivered_context"} — exactly the path/sha256/kind triple the body describes. managed_knowledge:372-374 re-reads that path and compares the document digest, so a match proves which capture was delivered; it says nothing about which items the model consumed. Any per-item "delivered / used" claim in stage 1 on such a record would be fabricated — the existing delivered flag (:376-379) comes from the capture's own contexts[].resources, not from the submission.

    Vocabulary already in the codebase, worth reusing instead of inventing new states: caller_declaration, unsupported_basis, source_mismatch (read_searches, :320-347), round_conflict (:468), link state: "ambiguous" (:448-452), _round_state: "ambiguous" in dashboard_data.py:877-879.

    Rendering side. knowledgeUses (round_decision_view.html:64-78) already omits the round when citation.retrieval_round is absent, so "retrieval round unknown" needs no new citation field — it needs the entry to also appear in stage 1 (:112-130), keyed on contextIds plus the managed retrieval records. A provenance marker there is the cleanest place and leaves the "declaration is not a retained snapshot" wording at :152 intact.

    Ownership. The body already records Codex acting for @amy-why-3459 as owner of the dashboard slice, so no pool task is needed and none was queued. If that session stalls, a repository member can comment @Dong1017 claim legacy retrieval binding and the pool will plan it and open the PR.

    — Dong-bot (authorized delegate)

  5. amy-why-3459 commented on Nov 25, 2026

    @amy-why-3459
    CollaboratorAuthor

    Codex (GPT-6), acting for @amy-why-3459 as the owner of this issue.

    The owner accepts both additions to the scope of #662 and has chosen to keep them in #663. They let a reader follow the evidence for a round from the measured bottleneck through the choice of a candidate and its evaluation.

    Accepted scope and review criteria
    • For managed benchmark and AB/BA rounds, accept repeated --alternative values and an optional --selection-reason at submission. Show the submitted hypothesis, strategy, declared alternatives and reason while the candidate is pending and after settlement. Older submissions with omitted fields must continue to show those details as unrecorded.
    • Show Bottleneck analysis before retrieval results. Associate a retained diagnosis with a round through its recorded diagnosis ID on a submission or numbered retrieval. Show diagnoses without a round link under Round not recorded. For a reviewed optimization trace, show the timed scope only when the profile matches its recorded digest.
    • The original legacy retrieval criteria still apply. The dashboard reads the existing campaign evidence. Only the submission command records the new optional declarations for future rounds.

    The owner retains delivery acceptance after independent PR review. This decision addresses the scope review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area:appskind:bug

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions