OpenParable
Skip to content
← Back to skills

Complexity Detection

Productivity
complexity-detection

Complexity Detection is an Agent Skill for productivity published in the hashgraph-online/awesome-codex-plugins repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.

Classify a task or feature as quick, standard, or thorough so the rest of the pipeline (budget sizing, model routing, review depth) can right-size itself. Used by /ck:sketch to default the kit's complexity, by /ck:map to assign task depth, and by /ck:make for per-task budgets. Also invoked by the ck:complexity agent with the haiku model. Trigger phrases: "how complex", "what depth", "pick a depth", "classify this task".

View on GitHub ↗
QUICK START

How to use this skill

Bring this guide into your coding agent with a prompt tailored to the tool you use.

  1. Open your project in Codex.
  2. Copy and paste the prompt below.
  3. Review files and risks before approving any action.
Prompt to paste
Inspect the Agent Skill at https://github.com/hashgraph-online/awesome-codex-plugins/blob/HEAD/plugins/JuliusBrussee/blueprint/skills/complexity-detection/SKILL.md and all supporting files. Report provenance, permissions, scripts, dependencies, and security risks. Propose an exact installation into .agents/skills/complexity-detection, but wait for my approval before writing files or running scripts.

Copying this prompt does not install or run the skill. Review third-party files before use.

Complexity Detection

A deterministic scoring rubric. Five axes, 0–4 each, summed to 0–20.

Axes

Axis01234
Files touched0–23–56–1011–2020+
Typechore / formatrefactorfeaturecross-cuttingarchitectural
Judgment requiredmechanicallow-ambiguitymediumhighcritical (sec/prod)
Cross-componentsingle moduletwo modulesthree modulesmany within one repomulti-repo
Noveltyknown patternrare patternnovelresearch neededunknown unknowns

Total score maps to:

ScoreDepth
0 – 6quick
7 – 13standard
14+thorough

Override signals

Upgrade one step regardless of score when any of these are true:

  • Security-sensitive: authentication, authorization, crypto, secrets, PII.
  • Data migration that is not reversible.
  • Public API shape change (breaking).
  • Performance-critical hot path with an existing SLA.

Downgrade one step only when all of these are true:

  • Zero new dependencies.
  • Existing tests cover the change.
  • No user-visible behaviour change.
  • Single file, single function.

Per-depth defaults

DepthToken budgetModel tierReviewTests
quick8 000haikuoptionalsmoke
standard20 000sonnetrequiredunit + integration
thorough45 000sonnet/opusmandatoryunit + integration + E2E

These defaults are recorded in .cavekit/config.json under task_budgets and consumed by the cavekit-router.cjs model router.

How agents score

The ck:complexity subagent (haiku) receives a task description and returns a JSON blob:

{
  "score": 11,
  "depth": "standard",
  "axes": {
    "files": 2, "type": 2, "judgment": 2, "cross_component": 2, "novelty": 3
  },
  "overrides_applied": []
}

/ck:map calls this agent per task to set depth in the task registry. If the agent produces a score in the "thorough" band with a novelty of 4 and a security override, it may return needs_research: true, which /ck:map must translate into an upstream ck:researcher task dependency before the work itself.

Integration points

  • /ck:sketch — runs complexity scoring on the whole domain to set the kit's complexity: frontmatter.
  • /ck:map — runs it per task to assign depth.
  • /ck:make — reads depth to size the task budget and pick the review intensity.
  • ck:complexity agent — pure-haiku worker; does nothing else.

Anti-patterns

  • Using one depth for every task in a kit "for consistency." Cost up, signal down.
  • Padding depth to "be safe" — if the budget is oversized, the model wastes tokens exploring. Right-size, then raise only when verification fails.
  • Ignoring overrides — scoring a login flow as "quick" because it touches one file. Security overrides exist for exactly this reason.