Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/userfrm/rpg-encoder/rpgnpx skills add userFRM/rpg-encoder --skill rpggit clone --depth 1 https://github.com/userFRM/rpg-encoderWhat 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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00040 | $0.01353 |
| Opus 5 | $0.00020 | $0.00677 |
| Sonnet 5 | $0.00008 | $0.00271 |
| Haiku 4.5 | $0.00004 | $0.00135 |
Grade A, and why
rpg 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 2d 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.
How it starts
The opening of the file, as written. The whole thing — 165 lines — stays where its author put it; the contents beside it link to each section on GitHub.
RPG-Encoder — USE BEFORE grep/cat/find
Reach for RPG first, shell commands second
Whenever the user asks about code structure, behavior, relationships, impact,
dependencies, or cross-file patterns, reach for RPG commands BEFORE falling
back to grep, cat, find, wc, or Read. RPG is indexed, semantically
organized, and answers structural questions in one call that would otherwise
require dozens of chained text searches.
| If you'd otherwise... | Use this instead |
|---|---|
grep -r by intent |
rpg-encoder search "describe what it does" |
grep -r by name |
rpg-encoder search "name" --mode snippets |
cat file for a function |
rpg-encoder fetch "file:func" |
| chained greps for callers | rpg-encoder explore ENTITY --direction up |
| chained greps for callees | rpg-encoder explore ENTITY --direction down |
wc -l / find / tree |
rpg-encoder info |
| reading many files | Use the MCP semantic_snapshot tool if available |
Fall back to grep / cat / Read only when the query is about literal text
(string search, comments, TODOs, log messages) — not structure or semantics.
If you have the RPG MCP server connected, prefer its tools (search_node,
fetch_node, explore_rpg, impact_radius, plan_change, semantic_snapshot,
context_pack) over the CLI — they're faster and return structured data.
You have access to rpg-encoder, a CLI tool that builds semantic code graphs (Repository Planning Graphs) from any codebase. Use it to understand code structure, search by intent, trace dependencies, and perform autonomous semantic lifting.
Quick Reference
Build a graph (run once per repo)
rpg-encoder build
Detects languages automatically, parses all source files, builds structural hierarchy and dependency edges. Creates .rpg/graph.json. Use --force to rebuild.
Search for code by intent
rpg-encoder search "validate user input"
rpg-encoder search "database connection" --mode features
rpg-encoder search "auth" --mode snippets
rpg-encoder search "parse config" --scope DataProcessing
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.
- 2d ago First seen · 165 lines · 40 tokens per session scan A 01a2c1a6884b
rpg is a skill published in the GitHub repository userFRM/rpg-encoder (33 stars, last pushed 3mo ago), licensed MIT. It adds 40 tokens to every session and 1,353 once invoked, about $0.0002 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-30.
Other skills, from other repositories
code-indexing-pipeline
How Infigraph turns source into a graph — adding a language (tree-sitter vs ANTLR grammar-plugin), cross-file call resolution, SCIP compiler-grade enrichment, and file-watch/reindex triage. Use when adding language support, debugging unresolved calls or SCIP import, or triaging stale index/watcher issues.
analysis-subsystems
How Infigraph's multi-repo/group mode and taint analysis work internally — HTTP contract extraction heuristics, cross-service edge linking, combined-graph merge, remote mode, plus taint's line-based tracking and sanitizer heuristic. Use when working on crates/infigraph-core/src/multi/ or src/taint/, or investigating…
review-pr-against-issue
Review one or more PRs against the GitHub issue(s) they claim to fix, including fetching PR branches directly when gh can't reach github.com (e.g. gh is authenticated to an enterprise host instead). Use whenever asked "does this PR fix issue.
verify
Run the self-serve verification loop — boot the current source stack against a golden fixture, assert every layer (MCP write → store → HTTP API → projection → rendered browser UI), and inspect the map visually via headless Playwright. Use when you changed Cartographer's service, store, projection, or UI and need to…
review-pr
Visualize a pull request on the Cartographer map — see which entities are affected, the blast radius, and the review path. Use when user says "review pr", "review pull request", or "/cartographer review-pr".
explore
Deep autonomous codebase exploration — traces behaviors end-to-end, creates boundaries by concern, builds navigable depth with sub-boundaries, enforces quality via cartographercheckdepth. Use when the user says explore, map, understand, or analyze deeply.