VS Code extension for the ESMF SDK Turtle language server. The extension supports prefix Go to Definition, fast syntax feedback while typing, and server-driven heavy Aspect validation for SAMM-style Turtle models.
turtle.languageServerSettings.activateEmbeddedLanguageServer(boolean, default:true)- When enabled, the extension starts the SAMM CLI language server process. When disabled, an external language server must be started manually.
turtle.languageServerSettings.automaticUpdateCheck(boolean, default:true)- Automatically check for updates of the SAMM CLI language server and notify when a new version is available.
turtle.languageServerSettings.sammCliPath(string)- Path to the SAMM CLI executable or jar file to use as the language server. Can be downloaded / set via the 'Select SAMM CLI Executable' command.
turtle.languageServerSettings.serverPort(number, default:1846)- TCP port used to connect to the Turtle/SAMM language server.
turtle.languageServerSettings.traceLevel(string, default:off)- Controls the verbosity of language client protocol tracing. Options:
off,messages,verbose.
- Controls the verbosity of language client protocol tracing. Options:
Use the command Turtle: Select SAMM CLI Executable to choose either:
- one of the latest SAMM CLI GitHub releases, or
- a custom executable path from your local file system.
- Prefix
Go to Definitioninside Turtle files. - Two-level validation:
- Fast feedback on type from the regular Turtle parser diagnostics provided by the server (appear in the editor and
Problems). - Heavy Aspect validation from the server for model-level issues (results shown in notifications and status bar).
- Fast feedback on type from the regular Turtle parser diagnostics provided by the server (appear in the editor and
- Manual validation command:
Turtle: Validate document now
- In this extension project, install dependencies with
npm install. - Compile the extension with
npm run build. - Press
F5in VS Code to open an Extension Development Host. - Open a Turtle file such as samples/valid.ttl or your Aspect model file.
If the server cannot be downloaded or started, the extension shows an error and leaves a detailed message in the Turtle LSP output channel.
Fast feedback on type:
- Driven by the server's regular Turtle parsing diagnostics.
- Results appear in the editor and
Problemspanel. - Intended for quick editor feedback while you type.
Heavy Aspect validation:
- Runs on the server, not in the extension.
- Results are displayed in notification messages (for manual validation) or status bar (for save-triggered validation).
- Always uses detailed server validation messaging when the server returns report text.
- Always shows visible progress for long-running validation.
- Runs automatically on save and can also be triggered manually.
When each validation runs:
- On type: fast syntax feedback only.
- On save: heavy Aspect validation for Turtle documents.
- Manual:
Turtle: Validate document nowfor the active Turtle document.
Turtle: Validate document now- Sends a server request for the active Turtle document.
Turtle: Select SAMM CLI Executable- Opens a quick pick with the latest 10 GitHub releases and a custom-path option.
Turtle: Restart and reconnect to Language Server- Restarts the language server and reconnects the client.
- Manual validation shows a progress notification while the request is running.
- Save-triggered validation always uses a short status-bar progress indicator instead of repeated popups.
- After completion, the user gets a summary message with validation results.
- Automatic save validation keeps progress and completion feedback in the status bar.
Use samples/valid.ttl:
- Open
samples/valid.ttl. - Place the cursor on
foaf:Person,foaf:name, or another prefixed name. - Run
Go to Definition. - Confirm that VS Code jumps to the matching
@prefixdeclaration.
Expected behavior:
foaf:*resolves to@prefix foaf: ....ex:*resolves to@prefix ex: ....
Use samples/org.eclipse.esmf.test/1.0.0/Aspect.ttl or samples/invalid.ttl.
Manual check:
- Open an Aspect model file.
- Run
Turtle: Validate document now. - Wait for the progress indicator to finish.
- Confirm that validation results appear in a notification message.
On-save check:
- Save the model file.
- Confirm that the status bar shows validation progress.
- Confirm that a summary message appears in the status bar after completion.