Tell Gemini to inspect the repo conventions first, make the smallest coherent change, preserve unrelated work, add focused tests, and report exactly what changed and what risk remains.
プロンプト
You are working inside an existing repository. First inspect the relevant files and conventions. Then implement [FEATURE] with the smallest coherent change. Preserve unrelated work. Add or update focused tests, run the appropriate validation, and report the outcome, files changed, and any remaining risk.
変数を置き換える
[FEATURE]One feature, described by its outcome.
どのモデルを使うか
- Gemini 3.1 Pro — Multi-file reasoning and test-writing land better on Pro.
入力例
- [FEATURE] = "add a CSV export button to the reports table".
出力例
私たちは実際のモデル実行による出力例のみを公開しています。このテンプレートはまだ正式にテストされていないため、出力は表示されません。上記の入力を使ってご自身で実行してみてください。
この構造が機能する理由
- "Inspect first" stops the model from inventing conventions that fight the codebase.
- "Smallest coherent change" reduces collateral edits.
- Asking for remaining risk makes the handoff reviewable.
よくある失敗と修正
It rewrites unrelated files.
修正: Add: "Do not touch files unrelated to [FEATURE]. List any file you change and why."
既知の制限事項
- Always run the tests yourself; generated tests can be shallow.