braintrust-langchain
DEPRECATED: LangChain integration is now included in the main braintrust package. Install braintrust instead.
What it is and what it does
braintrust-langchain is a deprecated integration package that adds automatic logging of LangChain executions to Braintrust. It works by providing a callback handler that can be attached globally to all LangChain components or passed explicitly to individual calls, capturing LLM calls, chat interactions, chain executions, tool usage, and state management events.
The package is no longer maintained as a standalone tool—its functionality has been integrated directly into the main braintrust package. Users should migrate by removing this package and installing or upgrading braintrust, then updating imports to use braintrust.integrations.langchain instead. The callback API remains the same, so migration requires only dependency and import path changes.
Use it for:
- Migrate existing LangChain + Braintrust projects from this deprecated package to the integrated braintrust version.
- Log LangChain chain executions and LLM calls to Braintrust for debugging and evaluation.
- Capture LLM responses and agent tool usage automatically without modifying chain code.
- Set up global callback handlers to trace all LangChain components without per-call configuration.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides a LangChain callback handler to log LangChain executions to Braintrust for tracing and evaluation—now deprecated in favor of the integration built into the main braintrust package.
No—do not install this package. It is deprecated and inactive. Install or upgrade the main braintrust package instead and use braintrust.integrations.langchain. The migration is straightforward (import path and dependency change only), and the main package receives active maintenance while this one does not.
Install
braintrust-langchain on PyPI
pip
pip install braintrust-langchainuv
uv add braintrust-langchainpoetry
poetry add braintrust-langchainInstalling braintrust-langchain
Before you install
Low friction install with only two runtime dependencies. However, the package is marked inactive—the integration has been moved into the main braintrust package, making this a migration candidate rather than a new installation target.
License in practice
MIT license permits permissive use, modification, and distribution with minimal restrictions.
Quickstart
pip install braintrust-langchain
from braintrust_langchain import BraintrustCallbackHandler, set_global_handler
from braintrust import init_logger
init_logger(project="your-project-name")
handler = BraintrustCallbackHandler()
set_global_handler(handler)
Requires Python >= 3.10 and BRAINTRUST_API_KEY environment variable set.
Verify before relying
- Whether the callback API remains fully compatible between this package and braintrust's integrated version.
- Feature parity of streaming LLM calls and agent/tool usage logging across both versions.
- Current maintenance status and feature completeness of braintrust.integrations.langchain.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 2 — braintrust, langchain |
| Maintenance | actively maintained — 135 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 2,346,864/month — #3,118 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: braintrust_langchain-0.3.0-py3-none-any.whl
Keywords: braintrust, langchain, llm, tracing, ai, agents, deprecated
Tags
More Artificial Intelligence packages
LiteLLM provides a unified Python interface to…
permissive · top 100 on PyPI
huggingface-hubClient library and CLI tool for downloading,…
permissive · top 100 on PyPI
langchainLangChain provides a framework for building…
permissive · top 1,000 on PyPI
hf-xethf-xet provides chunk-based deduplication and…
permissive · top 1,000 on PyPI
tokenizersTokenizers converts raw text into token…
permissive · top 1,000 on PyPI
transformersTransformers provides a unified framework for…
permissive · top 1,000 on PyPI
braintrustBraintrust is a Python SDK for logging,…
permissive · top 5,000 on PyPI
langchainplus-sdkClient library for connecting to LangSmith, a…
permissive · top 15,000 on PyPI
langchain-databricksConnects LangChain applications to Databricks…
permissive · top 15,000 on PyPI
opentelemetry-instrumentation-langchainAdds distributed tracing to Langchain LLM…
permissive · top 5,000 on PyPI
langchain-neo4jIntegrates Neo4j graph databases with…
permissive · top 15,000 on PyPI
openinference-instrumentation-langchainAuto-instruments LangChain applications to…
permissive · top 5,000 on PyPI
composio-langchainBridges Composio's 1000+ app integrations into…
permissive · top 15,000 on PyPI
langchain-cliCommand-line interface for building, testing,…
permissive · top 15,000 on PyPI
langchain-classicProvides legacy LangChain chains, community…
permissive · top 1,000 on PyPI