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.