langchain-ai/langsmith-sdk
This repo was archived on Oct 16, 2026. Python SDK moved to langchain-ai/langsmith-python and JS SDK to langchain-ai/langsmith-javascript.
LangSmith Client SDKs – Quick Overview
What it is – LangSmith is a hosted service from the creators of LangChain that helps teams debug, evaluate, and monitor large‑language‑model (LLM) applications and autonomous agents. This repository contains the client libraries (SDKs) that let your Python or JavaScript/TypeScript code talk to the LangSmith platform.
Why it matters – When you build an LLM‑powered app you often want to see what prompts were sent, what responses were returned, latency, token usage, and any custom metrics. LangSmith collects that data automatically, giving you a UI for tracing runs, comparing model versions, and spotting failures.
How you use it – 1. Install the package (pip install langsmith or pnpm add langsmith).
2. Enable tracing with environment variables (LANGSMITH_TRACING=true, your API key, and workspace ID).
3. Wrap your LLM client (OpenAI, Anthropic, etc.) with the provided helper (wrap_openai / wrapOpenAI).
4. Run your normal client.chat.completions.create(...) call – the wrapper records the request/response and sends it to LangSmith.
Key pieces of the repo
python/andjs/directories each contain a small, self‑contained SDK (functions liketraceable,wrap_openai).- Badges show the latest release and download counts for both PyPI and npm.
- The README points to the official LangSmith docs and a separate cookbook repo for deeper examples.
Who should look at this – Developers building LLM applications with LangChain or any other framework who want out‑of‑the‑box observability without writing their own logging infrastructure.
Status – The repo is now archived; the SDKs have moved to dedicated repos (langsmith-python and langsmith-javascript). The code itself is unchanged, so existing installations keep working, but new issues should be filed in the new locations.
Related
- Project
- Project
- Project
- Project
- Project