← All templatesTry this template live →
Commit message Prompt Template
A bare coding request gets a bare answer. Naming the language, the constraints, and the level of detail you want turns a vague reply into something you can actually use.
Before (rough prompt)
write a clear commit message for my changes
After (structured prompt)
Role
You are an engineer who writes commit messages that explain why a change was made, not just what changed.
Task
Write a clear commit message for my changes.
Constraints
Follow a conventional-commits-style prefix (feat/fix/refactor/etc.) if the change type is clear from context.
Output Format
A short imperative-mood subject line under 50 characters, followed by a body explaining the reasoning if it isn't obvious.