---
title: "swiftide"
type: "tool"
slug: "bosun-ai-swiftide"
canonical_url: "https://www.graphcanon.com/tools/bosun-ai-swiftide"
github_url: "https://github.com/bosun-ai/swiftide"
homepage_url: "https://swiftide.rs"
stars: 715
forks: 62
primary_language: "Rust"
license: "MIT"
categories: ["ai-agents", "model-training", "data-retrieval"]
tags: ["ml", "genai", "agents", "llm", "ai", "rust", "rag"]
updated_at: "2026-07-07T18:49:24.559053+00:00"
---

# swiftide

> Fast, streaming indexing, query, and agentic LLM applications in Rust

Swiftide is an opinionated framework for building large language model (LLM) applications using Rust. It offers an agent harness, typed task graphs for orchestration, and streaming, composable indexing/query pipelines for Retrieval-Augmented Generation (RAG).

## Facts

- Repository: https://github.com/bosun-ai/swiftide
- Homepage: https://swiftide.rs
- Stars: 715 · Forks: 62 · Open issues: 31 · Watchers: 5
- Primary language: Rust
- License: MIT
- Last pushed: 2026-07-06T07:00:04+00:00

## Categories

- [AI Agents](/categories/ai-agents.md)
- [Model Training](/categories/model-training.md)
- [Data & Retrieval](/categories/data-retrieval.md)

## Tags

ml, genai, agents, llm, ai, rust, rag

## Related tools

- [ECC](/tools/affaan-m-ecc.md) - The agent harness performance optimization system (★ 226,962)
- [hermes-agent](/tools/nousresearch-hermes-agent.md) - The self-improving AI agent built by Nous Research (★ 210,880)
- [AutoGPT](/tools/significant-gravitas-autogpt.md) - AutoGPT: Build, Deploy, and Run AI Agents (★ 185,417)
- [ollama](/tools/ollama-ollama.md) - Get up and running with Kimi-K2.6, GLM-5.1, MiniMax, DeepSeek, gpt-oss, Qwen, Gemma and other models. (★ 175,659)
- [transformers](/tools/huggingface-transformers.md) - 🤗 Transformers: the model-definition framework for state-of-the-art machine learning models (★ 162,347)
- [langflow](/tools/langflow-ai-langflow.md) - Langflow is a powerful platform for building and deploying AI-powered agents and workflows. (★ 151,298)
- [dify](/tools/langgenius-dify.md) - Production-ready platform for agentic workflow development (★ 148,070)
- [firecrawl](/tools/firecrawl-firecrawl.md) - The API to search, scrape, and interact with the web at scale. (★ 147,117)

## README (excerpt)

```text
<a name="readme-top"></a>



[![Crate Badge]][Crate]
[![Docs Badge]][API Docs]
[![Contributors][contributors-shield]][contributors-url]
[![Stargazers][stars-shield]][stars-url]

[![MIT License][license-shield]][license-url]
[![LinkedIn][linkedin-shield]][linkedin-url]

<br />
<div align="center">
  <a href="https://github.com/bosun-ai/swiftide">
    <img src="https://raw.githubusercontent.com/bosun-ai/swiftide/master/images/logo.png" alt="Swiftide logo" width="190" height="190">
  </a>

  <h1 align="center">Swiftide</h1>

  <p align="center">
    Composable LLM agents and harnass, typed task graphs, and streaming RAG pipelines in Rust.
    <br />
    <a href="https://docs.rs/swiftide/latest/swiftide/"><strong>API docs</strong></a>
    ·
    <a href="https://github.com/bosun-ai/swiftide/tree/master/examples"><strong>Examples</strong></a>
    ·
    <a href="https://swiftide.rs"><strong>Website</strong></a>
    ·
    <a href="https://discord.gg/3jjXYen9UY"><strong>Discord</strong></a>
  </p>
</div>

Swiftide is an opinionated framework for building LLM applications. It gives you
an agent harness, typed task graphs for orchestration, and streaming, composable indexing/query
pipelines for RAG.

<div align="center">
    <img src="images/composition.svg" alt="Swiftide composition overview" width="100%" >
</div>

<details>
  <summary>Table of Contents</summary>

- [Why Swiftide](#why-swiftide)
- [Quick Start](#quick-start)
- [Agent Harness](#agent-harness)
- [Typed Task Graphs](#typed-task-graphs)
- [RAG Pipelines](#rag-pipelines)
- [Integrations](#integrations)
- [Examples](#examples)
- [Project Status](#project-status)
- [Contributing](#contributing)
- [Core Team Members](#core-team-members)
- [License](#license)

</details>

## Why Swiftide

- Build agents that loop over LLM calls, tool calls, lifecycle hooks, and stop conditions.
- Compose prompt steps, agents, command executors, and domain-specific Rust code in typed task
  graphs.
- Fan out work into parallel branches and join typed results back into one task output.
- Pause and resume agents or tasks for human approval, external callbacks, or persisted state.
- Bring tools from local Rust functions, custom `Tool` implementations, or MCP servers.
- Stream large indexing and retrieval workloads through loaders, transformers, embedders, caches,
  and storage backends.
- Trace agent, task, and pipeline execution with `tracing`, metrics, and Langfuse support.

The core primitives provide the shared interaction model. Around them, use pipelines for data
flows, agents for tool loops, and tasks for graphs of typed hand-offs.

## Quick Start

Swiftide keeps default dependencies light. Start with the agent harness and add the integrations
your application needs.

```sh
cargo add swiftide --features swiftide-agents,openai
cargo add anyhow
cargo add tokio --features macros,rt-multi-thread
```

If using OpenAI, set the API key expected by the OpenAI-compatible integration:

```sh
export OPENAI_API_KEY=...
```

## Agent Harness

Swiftide provides a harnass for building (semi) autonomous agents. The harnass owns message history, call an LLM, invoke tools,
run hooks, and stopping. Tools are pure functions and easy to add. The AgentContext abstracts over message history (in memory by default) and provides tools access to the outside world via a ToolExecutor (local by default, see also the [docker executor](https://github.com/bosun-ai/swiftide-docker-executor)).

```rust
use anyhow::Result;
use swiftide::{
    agents,
    chat_completion::{ToolOutput, errors::ToolError},
    traits::AgentContext,
};

#[swiftide::tool(
    description = "Looks up a Swiftide concept",
    param(name = "concept", description = "Concept to explain")
)]
async fn explain_concept(
    _context: &dyn AgentContext,
    concept: &str,
) -> Result<ToolOutput, ToolError> {
    let explanation = match concept {
        "tasks" => "Tasks compose typed nodes into explicit workflows.",
        "agents" => "Agents run LLM comple
```

---

**Machine-readable endpoints**

- JSON: [`/api/graphcanon/tools/bosun-ai-swiftide`](/api/graphcanon/tools/bosun-ai-swiftide)
- LLM index: [/llms.txt](/llms.txt)
- Full corpus: [/llms-full.txt](/llms-full.txt)

_GraphCanon - The knowledge graph for AI development. https://www.graphcanon.com/_
