opencode-config/docs/decisions/069-pr-163-resolve-prompt-contradictions.md
Sergey 27db3851b6
fix(agents): resolve prompt contradictions and path mismatches (#163)
* fix(agents): allow echo and fix paths in docs-reviewer

* fix(agents): allow echo and load memory skill in memory-syncer

* fix(agents): fix skills path and load code-standards in reviewer

* fix(pipeline): remove checkout master from template E

* fix(scripts): update scaffold path in pipeline-status error

* docs(handoff): add handoff and ADR for prompt contradictions fix

* docs(handoff): set PR number

---------

Co-authored-by: opencode-agent <agent@opencode.local>
2026-07-31 18:47:32 +03:00

30 lines
No EOL
2.2 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# ADR-069: Resolve prompt contradictions and path mismatches
## Статус
Accepted (2026-07-31)
## Контекст
В prompt-инструкциях агентов (docs-reviewer.md, memory-syncer.md, reviewer.md), run-pipeline/SKILL.md и pipeline-status.py накопилось 8 противоречий между декларированными правилами и фактическими permission set'ами / структурой репозитория. Это приводило к doom-loop'ам, невозможности выполнить инструкции и несоответствию путей.
Конкретные противоречия:
1. `echo` запрещён в Rules, но разрешён в allow-list.
2. Путь `config/scripts/scaffold-handoff.sh` устарел — скрипт переехал в `.opencode/scripts/`.
3. `origin/master...HEAD` ломается на репо с default branch `main`.
4. `find skills/` не находит skills (реальный путь `.opencode/skills/`).
5. reviewer не загружает `code-standards` скилл.
6. Template E требует `git checkout master && git pull` — отсутствует в allow-list memory-syncer'а.
7. memory-syncer не загружает `memory` скилл перед дистилляцией.
8. Spec cleanup (post-merge операция) описан в docs-reviewer (pre-merge агент).
## Решение
Устранить все 8 противоречий точечными правками:
- Привести Rules в соответствие с allow-list (echo разрешён).
- Обновить пути: `config/scripts/``.opencode/scripts/`, `skills/``.opencode/skills/`.
- Унифицировать default-branch через `origin/HEAD...HEAD`.
- Добавить загрузку скиллов (`code-standards` для reviewer, `memory` для memory-syncer).
- Убрать `git checkout master && git pull` из Template E (memory-syncer работает на текущем состоянии).
- Добавить явный guard: spec cleanup — post-merge only.
- Синхронизировать зеркало `~/.config/opencode/` с repo-local `.opencode/`.
## Альтернативы