Skip to content

AI-141: Add LangSmith integration guide#4475

Open
xumaple wants to merge 2 commits intomainfrom
maplexu/AI-141-langsmith-docs
Open

AI-141: Add LangSmith integration guide#4475
xumaple wants to merge 2 commits intomainfrom
maplexu/AI-141-langsmith-docs

Conversation

@xumaple
Copy link
Copy Markdown

@xumaple xumaple commented Apr 22, 2026

Summary

  • New guide at /develop/python/integrations/langsmith covering the temporalio.contrib.langsmith.LangSmithPlugin (shipped in temporalio 1.26.0).
  • Modeled after the existing Braintrust guide. Single page covering plugin setup on Worker and Client, @traceable usage, wrap_openai for richer LLM runs, the add_temporal_runs toggle, and trace hierarchy examples for both modes.
  • Marked as Pre-release (the plugin is experimental).
  • Adds LangSmith to the Python integrations index and the sidebar.

- Add `docs/develop/python/integrations/langsmith.mdx` covering the
  LangSmithPlugin, @Traceable usage, wrap_openai, and the add_temporal_runs
  toggle. Modeled after the Braintrust guide.
- Add LangSmith row to the Python integrations index.
- Add the new page to the Python integrations sidebar.

Jira: AI-141
Samples PR: temporalio/samples-python#292
@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 22, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
temporal-documentation Ready Ready Preview, Comment Apr 22, 2026 9:47pm

Request Review

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 22, 2026

📖 Docs PR preview links

@xumaple xumaple marked this pull request as ready for review April 22, 2026 21:46
@xumaple xumaple requested a review from a team as a code owner April 22, 2026 21:46
@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Apr 22, 2026

CLA assistant check
All committers have signed the CLA.

---

Temporal's integration with [LangSmith](https://smith.langchain.com/) gives you end-to-end traces of your AI agent
Workflows—capturing every LLM call, tool execution, and orchestration step in a single LangSmith project.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Workflows—capturing every LLM call, tool execution, and orchestration step in a single LangSmith project.
Workflows—capturing every LLM call, tool execution, and orchestration step in a LangSmith project.


When building AI agents with Temporal, you get durable execution: automatic retries, state persistence, and recovery
from failures mid-Workflow. LangSmith adds the observability layer: see exactly what your agents do, inspect LLM
inputs and outputs, and trace a single request from the Client all the way through to the model.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The usage of "single" everywhere feels like it's trying to emphasize the wrong thing.

Suggested change
inputs and outputs, and trace a single request from the Client all the way through to the model.
inputs and outputs, and trace a request from the Client all the way through to the model.

1. Install the Temporal Python SDK with the LangSmith extra.

```bash
pip install "temporalio[langsmith]>=1.26.0"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

uv? 😄



# wrap_openai patches the client — every API call adds a ChatOpenAI run under the @traceable.
# max_retries=0 because Temporal's Activity retry policy handles retries.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# max_retries=0 because Temporal's Activity retry policy handles retries.
# Set max_retries=0 and use Temporal's Activity retry policy instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants