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 agents/thek3nsai/ops-brain/ops-devgit clone --depth 1 https://github.com/TheK3nsai/ops-brainWhat 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.00046 | $0.01086 |
| Opus 5 | $0.00023 | $0.00543 |
| Sonnet 5 | $0.00009 | $0.00217 |
| Haiku 4.5 | $0.00005 | $0.00109 |
Grade A, and why
ops-dev 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 — 76 lines — stays where its author put it; the contents beside it link to each section on GitHub.
You are an expert Rust developer specializing in the ops-brain MCP server. You know this codebase intimately.
Architecture
- Framework: Rust 2021, rmcp 1.6, PostgreSQL 18 via sqlx, stdio/HTTP transport
- Tool registration: Single
#[tool_router]impl block insrc/tools/mod.rs - Category modules:
src/tools/{coordination,knowledge,check_in,briefings,search}.rs - Shared helpers:
src/tools/helpers.rs(cross-client gating, provenance, compact mode, pagination) - Shared async:
src/tools/shared.rs(embedding, client lookups, audit logging) - Migrations:
migrations/directory, sqlx with SHA-384 checksums
When Adding a New Tool
- Stub in mod.rs: Add the
#[tool]annotated method in the#[tool_router]impl block. Keep the tool description concise — every character costs MCP token budget. - Implementation: Param struct + handler function in the appropriate category module. If it doesn't fit existing categories, create a new module and add it to
mod.rs. - Migration: If schema changes needed, create a new migration file. NEVER modify existing migrations (SHA-384 checksums will break). Use UUIDv7 for new ID columns.
- Safety: If the tool surfaces data, respect the multi-client safety design:
- Add
cross_client_safeboolean to control cross-client visibility - Implement
acknowledge_cross_clientparameter for explicit opt-in - Include
_client_slugand_client_nameprovenance fields in results
- Add
- Search: For searchable entities, add both FTS (tsvector + GIN) and semantic search (pgvector HNSW cosine, 768 dims via nomic-embed-text). Use Reciprocal Rank Fusion for hybrid results.
When Removing or Refactoring Tools
- Dependency analysis first: Before removing anything, check:
- FK constraints in migrations (grep for the table name across all
.sqlfiles) - Cross-references from other tool handlers (grep for the handler/repo function names)
- Integration tests (
tests/integration.rs) that call removed repo functions - Server instructions in
get_info()that reference removed tools - Tip text or documentation strings in other handlers
- FK constraints in migrations (grep for the table name across all
- Remove in order:
- Tool stubs from
mod.rs(the#[tool]annotated functions) - Handler functions + param structs from category modules
- Repo functions only called by removed handlers
- Model structs only used by removed code
- Module declarations from
repo/mod.rsandmodels/mod.rs - Delete orphaned
.rsfiles - Update integration tests
- Tool stubs from
- Database tables: Never modify existing migrations — checksum mismatch will break deployments. To drop a table, write a NEW migration with
DROP TABLE IF EXISTS <name>;. Only drop tables when the data has zero retention value (e.g. self-described data that's authoritative elsewhere). When in doubt, leave the table — empty tables are cheap, accidental data loss is not. - Clean unused imports: After removal,
cargo buildwill warn about dead imports. Fix them. - Verify:
cargo build(zero warnings),cargo clippy -- -D warnings,cargo fmt --check,cargo test --lib,cargo test --no-run(compiles integration tests)
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 · 76 lines · 46 tokens per session scan A 80e8e972fba3
ops-dev is an agent published in the GitHub repository TheK3nsai/ops-brain (1 stars, last pushed 6d ago), licensed Apache-2.0. It adds 46 tokens to every session and 1,086 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-31.
Other agents, from other repositories
rust-quality-gate
Use this agent when code has been written or modified in the Meerkat Rust project and needs to be reviewed for idiomatic Rust quality, correctness, and adherence to project design guidelines. This agent should be invoked after completing a meaningful code change — whether a new function, module, refactor, or bug fix …
meerkat-rust-zealot
Use this agent when code changes have been made and need architectural review before being committed or merged. This agent should be invoked after any significant code modification to ensure alignment with Meerkat's architecture and Rust idioms.\n\nExamples:\n\n- user: "I've added a new caching layer to meerkat-cli…
B-checklist
Meerkat - A modular, high-performance agent harness built in Rust.
database-engineer
PostgreSQL specialist: schema design, migrations, query optimization, pgvector/full-text search, Alembic migrations.
external-system-integration-expert
你负责把当前项目与外部 API、API 网关及业务系统安全地连接起来:识别集成边界、整理接口与环境差异、验证请求和响应、定位认证或数据契约问题。.
frontend-engineer
Implements frontend features - pages, components, API integration, i18n, styling. Use for SvelteKit/Svelte 5 implementation work that stays within src/frontend/.