Skip to main content

AgentsML Language Server

Language Server Protocol implementation for AgentsML documents (.agentsml.yaml).

Features

Feature Description
Diagnostics JSON Schema validation, YAML parse errors, required keys, version validation, cross-reference resolution, enum validation
Completions Top-level keys, collection item names, agent-side refs (tools/resources/prompts/policies), step targets, model refs, step ID refs, profile/side_effect/transport enums
Hover Agent/tool/model/workflow/resource/prompt/policy/MCP/A2A/step info with description, role, model ref, side effects; condition grammar help
Go to definition Jump from a reference to the item it names
Find references List every place a definition is referenced
Document links Turn every reference into a clickable link to its definition
Document Symbols Hierarchical outline of all collections and their items
Code actions A quick fix that creates the missing agent, tool, model, ... when a reference cannot be resolved

Diagnostics are reported at the line and column of the offending value, not at the top of the document.

Install

cd agentsml-ide/language-server
pip install -e .

This installs the agentsml-lsp console script.

Release

The package is published to PyPI by the publish workflow when a v* tag is pushed. Bump project.version in pyproject.toml before tagging — the workflow refuses to publish a tag whose version differs from the package metadata. See the project README for the details.

Run

# stdio mode — this is what editors use
python3 src/agentsml_lsp/server.py
python3 src/agentsml_lsp/server.py   # after installation: agentsml-lsp

# TCP mode, for debugging with an external LSP client
python3 src/agentsml_lsp/server.py --tcp --port 2087

Tests

python3 -m pytest tests/ -v
  • tests/test_diagnostics.py — the diagnostics engine against the shipped example documents.
  • tests/test_server_stdio.py — an end-to-end LSP session: initialize, open a document, check the published diagnostics, completions and hover.
  • tests/test_completions.py — the completion constants.

Layout

src/agentsml_lsp/server.py      LSP server: index, diagnostics, completion, hover, symbols
src/agentsml_lsp/completions.py  Completion constants (top-level keys, profiles, enums)
tests/               Diagnostics and end-to-end protocol tests

Validation rules

Rule Severity
Missing required top-level keys (agentsml, kind, metadata) Error
Invalid kind value Error
Invalid agentsml version Warning
Missing metadata.name Error
Unknown model/tool/resource/prompt/policy reference in an agent Error
Unknown agent/tool/workflow/a2a_agent reference in a step Error
Missing step required field (id) Error
Unknown edge from/to step ID Error
Unknown profile name Warning
Invalid tool side_effect value Warning
Invalid MCP transport value Warning

Metadata

Release files for agentsml-lsp 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for agentsml-lsp 0.4.0
File Size Uploaded Provenance Actions
agentsml_lsp-0.4.0.tar.gz 25.9 kB Without provenance Details for agentsml_lsp-0.4.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for agentsml-lsp 0.4.0
File Interpreter ABI Platform Actions
agentsml_lsp-0.4.0-py3-none-any.whl Python 3 none any Details for agentsml_lsp-0.4.0-py3-none-any.whl

Total release size: 46.2 kB

Release files / agentsml_lsp-0.4.0.tar.gz

Download URL agentsml_lsp-0.4.0.tar.gz
Size 25.9 kB
Tags Source
SHA-256 checksum
How to use checksums
97f57e3f3a6fca9541ff776bd1b150cd06eb8e678eea80a38946499036209525
BLAKE2b-256 checksum
How to use checksums
c78a1c9e2d23730944b29e3450cf457bf873ce8cb9eb5641203b5423c5e01c14
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / agentsml_lsp-0.4.0-py3-none-any.whl

Download URL agentsml_lsp-0.4.0-py3-none-any.whl
Size 20.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f9a8029dd449ebf4d24322a1d9a8f1dfcdd71ff53898211512d375a28f1789ab
BLAKE2b-256 checksum
How to use checksums
bb826af4b31ff49702845d076448d9ba2b1998f0722c52de0868cb129a3660c9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Security for agentsml-lsp 0.4.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page