xiaohongshu
xiaohongshu
lsp
Code navigation with LSP. When user says "find references", "go to definition", "where defined", "show type", "list symbols", "what uses", or "who calls" - use native LSP tools if available, otherwise fall back to specweave lsp commands.
Full skill instructions
Semantic code navigation and analysis.
⚠️ Native LSP is BROKEN in Claude Code v2.1.0+ (Issue #17468)
| Version | Native LSP | SpecWeave CLI |
|---|---|---|
| ≤2.0.76 | ✅ Works | ✅ Works |
| ≥2.1.0 | ❌ Broken | ✅ Works |
Always use SpecWeave CLI until native LSP is fixed.
# Find all references to a symbol (SEMANTIC, not grep!)
specweave lsp refs <file> <symbol>
# Go to definition
specweave lsp def <file> <symbol>
# Get type information (hover)
specweave lsp hover <file> <symbol>
# List all symbols in a file
specweave lsp symbols <file>
# Search workspace for symbols
specweave lsp search <query>
If user doesn't specify a file path, find it first:
# Step 1: Find which file(s) contain the symbol
grep -rn --include="*.ts" "function symbolName\|class symbolName" .
# Step 2: Then use LSP on the found file
specweave lsp refs <found-file> <symbol>
| Aspect | Grep | SpecWeave LSP |
|---|---|---|
| Type | Text matching | Semantic analysis |
| Results | Includes comments, strings, docs | Actual code usages only |
| Speed | Fast | 52x faster than grep |
| Accuracy | Many false positives | Zero false positives |
⚠️ Never use Grep for "find references" - Grep finds TEXT matches (including comments, strings, docs). LSP finds SEMANTIC references (actual code usages only).
If you need native LSP tools:
# Option 1: Use older Claude Code version
ENABLE_LSP_TOOL=1 npx @anthropic-ai/[email protected]
# Option 2: Use tweakcc patch
npx tweakcc --apply
For umbrella projects with multiple repositories, use the interactive setup:
# Scan project and install LSP plugins interactively
specweave lsp setup
# Options:
specweave lsp setup --max 5 # Limit to top 5 languages
specweave lsp setup --min-files 10 # Min files to consider a language
specweave lsp setup --scope project # Install to .claude/settings.json
specweave lsp setup --dry-run # Show what would be installed
repositories/, packages/, services/, etc.claude plugin install with specified scopeScans these directories for nested repositories:
repositories/ - Multi-repo umbrella patternpackages/ - Monorepo (Lerna, Nx, etc.)services/ - Microservicesapps/, libs/, modules/ - Nx/Turborepo patterns# Check current LSP status
specweave lsp status
# Shows:
# - LSP env ready (ENABLE_LSP_TOOL)
# - Detected languages
# - Missing servers/plugins
# - Warm-up state
SpecWeave LSP supports 10 major languages via their respective language servers:
| Language | Server | Install Command |
|---|---|---|
| TypeScript/JavaScript | tsserver (built-in) | npm i -g typescript |
| Python | pyright | npm i -g pyright or pip install pyright |
| Go | gopls | go install golang.org/x/tools/gopls@latest |
| Rust | rust-analyzer | rustup component add rust-analyzer |
| Java | jdtls | Via VS Code or manual install |
| C# | csharp-ls | dotnet tool install -g csharp-ls |
| Kotlin | kotlin-language-server | Via IntelliJ or manual install |
| Swift | sourcekit-lsp | Comes with Xcode/Swift toolchain |
| PHP | intelephense | npm i -g intelephense |
| Ruby | solargraph | gem install solargraph |
SpecWeave automatically detects which language servers to use based on project files:
| Language | Detection Files |
|---|---|
| TypeScript | tsconfig.json, package.json |
| Python | pyproject.toml, requirements.txt, setup.py |
| Go | go.mod, go.sum |
| Rust | Cargo.toml |
| Java | pom.xml, build.gradle |
| C# | *.csproj, *.sln |
| Kotlin | build.gradle.kts, *.kt |
| Swift | Package.swift, *.xcodeproj |
| PHP | composer.json |
| Ruby | Gemfile, *.gemspec |
# For Python projects
pip install pyright
# OR
npm install -g pyright
# For Go projects
go install golang.org/x/tools/gopls@latest
# For Rust projects
rustup component add rust-analyzer
# For C# projects
dotnet tool install -g csharp-ls
# It auto-detects languages!
specweave lsp refs src/file.py MyClass
specweave lsp def src/main.go HandleRequest
specweave lsp hover src/lib.rs calculate
specweave lsp status
Uses language-specific clients:
TsServerClient (direct tsserver protocol, fastest)LSPClient (JSON-RPC over stdio)Features:
Before starting work, check for project-specific learnings:
# Check if skill memory exists for this skill
cat .specweave/skill-memories/lsp.md 2>/dev/null || echo "No project learnings yet"
Project learnings are automatically captured by the reflection system when corrections or patterns are identified during development. These learnings help you understand project-specific conventions and past decisions.
xiaohongshu
technical spec
product ux expert
database patterns
Conduct multi-agent task orchestration and workflow coordination.
Initialize project with Conductor artifacts (product definition,
Expert in web animations, transitions, and motion design using Framer Motion and CSS
Creates Mermaid and ASCII diagrams for flowcharts, architecture, ERDs, state machines, mindmaps, and more. Use when user mentions diagram, flowchart, mermaid, ASCII diagram, text diagram, terminal diagram, visualize, C4, mindmap, architecture diagram, sequence diagram, ERD, or needs visual docume...
PostgreSQL bindings for H3 hexagonal grid system. Use when working with H3 cells in Postgres, including spatial indexing, geometry/geography integration, and raster analysis.
Context-Driven Development skill for projects using Conductor. Use this skill when you detect a `conductor/` directory in the project, when working on tasks defined in a `plan.md` file, or when the user asks about tracks, specs, or plans. Automatically applies TDD workflow, tracks task completion...
Display project status, active tracks, and next actions
Official Stakpak application containerization standard operating procedure, a step-by-step guidline to properly dockerize applications. This is a rule book curated by the Stakpak Team.
Generate, edit, and beat-sync AI video with leading models in one workspace.
The world's fastest calendar for remote work
Transform Your Design with AI Designer by ImgCreator.ai
Revolutionizing Video Production with AI-Powered Creativity
Extend an image past the frame and let AI fill the new aspect ratio.
Discover your celebrity doppelgänger with StarByFace!
ChainClarity explains 700+ crypto whitepapers in plain English, with layered summaries, comparisons, research tools, alerts, and a $4.99 Pro plan.
Opus.ai: Revolutionize Your Web Experience