Context Pack

Context Pack

Context Pack is a distilled bundle of code, graph signals, and memory context tailored to a question. It keeps prompts lean while delivering high-signal context — including intelligent surfacing of lessons, intent detection, and compaction awareness.

What it includes

Code + files

The most relevant files, snippets, and symbols for the question.

Graph signals

Dependency and impact context that explains what connects to what.

Memory + decisions

Prior decisions, lessons, and preferences related to the query.

Enhanced Context

Context Pack goes beyond simple retrieval. It understands what you're doing and proactively surfaces what matters.

Intent detection

Semantic classification understands your intent — whether you're debugging, refactoring, or implementing. Context is shaped accordingly.

Lessons surfacing

Past mistakes and critical lessons appear proactively before you repeat them. The system learns from corrections.

Context pressure tracking

Know when your conversation is getting long. Get warnings before context limits affect quality.

Compaction awareness

Pre-compaction snapshots preserve critical state. Session context automatically restores after summarization.

How to use it (MCP)

Ask your AI tool to call context_smart withmode="pack" when you need code or file context.

context_smart(
  user_message="What does the auth refresh worker do?",
  format="minified",
  max_tokens=400,
  mode="pack",
  distill=true
)

If Context Pack is disabled, the API falls back to standard context_smart.

Token controls

max_tokens - hard budget for the response payload.

format="minified" - compact output for assistants.

distill=true - returns a compact summary when available.

When to use Context Pack

Code explanation

Summarize what a function or module does without pulling the whole file.

Refactor planning

Quickly identify what might break and what depends on it.

Long sessions

Context pressure tracking warns you before hitting limits. Snapshots preserve state through compaction.

Avoiding past mistakes

Lessons from previous sessions surface automatically before you repeat them.

Next Steps