kmp-lsp

kmp-lsp is a skill for Claude Code, Codex from Hessesian/kmp-lsp. It costs 114 tokens per session (3,323 once invoked), scanned A, original, MIT.

Kotlin/Java/Swift LSP server for code navigation in Android and iOS codebases. Use when navigating Kotlin, Java, or Swift source files: finding class definitions, listing symbols, jumping to implementations, finding all usages, checking type signatures, or switching workspace between projects. Triggers for: "find this…

Skill for Claude CodeCodex

Install

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.

agentmods
npx agentmods add skills/hessesian/kmp-lsp/copilot-skill
Any agent
npx skills add Hessesian/kmp-lsp --skill copilot-skill
Clone the repo
git clone --depth 1 https://github.com/Hessesian/kmp-lsp

Made for: Claude Code, Codex.

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 kmp-lsp

README.md
[![agentmods](https://agentmods.dev/badge/skills/hessesian/kmp-lsp/copilot-skill.svg)](https://agentmods.dev/skills/hessesian/kmp-lsp/copilot-skill)
Your own site
<a href="https://agentmods.dev/skills/hessesian/kmp-lsp/copilot-skill"><img src="https://agentmods.dev/badge/skills/hessesian/kmp-lsp/copilot-skill.svg" alt="Measured on agentmods" height="20"></a>
Per session 114 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,323 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00114 $0.03323
Opus 5 $0.00057 $0.01662
Sonnet 5 $0.00023 $0.00665
Haiku 4.5 $0.00011 $0.00332

Measured today against content hash 4cded7570ab2, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

kmp-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 today.

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.

contrib/copilot-skill/SKILL.md · 181 lines

How it starts

The opening of the file, as written. The whole thing — 181 lines — stays where its author put it; the contents beside it link to each section on GitHub.

kmp-lsp — Capabilities & Limitations

⚠️ Prerequisite: Experimental mode required

The lsp tool is only available when Copilot CLI is started with copilot --experimental (or --exp). Without it, the LSP tool does not appear and kmp-lsp will not be connected. If you see no lsp tool available, ask the user to restart with copilot --experimental.

You have access to a Kotlin/Java/Swift LSP server (kmp-lsp) via the lsp tool.

Language support

  • Kotlin / Java — full support: indexing, hover, goToDefinition, workspaceSymbol, goToImplementation, findReferences, rename
  • Swift — structural support: documentSymbol (immediate), hover (property types), goToDefinition (cross-module); no type inference (no sourcekit-lsp backend)

Indexing & Readiness

The server indexes files in the background on startup. Before using workspaceSymbol, always call kmp_lsp_status to check if indexing is complete.

  • Cold index (no cache): 30–70s depending on project size
  • Warm start (from cache): 1–3s
  • Progress shown in editor (0% → live % every 500ms → done)

Cold-start navigation: documentSymbol, hover, and goToDefinition work immediately on any opened file — the current file is indexed on-demand before symbol lookup. workspaceSymbol requires full indexing.

Cache staleness: cache version bump triggers a full re-index automatically. A "Cache deserialize failed" warning means a one-time re-index is occurring.

Workspace root auto-detection

When no config file is set, did_open detects the workspace root using tiered marker priority:

  1. Strong markers (nearest wins): settings.gradle.kts, build.gradle, pom.xml, Cargo.toml — subproject root in a mono-repo
  2. .git — repo root; wins over weak markers
  3. Weak markers: Package.swift — last resort (present at every Swift module, not reliable as root)

This correctly handles mono-repos (e.g. android/settings.gradle.kts beats monorepo .git) and Swift mono-repos (e.g. ios/.git beats nested ios/Modules/*/Package.swift).

Read the full file on GitHub · 181 lines

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. today First seen · 181 lines · 114 tokens per session scan A 4cded7570ab2

Subscribe to this mod's changes

kmp-lsp is a skill published in the GitHub repository Hessesian/kmp-lsp (180 stars, last pushed today), licensed MIT. It adds 114 tokens to every session and 3,323 once invoked, about $0.0006 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.