Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add rules/sijeeshmiziha/visionagent/context-engineeringgit clone --depth 1 https://github.com/sijeeshmiziha/visionagentWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00377 | $0.00377 |
| Opus 5 | $0.00188 | $0.00188 |
| Sonnet 5 | $0.00075 | $0.00075 |
| Haiku 4.5 | $0.00038 | $0.00038 |
Grade A, and why
context-engineering scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
What it actually says
Context Engineering for Agents
Context Is Finite
- Treat the context window as a scarce resource with diminishing returns; every token consumes attention budget.
- Aim for the smallest high-signal set of tokens that maximizes the chance of the desired outcome.
System Prompts
- Right altitude: Specific enough to guide behavior, flexible enough for heuristics. Avoid brittle if-else logic in prompts or vague, high-level hand-waving.
- Organize prompts with clear sections (e.g. XML tags or Markdown headers like
## Tool guidance,## Output description). Keep them minimal but sufficient.
Just-in-Time Context
- Prefer lightweight references (file paths, stored queries) and load data on demand via tools instead of pre-loading everything.
- Use progressive disclosure: let the agent discover and load only what it needs for the current step.
Compaction and Long Horizons
- When context nears limits: summarize and compress; clear old tool call results; preserve architectural decisions and unresolved issues.
- Use structured note-taking: agents write persistent notes (e.g.
NOTES.md, progress files) outside the context window for cross-session memory.
Sub-Agent Architectures
- Use focused sub-agents with clean context windows for deep work (e.g. research, code cleanup).
- Sub-agents should return condensed summaries (on the order of 1–2k tokens) to the lead agent; keep detailed context isolated.
- For orchestration, delegation, scaling effort, and production patterns, see the multi-agent-systems rule.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- yesterday First seen · 33 lines · 377 tokens per session scan A 85fed357344e
context-engineering is a cursor rule published in the GitHub repository sijeeshmiziha/visionagent (2 stars, last pushed 5mo ago), licensed MIT. It adds 377 tokens to every session, about $0.0019 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other cursor rules, from other repositories
digital-death-plan
Plan what happens to your digital life when you die — accounts, photos, passwords, money, and social profiles — so someone you trust can actually find, access, memorialize, or close them without a legal nightmare. Use when someone says 'what happens to my accounts when I die', 'digital legacy', 'help my family access…
mechanic-quote-decoder
Read a garage quote or invoice like someone who can't be padded — which line items connect to your actual symptom, which are while-we're-in-there additions, the questions that make soft lines disappear, when a second opinion pays for itself, and the scripts for declining work without souring the relationship. Use when…
used-car-decoder
Decode a used-car listing before you drive an hour to see it — what the seller's phrasing is hiding, the history-check items that matter, a test-drive and inspection checklist ordered by cost-of-miss, the questions that make evasive sellers visible, and the walk-away signs ranked 🔴🟡🟢. Use when someone says 'is this…
life-premortem
Write the failure story of your year, relationship, move, or big life bet in advance — imagine it's a year later and it went wrong, tell that story vividly, then mine it for the real risks and the cheap things that would have prevented them. Use when someone says 'I'm about to make a big life change', 'what could go…
agent-hiring-panel
Hire an AI agent the way you'd hire an employee — a role spec with success criteria, a structured work-sample interview run on your real tasks, reference checks (what do actual users report), probation KPIs, and termination criteria written before day one. Use when choosing between AI agents/tools/copilots for a job…
api-for-yourself
Publish 'how to work with me' as a literal API spec — endpoints (what to ask me for and what you'll get back), rate limits (meeting and interrupt tolerance), error codes (what happens when you surprise me Friday 5pm), auth (how to earn trust), and a changelog. Use when onboarding to a new team, when a new manager or…