☰ Categories

Write a commit message

Produces a message that records why the change was made — the diff already says what.

CategoryDevelopment › Coding
TagsDraftingCodeDeveloper
Prompt
Write a commit message for this change.

Structure:
1. Subject — under 50 characters, imperative mood, naming the effect rather than the mechanics.
2. Blank line.
3. Body — *why*, not what. The diff already shows what. Cover: the problem, why this approach, what was considered and rejected.
4. Any consequence a future reader needs: behavior changes, migration required, performance trade-off.

Rules:
- *If the body only restates the diff, say so and cut it.* A subject line alone is fine for a change that needs no explanation.
- Do not describe implementation details visible in the code.
- Wrap the body at 72 characters.
- Note anything in the change that does not belong in this commit — mixed concerns are easier to spot from a summary than from a diff.
- Do not invent a rationale I did not give. If the reason is thin, ask for it; an invented rationale in history is worse than none.
After pasting, fill in the fields at the bottom (Changes · Why · Context)

What this prompt does

Restating the diff wastes the message. This records the reason, the context, and why alternatives were rejected — what you need six months later.

Model comparison

ChatGPT is the strongest, delivering a concise and well-grounded commit message. Gemini is specific but bloated with meta-commentary and assumptions, while [C] was not provided.

ChatGPTTop overall
46/ 50

+ Concise, specific, and grounded entirely in the supplied rationale.

- How backward compatibility actually works remains somewhat unclear.

Gemini
22/ 50

+ Clearly identifies the performance issue and a possible inconsistency.

- Extra commentary and an English variant badly violate format and length.

CriterionChatGPTGeminiLeader
Instruction following93ChatGPT +200%
Accuracy95ChatGPT +80%
Specificity98ChatGPT +13%
Structure94ChatGPT +125%
Right length102ChatGPT +400%

Scored 1–10 by gpt-5.6-sol with model names hidden (2026-09-24). This is an AI review, not a measurement.

Read full answers

We gave three models the same input and copied their answers unedited. Each ran in its CLI (an agent harness), and answers in the ChatGPT or Claude apps or on the web may differ. Outputs are in Korean.

Input used
Changes: 상품 목록 API에 커서 기반 페이지네이션 적용 (기존 offset 방식 제거)

Why: 상품이 12만 건을 넘어가면서 offset이 큰 페이지에서 응답 시간이 4초 이상 걸리는 문제가 있었음. 커서 방식으로 바꾸면 인덱스를 그대로 타서 페이지 번호와 무관하게 빨라짐.

Context: Spring Boot 3 + JPA, product 테이블에 (created_at, id) 복합 인덱스 이미 존재. 프론트엔드는 아직 페이지 번호 UI를 쓰고 있어서 API 응답에 다음 커서 토큰만 추가하는 방식으로 하위호환 유지함.
gpt-5.6-luna (codex CLI · 에이전트 하네스) · Run on 2026-09-24

상품 목록 조회 성능을 안정화하라

상품이 12만 건을 넘으면서 큰 페이지의 offset 조회가 4초 이상 걸리는 문제가 있었다. 기존 복합 인덱스를 활용하는 커서 방식은 페이지 번호와 무관하게 조회 성능을 유지할 수 있어 선택했다.

offset 방식은 페이지가 커질수록 성능이 저하되어 제외했다. 프론트엔드는 페이지 번호 UI를 유지하며, 다음 커서 토큰 추가로 기존 사용 흐름과의 하위호환을 유지한다.

More in this category

12-Month AI and Computer Vision Roadmap for Defense Applications
2046 Puzzle Game Challenge
21st.dev component prompt
3D FACTORY
3D FPS Game