raven-router

raven-router is a cursor rule for Claude Code, Cursor from giggsoinc/raven. It costs 247 tokens per session, scanned A, original, MIT.

A turn-by-turn routing rule that runs a Python command before the agent does anything else. It prints the host, rules, memory, expected route, and the user’s intent.

In plain words
What is it for?
It is for enforcing startup procedures, choosing a route for each request, loading limited memory when needed, and tracking session state and cost.
Why use it?
It gives every user turn the same startup checks and routing process across supported coding environments. It can also pause after a guided briefing until the user approves continuing.

Cursor rule for Claude CodeCursor

Written for Claude Code and Cursor: ${CLAUDE_PLUGIN_ROOT} variable, but also installed under .cursor/.

Runs only inside a plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else, and the catalogue could not identify which plugin ships it.

Install

Getting it into your agent

There is no command for this one: it runs only inside a plugin, and the catalogue could not identify which plugin ships it. The source is linked below.

Made for: Claude Code, Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for raven-router

README.md
[![agentmods](https://agentmods.dev/badge/rules/giggsoinc/raven/raven-router.svg)](https://agentmods.dev/rules/giggsoinc/raven/raven-router)
Your own site
<a href="https://agentmods.dev/rules/giggsoinc/raven/raven-router"><img src="https://agentmods.dev/badge/rules/giggsoinc/raven/raven-router.svg" alt="Measured on agentmods" height="20"></a>
Per session 247 This file is loaded in full into every session.
When invoked 247 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00247 $0.00247
Opus 5 $0.00123 $0.00123
Sonnet 5 $0.00049 $0.00049
Haiku 4.5 $0.00025 $0.00025

Measured 5d ago against content hash 3c0fe7197934, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

raven-router scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/raven-router.mdc · 18 lines

What it actually says

First load (same UX every IDE)

  1. python3 scripts/ops/raven-first.py --boot — print host/rules/memory/load/educate/route/expected_route/first_load Fallback: python3 "${CLAUDE_PLUGIN_ROOT}/scripts/ops/raven-first.py" --boot
  2. If load=1, Read only the memory= card
  3. python3 scripts/ops/raven-first.py --session-start — print banner
  4. Every later turn before any other tool: python3 scripts/ops/raven-first.py --prompt "<user message>" Fallback: python3 "${CLAUDE_PLUGIN_ROOT}/scripts/ops/raven-first.py" --prompt "<user message>"

Do not lead with bash scripts/raven-python.sh as the only path — raven-first copies the engine into the app repo when missing.

Print 🔀 then 💰 then educate= expected= then session= then Intent:. git log/status is not an exemption. educate=guided: briefing then STOP until go ahead.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 18 lines · 247 tokens per session scan A 3c0fe7197934

Subscribe to this mod's changes

raven-router is a cursor rule published in the GitHub repository giggsoinc/raven (5 stars, last pushed 5d ago), licensed MIT. It adds 247 tokens to every session, about $0.0012 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.