context-audit
यह क्या करती है
यह स्किल AI एजेंट को उन हमेशा-लोड होने वाली संदर्भ फ़ाइलों की समीक्षा में मार्गदर्शन देती है, जैसे CLAUDE.md और memory फ़ाइलें। यह उन लोगों के लिए है जो चाहते हैं कि उनका एजेंट तेज़ हो और निर्देश अधिक भरोसेमंद ढंग से माने।
कब इस्तेमाल करें
- ✓जब आपके एजेंट की निर्देश फ़ाइलें लंबी हो गई हों और आप उन्हें छोटा करना चाहें।
- ✓जब आपको शक हो कि दो निर्देश फ़ाइलें आपस में विरोधाभासी हैं।
- ✓जब आप हर कटौती के लिए जोखिम स्तर के साथ रैंक की गई सूची चाहें।
Skill का लिंक
https://github.com/garrytan/gbrain/blob/master/plugin-variants/gbrain-coding/skills/context-audit/SKILL.mdइसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।
कैसे इस्तेमाल करें
सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।
पेस्ट करने के लिए तैयार मैसेज
Claude Code, Codex या Cursor के लिए: प्रोजेक्ट फ़ोल्डर में चलाएँ और skill इंस्टॉल हो जाएगी।
SKILL.md डाउनलोड करें और अपने एजेंट के skills फ़ोल्डर में रखें।
AI से क्या माँगें: उदाहरण
“मेरी CLAUDE.md और memory फ़ाइल लंबी हो रही हैं। क्या आप उनका ऑडिट करके बता सकते हैं कि पहले क्या छाँटना चाहिए?”
हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।
यह कैसे काम करती है
आपका एजेंट हर टर्न पर लोड होने वाली हर फ़ाइल की सूची बनाता है, दोहराव, विरोधाभास और पुरानी सामग्री खोजता है, फिर सबूत के साथ रैंक की गई कार्य-सूची देता है।
तकनीकी सामग्री (मूल SKILL.md)
लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।
context-audit — Token Hygiene for the Always-Loaded Context Stack
Convention: see conventions/brain-first.md — before running a fresh audit, check the brain for prior audit reports (
gbrain recall "context audit report") so you can compute token DRIFT since the last run and avoid re-flagging findings the user already declined.Convention: see conventions/quality.md — every finding cites its file and evidence; no unsourced claims.
What this is
Every file that loads on every turn is a per-turn tax: tokens, latency, and — past a point — instruction-following quality. Always-loaded files accrete (append-only release notes, promoted memory blocks nobody re-reads, rules restated in three files that drift into contradiction). This skill audits the whole always-loaded stack at once and returns a ranked, evidence-cited action list sorted by token savings.
It is an auditor, not a surgeon. It measures, finds, ranks, and recommends. The user (or a skill the user explicitly invokes afterward) applies changes.
Scope: what counts as "always-loaded"
Enumerate what THIS harness actually loads every turn — do not assume a fixed list. Typical stack:
| File | Role | Fix belongs in |
|---|---|---|
project CLAUDE.md / AGENTS.md |
orientation, routing, invariants | the file itself (source-editable) |
user-global CLAUDE.md |
cross-project instructions | the file itself (source-editable) |
auto-memory MEMORY.md |
promoted memory blocks | the memory store (demote/expire) |
SOUL.md, USER.md, ACCESS_POLICY.md, HEARTBEAT.md, rendered AGENTS.md |
bootstrap-rendered identity files | the interview answer bank / templates — NEVER the rendered file |
| harness system-prompt fragments (identity/tools files) | per-harness | wherever that harness sources them |
Skills, reference docs, and anything loaded on demand are OUT of scope as audit subjects — but they are the DESTINATION for skill-extraction findings (content that only matters for one workflow should move out of the always-loaded stack into a skill).
Contract
This skill guarantees:
- Report-only. No audited file is edited, no page is written, nothing is auto-fixed — including 🟢 zero-risk findings. The output is a recommendation list the user applies deliberately.
- Rendered-file safety. Any recommendation touching a bootstrap-rendered
file is expressed as an answer-bank or template change
(
gbrain bootstrap interview --set KEY "..."thengbrain bootstrap render --only <FILE> --force), never as a direct edit. See skills/soul-audit/SKILL.md for the mechanics. - Estimated with a stated basis, never invented. Token figures come from
the deterministic pre-pass (
wc -cbytes/2.8 — Claude-family tokenizers run ~2.6-3.5 bytes/token on markdown dense with paths and code spans; 2.8 is the calibrated midpoint of measured always-loaded markdown, see #4988). The report prints the divisor so a reader can re-derive every number. If the host client reports an exact per-category context breakdown (e.g. Claude Code/context), that figure outranks the estimate — quote it and use it for the stack total. - Native judging. The draft report is quality-gated through
gbrain eval cross-modal— no raw model API calls, no hardcoded model IDs. - Cost line. Default judging is ONE cheap model (the user's utility-tier
model, all three slots,
--cycles 1— a few cents). The full three-provider frontier panel runs only when the user explicitly asks for a "full" or "multi-model" audit (~3x+ the cost per cycle).
Procedure
1. Enumerate the stack (deterministic)
List the always-loaded files for this harness and measure each:
# bytes/2.8 (calibrated for Claude-family tokenizers on markdown, #4988); integer ceil: (n*10+27)/28
for f in CLAUDE.md AGENTS.md SOUL.md USER.md ACCESS_POLICY.md HEARTBEAT.md MEMORY.md; do
[ -f "$f" ] && echo "$f: $(wc -c < "$f") bytes (~$(( ( $(wc -c < "$f") * 10 + 27 ) / 28 )) tokens)"
done
Record the total. If a prior audit report exists in the brain, compute drift (net tokens grown/shrunk since last run, which files moved).
2. Read and analyze (the agent does this — no model calls yet)
Read every file in the stack in full. Evaluate against six dimensions:
- Token efficiency — tokens spent per unit of behavioral value
- Redundancy — the same rule/
अक्सर पूछे जाने वाले सवाल
क्या यह मेरी फ़ाइलें बदलती है?
नहीं। स्किल एक ऑडिटर है, जो मापता और सिफ़ारिश करता है; बदलाव आप या चुनी हुई स्किल लागू करती है।
यह क्यों मायने रखता है?
स्किल समझाती है कि हर हमेशा-लोड होने वाली फ़ाइल हर टर्न पर tokens खर्च करती है और निर्देशों के पालन को नुकसान पहुँचा सकती है।
क्या यह पिछली रिपोर्ट देखती है?
हाँ। यह पिछले ऑडिट की रिपोर्ट के लिए ब्रेन देख सकती है, ताकि पिछली बार से बदलाव मापा जा सके।
जानकारी
लेखक का मूल विवरण
Token-hygiene audit of the always-loaded context stack — CLAUDE.md, AGENTS.md, auto-memory MEMORY.md, and the bootstrap-rendered identity files (SOUL.md, USER.md, ACCESS_POLICY.md, HEARTBEAT.md) or their harness equivalents. Finds redundancy, contradictions, stale content, compression candidates, and skill-extraction candidates; produces a ranked action list sorted by token savings with a risk class per finding. REPORT-ONLY: this skill never edits any audited file. Recommendations for bootstrap-rendered files target the interview answer bank / templates, never the rendered output. Judging rout
repo: garrytan/gbrain
लोकप्रियता
- GitHub स्टार
- 31k
- रैंकिंग में स्थान
- #9252
- लाइसेंस
- MIT
- अपडेट की गई
- 2/11/2026
कमेंट
- …
इस repository की और skills
gbrain
31kयह आपके एजेंट को लोगों, प्रोजेक्ट और फ़ैसलों के बारे में तथ्य खोजने के लिए साझा कंपनी ज्ञान ब्रेन में खोजने और उसमें स्थायी नोट सहेजने देती है।
brain-ingest-gate
31kयह आपके एजेंट को नई सामग्री जोड़ने से पहले मौजूदा ज्ञान ब्रेन से जाँचने देती है, ताकि डुप्लिकेट न बनें और नामित इकाइयाँ पहले सुलझें।
brain-link-discipline
31kयह सुनिश्चित करती है कि आपका एजेंट हर उस ब्रेन पेज का काम करने वाला लिंक उसी संदेश में दे, जिसकी वह रिपोर्ट करता है, ताकि आप उसे तुरंत खोल सकें।
brain-ops
31kयह आपके एजेंट को ज्ञान ब्रेन की मुख्य दिनचर्या देती है: पहले मौजूदा संदर्भ जाँचना, स्पष्ट नोट उनके स्रोत के साथ सहेजना, और संबंधित पेज जोड़ना।
मिलती-जुलती skills
writing-skills
311kयह आपके एजेंट को नई स्किल लिखना और हर एक को पहले टेस्ट करना सिखाती है, यह जांचते हुए कि स्किल सच में उसका व्यवहार बदलती है।
writing-for-agents
310kAI एजेंट्स के लिए साफ़ निर्देश कैसे लिखें, यह समझाती है, जिसमें स्किल, AGENTS.md और CLAUDE.md फ़ाइलें शामिल हैं, ताकि एजेंट अनुमानित ढंग से व्यवहार करे।
bengali-nlp
280kयह आपके एजेंट को Bengali text प्रोसेस करने देता है। यह भाषा को समझने और उसके text को normalize करने जैसी उसकी खास बातों को संभालने में मदद करता है।