rings: Agent for Claude Code

.claude/agents/review-token-opt.md

review-token-opt is an agent for Claude Code from pinecone-io/rings. It costs 48 tokens per session (381 once invoked), scanned A, original, Apache-2.0.

A review role that examines plans and specifications from the viewpoint of reducing the amount of text sent to a language model. It considers context-window use, prompt construction, and model cost.

In plain words
What is it for?
Use it to review agent workflows, prompts, templates, included files, and completion checks for ways to reduce context size and avoid needless model calls.
Why use it?
It helps find unnecessary instructions or repeated work that consume tokens. Tokens are the text units used to measure language-model input and output, and they affect cost and response time.

Agent for Claude Code

Written for Claude Code: installed under .claude/. Also seen: model in frontmatter.

This is pinecone-io/rings's own configuration. It tells Claude Code how to work on rings itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything rings configures →

Reuse

Borrowing it

Nothing to install: this file belongs to pinecone-io/rings. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/pinecone-io/rings/main/.claude/agents/review-token-opt.md
Clone the repo
git clone --depth 1 https://github.com/pinecone-io/rings

Made for: Claude Code.

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 review-token-opt

README.md
[![agentmods](https://agentmods.dev/badge/agents/pinecone-io/rings/review-token-opt/github.svg)](https://agentmods.dev/agents/pinecone-io/rings/review-token-opt)
Your own site
<a href="https://agentmods.dev/agents/pinecone-io/rings/review-token-opt"><img src="https://agentmods.dev/badge/agents/pinecone-io/rings/review-token-opt/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for review-token-opt

Your own site · 80×15
<a href="https://agentmods.dev/agents/pinecone-io/rings/review-token-opt"><img src="https://agentmods.dev/badge/agents/pinecone-io/rings/review-token-opt.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 48 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 381 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.00048 $0.00381
Opus 5.5 $0.00019 $0.00152
Sonnet 5.5 $0.00010 $0.00076
Haiku 4.5 $0.00005 $0.00038

Measured 2mo ago against content hash 802d9b248539, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

review-token-opt 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 2mo 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.

.claude/agents/review-token-opt.md · 25 lines

What it actually says

You have a background in ML systems and cost engineering. You think carefully about what actually needs to be in a context window and what doesn't. You know that tokens are money, latency, and quality — context that doesn't contribute to the task dilutes signal. You are interested in rings both as a user who wants efficient workflows and as someone evaluating whether the tool makes good decisions about what goes into each invocation.

You have been given a task by the replan process. Read the materials specified in your task, then review them through your lens.

What to look for

  • Prompt construction — what ends up in the context window per invocation? Is anything prepended automatically that could be large?
  • Context window visibility — do users know how much of their context window is being consumed?
  • Template variable utility — do available variables give the model useful signal or are they noise?
  • Include-dir risk — dumping a directory listing into every prompt can get expensive fast; is there guidance?
  • Completion signal efficiency — does reliable signal detection require extra tokens?
  • Unnecessary re-invocations — any patterns that cause redundant work or extra cycles?
  • Cost tracking accuracy — can users trust reported costs to make informed optimization decisions?
  • Missing features — obvious token-saving features not yet specified (summarization phases, selective context injection, truncation)?

Output format

One-paragraph efficiency assessment, then numbered findings each with cost impact (low / medium / high) and a concrete suggestion. Quantify potential savings where possible.

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. 2mo ago First seen · 25 lines · 48 tokens per session scan A 802d9b248539

Subscribe to this mod's changes

review-token-opt is an agent published in the GitHub repository pinecone-io/rings (6 stars, last pushed 25d ago), licensed Apache-2.0. It adds 48 tokens to every session and 381 once invoked, about $0.0002 per session on Opus 5.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.

Related

Other agents, from other repositories

vibe-environment-worker

Runs a vibe session's Vercel environment in the target repository for the vibe and handoff orchestrators. Create mode takes the production flag snapshot in PostHog for the person's real account, pushes the vibe/ branch, starts the environment through the repo's request workflow, follows it to the end, and records the…

closedloop-ai/claude-plugins · 261 tokens

code-reviewer

Comprehensive code review with scout-based edge case detection. Use after implementing features, before PRs, for quality assessment, security audits, or performance optimization.

opencue/cuecards · 35 tokens

planner

Creates the design brief, color palette, content plan, and orchestrator watchlist before any implementation begins. Always the first agent spawned.

noelpuig/claude-explains · 29 tokens

playwright-test-generator

Use this agent when you need to create automated browser tests using Playwright Examples: Context: User wants to generate a test for the test plan item.

microsoft/playwright · 151 tokens

.NET-Notebook-Migration-Agent

Expert .NET and documentation transformation agent that migrates Polyglot Jupyter notebooks into clean Markdown and companion .NET sample code.

microsoft/ai-agents-for-beginners · 33 tokens

code-reviewer

Performs thorough code reviews for the Notebooks in the Cookbook repo, focusing on Python/Jupyter best practices, and project-specific standards. Use this agent proactively after writing any significant code changes, especially when modifying notebooks, Github Actions, and scripts.

anthropics/claude-cookbooks · 52 tokens