Skip to main content

nlalpha-capability

Capability discovery MCP server for the NLAlpha quantitative strategy workflow engine.

Positioning

This package is independent of strategy generation (nlalpha-strategy) and backtest execution (nlalpha-backtest). It only exposes capability discovery tools for agents to query available helpers by domain and decide which capabilities to call.

Tools

  • list_capability_domains(): returns the exact domain labels that currently have available helpers.
  • list_capabilities_by_domain(domain): matches helper domain exactly; returns name, category (function or property), signature, description, source plugin, and read-only flag.
  • list_family_helpers(family, domain=""): returns helpers of a discovered strategy family; an empty domain returns all helpers of that family.
  • list_capability_providers(): returns entry point, distribution, version, manifest classification, and helper count for each available provider.
  • diagnose_providers(): returns installed but unavailable or failed capability/family plugins with reasons. Uninstalled optional plugins are not reported as failures.

Provider manifest domains are provider classifications; helper domain is a per-helper label. They are stored and queried under different contracts. category indicates a function or a read-only property and is not a domain. Provider discovery caches one instance and result per entry point; only providers with available status and a valid manifest enter the catalog.

Stable provider identities currently include talib, performance, and statistics_impl. When an optional dependency is missing, an installed plugin keeps the same provider ID and appears in diagnostics as unavailable with a reason; the catalog only returns available providers. Querying an uninstalled optional family does not fail server startup.

Dependencies

  • nlalpha-core: provides the CapabilityPluginRegistry and ProviderManifest contracts.
  • mcp>=1.6.0: MCP server runtime.

Installation

pip install nlalpha-capability

Running

NLALPHA_HOST=127.0.0.1 NLALPHA_PORT=8000 python -m nlalpha_capability.server

Or via the stdio transport:

python -c "from nlalpha_capability.server import main; main()"

DNS-rebinding protection allows only localhost/loopback by default. When a container or gateway uses another host, list the hosts explicitly through NLALPHA_ALLOWED_HOSTS; do not use wildcards.

Focused verification

The capability discovery suite passed 26 tests and 37 subtests, with 1 warning, in 3.76 seconds. This verifies the focused capability cases only; it is not a full release-gate result.

Self-description

about(sections=None) reports the service catalog and discovery diagnostics. confess(provider_id, sections=None) describes the cached provider manifest, declared methods, helper entries, and optional declared guidance. Reuse a complete description while its SHA-256 revision is unchanged and request selected sections when only part is needed. A missing required description document is an explicit discovery error; no synthetic helper is created to fill an absent optional provider.

Description revisions

about and provider confess use nlalpha.description.v1 and derive their content from the cached discovery records, installed package metadata, provider manifest, declared methods, helper records, and packaged resources. Selected sections and complete documents carry the same canonical description_revision. The available catalog includes only providers that are actually available; diagnostics describe installed or registered providers that cannot load. Missing optional providers do not create synthetic catalog entries.

License

nlalpha-capability is a community distribution under AGPL-3.0-or-later. Private enhancement packages and third-party dependencies retain their own licenses.

Container image

The community image is built with this package's Dockerfile and installs a non-editable wheel closure on Python 3.12 slim. It runs this service's MCP entry point.

Metadata

Release files for nlalpha-capability 0.3.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 nlalpha-capability 0.3.0
File Size Uploaded Provenance Actions
nlalpha_capability-0.3.0.tar.gz 27.0 kB Without provenance Details for nlalpha_capability-0.3.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for nlalpha-capability 0.3.0
File Interpreter ABI Platform Actions
nlalpha_capability-0.3.0-py3-none-any.whl Python 3 none any Details for nlalpha_capability-0.3.0-py3-none-any.whl

Total release size: 45.5 kB

Release files / nlalpha_capability-0.3.0.tar.gz

Download URL nlalpha_capability-0.3.0.tar.gz
Size 27.0 kB
Tags Source
SHA-256 checksum
How to use checksums
7a1ac968d04b18e4dc3508461ce952bc89003232c54e5a3cd74563132d5a14cd
BLAKE2b-256 checksum
How to use checksums
aa0a40d030baa2ee6a2971e02046941bdfaa052c5954ca60b6bf0ae6868d61af
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Release files / nlalpha_capability-0.3.0-py3-none-any.whl

Download URL nlalpha_capability-0.3.0-py3-none-any.whl
Size 18.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4ad76ba1a5805575eb115b9d199589bfef5f3096dc87e454bccbedb33bd6197d
BLAKE2b-256 checksum
How to use checksums
a5e9a841a240678b12e8c97c0498bcece584cffc542479d0ae44da0b4dccf869
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Security for nlalpha-capability 0.3.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