Repository navigation
Closed as not planned
Closed as not planned
Copy link
Labels
Description
Machine-Readable Contract
contract_schema_version: v1
issue_kind: implementation
parent_issue: "none"
goal_ref: "issue-refinement-loop が anchor_comment_url 未指定時に trusted author コメントを自動検出して Step 0a/0b を起動する"
change_kind: workflowParent Issue
なし(単独改善)
Parent Goal Ref
- Goal: issue-refinement-loop の anchor_comment 処理を、URL 明示なしでも trusted author コメントがある場合は自動起動する
- Desired Destination: ユーザーが「コメントも参照して」と指示するだけで anchor_comment_url を省略できる
Current Validated Scope
.claude/skills/issue-refinement-loop/SKILL.mdの Step 0 セクションに anchor_comment 自動検出ロジックを追加
Remaining Parent Gaps
なし(standalone improvement)
Outcome
anchor_comment_url 未指定時に Issue コメントを取得し、trusted author(OWNER/MEMBER/COLLABORATOR)の最新コメントを auto_anchor として LOOP_STATE に格納した上で Step 0a/0b が起動する状態。anchor_comment_url が明示された場合は従来通り動作し、自動検出は影響しない。
In Scope
issue-refinement-loop/SKILL.mdの Step 0 に「anchor_comment_url 未指定時の自動検出サブステップ」を追加- 自動検出ロジック:
gh api repos/.../issues/<N>/commentsを取得し、author_associationがOWNER/MEMBER/COLLABORATORの最新コメントを候補とする - 候補が 0 件の場合は通常通り Step 0b をスキップして Step 1 へ進む
- 候補が 1 件以上の場合は最新コメントを
auto_anchorとしてLOOP_STATE.anchor_commentに格納し、auto_detected: trueフラグを追加して Step 0b へ進む - trusted_author_policy は従来ルール(OWNER/MEMBER/COLLABORATOR のみ信頼)を維持
preliminary_classificationの manual override は変更しない(Step 0b の logic はそのまま)- human_escalation 条件も変更しない
Out of Scope
- anchor_comment_url を明示した場合の動作変更
- trusted author policy の変更(CONTRIBUTOR / NONE の扱い変更)
- Step 0b/0c の分類ロジックの変更
- 複数コメントを同時に anchor として扱うケース(最新 1 件のみ)
- UI/フロントエンド変更
Acceptance Criteria
- AC1:
anchor_comment_urlが未指定かつ trusted author コメントが存在しない場合、Step 0b をスキップして Step 1 へ進む(従来動作を維持) - AC2:
anchor_comment_urlが未指定かつ trusted author コメントが 1 件以上存在する場合、最新コメントがLOOP_STATE.anchor_commentに格納されauto_detected: trueが設定される - AC3:
anchor_comment_urlが明示された場合、自動検出を行わず従来の Step 0a ロジックを使用する - AC4: 自動検出された anchor_comment の trusted_author_policy チェックは従来ルール(OWNER/MEMBER/COLLABORATOR のみ)を維持する
- AC5: SKILL.md に
auto_detected: true | falseフィールドがLOOP_STATE.anchor_commentスキーマに追加されている
Verification Commands
rg -n 'auto_detected|自動検出|auto_anchor|anchor_comment_url.*未指定' .claude/skills/issue-refinement-loop/SKILL.md— AC1-AC3: 自動検出ロジックの記述確認rg -n 'trusted_author_association|OWNER.*MEMBER.*COLLABORATOR' .claude/skills/issue-refinement-loop/SKILL.md— AC4: trusted_author_policy の維持確認rg -n 'auto_detected:' .claude/skills/issue-refinement-loop/SKILL.md— AC5: LOOP_STATE スキーマへの auto_detected フィールド追加確認
Allowed Paths
.claude/skills/issue-refinement-loop/SKILL.md
Stop Conditions
- Allowed Paths 外の変更が必要と判明した場合
- In Scope の固定契約(キー集合・スキーマ・型定義)の変更が必要になった場合
- 新規 Issue の起票が必要と判断した場合(スコープ分割が発生する場合)
- 後続 Phase / 別スコープへの波及が判明した場合
- nested SubAgent delegation が必要になった場合
- 外部サービス利用・権限昇格・既存テスト大規模改変が必要になった場合
Required Skills
- Markdown / YAML 編集(skill ファイル構造)
- GitHub Issues API(comments endpoint)
Runtime Verification Applicability
decision: not_applicable
reason: "SKILL.md のテキスト変更のみ。ランタイム動作確認コンポーネントなし"Scope Delta
N/A
Delivery Rule
1 Issue = 1 PR- Allowed Paths:
.claude/skills/issue-refinement-loop/SKILL.mdは Issue 実装: issue-refinement-loop Step 0b に複合シグナルの決定論的絞り込み規約を追加する #138 と共有。並行実装禁止のためDepends on #138 merge(先に 実装: issue-refinement-loop Step 0b に複合シグナルの決定論的絞り込み規約を追加する #138 をマージしてから着手) - Draft PR 既定
Background
Issue #211 の issue-refinement-loop 実施中に、ユーザーが anchor_comment_url を明示せず「コメントも参照して」と指示した際、main thread が手動でコメントを検索・評価する必要があった。trusted author コメントが存在する場合は自動検出できれば、このコストを削減できる。
Source
- dedupe_key:
follow-up:211:anchor-comment-auto-detection:issue-refinement-loop - origin_issue: 改善: state/blocked/state/queued を着手判定から除外し、refinement 時の stale state label 掃除に縮退する #211 (issue-refinement-loop 実施)
- origin_skill: issue-refinement-loop
Activity
squne121 commentedon May 27, 2026
Decision: Superseded
Reasoning: Superseded by the thin entrypoint architectural shift, where orchestrator or CLI explicitly pass the anchor comment URL.
squne121 commentedon May 27, 2026
CLOSE_DECISION_V1
squne121 commentedon May 27, 2026
CLOSE_DECISION_V1_CORRECTION
訂正理由: 前回コメントの
decision: not_plannedは #395 Outcome の語彙外。正しくはdecision: superseded(design: no auto-detection — anchor_comment_url は orchestrator が明示的に渡す設計を維持)。github_state_reason: not_plannedは GitHub の close reason として分離して保持する。