You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Braintrust Rust SDK has no instrumentation support for swiftide, a Rust-native framework for streaming indexing, RAG query execution, and autonomous agent workflows. Swiftide provides explicit LLM chat completions, embedding generation, and agent execution API surfaces. No other Braintrust SDK instruments this library, as it is Rust-specific. Braintrust documents equivalent frameworks in other languages (LlamaIndex, LangChain, CrewAI) as supported integrations.
What is missing
Swiftide exposes three execution-oriented pipeline types, each making direct LLM or embedding calls:
1. Chat completions module
The swiftide::chat_completion module provides traits and types for LLM interactions. Each supported backend (OpenAI, Anthropic, Gemini, Groq, etc.) implements these traits. LLM calls made through swiftide's chat completion layer are not wrapped with Braintrust spans, so inputs, outputs, token usage, and latency are not captured.
2. Indexing pipeline (embedding execution)
Swiftide's indexing pipeline (swiftide::indexing) processes documents via async streaming steps including embedding generation:
indexing::Pipeline::from_loader(FileLoader::new(".").with_extensions(&["rs"])).then_chunk(ChunkCode::try_for_language("rust")?).then(OpenAIEmbed::default())// ← embedding call not traced.then_store_with(Qdrant::default()).run().await?;
Embedding calls within then() or then_in_batch() steps produce Embedding/Embeddings values that are never captured as Braintrust spans.
3. Query pipeline (RAG generation)
The query pipeline (swiftide::query) executes semantic retrieval and LLM response generation:
query::Pipeline::default().then_transform_query(GenerateSubquestions::from_client(openai.clone())).then_retrieve(SimilaritySearch::default()).then_answer(Simple::from_client(openai.clone()))// ← LLM call not traced.query("What is swiftide?").await?;
LLM calls in then_answer() and query transformation steps are not captured as spans.
4. Agent framework
The swiftide-agents crate provides an autonomous agent framework with tool integration and lifecycle hooks:
AgentBuilder::new().llm(&openai)// ← repeated LLM calls not traced.tools(vec![my_tool]).build()?
.run().await?;
Agent execution involves repeated LLM calls with tool invocations. Neither the individual LLM calls nor the overall agent run is captured as a Braintrust span.
supported (in other languages, equivalent frameworks) — Braintrust documents instrumentation for frameworks that serve the same purpose as swiftide in other languages:
LlamaIndex (Python/TypeScript) — RAG indexing and query pipelines; swiftide is the closest Rust equivalent
src/extractors.rs — only extract_openai_usage() and extract_anthropic_usage(); no swiftide-specific extractor; swiftide delegates to its provider backends (OpenAI, Anthropic, etc.) internally
src/stream.rs — wrap_stream_with_span() is a generic stream helper but is not wired to swiftide pipeline steps; swiftide's async pipeline does not yield Result<Value, E> streams compatible with the current wrapper signature
src/lib.rs — public API exports; no swiftide references
Cargo.toml — no swiftide dependency
Full codebase grep for swiftide, IndexingPipeline, QueryPipeline, AgentBuilder — zero results
Summary
The Braintrust Rust SDK has no instrumentation support for
swiftide, a Rust-native framework for streaming indexing, RAG query execution, and autonomous agent workflows. Swiftide provides explicit LLM chat completions, embedding generation, and agent execution API surfaces. No other Braintrust SDK instruments this library, as it is Rust-specific. Braintrust documents equivalent frameworks in other languages (LlamaIndex, LangChain, CrewAI) as supported integrations.What is missing
Swiftide exposes three execution-oriented pipeline types, each making direct LLM or embedding calls:
1. Chat completions module
The
swiftide::chat_completionmodule provides traits and types for LLM interactions. Each supported backend (OpenAI, Anthropic, Gemini, Groq, etc.) implements these traits. LLM calls made through swiftide's chat completion layer are not wrapped with Braintrust spans, so inputs, outputs, token usage, and latency are not captured.2. Indexing pipeline (embedding execution)
Swiftide's indexing pipeline (
swiftide::indexing) processes documents via async streaming steps including embedding generation:Embedding calls within
then()orthen_in_batch()steps produceEmbedding/Embeddingsvalues that are never captured as Braintrust spans.3. Query pipeline (RAG generation)
The query pipeline (
swiftide::query) executes semantic retrieval and LLM response generation:LLM calls in
then_answer()and query transformation steps are not captured as spans.4. Agent framework
The
swiftide-agentscrate provides an autonomous agent framework with tool integration and lifecycle hooks:Agent execution involves repeated LLM calls with tool invocations. Neither the individual LLM calls nor the overall agent run is captured as a Braintrust span.
Library significance
swiftide-core,swiftide-agents,swiftide-integrations)Braintrust docs status
supported (in other languages, equivalent frameworks) — Braintrust documents instrumentation for frameworks that serve the same purpose as swiftide in other languages:
Braintrust does not list swiftide in its integrations directory or trace LLM calls page.
Upstream sources
Local files inspected
src/extractors.rs— onlyextract_openai_usage()andextract_anthropic_usage(); no swiftide-specific extractor; swiftide delegates to its provider backends (OpenAI, Anthropic, etc.) internallysrc/stream.rs—wrap_stream_with_span()is a generic stream helper but is not wired to swiftide pipeline steps; swiftide's async pipeline does not yieldResult<Value, E>streams compatible with the current wrapper signaturesrc/lib.rs— public API exports; no swiftide referencesCargo.toml— noswiftidedependencyswiftide,IndexingPipeline,QueryPipeline,AgentBuilder— zero results