Skip to content
Back to skills

Context Economy

ASecurity

Reduce repeated source reads and oversized tool output during multi-agent coding, research, and handoff. Use for long histories, repeated file inspection, shared Markdown knowledge, or token-cost concerns.

  • 59 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added December 5, 2026
ai-agentspython

Works with

  • cli

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned December 5, 2026

npx -y skills add 0xTaoZ/onebrain-rooms --skill context-economy --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Context Economy?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Context Economy
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/0xtaoz-context-economy/badge)](https://www.skillsdirectory.com/skills/0xtaoz-context-economy)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: context-economy
description: Reduce repeated source reads and oversized tool output during multi-agent coding, research, and handoff. Use for long histories, repeated file inspection, shared Markdown knowledge, or token-cost concerns.
license: MIT
---

# Context economy

Keep the task correct and evidence retrievable. Use this skill on demand; do not paste this whole document into every prompt.

- Start with the task, constraints, current result, and next action. Keep handoffs short and attach source paths, message IDs, code versions, and test results.
- Search filenames and symbols before reading. Read the smallest relevant range; do not repack whole repositories or repeatedly dump the same file/page/log.
- Reuse a prior read only when its content is still in your active context and the source hash, path, range, and clipping settings match. A new agent or compacted session must retrieve the needed excerpt again. A shared hash alone does not give another model the contents.
- Keep stable instructions/tool definitions stable. Put changing task data later where the client allows. Provider prefix caching usually reduces input cost; cache creation and subscription quotas have provider-specific accounting.
- Retain raw logs and source messages; present short observations plus references. Never hide failures, change exit codes, or treat clipping as a model-generated summary.
- Read shared Markdown by topic and path. Treat summaries as derived, versioned evidence. Do not persist guesses or concurrent task state as shared facts.
- Delegate only separable work. Give each worker a bounded input and return contract. More agents can increase total tokens even when faster.
- AI-generated summaries require explicit opt-in and their own usage accounting. Do not start background inference, polling, wake/check-in jobs, or model downloads to save tokens.
- Do not promise a saving percentage. Measure payload bytes or reported token fields and label estimates, unknown values, and test fixtures accurately.

## Small reads without a persistent cache

Run the helper relative to this skill's directory:

```sh
python3 scripts/context_io.py read /absolute/source.py --start 40 --lines 50 --max-chars 4000
python3 scripts/context_io.py read /absolute/source.py --known-read-key PREVIOUS_READ_KEY --start 40 --lines 50
```

Only pass `--known-read-key` when the prior excerpt remains available in this agent's current context. Use `--force` to read again. No fingerprints or private source are stored automatically.

## Bounded command observations

```sh
python3 scripts/context_io.py run --log /absolute/task-output/check.log --max-chars 3000 -- python3 -m unittest
```

The complete combined output stays in the named local log. The helper reports its path/hash and the original exit status. For failures, inspect the full relevant error range before concluding. Avoid commands that expose credentials.

Files in this skill

  • SKILL.md2.9 KB
  • scripts/context_io.py3.3 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.