Stop serving a triage recommendation when its proposal or evidence changes

Abierto
#1,763 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
5/5
Tiempo estimado
Más de una semana
Aptitud para principiantes
35/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
python

Línea de trabajo

Start with server/memory/api/models_proposals.py to see how proposal content hashes are exposed and acceptance binds approved_sha256; then trace the triage read and Apply paths associated with #1144. Define which evidence revisions count as read and whether invalidated recommendations are retained as history before implementing the hash and access checks. Done means the five acceptance cases pass, including unchanged-input reuse without a model call.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

enhancement
Company

ClickHouse

Component

Memory and search

Use case

In #1144 the assistant drafts accept, reject or request-evidence recommendations for selected proposal revisions, and a reviewer confirms a batch later. The issue rechecks revisions at Apply, where an edited item stays undecided.

Between triage and Apply nothing ties a recommendation to the content it was written for. A proposal edited in that window still shows the recommendation drafted for its earlier text, and the reviewer reads it until Apply refuses the item.

Describe the solution you'd like

Bind each recommendation to what it read. This is a proposal; nothing is implemented or measured.

  • A recommendation is keyed by the proposal's content hash and the revisions of the evidence it read.
  • On every read Loom compares that key with the current hash and revisions. When either differs, the recommendation is not served, and the item shows as needing triage again with a reason: proposal_changed or evidence_changed.
  • The comparison is a hash check on read. It adds no model call.
  • With unchanged inputs a repeated triage request returns the stored recommendation without a second model pass.
  • A stored recommendation is served only to a caller who can read the proposal and every evidence revision it read. For any other caller the item shows as needing triage, with no reason that names the evidence.

What Loom has that this builds on: memory.proposals returns content_sha256 for each proposal, and acceptance binds approved_sha256 per key (server/memory/api/models_proposals.py).

Acceptance fixture, added to #1144's labeled proposal set:

  1. Editing a proposal removes its recommendation from the triage read, with proposal_changed.
  2. Replacing a document revision the recommendation read removes it, with evidence_changed.
  3. A repeated request on unchanged inputs returns the same recommendation and makes no model call.
  4. A batch prepared before the edit leaves that item undecided at Apply, as #1144 already requires.
  5. A reviewer who cannot read one evidence item of a stored recommendation is not served it.

Evidence still needed before rollout:

  • A read-only count, on a deployment with a proposal queue, of proposals whose content changed while they were pending. It sizes how often a recommendation would outlive its content.

Two decisions are open:

  • Whether a recommendation that is no longer served is deleted or kept as history. It is derived text, and it leaves with its proposal under erasure in both cases.
  • Which evidence counts as read. A grade that arrives after triage changes the evidence without changing any revision the recommendation cited.
Describe alternatives you've considered
  • Rely on the recheck at Apply. The reviewer then reads a recommendation for other content until the batch is refused.
  • Expire recommendations by age. Age says nothing about whether the content changed.
Where the need comes from

An AI tool suggested this feature

Additional context

Found by source review; no triage was run.

Related: Proposed as part of #1144. Roadmap: #1232.

Lenguaje dominante
Python
Estrellas
221
Forks
35
Merge medio
14 h 21 min
PR fusionados (30 d)
873

Preparar el entorno

Abrir en Codespaces

Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de ClickHouse/loom

Todos los issues de ClickHouse/loom

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.