harness-lsp 0.1.1

LSP tool for AI agent harnesses — language-server-protocol operations (hover, definition, references, symbols) with manifest, lazy-spawn policy, pluggable client adapter
Documentation
pub const DEFAULT_HEAD_LIMIT: usize = 200;
pub const DEFAULT_TIMEOUT_MS: u64 = 30_000;
pub const SESSION_BACKSTOP_MS: u64 = 60_000;
pub const SERVER_STARTUP_MAX_WAIT_MS: u64 = 5_000;
pub const MAX_HOVER_MARKDOWN_BYTES: usize = 10_000;
pub const MAX_PREVIEW_LINE_LENGTH: usize = 200;
pub const MAX_WORKSPACE_SYMBOLS_SCANNED: usize = 10_000;

pub const SERVER_STARTING_RETRY_BASE_MS: u64 = 3_000;
pub const SERVER_STARTING_RETRY_MAX_MS: u64 = 30_000;

pub const MANIFEST_FILENAME: &str = ".lsp.json";

/// LSP SymbolKind numeric → short name. Index = LSP SymbolKind enum value.
pub const LSP_SYMBOL_KIND_NAMES: &[&str] = &[
    "_unknown",
    "file",
    "module",
    "namespace",
    "package",
    "class",
    "method",
    "property",
    "field",
    "constructor",
    "enum",
    "interface",
    "function",
    "variable",
    "constant",
    "string",
    "number",
    "boolean",
    "array",
    "object",
    "key",
    "null",
    "enumMember",
    "struct",
    "event",
    "operator",
    "typeParameter",
];

pub fn kind_name(kind: u32) -> &'static str {
    LSP_SYMBOL_KIND_NAMES
        .get(kind as usize)
        .copied()
        .unwrap_or("_unknown")
}