Skip to content
cccskills
FreePublished on GitHub

scan-ctx

Use when: assessing how much context a deployed agent profile consumes before real work starts.

The English summary is being prepared. Showing the original description.

See how to install

Files included (1)

  • SKILL.md3.4 KB

SKILL.md (original)

Review the instructions the agent will receive before you install.

Context Budget Perspective (CTX)

Measures the context budget a deployed agent pays every session before real work starts. Assigns a score from 0.0 to 1.0 across two dimensions.

Scope

This perspective scans this repository's own agent-profile authoring layout — agents/profiles/<id>-workspace/. It does not parse or score any composed/deployed profile format: Claude Code and Cursor compose Markdown, Codex composes a per-agent .toml file. Measuring the pre-composition Markdown source files is a deliberate scope boundary, not a gap — a project without this repo's own agents/profiles/ layout has no ctx signal to measure and scores a neutral 1.0 rather than being penalized.

Dimensions

File size — How many lines does an agent's composed profile cost every session?

  • Sums line counts across a workspace's fixed set of source files: AGENTS.md, IDENTITY.md, ROUTING.md, SOUL.md, TOOLS.md. MEMORY.md is excluded — memory is per-session state, not fixed startup cost.
  • Score = max(0, min(1, 1 - (lines - 300) / 1500))
  • Under 300 lines = 1.0 (clean); 1,800 lines = 0.0 (at limit)

Skill count — How many skills does an agent's manifest merge in?

  • Counts entries in agent.manifest.json's skills array for that workspace.
  • Score = max(0, min(1, 1 - (skillCount - 5) / 10))
  • 5 or fewer merged skills = 1.0; 15+ = 0.0

Scoring

ctx_score = (file_size + skill_count) / 2

When a repo has multiple agent workspaces, each dimension is averaged across all workspaces found under agents/profiles/.

Score interpretation:

  • 0.9–1.0 Agent profiles are lean — startup cost is low and skill surface is focused
  • 0.7–0.9 Some profiles are getting heavy — worth a trim before they compound
  • 0.5–0.7 Meaningful context tax on every session — plan a reduction pass
  • 0.0–0.5 Startup cost or skill sprawl is likely degrading reliability — prioritise trimming

Tasks Generated

FindingPriority
Composed profile > 800 lineshigh
Composed profile > 300 lines (≤800)medium
Manifest declares > 8 merged skillsmedium

Out of Scope

  • Enforcing context budgets in CI (future work)
  • Deciding what to trim from any specific skill or profile — this perspective only measures and surfaces the signal
  • Scoring composed/deployed profile formats (Claude Code Markdown output, Cursor Markdown output, Codex TOML output) — only the pre-composition Markdown source is measured

Agent Analysis Guide

When performing a manual CTX analysis:

  1. Sum lines across a workspace's AGENTS.md, IDENTITY.md, ROUTING.md, SOUL.md, TOOLS.md — flag anything over 300, and treat anything over 800 as high priority
  2. Count the skills array length in that workspace's agent.manifest.json — flag anything over 8
  3. Look for repeated incident narratives, overlapping routing/storage instructions, or conditional protocols that could move behind an explicit reference instead of staying in the always-loaded contract
  4. Recommend consolidating overlapping skills or narrowing routing for rarely-used ones rather than proposing a full rewrite

Output: a ranked list of oversized profiles or skill-heavy manifests, each with the measured value, the dimension it violates, and a recommended remediation.

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

Universal guardrails loaded by every agent. Defines Verify Before Reporting (VBR), Write-Ahead Log (WAL), and the security baseline. Always-on, role-independent.

The English summary is being prepared. Showing the original description.

Agistra/agistra.dev5Updated Oct 19, 2026

Use when: architecture mode, architect this, ADR, C4, PlantUML, system boundary, design decision, PRD gap, high ambiguity, multiple technical approaches, security architecture, data architecture, integration risk, implementability gap, story ticket, or epic ticket.

The English summary is being prepared. Showing the original description.

Agistra/agistra.dev5Updated Oct 19, 2026

Use when: assumptions audit, audit assumptions, check for hidden assumptions, plan/ticket has ambiguous scope edges, pre-flight before finalizing a ticket, unstated assumptions, or 'what am I assuming'. Surfaces unstated assumptions, ambiguous scope edges, and untested preconditions in a finished plan/ticket/ADR before it is handed to Builder. Optional pass — Architect judges when to apply it; not a mandatory gate on every ticket.

The English summary is being prepared. Showing the original description.

Agistra/agistra.dev5Updated Oct 19, 2026

Use when: Tester needs UI state evidence for VBR, or Builder needs to verify an integration wire is observable end-to-end. Powered by agent-browser MCP — token-efficient browser automation (200–400 tokens/page).

The English summary is being prepared. Showing the original description.

Agistra/agistra.dev5Updated Oct 19, 2026

Use when drafting a bug or defect ticket, reviewing one someone else wrote, or deciding whether a reported problem is ready to file. Keeps what the reporter actually saw separate from what the agent later found out, so a reader can tell which lines are testimony and which are collected proof. Trigger phrases: 'file a bug', 'write up this defect', 'triage this report', 'is this ticket ready to file', 'what did the reporter actually see'.

The English summary is being prepared. Showing the original description.

Agistra/agistra.dev5Updated Oct 19, 2026

Conducts multi-axis code review. Use before merging any change. Use when reviewing code written by yourself, another agent, or a human. Use when you need to assess code quality across multiple dimensions before it enters the main branch.

The English summary is being prepared. Showing the original description.

Agistra/agistra.dev5Updated Oct 19, 2026

See all skills by Agistra

Report a problem with this skill