Run commands in a Docker container via an LLM tool
Project description
llm-tools-docker
Run commands in a Docker container via an LLM tool
Installation
Install this plugin in the same environment as LLM.
llm install llm-tools-docker
Usage
To use this with the LLM command-line tool:
llm chat -T DockerAlpine --tools-debug --chain-limit 0
Then in the chat try:
Install Python 3 and use it to draw a cowsay cow
This plugin currently only works with llm chat since the container is not persisted across multiple calls.
Warning
This is a very early alpha. Every time you start a new chat it will create a new Docker container without closing down the previous one.
It will mount the current directory as a volume in the container, so commands that run in Docker will be able to modify or delete files in that directory.
Development
To set up this plugin locally, first checkout the code. Then create a new virtual environment:
cd llm-tools-docker
python -m venv venv
source venv/bin/activate
Now install the dependencies and test dependencies:
llm install -e '.[test]'
To run the tests:
python -m pytest
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file llm_tools_docker-0.1a0.tar.gz.
File metadata
- Download URL: llm_tools_docker-0.1a0.tar.gz
- Upload date:
- Size: 7.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f6daafd2a37ab04a2903b0cf4f564fbb816f87ce9a5bf2f688979e6ed7cb3752
|
|
| MD5 |
9cd97a3bb1b84403d75f03bc64da3c09
|
|
| BLAKE2b-256 |
76343e8e7ecf38dd50a40497bf0de2a6bf804782f30fb9c1143409ec640cb105
|
Provenance
The following attestation bundles were made for llm_tools_docker-0.1a0.tar.gz:
Publisher:
publish.yml on simonw/llm-tools-docker
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
llm_tools_docker-0.1a0.tar.gz -
Subject digest:
f6daafd2a37ab04a2903b0cf4f564fbb816f87ce9a5bf2f688979e6ed7cb3752 - Sigstore transparency entry: 237903291
- Sigstore integration time:
-
Permalink:
simonw/llm-tools-docker@2c0191244c786560298125265d37b8902afc9986 -
Branch / Tag:
refs/tags/0.1a0 - Owner: https://github.com/simonw
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@2c0191244c786560298125265d37b8902afc9986 -
Trigger Event:
release
-
Statement type:
File details
Details for the file llm_tools_docker-0.1a0-py3-none-any.whl.
File metadata
- Download URL: llm_tools_docker-0.1a0-py3-none-any.whl
- Upload date:
- Size: 7.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ab949766d183f2db516f073f52e90ed59dcb3c6b6c2848da881cc351369e01ef
|
|
| MD5 |
f78549405e0727406da95f37ff76a94f
|
|
| BLAKE2b-256 |
6a3573f2e8d0ef380722d2fdd2b323edd9df70556bd15bc8a36eb7195e4375a3
|
Provenance
The following attestation bundles were made for llm_tools_docker-0.1a0-py3-none-any.whl:
Publisher:
publish.yml on simonw/llm-tools-docker
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
llm_tools_docker-0.1a0-py3-none-any.whl -
Subject digest:
ab949766d183f2db516f073f52e90ed59dcb3c6b6c2848da881cc351369e01ef - Sigstore transparency entry: 237903299
- Sigstore integration time:
-
Permalink:
simonw/llm-tools-docker@2c0191244c786560298125265d37b8902afc9986 -
Branch / Tag:
refs/tags/0.1a0 - Owner: https://github.com/simonw
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@2c0191244c786560298125265d37b8902afc9986 -
Trigger Event:
release
-
Statement type: