newo-dsl-lsp
v1.0.0
Published
Language Server Protocol server for the Newo DSL (NSL/Guidance). Powers the VS Code extension and any LSP-aware editor (Neovim, Helix, Zed).
Maintainers
Readme
newo-dsl-lsp
Language Server Protocol implementation for the Newo DSL (NSL / Guidance / Jinja). Powers the Newo DSL VS Code extension and is installable as a standalone binary for Neovim, Helix, Zed, and any other LSP-aware editor.
LSP features
| Feature | Description |
|---------|-------------|
| Diagnostics | Real-time validation of action calls, parameter checking, syntax errors, unclosed Guidance blocks, undefined variables |
| Completions | IntelliSense for 76 built-in NSL actions, 80+ Jinja builtins, project skills (workspace-scanned), variables, and object properties |
| Variable intelligence | Completions, hover, go-to-definition, and diagnostics for template variables (including type inference across 12 object shapes) |
| Object property completions | Dot-access completions for typed returns (e.g. user.name after GetUser()) |
| Attribute discovery | Autocomplete for attribute field names discovered from project templates |
| Hover | Syntax, parameters, examples, variable info, and property descriptions |
| Go-to-definition | Skill files, action definitions, variable assignments, metadata files |
| Typo suggestions | "Did you mean?" suggestions via Levenshtein distance |
| Quick-fixes | Code actions to fix typos and add missing parameters |
| Semantic tokens | Rich syntax highlighting beyond TextMate grammars |
Install
As a VS Code / Cursor extension
Install the Newo DSL extension from the VS Code Marketplace or OpenVSX. The extension bundles this LSP server - no separate install needed.
As a standalone binary (Neovim / Helix / Zed / other)
npm install -g newo-dsl-lsp
# `newo-lsp` is now on your PATH.Verify:
newo-lsp --versionNeovim (nvim-lspconfig)
require('lspconfig.configs').newo_lsp = {
default_config = {
cmd = { 'newo-lsp', '--stdio' },
filetypes = { 'newo-jinja', 'newo-guidance', 'newo-nsl', 'newo-nslg' },
root_dir = require('lspconfig.util').root_pattern('newo_customers', '.neworc.yaml', '.git'),
},
}
require('lspconfig').newo_lsp.setup({})Helix
In ~/.config/helix/languages.toml:
[[language]]
name = "newo-jinja"
scope = "source.newo-jinja"
file-types = ["jinja", "nsl"]
language-servers = ["newo-lsp"]
[language-server.newo-lsp]
command = "newo-lsp"
args = ["--stdio"]Zed
In ~/.config/zed/settings.json:
{
"lsp": {
"newo-lsp": {
"command": { "path": "newo-lsp", "args": ["--stdio"] }
}
}
}Configuration
LSP clients may send the following settings via workspace/configuration:
| Setting | Type | Default | Description |
|---------|------|---------|-------------|
| newo-dsl.schemasPath | string | "" | Override path to DSL schemas directory |
| newo-dsl.enableDiagnostics | boolean | true | Enable diagnostic reporting |
| newo-dsl.enableCompletions | boolean | true | Enable code completions |
| newo-dsl.enableHover | boolean | true | Enable hover information |
| newo-dsl.validateOnStartup | boolean | false | Validate all workspace templates on startup |
Workspace layout detection
The server scans your workspace for skill files in both NEWO project formats:
| Format | Marker | Skill files |
|--------|--------|-------------|
| cli_v1 | projects/ directory | {project}/{agent}/{flow}/{skill}/*.jinja + *.guidance |
| newo_v2 | import_version.txt file | {project}/agents/{agent}/flows/{flow}/skills/*.nsl + *.nslg |
Both can coexist in newo_customers/.
Running standalone
newo-lsp --stdioOr directly via node (useful for editor-wrapper scripts):
node $(npm root -g)/newo-dsl-lsp/dist/server.js --stdioUnder the hood
This package wraps newo-dsl-analyzer - the same engine that powers newo lint. That means diagnostics in your editor match diagnostics in CI, byte-for-byte.
License
Proprietary - Newo AI. All rights reserved.
