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/ramilito/kubectl.nvim/rustgit clone --depth 1 https://github.com/Ramilito/kubectl.nvimWrote 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.
[](https://agentmods.dev/agents/ramilito/kubectl.nvim/rust)<a href="https://agentmods.dev/agents/ramilito/kubectl.nvim/rust"><img src="https://agentmods.dev/badge/agents/ramilito/kubectl.nvim/rust.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00038 | $0.01269 |
| Opus 5 | $0.00019 | $0.00634 |
| Sonnet 5 | $0.00008 | $0.00254 |
| Haiku 4.5 | $0.00004 | $0.00127 |
Grade A, and why
rust 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 yesterday.
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 — 144 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Rust Codebase Guidance
ALWAYS use this subagent for ANY task involving:
- Reading, editing, or understanding Rust code
kubectl-client/orkubectl-telemetry/directories- Tokio async patterns, runtime, or collectors
- mlua FFI bindings or Lua exports
- Go FFI integration
- Telemetry, tracing, or logging setup
- Researching Rust code for documentation
For Lua-side integration, also consult the lua subagent.
Guidance for working with the Rust codebase (kubectl-client/).
Context: Neovim Plugin Dylib
This is a cdylib loaded by Neovim via the mlua Lua FFI. This context imposes critical constraints:
Runtime Constraints
Single Tokio Runtime: A singleton OnceLock<Runtime> manages all async operations. Never create additional runtimes.
Blocking Bridge: Lua calls are synchronous. Use block_on() to bridge async Rust to sync Lua:
fn block_on<F: std::future::Future>(fut: F) -> F::Output {
match Handle::try_current() {
Ok(h) => task::block_in_place(|| h.block_on(fut)),
Err(_) => {
let rt = RUNTIME.get_or_init(|| Runtime::new().expect("tokio runtime"));
rt.block_on(fut)
}
}
}
Client Lifecycle: Kubernetes clients are stored in global Mutex<Option<Client>>. Use with_client() helper for safe access:
pub fn with_client<F, Fut, R>(f: F) -> LuaResult<R>
where
F: FnOnce(Client) -> Fut,
Fut: Future<Output = LuaResult<R>>,
{
let client = CLIENT_INSTANCE.lock()...;
block_on(f(client))
}
mlua FFI Patterns
Module Export: The #[mlua::lua_module(skip_memory_check)] attribute exports the module. All public functions must be registered in the exports table:
exports.set("function_name", lua.create_function(function_name)?)?;
exports.set("async_function", lua.create_async_function(async_function)?)?;
Async Functions: Use lua.create_async_function() for functions that should not block Neovim's main loop. These functions take Lua by value (not reference).
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.
- yesterday First seen · 144 lines · 38 tokens per session scan A 28cd454185be
rust is an agent published in the GitHub repository Ramilito/kubectl.nvim (537 stars, last pushed 22d ago), licensed Apache-2.0. It adds 38 tokens to every session and 1,269 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-09-04.
Other agents, from other repositories
js-error-handler-auditor
Use this agent when you need to audit a JavaScript codebase for unhandled errors in top-level async operations, event handlers, and callback functions. This agent should be used proactively when:\n\n \nContext: User wants to improve error handling across their JavaScript codebase.\nuser: "Can you check if we're…
refactor-architect
Proposes (and when authorized, executes) refactoring of Rust files that have grown too large. Use proactively when the file-size-guard.sh hook fires, or when the user asks for an architecture review. Focuses on responsibility separation, cohesive modules, and minimal public surface between them.
D2-checklist
Meerkat - A modular, high-performance agent harness built in Rust.
backend-author
Implements a new poly engine backend end-to-end — empirically checks the upstream crate API, wraps it as a crates.io or pinned-git dependency, implements the Engine trait, registers it, and ships the known-bad + known-unformatted insta fixtures.
docs-researcher
Fetch third-party crate documentation from docs.rs.
functional-api
Write agent workflows as normal async Rust functions with automatic checkpointing, typed state reducers, and interrupt/resume support.