Skip to main content

MCP support for LLM CLI

Project description

llm-tools-mcp

[!WARNING] Work in progress!
Only an alpha version has been released so far.
Please refrain from using it unless you know what you're doing.
If you do decide to try it, make sure to use the --ta flag (manual approval required for every tool execution).

PyPI Changelog Tests License

MCP support for the LLM CLI tool.

Demo

To Do

  • Release alpha version
  • Build a solid test suite
    • test sse with dummy server
    • test stdio with dummy server
    • test http streamable with dummy server (see #1)
    • test sse with real server
    • test stdio with real server
    • test http streamable with real server
  • Redirect stdout/stderr from the MCP SDK to a file or designated location
  • Reuse stdio connections
  • Support non-stdio MCP servers
  • Handle tool name conflicts (prefix with mcp server name?)
  • Gather feedback on the ~/.llm-tools-mcp directory naming
  • Improve failure handling:
    • When connecting to an MCP server fails
    • When mcp.json is malformed
  • Improve this README:
    • Add more detail in the Development section (mention uv?)

Installation

Install this plugin in the same environment as LLM:

llm install llm-tools-mcp

Usage

[!WARNING] Work in progress!
Only an alpha version has been released so far.
Please refrain from using it unless you know what you're doing.
If you do decide to try it, make sure to use the --ta flag (manual approval required for every tool execution).

  1. Create mcp.json file in ~/.llm-tols-mcp
  2. Run llm, for example: llm --ta -T read_file -T list_allowed_directories -T list_directory "what files are in the demo directory? show me contents of one of the files (any)"

Development

Now (to be verified)

  • Sync dependencies: uv sync --all-extras
  • Run linters / type checker: ./check.sh
  • Run tests: ./test.sh

Before

To set up this plugin locally, first checkout the code. Then create a new virtual environment:

cd llm-tools-mcp
python -m venv venv
source venv/bin/activate

Now install the dependencies and test dependencies:

python -m pip install -e '.[test]'

To run the tests:

python -m pytest

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

llm_tools_mcp-0.1.0a6.tar.gz (10.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

llm_tools_mcp-0.1.0a6-py3-none-any.whl (8.9 kB view details)

Uploaded Python 3

File details

Details for the file llm_tools_mcp-0.1.0a6.tar.gz.

File metadata

  • Download URL: llm_tools_mcp-0.1.0a6.tar.gz
  • Upload date:
  • Size: 10.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for llm_tools_mcp-0.1.0a6.tar.gz
Algorithm Hash digest
SHA256 63abb28a715273f9c1432ac6bce0bd2f95e536d70f8094f03be623f8453ac1d8
MD5 99029f50385b88c2308349a5437f76d3
BLAKE2b-256 10b14ab451f406fecd815243a7998175ec305784903ecbd8c67874245225dc83

See more details on using hashes here.

Provenance

The following attestation bundles were made for llm_tools_mcp-0.1.0a6.tar.gz:

Publisher: publish.yml on VirtusLab/llm-tools-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file llm_tools_mcp-0.1.0a6-py3-none-any.whl.

File metadata

File hashes

Hashes for llm_tools_mcp-0.1.0a6-py3-none-any.whl
Algorithm Hash digest
SHA256 c18da6f1c08565492db70c0fac63946a6bbb556a35ae7741413ca332acdc10f6
MD5 cce72b529f35520a8005b4541979d063
BLAKE2b-256 efe56e6422c83f6bd9b38cf0b2905b5f624e57a1d1384ae80e1a384bce9f6fcf

See more details on using hashes here.

Provenance

The following attestation bundles were made for llm_tools_mcp-0.1.0a6-py3-none-any.whl:

Publisher: publish.yml on VirtusLab/llm-tools-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page