history が長くなり、現在の task に以前の詳細が不要になったら conversation を summarize します。毎 turn で transcript 全体を再送する代わりに、古く解決済みの部分を短い summary に置き換え、key decisions と current state を残し、解決済みの tangent を落とします。
KEEP → decisions made ("we chose Postgres"), constraints ("must run on Node 18"),
current state ("auth works; now wiring the dashboard"), open questions
DROP → resolved tangents, dead-end attempts, long pasted output already acted on,
polite filler
# Instead of 40 messages, summarize the settled context:
Summary so far:
- Building a REST API in Express + Postgres (Node 18).
- Auth (JWT) is done and tested.
- DECISION: use Zod for request validation.
Current task: add the GET /orders endpoint with pagination.
これにより、model は decision と current task に grounded なまま、そこに至る noise を捨てられます。
いつ summarize するかを知っていると、AI assistant を context window 内で、速く、安く動かし続けられます。また、解決済み history に埋もれるのではなく、次の step を決める decisions と current state に attention を保てます。
ジュニアからシニアまで、詳細な回答付きのIT面接質問ライブラリ。
寄付する