auto-lsp

Crates.ioauto-lsp
lib.rsauto-lsp
version0.6.2
created_at2025-01-20 15:43:47.275685+00
updated_at2025-06-17 15:25:22.540236+00
descriptionA rust crate for creating AST and LSP servers powered by tree-sitter.
homepage
repositoryhttps://github.com/adclz/auto-lsp
max_upload_size
id1524000
size2,991,936
Adrien Clauzel (adclz)

documentation

README

Auto LSP

A Rust crate for creating Abstract Syntax Trees (AST) and Language Server Protocol (LSP) servers powered by Tree-sitter

CI Status CI Status Book crates.io Rust Version

auto_lsp is a generic library for creating Abstract Syntax Trees (AST) and Language Server Protocol (LSP) servers.

It leverages crates such as lsp_types, lsp_server, salsa, and texter, and generates the AST of a Tree-sitter language to simplify building LSP servers.

auto_lsp provides useful abstractions while remaining flexible. You can override the default database as well as all LSP request and notification handlers.

It is designed to be as language-agnostic as possible, allowing any Tree-sitter grammar to be used.

See ARCHITECTURE.md for more information.

✨ Features

  • Generates a thread-safe, immutable and iterable AST with parent-child relations from a Tree-sitter language.
  • Supports downcasting of AST nodes to concrete types.
  • Integrates with a Salsa database and parallelize LSP requests and notifications.

📚 Documentation

Examples

Cargo Features

  • lsp_server: Enables the LSP server (uses lsp_server).
  • wasm: Enables WASM support (compatible only with wasi-p1-threads).

Inspirations / Similar Projects

Commit count: 695

cargo fmt