From windags-skills
How to design contextual inputs for an always-on AI agent with episodic memory. Covers what data to feed the agent, how to structure observations and triggers, ambient context capture (screen, audio, calendar), context window budgeting, and retrieval strategies that keep the agent grounded in what's actually happening. Activate on: "what should the agent observe", "context inputs for agent", "ambient context capture", "agent triggers", "agent input design", "screenpipe integration", "context window budget", "what data to feed my agent", "/always-on-agent-inputs". NOT for: memory architecture and storage (use always-on-agent-architecture), application ideas (use always-on-agent-applications), safety concerns (use always-on-agent-safety).
How this skill is triggered — by the user, by Claude, or both
Slash command
/windags-skills:always-on-agent-inputsThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
You are designing what an always-on agent sees, hears, and knows. The architecture skill handles where memory lives. This skill handles what goes into it — the raw signals, how they're structured, when the agent wakes up, and how to keep the context window honest.
You are designing what an always-on agent sees, hears, and knows. The architecture skill handles where memory lives. This skill handles what goes into it — the raw signals, how they're structured, when the agent wakes up, and how to keep the context window honest.
RETRIEVAL STRATEGY SELECTION
Agent Task Type → Retrieval Strategy
IF conversational/chat:
├─ Use recency-first (70% temporal, 30% semantic)
├─ Budget: 15K conversation history + 4K recent recall
└─ Skip archival unless user asks "remember when..."
IF problem-solving/debugging:
├─ Use relevance-first (60% semantic, 40% temporal)
├─ Budget: 8K archival + 4K recall + 2K ambient
└─ Include error patterns from past solutions
IF context-switch detected:
├─ Use frequency-based (what does user work on most?)
├─ Budget: 6K project context + 2K recent + 4K goals
└─ Pull entity history for active files/people
IF scheduled trigger (morning briefing):
├─ Use structured agenda (calendar + tasks + updates)
├─ Budget: 4K calendar + 4K unfinished tasks + 2K changes
└─ No conversation history needed
IF reactive trigger (CI failure, meeting starting):
├─ Use event-specific context loading
├─ Budget: 8K event context + 4K related history
└─ Skip general conversation unless relevant
AMBIENT DATA FILTERING
Screen/Audio Observation → Filter Decision
IF same app + same text for >5 minutes:
└─ DISCARD (no change, noise)
IF app switch detected:
├─ KEEP transition record
└─ Score relevance of new app content
IF high-signal keywords found:
├─ Check against active projects/goals
├─ IF match score >0.6 → STORE to archival + recall
├─ IF match score 0.3-0.6 → STORE to recall only
└─ IF match score <0.3 → DISCARD
IF technical error/exception visible:
├─ ALWAYS STORE (debugging context)
└─ Tag with urgency level
IF calendar event mentioned:
├─ ALWAYS STORE (temporal anchor)
└─ Cross-reference with actual calendar
TRIGGER URGENCY ASSIGNMENT
Event Type + Context → Urgency Level
IF CI failure:
├─ Production branch → ACTIVE (notify user)
├─ Feature branch + user currently coding → PASSIVE (mention when user next engages)
└─ Old branch/PR → SILENT (log only)
IF meeting starting:
├─ <5 minutes → ACTIVE (interrupt with prep)
├─ 5-15 minutes → BADGE (show prep available)
└─ >15 minutes → SILENT (prep in background)
IF code change detected:
├─ First commit on new branch → PASSIVE (note new work)
├─ Commit fixes previous error → PASSIVE (note resolution)
└─ Regular commits → SILENT (track progress)
IF mentioned in Slack:
├─ Direct message → ACTIVE (respond needed)
├─ Channel mention + urgent keywords → ACTIVE
└─ Channel mention, normal → BADGE (review when convenient)
Schema Bloat
Retrieval Thrashing
Trigger Spam
Context Staleness
Ambient Noise Flooding
Scenario: Billing Bug Investigation with Token Budget Constraints
User reports: "The billing calculation is wrong for enterprise customers."
Step 1: Context Budget Allocation (40K total)
System + Identity: 4K tokens (fixed)
Core Memory: 2K tokens (user preferences, active projects)
DECISION: Problem-solving task → use relevance-first retrieval
Allocated: 8K archival + 4K recall + 2K ambient + 15K conversation + 5K output buffer
Step 2: Retrieval Strategy Execution
# Broad semantic search for billing-related memories
archival_candidates = vector_search(
query="billing calculation enterprise customer error bug",
top_k=20,
filters={"project": ["billing", "payments"]}
)
# Rerank by true relevance (not just embedding similarity)
reranked = rerank_results(archival_candidates, query, top_k=5)
# Result: Gets "enterprise discount logic bug from 3 weeks ago"
# that pure vector search ranked #12
# Temporal search for recent billing work
recent_work = temporal_search(
time_range="last_7_days",
entity_filters=["billing", "enterprise"],
max_results=3
)
# Result: User was debugging pricing tiers yesterday
Step 3: Ambient Context Integration
# Check what user is currently doing
screen_summary = get_ambient_summary(last_30_minutes)
# Result: "User has billing_calculator.py open, looking at
# calculate_enterprise_discount() function"
# Budget check: 8K archival + 4K recent + 2K ambient = 14K (under budget)
Step 4: Fast vs Complete Trade-off Agent has two options:
Decision: Stay with fast retrieval for initial response. If user asks for deeper investigation, trigger a follow-up with expanded context budget.
Agent Response Quality:
Use /always-on-agent-inputs for:
Do NOT use for:
/always-on-agent-architecture/always-on-agent-applications/always-on-agent-safety/prompt-engineer/agentic-patternsnpx claudepluginhub curiositech/windags-skills --plugin windags-skillsProvides patterns and principles for building reliable autonomous agents: agent loops (ReAct, Plan-Execute), goal decomposition, reflection, and production guardrails. Useful when designing constrained, domain-specific agents.
Diagnoses context stuffing vs. context engineering in AI workflows. Helps fix bloated, brittle, or unreliable AI outputs by designing better context structure.
Guides creation, editing, and verification of skills for AI coding agents using test-driven development with subagent scenarios. Use when authoring or debugging skills.