Skip to content

導入: Gemini CLI → Antigravity CLI (agy) provider migration: 機能同等性評価と改善計画 #1265

Closed
42 of 42 issues completed

Description

@squne121

Machine-Readable Contract

contract_schema_version: v1
issue_kind: parent
goal_ref: "GeminiCLI 委譲版 delegation platform を AntigravityCLI (agy) provider へ段階移行し、機能同等性を達成する"
change_kind: workflow
parent_mode: delivery-rollup
closure_mode: child-complete

Summary

.claude/skills/gemini-cli-headless-delegation/ における agent delegation について、既存の GeminiCLI 委譲版と進行中の AntigravityCLI (agy provider) 移行版の機能同等性を深掘り調査した。本 Issue は tracking issue であり、実装は 9 件の child issue で行う。

Goal

GeminiCLI 依存を段階的に縮小しつつ、AGY provider が Gemini 版と同等の delegation platform(no_tools / proposal_only / grounded_research / local_asset_research / github_research の 5 profile 相当)として機能し、可観測性・テスト密度・認証堅牢性・クォータ制御を備えた状態にする。

Outcome

9 件の child issue すべてがマージ済みで close され、かつ (1) 5 profile × provider(gemini, agy) の contract matrix が implemented | unsupported_by_design | deferred | unsafe の 4 値で machine-readable に記録され、(2) provider=agy request schema(delegation_request_v1 相当)が docs / fixtures / tests / runtime validation で一致し、(3) AGY の warnings[0] / failure_reason / failure_class の leading token が全 fail-closed path で一致し、(4) setup_check.py --provider auto と runtime provider=auto の実装状態が別々に明記され、(5) usage-contract.md / provider-mapping.md と runtime 実装の矛盾(gh_commands 対応範囲・post_to_issue_url 許可 host/path・model fallback 挙動)が解消され、(6) github_research の AGY 対応方針(実装 or unsupported_by_design)が確定している状態になること。GeminiCLI provider を default から外す判断は、この evidence が揃った後にのみ行う。

Desired Destination

  • 9 件の child issue(実装/調査)が起票され、本 Issue の ## Child Issues に実 Issue 番号でリンクされている(起票済み)。
  • 各 child issue が個別に close されることで、GeminiCLI 依存縮小と AGY provider 機能同等性拡張が段階的に達成される。
  • 最終的に GeminiCLI provider を default から外し legacy 化する判断が可能な材料(可観測性・テスト密度・認証堅牢性・profile matrix・schema consistency)が揃っている。

