Summarize (Mid-Session)
Capture context, learnings, and progress without ending the session. Write a checkpoint, then continue.
When to Use
- Significant milestone reached but more work ahead
- Switching to a different topic within the same session
- Context getting close to its limit — checkpoint before compaction
- After completing a multi-step task, before starting the next
- Patterns or decisions have emerged that should be recorded
Not for session-ending summaries — use a full session summary for that.
Proactive Capture Triggers
Fire a capture immediately when any of these occur:
| Trigger | Action |
|---|---|
| Decision made | Record decision + rationale + alternatives considered |
| Pattern discovered | Note the pattern with "when to use" conditions |
| Significant work completed | Capture what was done + outcome |
| Problem solved | Record approach + what worked / what didn't |
| Session winding down | Offer to run a full session summary or auto-capture key points |
| Topic switch | Quick checkpoint before context shifts |
Session wind-down signals: "thanks", "that's it", "done for now", long pause after significant work, context switch to unrelated topic, time indicators ("gotta go", "wrapping up").
What's Worth Capturing
Always: architectural decisions, technology choices with rationale, bug root causes + fixes, performance optimizations, security considerations, integration patterns.
When significant: refactoring approaches, test strategies, debugging techniques, file organization decisions, naming conventions.
Skip: routine edits, typo fixes, standard boilerplate, obvious patterns already documented.
Key Principles
- Fast > thorough: This is a checkpoint, not a dissertation. Keep it brief enough to preserve momentum.
- File-first: Write to
./notes/checkpoints/so checkpoints survive context resets. - Continue after: This skill does NOT end the session.
- Compound: Multiple checkpoints per session is fine — they build a trail.
- Searchable: Use clear prefixes (CHECKPOINT, PATTERN, DECISION, LESSON) for future grep.
- Silent capture: Don't interrupt flow. Capture at natural breaks, not mid-thought.
Anti-Patterns
- Writing a full session summary mid-session (use a full session summary)
- Spending longer on the checkpoint than the work needs
- Only commenting in-line without writing a retrievable file
- Generic summaries without specifics ("worked on stuff")
- Over-capturing: not every line of code matters
See checkpoint-format.md for detailed checkpoint template, memory type distinction, decision/pattern/lesson capture templates, a delegated-capture example through the plugin's MCP server, and the quality guide.
Relevant Source Files
lionhub/src/lionhub/orchestration/runs.py— run persistence at~/.lionagi/runs/{run_id}/lionhub/src/lionhub/orchestration/console.py— structured logging conventions used in CLI sessionslionhub/src/lionhub/serve/mcp/server.py,lionhub/src/lionhub/serve/mcp/verbs.py—agent.submit/job.output, the MCP path for delegating a capture to a sub-agent and reading back its saved artifactslionhub/src/lionhub/serve/cli/agent.py—li agent, the checkout-local equivalent; it persists runs without a flag