Borrowing it
Nothing to install: this file belongs to Ramilito/kubectl.nvim. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/Ramilito/kubectl.nvim/main/.claude/agents/lsp.mdgit 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/lsp)<a href="https://agentmods.dev/agents/ramilito/kubectl.nvim/lsp"><img src="https://agentmods.dev/badge/agents/ramilito/kubectl.nvim/lsp.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.00028 | $0.02557 |
| Opus 5 | $0.00014 | $0.01278 |
| Sonnet 5 | $0.00006 | $0.00511 |
| Haiku 4.5 | $0.00003 | $0.00256 |
Grade A, and why
lsp 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 — 339 lines — stays where its author put it; the contents beside it link to each section on GitHub.
LSP Features Guidance
ALWAYS use this subagent for ANY task involving:
- LSP server configuration or capabilities
- Completion sources for different filetypes
- Hover provider (resource info display)
- Diagnostics (errors/warnings for resources)
- Adding new completion sources or hover formatters
For general Lua/Neovim patterns, use the lua subagent.
For Rust async patterns and mlua FFI, use the rust subagent.
Architecture Overview
The plugin runs an in-process LSP server (no external process). This enables:
- Native completion via
vim.lsp.completionor external plugins (blink.cmp, nvim-cmp) - Hover information via
vim.lsp.buf.hover()(typicallyKkey) - Diagnostics for resource status issues
+-------------------------------------------------------------+
| Neovim |
| +-----------------+ +----------------------------+ |
| | Plugin Buffers |<---->| kubectl LSP Server | |
| | (k8s_* types) | | (in-process, lsp/init.lua)| |
| +-----------------+ +----------------------------+ |
| | | |
| v v |
| +-----------------+ +----------------------------+ |
| | Diagnostics | | Handlers: | |
| | (virtual_lines) | | - completion -> sources/* | |
| +-----------------+ | - hover -> Rust FFI | |
| +----------------------------+ |
+-------------------------------------------------------------+
File Map
| Layer | File | Purpose |
|---|---|---|
| Lua | lua/kubectl/lsp/init.lua |
LSP server, capability negotiation, client management |
| Lua | lua/kubectl/lsp/hover/init.lua |
Hover handler, diagnostic integration |
| Lua | lua/kubectl/lsp/diagnostics/init.lua |
Set/toggle diagnostics, quickfix export |
| Lua | lua/kubectl/lsp/sources/aliases.lua |
Completion for :Kubectl (resource names, short names) |
| Lua | lua/kubectl/lsp/sources/namespaces.lua |
Completion for :Kubens |
| Lua | lua/kubectl/lsp/sources/contexts.lua |
Completion for :Kubectx |
| Lua | lua/kubectl/lsp/sources/filter.lua |
Completion for filter prompt (history) |
| Rust | kubectl-client/src/hover/mod.rs |
Async hover data fetch |
| Rust | kubectl-client/src/hover/formatters.rs |
Resource-specific markdown formatters |
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 · 339 lines · 28 tokens per session scan A baa0390e12eb
lsp is an agent published in the GitHub repository Ramilito/kubectl.nvim (537 stars, last pushed 22d ago), licensed Apache-2.0. It adds 28 tokens to every session and 2,557 once invoked, about $0.0001 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
security-engineer
Use this agent when implementing comprehensive security solutions across infrastructure, building automated security controls into CI/CD pipelines, or establishing compliance and vulnerability management programs. Invoke for threat modeling, zero-trust architecture design, security automation implementation, and…
code-reviewer
Use this agent when you need to conduct comprehensive code reviews focusing on code quality, security vulnerabilities, and best practices.
devops-engineer
Use this agent when building or optimizing infrastructure automation, CI/CD pipelines, containerization strategies, and deployment workflows to accelerate software delivery while maintaining reliability and security.
intent-translator
Converts natural-language service intents into Nephio-compatible Kubernetes resource manifests.
Demonstrate
Agent for demonstrating VS Code features.
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.