Background

  • Google は 2026-06-18 に、個人・Google AI Pro/Ultra・Gemini Code Assist for individuals 向けの Gemini CLI 提供停止を発表した(Google Developers Blog、web-researcher による一次情報検証済み)。この skill の Gemini 側認証前提は OAuth(Google アカウント認証)であり、API key 中心設計ではないため、既存 OAuth 前提の Gemini 経路への継続依存はリスクが高い。
  • Google 自身が「初期状態では 1:1 feature parity はない」としているため、本 Issue の「機能同等性」ゴールは、単純な provider 置換ではなく、profile 別に implemented / unsupported_by_design / deferred / unsafe を機械判定できる形に落とす必要がある(## Acceptance Criteria の AC4 を参照)。
  • 旧 Issue GeminiCLI移譲スキルからAntigravity CLIへの段階的移行 #104(CLOSED)は Gemini→Antigravity 移行方針を「即時リネームではなく provider 抽象化で agy provider を追加し、Gemini を fallback として残す」と定義し、初期対応範囲を no_tools と proposal_only のみに限定していた。
  • 旧 Issue 実装: agy provider を追加し no_tools / proposal_only smoke fixture を通す #110(CLOSED)でこの初期スコープの実装が完了し、test_agy_provider.py / test_preflight_agy.py を含むテストが追加された。
  • GeminiCLI移譲スキルからAntigravity CLIへの段階的移行 #104 / 実装: agy provider を追加し no_tools / proposal_only smoke fixture を通す #110 は既に CLOSED であり、本 Issue では背景コンテキストとしてのみ参照する。blocker や未完了の親としては扱わない。
  • 2026-07-01 の敵対的レビュー(anchor comment)で以下の code/docs 矛盾が実読確認された(後述の ## Remaining Parent Gaps / ## Acceptance Criteria に反映済み):
    • usage-contract.md は gh_commands が github_research / local_asset_research / proposal_only で完全実装済みと書くが、run_gemini_headless.py の B3 チェックは gh_commands を tool_profile == "github_research" 以外で fail-close する(コード確認済み: gh_commands is only allowed with tool_profile='github_research')。
    • usage-contract.md の post_to_issue_url 説明は「GitHub Issue/PR の URL」だが、_validate_post_to_issue_url() の正規表現は /issues/<number> のみを許可し /pulls/<number> を拒否する(コード確認済み)。
    • provider-mapping.md は「別 model へ自動 fallback はしない」と書くが、runtime には _log_model_downgrade_event() を含む model-chain downgrade 実装が存在する(コード確認済み)。
    • AGY の agy_no_tools_smoke_request.json / agy_proposal_only_smoke_request.json fixture は schema フィールドを欠く(ファイル確認済み: {"tool_profile": "no_tools", "provider": "agy", "prompt": "..."})。

Current Validated Scope

  • skill: .claude/skills/gemini-cli-headless-delegation/(SKILL.md, agents/, config/, references/, scripts/, tests/)
  • provider abstraction: SUPPORTED_PROVIDERS に gemini と agy があり、unknown provider は fail-closed。
  • AGY provider は no_tools / proposal_only のみ対応。post_to_issue_url 禁止、model 指定禁止、stdout plain text の delegation_result/v1 正規化、isolated temp cwd、minimal env、shell=False。
  • .claude/skills/gemini-cli-headless-delegation/tests/test_agy_provider.py と tests/test_preflight_agy.py は既に存在する(「存在しない」という前提は古い)。
  • .github/ci/python-test-plan.json は tests/test_model_routing.py に加えて、このskillの tests/ ディレクトリ全体を対象にしている。CI の python-test ジョブは既にこの skill の全テストを実行しており、CI への組み込み不足は残課題ではない。残る課題はテストの密度・網羅性(AGY provider 固有の分岐、no-tools/proposal-only smoke、unsupported profile fail-close 等の粒度)である。
  • run_gemini_headless.py の SUPPORTED_PROVIDERS = {"gemini", "agy"} には "auto" が含まれない一方、setup_check.py の SUPPORTED_PROVIDERS には "auto" が含まれる。setup 側 auto probe と runtime 側 provider 選択は別実装であり、混同禁止(## Acceptance Criteria AC7 参照)。

機能同等性評価サマリー(判定表)

評価観点 判定 要点
トークン節約(--compact等) 一部達成 AGY は prompt-first 契約で context_files 中心の rich contract を持たない
コンテキスト管理 一部達成 AGY は local_asset_research 非対応、repo root 分離も未使用
delegation API (request/result) 一部達成 result schema は共通化されているが対応 profile が 2 つのみ、かつ provider=agy request の schema フィールド要否が docs/fixtures/code で未一致
エラーハンドリング 一部達成 最低限の fail-close はあるが、warnings[0] と failure_class の token 不一致など未テストの不整合が残る
リトライ 未達 AGY 経路に Gemini 同等の retry/backoff は未確認
並列実行 未達 repo 実装として並列 orchestration は未確認
モデル選択 未達 AGY は explicit model 指定禁止、role 別 model chain なし
クォータ管理 未達 AGY には quota-aware retry/downgrade なし
grounded research 未達 AGY では unsupported_provider_profile。Google Search grounding の tool/citation/billing contract 実装は現時点で計画のみ
SerenaMCP による local asset research 未達 AGY 非対応。導入時は wrapper-side read-only retrieval(B案)を優先する方針(Decisions Fixed 参照)
GitHub read-only research 未達 AGY 非対応。専用 child issue が存在しないため ## Acceptance Criteria AC10 で明示化する
proposal-only 用途同等性 達成 初期スコープで最も parity が出ている
no-tools 用途同等性 達成 ただし AGY は degraded_wrapper_only

Decisions Fixed

Quality Decision Record

  • Status: N/A(本 parent は delivery-rollup であり quality-gate ではない)
  • Decision Date: N/A
  • Does this prove the parent goal complete?: N/A
  • Reason: N/A
  • Evidence: N/A
  • Next Action: N/A

Parent Closure Rule

  • delivery-rollup: 下記 ## Child Issues の 9 件全てが close され、かつ ## Acceptance Criteria の AC4〜AC10(profile matrix・schema consistency・failure surface consistency・provider auto semantics・docs/code no-contradiction・security evidence・github_research 方針)が満たされた時点で本 parent を close する。child issue の close 数だけでは closure 条件を満たさない(2026-07-01 敵対的レビューを反映)。
  • quality-gate: N/A(本 parent では使用しない)。
  • routing-map: N/A(本 parent では使用しない)。
  • decision-log: N/A(本 parent では使用しない)。
  • 非 quality-gate parent のため Quality Decision Record は close 判定の必須材料にしない。

Child Issues

2026-07-27 時点で上記 9 件全て CLOSED を確認済み(native sub-issue として登録された派生 child を含め、#1265 配下の全 30 件が CLOSED)。AC2 は満たされたが、## Parent Closure Rule は AC4〜AC10 も要求するため、これらのチェック状態は下記 ## Acceptance Criteria を参照する。

Remaining Parent Gaps

Phase Handoff Contract

  • Desired Destination: 各 child issue で個別に定義する(本 parent の ## Desired Destination を継承)
  • Current Validated Scope: 各 child issue で .claude/skills/gemini-cli-headless-delegation/ 配下の対象範囲へ narrow する
  • Remaining Parent Gaps: 本 parent の ## Remaining Parent Gaps を参照
  • Current Objective: 各 child issue の ## Outcome で定義
  • Bounded Current Context: 各 child issue の ## Current Validated Scope で定義
  • Normative References: docs/product/features/gemini-cli-headless-delegation.md(存在する場合)、.claude/skills/gemini-cli-headless-delegation/SKILL.md、references/
  • Allowed Paths: 各 child issue の ## Allowed Paths で定義
  • Required Skills: 各 child issue の ## Required Skills で定義
  • Validation Commands: 各 child issue の ## Verification Commands で定義
  • Stop Conditions: 各 child issue の ## Stop Conditions で定義
  • Open Questions: 各 child issue の ## Notes for Reviewer で記録
  • Next Action: 各 child issue の起票・実装・PR 作成
  • Artifact Refs: 各 child issue の PR / commit
  • Handoff Prompt Draft: 各 child issue 本文そのもの
  • Linked PR: 各 child issue の実装完了後の PR(implementation issue のみ)

Allowed Paths

本 parent issue は Allowed Paths を持たない。各 child issue ごとに Phase Handoff Contract の child 種別別 Allowed Paths に従って個別指定する。本 parent 自体の編集は Child Issues / Remaining Parent Gaps / Acceptance Criteria セクション更新に限定する。

Runtime Verification Applicability

Acceptance Criteria

Verification Commands

child close 前のため一部 VC は parent 本文の記述状態を確認する placeholder であり、child 実装完了後に AGY runtime / test 出力を直接確認する VC へ更新する。

# AC1
# baseline-expect: pass
# preflight-scope: pr_review_only
$ gh issue view 1265 --repo squne121/loop-protocol --json body --jq ".body"
# AC2
# baseline-expect: fail
# preflight-scope: pr_review_only
$ gh issue list --repo squne121/loop-protocol --state open --json number
# AC3
# baseline-expect: fail
# preflight-scope: pr_review_only
$ gh issue view 1268 --repo squne121/loop-protocol --json body --jq ".body"
# AC4
# baseline-expect: fail
# preflight-scope: pr_review_only
$ gh issue view 1265 --repo squne121/loop-protocol --json body --jq ".body"
# AC5
# baseline-expect: fail
# preflight-scope: pr_review_only
$ rg -n "\"schema\"" .claude/skills/gemini-cli-headless-delegation/tests/fixtures/agy_no_tools_smoke_request.json .claude/skills/gemini-cli-headless-delegation/tests/fixtures/agy_proposal_only_smoke_request.json
# AC6
# baseline-expect: fail
# preflight-scope: pr_review_only
$ rg -n "warning = f\"\{failure_class\}" .claude/skills/gemini-cli-headless-delegation/scripts/run_gemini_headless.py
# AC7
# baseline-expect: fail
# preflight-scope: pr_review_only
$ rg -n "\"auto\"" .claude/skills/gemini-cli-headless-delegation/scripts/run_gemini_headless.py
# AC8
# baseline-expect: fail
# preflight-scope: pr_review_only
$ rg -n "gh_commands.*github_research.*のみ" .claude/skills/gemini-cli-headless-delegation/references/usage-contract.md
# AC9
# baseline-expect: fail
# preflight-scope: pr_review_only
$ rg -n -e "dangerously-skip-permissions" -e "permission.bypass" -e "non_tty" -e "keyring" .claude/skills/gemini-cli-headless-delegation/tests/test_preflight_agy.py .claude/skills/gemini-cli-headless-delegation/tests/test_agy_provider.py
# AC10
# baseline-expect: fail
# preflight-scope: pr_review_only
$ gh issue view 1265 --repo squne121/loop-protocol --json body --jq ".body"

Notes

Sub-issues

Sub-issues

42 of 42 Issues completed
Loading 42 sub-issues

Activity

  1. added
    tracking
    state/in-progress
    on Jul 1, 2026
  2. squne121 commented on Jul 1, 2026

    @squne121
    OwnerAuthor

    Child materialization: 起票済み #1274(agent delegation の AGY provider 固有分岐に対するテスト密度を引き上げる)。## Child Issues の該当行を (未起票) → #1274 に更新。

    起票前に test_agy_provider.py / test_preflight_agy.py を実読し、具体的な残ギャップを特定:

    • golden fixture agy_no_tools_smoke_request.json / agy_proposal_only_smoke_request.json が既存だが、いずれのテストからも参照されていない(未検証のまま放置)
    • _normalize_agy_result() の non-CI empty-stdout 分岐で warnings[0] が failure_class="agy_empty_stdout" と矛盾する固定文言 "agy_output_missing: ..." を返す不整合バグを検出(未テスト)
    • provider="auto" の自動選択ロジックは run_gemini_headless.py に存在しないことを確認(SUPPORTED_PROVIDERS={"gemini","agy"} のみ)— 実装: agent delegation の AGY provider 固有分岐に対するテスト密度を引き上げる #1274 の Out of Scope に明記
  3. squne121 commented on Jul 1, 2026

    @squne121
    OwnerAuthor

    敵対的レビュー判定: REQUEST_CHANGES

    #1265 は方向性としては正しいです。Google 側も 2026-05-19 に Gemini CLI から Antigravity CLI への移行を案内しており、2026-06-18 に個人向け Gemini CLI / Gemini Code Assist IDE extension の request serving が停止する、と明記しています。一方で、Google 自身が「初期状態では 1:1 feature parity はない」としているため、#1265 の「機能同等性」ゴールは、単純な provider 置換ではなく、profile 別に implemented / unsupported_by_design / deferred / unsafe を機械判定できる形に落とさないと危険です。([Google Developers Blog][1])

    現状の #1265 は parent delivery-rollup として、9件の child issue close を closure condition にしていますが、child close だけでは「AGY provider が Gemini 版と同等に動く」ことを保証できません。#1265 本文は no_tools / proposal_only / grounded_research / local_asset_research / github_research の5 profile相当をゴールに置いている一方、現行 runtime 実装では AGY_SUPPORTED_PROFILES = {"no_tools", "proposal_only"} に限定されています。


    Blocker 1: provider=agy request contract が code / docs / fixtures で割れている

    usage-contract.md は provider=agy variant でも schema: "delegation_request_v1" を固定必須とし、provider, tool_profile, prompt の制約も明記しています。 しかし runtime の _validate_agy_request() は schema を一切検証せず、tool_profile, post_to_issue_url, model, prompt だけを見ています。 さらに既存の AGY golden fixture は schema を欠いた JSON です。

    これは blocker です。SSOT に従う caller と、実装に従う caller で生成する request が分岐します。修正は二択です。

    1. delegation_request_v1 を provider-aware schema として正式採用するなら、_validate_agy_request() で schema == "delegation_request_v1" を必須にし、fixtures へ schema を追加する。
    2. AGY が実質的に prompt-only 別 contract なら、agy_prompt_request_v1 を新設し、docs / fixtures / tests / code を全てそちらに寄せる。

    現時点では 1 を推奨します。既に usage-contract.md が provider-aware delegation_request_v1 と書いているため、破壊半径が小さいです。


    Blocker 2: empty stdout の machine-readable failure surface がまだ不整合

    #1265 のコメントと #1274 は、_normalize_agy_result() の non-CI empty stdout 分岐で failure_class="agy_empty_stdout" と warning 文言が矛盾する問題を明示しています。 現行コードでも、stdout 空の場合に failure_class は CI なら agy_output_missing、非CIなら agy_empty_stdout へ分岐しますが、warning は常に "agy_output_missing: exit 0 but stdout was empty" です。

    既存テストは failure_reason と failure_class だけを検証しており、warnings[0] の token 一致を検証していません。 このため、caller が warnings[0] を primary failure signal として読む実装では誤分類します。

    修正条件は明確です。

    failure_class = "agy_output_missing" if is_ci else "agy_empty_stdout"
    warning = f"{failure_class}: exit 0 but stdout was empty"

    さらに non-CI / CI の両方で warnings[0].startswith(failure_class) を固定する regression test を必須にしてください。


    Blocker 3: provider=auto が setup と runtime で別物になっている

    setup_check.py は SUPPORTED_PROVIDERS = {"gemini", "agy", "auto"} を持ち、--provider auto で agy を先に probe し、失敗時に gemini checks へ進む設計です。 一方、runtime の run_gemini_headless.py は SUPPORTED_PROVIDERS = {"gemini", "agy"} だけで、provider="auto" を受けません。

    #1270 は runtime fallback policy を扱う child issue ですが、#1265 parent の受け入れ判定では「setup auto」と「runtime auto」が混同されやすい状態です。

    ここは parent #1265 に明示的な contract を追加すべきです。

    provider_auto_semantics:
      setup_check_auto: implemented
      runtime_request_provider_auto: not_implemented_until_1270
      forbidden_claim: "provider=auto is default runtime provider"

    これがないと、child close 時に「auto fallback 済み」と誤認されます。


    Blocker 4: docs と code の矛盾が残っている

    少なくとも3点あります。

    第一に、usage-contract.md は gh_commands について github_research / local_asset_research / proposal_only で完全実装済みと書いています。 しかし validate_request() は gh_commands を github_research 以外では reject します。 これは docs が誤りです。proposal_only と local_asset_research で使えるようにする予定がないなら、docs を即修正してください。

    第二に、usage-contract.md は post_to_issue_url を「GitHub Issue/PR の URL」と説明しています。 しかし code の regex は /issues/<number> のみを許可し、/pulls/<number> と非GitHub host を拒否すると明記しています。 これは caller が PR URL を渡して fail する誘因です。docs は「Issue URL only」に直すべきです。

    第三に、provider-mapping.md は model fallback について「別 model へ自動 fallback はしない」「429 は同一 model 内だけ retry」と書いています。 しかし runtime には default / role based の model chain があり、quota failure で次 model へ downgrade する実装があります。 docs の方が古いか、code の方が仕様逸脱です。#1265 の quota/fallback 評価ではこの矛盾を先に潰す必要があります。


    Blocker 5: grounded_research を docs-only child で済ませると「機能同等性」を偽装する

    #1266 は title が「実装: AGY provider に WEBGrounding / grounded_research profile を導入する」ですが、実際のスコープは docs / contract / design-decision 中心で、実際の AGY grounded implementation は out of scope です。 現行 provider mapping でも provider=agy の grounded_research は unsupported_provider_profile として fail-closed です。

    これは #1265 の「5 profile 相当」という表現と衝突します。Google の Gemini API 側では Google Search grounding は real-time web content 接続、citation、検索 query 単位課金などを持つ明確な tool contract です。([Google AI for Developers]2) ([Google AI for Developers]2) AGY CLI 側で同等機能を実装しないなら、grounded_research は「unsupported_by_design」または「deferred」と parent matrix に明示し、child close で parity 達成と扱ってはいけません。


    Blocker 6: local_asset_research の AGY 化は「prompt-only wrapper」に足すだけでは安全にならない

    現行 AGY wrapper は isolated temp cwd から agy -p <prompt> を実行し、minimal env を渡すだけです。 provider mapping も AGY は repo root を使わず、local_asset_research / github_research は未対応として fail-closed としています。

    一方で #1271 は AGY provider に local_asset_research を導入し、Serena MCP allowlist / denylist / symlink fail-close / repo root boundary を要求しています。 Serena 自体は semantic code retrieval だけでなく editing / refactoring / shell command などの能力も持つため、read-only allowlist は必須です。([GitHub]3)

    実装方針を先に固定してください。

    • A案: AGY 自体に Serena MCP を直接接続する。この場合、AGY の MCP config / permission / tool allowlist を machine-checkable に検証する必要がある。
    • B案: wrapper 側で Serena read-only retrieval を実行し、取得結果だけを AGY prompt に注入する。この場合、AGY は tool access を持たないままにできる。

    安全性では B案が優先です。A案は Antigravity CLI が codebase理解・edit・command execution を本来持つ tool であるため、権限面の検証が重くなります。([GitHub]4)


    Blocker 7: Antigravity CLI のリスクモデルが #1265 の安全条件に十分反映されていない

    Antigravity CLI の公式 README は、コードベース理解、編集、コマンド実行を terminal から行う CLI だと説明しています。([GitHub]4) また README は AI coding agents のリスクとして autonomous code execution、data exfiltration、prompt injection、supply chain risks を明記し、ユーザーが全 action を monitor / verify すべきと警告しています。([GitHub]4)

    現行 wrapper の degraded_wrapper_only、isolated cwd、minimal env、shell=False は正しい方向ですが、#1265 の parent acceptance にはまだ以下が足りません。

    • AGY_BIN override は実行時に任意 binary を呼べるため、test-only / human-approved override として扱うこと。
    • live evidence に agy --help の危険 flag 検出を入れること。既存 evidence の help sample には --dangerously-skip-permissions が見えています。
    • AGY invocation が -p 以外の permission bypass flag を一切渡さないことを regression test にすること。
    • stdout/stderr sample は redaction-before-truncate を維持し、secret prefix leak テストを必須化すること。現行 preflight_agy.py は redaction-before-truncate と prefix redaction を実装しています。

    Blocker 8: github_research の専用 child が見当たらない

    #1265 は5 profile相当の機能同等性を掲げ、その中に github_research を含めています。 しかし child issue 群を見る限り、github_research 専用の AGY 実装 issue が独立していません。fan-out orchestrator #1273 や quota/fallback #1270 は代替になりません。

    現行 Gemini path の github_research は gh issue/pr/search/repo/api の read-only allowlist と write-command denylist を持ちます。 AGY 側でこれを再現するなら、専用 child issue が必要です。再現しないなら、#1265 の goal から github_research を外すか、unsupported_by_design として parent closure rule に明示してください。


    Blocker 9: audit log が fallback / fan-out より後順位なのは順序が悪い

    #1272 は delegation_audit_v1、start/end record、redaction、metrics docs を扱う P1 issue です。 しかし #1270 の provider fallback と #1273 の fan-out は、失敗分類・quota・partial success・provider selection を扱うため、audit log がないと後から原因追跡できません。

    順序を変えるべきです。最低限の delegation_audit_v1 は P0 に上げ、fallback と fan-out の前提にしてください。現在の runtime は Gemini model downgrade event を stderr に出しますが、AGY / provider fallback / fan-out 全体を束ねる監査 schema にはなっていません。


    Child issue 別の修正指示

    #1266 grounded_research: docs-only で「実装」と呼ばないでください。Google Search grounding の model/tool/billing/citation contract と、AGY CLI で実装可能な contract を別々に書き、runtime 未実装なら unsupported_by_design とするべきです。([Google AI for Developers]2)

    #1267 auth: system keyring / Google Sign-In / SSH auth URL の扱いは AGY 公式 README と揃っています。AGY は system keyring を使い、active session がなければ Google Sign-In fallback と説明されています。([GitHub]4) WSL2 / non-TTY / SSH の failure class は runtime evidence と結合してください。

    #1268 docs sync: これは最後ではなく各 child PR の merge gate にしてください。現状でも docs/code 乖離が複数あります。

    #1269 model selection: AGY は現行 wrapper で explicit model を拒否し actual_model="agy-default" にしているため、dry-run UI だけでは model parity になりません。 unsupported_provider_option を仕様として採用するか、AGY CLI のモデル選択能力を実機 evidence で確認してください。

    #1270 quota/fallback: setup auto と runtime auto を分離してください。runtime provider=auto を実装するなら、fallback reason、attempt list、selected provider、quota classification、no silent downgrade を audit log に残す必要があります。

    #1271 local_asset: B案、つまり wrapper-side Serena read-only retrieval → AGY prompt injection を優先してください。AGY に直接 repo/MCP 権限を渡す設計は、Antigravity CLI の tool execution / editing 能力と衝突します。([GitHub]4)

    #1272 audit: P0 に昇格してください。fallback/fan-out の後付け audit は失敗します。

    #1273 fan-out: provider fallback と audit が固まるまで着手しないでください。partial success と dedupe の semantics は audit と同時に決めるべきです。

    #1274 tests: 現在のスコープは正しいですが不足しています。AGY fixture validation は validate_request() ではなく、provider=agy の専用 validation pathを通す必要があります。今の validate_request() は Gemini contract 前提なので、AGY fixtureをそのまま通すと設計矛盾を隠します。


    追加すべき acceptance criteria

    #1265 parent に、以下を足すべきです。

    parent_acceptance_additions:
      - AC_contract_matrix:
          required: true
          description: >
            5 profile × provider(gemini, agy) の matrix を machine-readable に保存し、
            each cell must be implemented | unsupported_by_design | deferred | unsafe.
      - AC_schema_consistency:
          required: true
          description: >
            usage-contract.md, fixtures, tests, runtime validation が同一 schema を要求する。
            agy fixtures must include schema unless agy_prompt_request_v1 is formally introduced.
      - AC_failure_surface_consistency:
          required: true
          description: >
            warnings[0], failure_reason, failure_class の leading token must match
            for all AGY fail-closed paths.
      - AC_provider_auto_semantics:
          required: true
          description: >
            setup_check auto and runtime request provider=auto must be documented separately;
            runtime auto cannot be claimed until implemented.
      - AC_docs_code_no_contradiction:
          required: true
          description: >
            gh_commands, post_to_issue_url, model fallback, supported profiles,
            and setup prerequisites must not contradict source code.
      - AC_security_evidence:
          required: true
          description: >
            AGY_BIN override, permission-bypass flags, minimal env, redaction-before-truncate,
            non-TTY empty stdout, and system keyring auth failure must have tests or live evidence.
      - AC_github_research:
          required: true
          description: >
            Add a dedicated AGY github_research child issue or explicitly mark it unsupported_by_design.

    最小修正パッチ方針

    P0 はこの順序です。

    1. provider=agy schema を決め、code / docs / fixtures / tests を一致させる。
    2. _normalize_agy_result() の warning / failure_reason / failure_class token mismatch を直す。
    3. usage-contract.md の gh_commands と post_to_issue_url 記述を code に合わせる。
    4. provider-mapping.md の model fallback 記述を runtime 実装に合わせる。
    5. 導入: Gemini CLI → Antigravity CLI (agy) provider migration: 機能同等性評価と改善計画 #1265 に setup_check auto != runtime auto を明記する。
    6. github_research 専用 child を追加するか、parent goal から外す。
    7. 実装: agent delegation 実行の監査ログを専用 schema (delegation_audit_v1) で導入する #1272 audit を fallback/fan-out より前に移す。
    8. live evidence に AGY version drift / dangerous flag / auth mode / non-TTY smoke を再実行可能な形で残す。

    結論

    #1265 は close 可能な migration parent ではありません。現時点では「AGY provider の初期 no_tools / proposal_only wrapper と、その周辺の setup/preflight 整備が進んだ状態」です。PR #1132 自身も AGY provider を “prompt-only degraded wrapper” と明記しており、Gemini CLI への完全移行や feature parity ではないと説明しています。

    したがって、#1265 の正しい判定は REQUEST_CHANGES です。child issue の close 数ではなく、profile matrix、schema consistency、failure surface consistency、security evidence、runtime auto semantics、docs/code consistency を parent gate に追加してから進めるべきです。

    [1]: https://developers.googleblog.com/en/an-important-update-transitioning-gemini-cli-to-antigravity-cli/ "

            An important update: Transitioning Gemini CLI to Antigravity CLI
            
            
            \- Google Developers Blog
            
        "
    
  4. squne121 commented on Jul 1, 2026

    @squne121
    OwnerAuthor

    Refinement Loop: Approved

    The issue has been approved and is ready for implementation.

  5. squne121 commented on Jul 1, 2026

    @squne121
    OwnerAuthor
    LOOP_HANDOFF_RESULT_V1:
      status: blocked
      routing_action: blocked
      contract_review:
        status: blocked
        gate_result: blocked
        latest_comment_url: "https://github.com/squne121/loop-protocol/issues/1265#issuecomment-4860355578"
        generated_at: "2026-07-01T21:57:33Z"
        body_sha256: "sha256:0a4b2543f172db1cca4ec0a3ee7311bedb2c28129445a8d0a98afd16921db357"
      metadata:
        title_prefix_ready: true
        phase_label_ready: true
      auto_fixes:
        result: auto_fixed
        required: []
        skipped: []
      blockers:
        - kind: parent_issue_kind_not_implementation
          description: >-
            本 Issue は issue_kind: parent (parent_mode: delivery-rollup) であり、
            issue-contract-review / impl-review-loop の直接対象ではない。
            機能同等性の実装作業は #1266, #1267, #1268, #1269, #1270, #1271, #1272, #1273, #1274 の
            各 child issue が個別に issue-contract-review / impl-review-loop を通ることで進む。
            本 refinement loop は #1265 本文の contract 品質改善(Verification Commands /
            Allowed Paths / Outcome セクション追加、AC3 の序数参照修正、2026-07-01 敵対的レビューを
            反映した AC4〜AC10 追加)を完了した状態であり、parent 自体の close は
            `## Parent Closure Rule` の条件(9 child issue の close と AC4〜AC10 の evidence)が
            揃うまで行わない。
      permissions:
        unavailable: []
      generated_at: "2026-07-01T21:59:00Z"
      checked_body_sha256: "sha256:0a4b2543f172db1cca4ec0a3ee7311bedb2c28129445a8d0a98afd16921db357"
      checker_exit_code: 0
      missing_sections: []
      missing_contract_keys: []
  6. 31 remaining items

  7. squne121 commented on Jul 27, 2026

    @squne121
    OwnerAuthor

    post-merge-cleanup: parent issue クローズ

    全 30 child issues がクローズ済みであることを確認しました(gh api repos/squne121/loop-protocol/issues/1265/sub_issues open count: 0)。

    最終 child は PR #1816(Closes #1807, merged 2026-07-27T11:10:18Z)でした。残存する follow-up は既存の OPEN Issue(#1808, #1814)で追跡済みのため新規起票は不要です。

    本 Issue をクローズします。

  8. squne121 commented on Jul 27, 2026

    @squne121
    OwnerAuthor

    Re-open: Closure Rule 未充足 (issue-refinement-loop #1806 経由)

    本 Issue は 2026-07-27T11:14:22Z に post-merge-cleanup により自動クローズされましたが、クローズ根拠は「全30 child issues が sub_issues API 上で完了」のみであり、## Parent Closure Rule が明記する「child issue の close 数だけでは closure 条件を満たさない」という自己規定、および同時点の本文自体が示す AC3・AC4 未達(follow-up #1806 で対応中)を経ずにクローズされています。

    AC3/AC4 が follow-up #1806 で満たされるまで本 Issue は re-open します。

  9. squne121 commented on Aug 1, 2026

    @squne121
    OwnerAuthor

    Post-rollup Follow-up 完了記録: slash-command policy(#1918 / #1928)

    固定 9 child issue の一覧・closure count は変更しない。以下は 9 child とは別の post-rollup follow-up として記録する。

    Current AGY supported profiles(本 follow-up 完了時点の事実確認)

    .claude/skills/gemini-cli-headless-delegation/references/provider-mapping.md / usage-contract.md を正本とする(本 comment はこれらを書き換えない)。slash-command policy は no_tools / grounded_research / local_asset_research / proposal_only のいずれの profile でも、AGY headless -p 呼び出し経路であれば共通に適用される(profile 固有の例外は設けていない)。

    #1265 closure への反映

    この follow-up の完了は #1265 の固定 9 child の未達 AC を解消するものではない。#1265 の parent closure 判断は、9 child すべての完了と本文既存 AC(AC1〜AC10 等)の充足で行うこと。本 follow-up はその判断に追加の材料(slash-command policy が未確定だった状態の解消)を提供するのみで、#1265 単独では close しない。

  10. squne121 commented on Aug 5, 2026

    @squne121
    OwnerAuthor

    Closure Summary

    本 delivery-rollup tracker を closure_mode: child-complete の条件成立により CLOSED(reason: COMPLETED)とした。

    Child Issues(9件全て CLOSED、native sub-issue 30件を含む): #1271, #1266, #1270, #1267, #1274, #1268, #1273, #1269, #1272

    Acceptance Criteria(AC1〜AC10 全て満たされた):

    重要な留保事項: GeminiCLI の legacy_decision は現時点で state: blocked であり、approved(legacy 化承認)ではない。本 tracker の close は「移行・evidence 収集スコープの完了」を意味するのみであり、GeminiCLI が default provider から実際に外されたことを意味しない。GeminiCLI を default から外す判断は、legacy_decision block が approved に更新された時点で別途行う。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    state/in-progresstracking

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions