Orchestrator should own decisions/log.md writes; subagents return drafted entries, never write directly

Abierto
#21 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
68/100
Tipo de issue
Refactorización
Claridad
Bastante claro
Estado de actividad
Activo
Área
tooling

Línea de trabajo

Start by reading the ace-protocol skill, the ace agent definition, and the ACE synthesis protocol section in user-testing SKILL.md. Trace every instruction that lets subagents read or write decisions/log.md, then audit for other shared files with concurrent writers. Done means the orchestrator is the sole writer, subagents return drafted entries, and serialized appends assign numbers without collisions.

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

Descripción

Problem

During the Pass 3 user-testing battery (2026-09-28), 10 chapters' worth of ACE synthesis agents ran concurrently (up to ~20 at once), each independently tasked with checking decisions/log.md's current tail, picking the next free DL number, and appending its own entry.

This raced badly. Over the course of one battery we hit at least four real collisions: two, then three, then four separate entries independently landed on the same DL number (DL-054, then DL-056, then DL-058), because each agent's "read the tail, then write" sequence wasn't atomic against the others doing the same thing concurrently. The orchestrator had to do several rounds of manual detection (grep -o "^## DL-[0-9]*" decisions/log.md | sort | uniq -c) and renumbering, and even a "renumber it now" fix sometimes landed after a new concurrent collision had already appeared at the newly-assigned number.

The eventual workaround (switching later ACE agents to return their fully-drafted entry text with a placeholder number, rather than writing to the file at all, so the orchestrator does one single serialized append) worked cleanly and produced zero further collisions. But it was discovered mid-battery, not planned for.

Proposed fix

Make this the standing rule, not a one-off workaround: the orchestrator (or a single designated writer) is the only actor that ever writes to decisions/log.md. Every subagent — ACE synthesis, builder, reviewer, whatever role — composes its DL entry text as part of its report and returns it; it never reads the file's tail to pick a number, and never edits the file itself. The orchestrator serializes all appends, assigning numbers in the order entries actually arrive.

This likely means:

  • Updating the ace-protocol skill and the ace agent definition to state this as a hard rule (some agent definitions in this session already say "the orchestrator numbers and commits the log entry" — that text exists but wasn't consistently followed, or wasn't present in every agent's launch context).
  • Possibly updating user-testing SKILL.md's "ACE synthesis protocol" section, which currently has the ACE both drafting and logging.
  • Considering whether this generalizes to any other file multiple concurrent subagents might write to (none identified yet beyond decisions/log.md, but worth a quick audit).

Not urgent

This didn't cause any lost work or wrong content — every collision was caught and cleanly resolved before commit — but it cost real orchestrator turns doing manual dedup/renumbering that a structural fix would avoid entirely. Deferred for now per Z's own note; revisit before the next large parallel-agent battery (e.g. a future Pass 3 run, or a similarly large fan-out).

Lenguaje dominante
Jupyter Notebook
Estrellas
0
Forks
0
Métricas de merge de PR
Sin PR fusionados en 30 d

Preparar el entorno

  • Sin Dockerfile ni archivo de Docker Compose
  • Tiene una plantilla de pull request
  • Sin guía de contribución

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 Open-MBEE/toaster

Todos los issues de Open-MBEE/toaster

Issues similares

Más issues de DevTools

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.