lsp

A command-line tool for configuring language servers from a community registry. A language server is a program that helps development tools understand a programming language, such as by finding symbols in source code.

In plain words
What is it for?
Use it to add, list, update, and diagnose language-server settings in `.ctx/config.toml`.
Why use it?
It lets `ctx index` extract code symbols for supported languages through declarative configuration. It also checks configured servers and updates registry entries without executing commands during installation.

Command

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 commands/agentis-tools/ctx/lsp
Clone the repo
git clone --depth 1 https://github.com/agentis-tools/ctx
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,047 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.00000 $0.03047
Opus 5 $0.00000 $0.01523
Sonnet 5 $0.00000 $0.00609
Haiku 4.5 $0.00000 $0.00305

Measured 2d ago against content hash 5bf5d9fe067a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

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

docs/commands/lsp.md · 250 lines

How it starts

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

ctx lsp

Manage LSP-backed language support from the community registry.

Synopsis

ctx lsp add <LANGUAGE> [--server <NAME>] [--yes] [--json]
ctx lsp list [--available] [--json]
ctx lsp update [LANGUAGE] [--yes] [--json]
ctx lsp doctor [--json]

Description

The lsp command manages [lsp.<language>] blocks in .ctx/config.toml — the declarative registrations that let ctx index extract symbols through any stdio language server (see Add a language via LSP). add installs a curated entry from the community LSP registry, list shows what is configured (or available), update refreshes registry-installed entries, and doctor health-checks every configured server.

The registry lives in a separate repository, agentis-tools/ctx-lsp-registry. ctx fetches its raw TOML manifests over HTTPS from the pinned v1 branch (10-second timeout per fetch). Entries whose schema_version is newer than the running binary understands are rejected with a message telling you to upgrade ctx.

Trust model

ctx lsp add never executes anything. It writes a TOML block to .ctx/config.toml — nothing else:

  • The command, arguments, install hint, and homepage from the registry are shown to you first, and nothing is written until you confirm (--yes skips the prompt).
  • The install hint (e.g. npm install -g pyright) is printed for you to run yourself; ctx never installs a server.
  • The server binary itself is only ever executed later, by ctx index (when a matching file is indexed) or by ctx lsp doctor (as an explicit health probe).
  • Hand-written [lsp.<language>] entries are never touched: add refuses to overwrite them and update refuses to refresh them. Only entries carrying the source = "registry" provenance key are managed by these commands.
  • Config writes are format-preserving and atomic: comments, formatting, and unrelated tables in .ctx/config.toml survive byte-for-byte.

Read the full file on GitHub · 250 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. 2d ago First seen · 250 lines · 0 tokens per session scan A 5bf5d9fe067a

Subscribe to this mod's changes

lsp is a command published in the GitHub repository agentis-tools/ctx (11 stars, last pushed 15d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 3,047 tokens. 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-30.