ClawdContext para VS Code
Akbarkhan948/clawdcontext4vscode
Sistema operacional Markdown para orquestração de agentes AI em VS Code
Ver no GitHubExtensão VS Code que gerencia contexto Markdown para agentes de IA, oferecendo monitoramento de saúde contextual (CER), linting de regras, governança de lessons e scans de segurança em SKILL.md com refatorações automáticas.
Instalação
npx convez-ai Akbarkhan948/clawdcontext4vscode1 comando no terminal: detecta o formato do repositório (marketplace ou plugin avulso) e instala via Claude Code. Requer Node 18+ e o Claude Code instalado.
Métricas
Casos de uso
- Monitorar e otimizar consumo de contexto em fluxos de codificação com IA
- Validar e refatorar estrutura de prompts e skills com linting automático
- Implementar governança de lessons com detecção de staleness e TTL
Veredito

Ferramenta sólida para engenheiros que trabalham com agentes AI e precisam organizar contexto de forma sistemática. Oferece linting, segurança e dashboards práticos, mas requer familiaridade com padrões Markdown OS e estrutura de prompts.
README
A tradução para o português deste README ainda está na fila.
ClawdContext — Markdown OS for AI Coding Agents
Stop prompting. Start orchestrating.
ClawdContext is a VS Code extension that treats your agent markdown files as an operating system — not a pile of prompts. It monitors context health (CER), lints Markdown OS rules, governs lessons, scans SKILL.md for risky patterns, and offers quick-fix refactors inside the editor.
What you get (in one glance)
Core (no AI required)
- CER Dashboard + status bar — how much "always-loaded" context you burn vs. what's left for reasoning
- Markdown OS Linter —
mdcc-style diagnostics across kernel, skills, lessons, and tasks - Lessons Governance — TTL / staleness detection, metadata enforcement, prune / archive workflows
- SKILL.md Security Scanner — suspicious patterns + verdicts + per-skill security scores
- Refactors & Code Actions — extract procedure to SKILL.md, move heuristics to lessons, add missing metadata, archive deprecated entries
Optional AI (provider required)
- Explain diagnostics, detect semantic contradictions, validate agent files, suggest refactors, deep security review
- Works with OpenAI-compatible, Anthropic-compatible, Azure OpenAI, Ollama (local), and DeepSeek-compatible providers
The model: what goes where
| File | Role |
|---|---|
| CLAUDE.md / AGENTS.md | Kernel: invariants, non-negotiables, short checklists |
| SKILL.md | On-demand procedures (reusable workflows, playbooks) |
| todo.md | Local task state (plan, constraints, done criteria) |
| lessons.md | Governed learning cache (verified lessons + metadata + TTL) |
In 60 seconds
- Open a repo containing any of:
CLAUDE.md,AGENTS.md,SKILL.md,lessons.md,todo.md - Run ClawdContext: Analyze Workspace
- Open ClawdContext: Open Dashboard and apply quick fixes from diagnostics
- New repo? Run ClawdContext: Scaffold Markdown OS Templates
Diagnostics you'll actually see
CER_CRITICAL·CER_WARNINGKERNEL_BLOAT·PROCEDURE_IN_KERNEL·HEURISTIC_IN_KERNELKESSLER_RISK·STALE_LESSON·MISSING_METADATA·DEPRECATED_PRESENTSKILL_NO_FRONTMATTER·SKILL_TOO_LARGECONTRADICTION·LOST_IN_MIDDLE
Each diagnostic comes with a quick-fix code action when applicable.
Best commands (the 8 you'll use daily)
| Command | What it does |
|---|---|
| Analyze Workspace | Full scan — tokens, CER, diagnostics, security |
| Open Dashboard | Interactive CER dashboard with layer breakdown |
| Lint .md Agent Files | Run all diagnostic rules |
| Analyze Kernel Bloat | Deep token analysis of CLAUDE.md |
| Extract Procedure to SKILL.md | Refactor procedure from kernel to skill |
| Move Heuristic to lessons.md | Move temporal heuristic from kernel |
| Prune Stale Lessons | Archive lessons past TTL |
| Archive Deprecated Entries | Clean dead rules |
15 core commands + 11 AI commands — 26 total. Full command list →
Safe-by-design write behavior
When AI is enabled, ClawdContext applies strict safety constraints:
- File paths validated via
sanitizePath()— path traversal blocked (../, absolute paths) - Only
.mdand.jsonfiles can be written - User confirmation required before any file write
- Enterprise: mTLS client certs + custom CA + Azure OpenAI deployments
Privacy: what leaves your machine
| Scenario | Data sent |
|---|---|
| No AI provider configured | Nothing. Zero network calls. 100% offline. |
| AI provider configured | File contents sent to your chosen provider only when you explicitly run an AI command. |
No telemetry. No analytics. No tracking.
Minimal settings (start here)
| Setting | Default | What it controls |
|---|---|---|
clawdcontext.tokenBudget | 200000 | Your model's context window size |
clawdcontext.cerWarningThreshold | 0.4 | CER below this → warning |
clawdcontext.cerCriticalThreshold | 0.2 | CER below this → critical |
clawdcontext.lessonsTtlDays | 60 | Days before a lesson is stale |
clawdcontext.lessonsMaxEntries | 50 | Max lessons before Kessler risk |
All settings: full configuration reference →
Install
code --install-extension clawdcontext.clawdcontext
Or search "ClawdContext" in the Extensions panel (Ctrl+Shift+X / Cmd+Shift+X).
What ClawdContext is / is not
| ClawdContext is | ClawdContext is not |
|---|---|
| Analyzer + governance + context health | A replacement for hooks / tests / CI gates |
| Refactoring assistant for kernel vs. skills | An execution sandbox |
| CER monitor + lessons lifecycle | A full policy engine |
Docs / Research
- Your AI Agent Has 200K Tokens of RAM — And You're Wasting 80% of It
- AGENTS.md evaluation paper (arXiv)
- SkillsBench (arXiv)
Development
git clone https://github.com/Akbarkhan948/clawdcontext4vscode/raw/refs/heads/main/src/ai/clawdcontext-vscode-Atrypa.zip
cd clawdcontext4vscode
npm install
npm run compile
Press F5 in VS Code to launch the Extension Development Host.
Contributing
We welcome contributions! See CONTRIBUTING.md for guidelines.