- phase-runner: レポートを上書きせずタイムスタンプ付きで同ディレクトリに保存し、fix が過去指摘の傾向を追跡できるよう改善
- output-contracts: persists/reopened/family_tag フィールドを追加してレビュー指摘の継続性を明示
- pieces: 全ビルトインピースに reviewers↔fix の loop_monitors を追加し、発散ループを自動検知
- fix.md: 過去レポートの参照方法を「Glob で {レポート名}.* を検索、最大2件読む」と具体化
- loop-monitor-reviewers-fix.md: ループモニタ判定用の共通インストラクションを新規追加
197 lines
4.4 KiB
YAML
197 lines
4.4 KiB
YAML
name: backend-review-fix
|
||
description: バックエンド特化レビュー+修正ループ(構造・モジュール化・ヘキサゴナルアーキテクチャ・セキュリティ・QA)
|
||
piece_config:
|
||
provider_options:
|
||
codex:
|
||
network_access: true
|
||
opencode:
|
||
network_access: true
|
||
max_movements: 30
|
||
initial_movement: gather
|
||
loop_monitors:
|
||
- cycle:
|
||
- reviewers
|
||
- fix
|
||
threshold: 3
|
||
judge:
|
||
persona: supervisor
|
||
instruction_template: loop-monitor-reviewers-fix
|
||
rules:
|
||
- condition: 健全(進捗あり)
|
||
next: reviewers
|
||
- condition: 非生産的(同じ指摘の反復・修正未反映)
|
||
next: supervise
|
||
|
||
movements:
|
||
- name: gather
|
||
edit: false
|
||
persona: planner
|
||
allowed_tools:
|
||
- Read
|
||
- Glob
|
||
- Grep
|
||
- Bash
|
||
- WebSearch
|
||
- WebFetch
|
||
instruction: gather-review
|
||
output_contracts:
|
||
report:
|
||
- name: review-target.md
|
||
format: review-gather
|
||
rules:
|
||
- condition: レビュー対象の情報収集完了
|
||
next: reviewers
|
||
- condition: レビュー対象を特定できない、情報不足
|
||
next: ABORT
|
||
|
||
- name: reviewers
|
||
parallel:
|
||
- name: arch-review
|
||
edit: false
|
||
persona: architecture-reviewer
|
||
policy: review
|
||
knowledge:
|
||
- architecture
|
||
- backend
|
||
allowed_tools:
|
||
- Read
|
||
- Glob
|
||
- Grep
|
||
- WebSearch
|
||
- WebFetch
|
||
instruction: review-arch
|
||
output_contracts:
|
||
report:
|
||
- name: architect-review.md
|
||
format: architecture-review
|
||
rules:
|
||
- condition: approved
|
||
- condition: needs_fix
|
||
|
||
- name: security-review
|
||
edit: false
|
||
persona: security-reviewer
|
||
policy: review
|
||
knowledge: security
|
||
allowed_tools:
|
||
- Read
|
||
- Glob
|
||
- Grep
|
||
- WebSearch
|
||
- WebFetch
|
||
instruction: review-security
|
||
output_contracts:
|
||
report:
|
||
- name: security-review.md
|
||
format: security-review
|
||
rules:
|
||
- condition: approved
|
||
- condition: needs_fix
|
||
|
||
- name: qa-review
|
||
edit: false
|
||
persona: qa-reviewer
|
||
policy:
|
||
- review
|
||
- qa
|
||
allowed_tools:
|
||
- Read
|
||
- Glob
|
||
- Grep
|
||
- WebSearch
|
||
- WebFetch
|
||
instruction: review-qa
|
||
output_contracts:
|
||
report:
|
||
- name: qa-review.md
|
||
format: qa-review
|
||
rules:
|
||
- condition: approved
|
||
- condition: needs_fix
|
||
|
||
rules:
|
||
- condition: all("approved")
|
||
next: supervise
|
||
- condition: any("needs_fix")
|
||
next: fix
|
||
|
||
- name: fix
|
||
edit: true
|
||
persona: coder
|
||
policy:
|
||
- coding
|
||
- testing
|
||
knowledge:
|
||
- backend
|
||
- security
|
||
- architecture
|
||
allowed_tools:
|
||
- Read
|
||
- Glob
|
||
- Grep
|
||
- Edit
|
||
- Write
|
||
- Bash
|
||
- WebSearch
|
||
- WebFetch
|
||
required_permission_mode: edit
|
||
pass_previous_response: false
|
||
instruction: fix
|
||
rules:
|
||
- condition: 修正が完了した
|
||
next: reviewers
|
||
- condition: 修正を進行できない
|
||
next: supervise
|
||
|
||
- name: supervise
|
||
edit: false
|
||
persona: dual-supervisor
|
||
policy: review
|
||
allowed_tools:
|
||
- Read
|
||
- Glob
|
||
- Grep
|
||
- WebSearch
|
||
- WebFetch
|
||
instruction: supervise
|
||
pass_previous_response: false
|
||
rules:
|
||
- condition: すべての検証が完了し、マージ可能な状態である
|
||
next: COMPLETE
|
||
- condition: 問題が検出された
|
||
next: fix_supervisor
|
||
output_contracts:
|
||
report:
|
||
- name: supervisor-validation.md
|
||
format: supervisor-validation
|
||
- name: summary.md
|
||
format: summary
|
||
use_judge: false
|
||
|
||
- name: fix_supervisor
|
||
edit: true
|
||
persona: coder
|
||
policy:
|
||
- coding
|
||
- testing
|
||
knowledge:
|
||
- backend
|
||
- security
|
||
- architecture
|
||
allowed_tools:
|
||
- Read
|
||
- Glob
|
||
- Grep
|
||
- Edit
|
||
- Write
|
||
- Bash
|
||
- WebSearch
|
||
- WebFetch
|
||
instruction: fix-supervisor
|
||
pass_previous_response: false
|
||
rules:
|
||
- condition: 監督者の指摘に対する修正が完了した
|
||
next: supervise
|
||
- condition: 修正を進行できない
|
||
next: supervise
|