Replies: 1 comment
-
Weekly Update — Deep Research: LSP-MCP Server Selection, Caching Design & Tier GatingWhat ChangedMajor new market signals since initial writeup:
Research Answers to Open QuestionsQ1: Start with dev-lead (code-writing) or pr-review (finding-verification) first? Recommendation: pr-review deep tier first. Rationale:
Q2: Per-run indexing cost — acceptable or need persistent/warm LSP service? Acceptable with mitigations, no sidecar needed. Key data points:
Q3: Pilot language/repo — TS in markets or Shell in .github-private? Start with Shell in .github-private (this repo). Rationale:
Q4: Which LSP-MCP server — Serena vs lsp-mcp vs agent-lsp? Recommendation: agent-lsp. Comparative analysis:
Serena has the production benchmark (AEGIS), but agent-lsp's CI-first design (Go binary, non-interactive mode, GCF token compression, 30-language CI matrix) better fits our ephemeral-runner, multi-engine architecture. Pilot agent-lsp; use Serena results as the success bar to beat. Updated Assessment
RecommendationAdvance — start the pilot. All five open questions from the original writeup now have data-backed answers. The integration path is clear: add
Sources
🤖 Researched & drafted by Mary (BMAD Strategic Business Analyst) with Claude Code |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
TL;DR
Adding LSP (Language Server Protocol) tooling to our agent harness is worth piloting — it gives the agents real semantic code intelligence (go-to-definition, find-references, type resolution, diagnostics) instead of
grep+ file-reading. The clearest wins are dev-lead writing/fixing code and pr-review verifying findings across files. The one catch unique to us: LSP servers must cold-start and index on every ephemeral CI run, so it needs a caching + tier-gating strategy. It would not have helped the config/YAML/secrets incidents we hit recently — LSP raises code-intelligence, not config-intelligence.The problem it solves (in our terms)
Our agents navigate code by
grep+ reading files. That fails exactly where they operate:validateTokenin a string/comment), not semantic ones.node_modules/site-packagesor guessing → a documented source of hallucinated APIs (~20% of AI package suggestions point at libraries that don't exist).LSP replaces that with
textDocument/definition,references,hover,diagnostics,documentSymbol,rename— exact source locations + fully-resolved types, exposed to the agent as MCP tools.Quantified benefits
Why this matters to us specifically: we run a Token Cost Observatory and just had a Gemini-credits-depleted incident. A 5–34× cut on navigation-heavy turns is a direct hit to per-run token spend and rate-limit pressure.
Where it helps in our harness
rename,diagnosticsto self-check before pushing → fewer broken commits.deep/audittiers: before posting "this is undefined / breaks N callers," confirm vialsp_get_diagnostics/lsp_find_references. Directly attacks the false-positive problem (30–42% of AI-review false positives come from misreading context) — which is exactly what erodes trust in an auto-approving agent.engine.sh,review-batch.sh,compliance-audit.sh).bash-language-server+ existingshellcheckgive the agents real navigation over their own substrate.Costs / caveats specific to us
tsserver,gopls,jdtls) must cold-start + index on every run — minutes on a big repo, eating tier budgets. This is the make-or-break operational issue. Mitigations:actions/cachethe LSP index, scope to changed files, gate LSP todeep/auditonly, lazy single-file diagnostics.@v1workflow ref, channel-tag pins, the markets PAT override) — those are YAML/config/secrets, outside LSP's wheelhouse.Recommendation — phased, low-regret
markets, or Shell in.github-private) using an existing LSP-MCP server (e.g. Serena, or the 24-tool CI-verifiedlspMCP server) — don't build one.deep/audittiers and cache the index to keep cold-start off the critical path.lsp_get_diagnostics/lsp_find_referencesbefore posting — measure false-positive rate before/after.Open questions for discussion
marketsor Shell in.github-private?Sources
🤖 Researched & drafted with Claude Code
Beta Was this translation helpful? Give feedback.
All reactions