nap

Compress agent histories and prune old logs to reclaim context window budget.

Updated Mar 27, 2026
One-click install
npx skills add https://github.com/lbouriez/Squad-Templates --skill nap-lbouriez
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: nap
Source: https://github.com/lbouriez/Squad-Templates/tree/main/Nectari-Devops-Squad/.copilot/skills/nap
Command: npx skills add https://github.com/lbouriez/Squad-Templates --skill nap-lbouriez

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Reclaims context window budget by compressing agent histories, pruning old logs, and archiving stale decisions, ensuring smoother long-running sessions.

Core Features & Use Cases

  • Context hygiene: compress histories and prune logs to free up memory.
  • Archive and clean up: move old decisions and inbox files to archive to reduce clutter.
  • Pre-sprint readiness: run before large fan-out sessions to maintain responsive agents.

Quick Start

Run nap to compress histories and prune archived state for the current session.

Frequently Asked Questions about nap

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I compress agent histories and reclaim context window budget?

Prune old logs and archive stale decisions to reduce .squad/ total size when it exceeds 1MB. Archiving moves old decisions and inbox files out of the active context, reducing clutter and reclaiming context window budget for smoother operations.

How do I clean up agent context before a large fan-out session?

Use nap to compress histories and prune archived state for the current session. It is designed to run deterministically with existing .copilot/skills tooling and supports CLI and REPL invocation through squad nap commands.

When should I prune logs and archive stale decisions in my agent workflow?

Prune logs and archive stale decisions during heavy fan-out or after long-running sessions. Specifically, trigger cleanup when history.md files exceed 15KB or the .squad/ total size exceeds 1MB to prevent context window waste.

Does the squad nap command work with existing .copilot/skills tooling?

Yes, the squad nap command works with existing .copilot/skills tooling. It is designed to run deterministically within that environment, supporting both CLI and REPL invocation for compressing histories and pruning archived state.

What are the size limits for triggering context window cleanup in agent histories?

The size limits for triggering context window cleanup are when individual history.md files exceed 15KB or the total .squad/ directory size exceeds 1MB. Exceeding these thresholds indicates context window waste that requires pruning and archiving.