#llm #openai #rag #ai #data

swiftide-docker-executor

A docker executor for swiftide agent tools

8 releases

new 0.3.1 Jan 17, 2025
0.3.0 Jan 17, 2025
0.2.3 Jan 16, 2025
0.1.1 Jan 6, 2025

#339 in Machine learning

Download history 796/week @ 2025-01-02 779/week @ 2025-01-09

1,575 downloads per month
Used in kwaak

MIT license

32KB
628 lines

Swiftide Docker Tool Executor

A Tool executor meant to be used with Swiftide Agents.

Process is two-staged. First, configure the executor, then start it. The started executor implements ToolExecutor and can then be used in agents.

Usage


let executor = DockerExecutor::default()
    .with_context_path(".")
    .with_image_name("test")
    .with_dockerfile("Dockerfile.overwritten");

executor

let context = DefaultContext::from_executor(executor);

let agent = Agent::builder().context(context).build();

lib.rs:

A library for executing swiftide agent tools in a docker container

Example


let executor = DockerExecutor::default()
    .with_context_path(".")
    .with_image_name("test")
    .with_dockerfile("Dockerfile.overwritten")
    .to_owned()
    .start().await.unwrap();

let context = DefaultContext::from_executor(executor);
let agent = Agent::builder().context(context);

Dependencies

~24–37MB
~597K SLoC