Skip to content

Conversation

@alexmojaki
Copy link
Contributor

No description provided.

@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Jan 27, 2026

Deploying logfire-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: a10d54a
Status: ✅  Deploy successful!
Preview URL: https://9b325bcf.logfire-docs.pages.dev
Branch Preview URL: https://alex-langchain-reasoning.logfire-docs.pages.dev

View logs

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This pull request adds support for handling langchain reasoning summaries from OpenAI's GPT-5 model with reasoning capabilities. The changes enable proper transformation and display of reasoning steps in the Logfire UI.

Changes:

  • Updated test to use GPT-5 with reasoning parameters and updated expected snapshots to include reasoning content
  • Added logic to _transform_langchain_message to filter duplicate function_call items and transform reasoning summaries
  • Updated VCR cassette with new API requests/responses that include reasoning summaries

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
tests/otel_integrations/test_langchain.py Updated test to use gpt-5 model with reasoning capabilities, added expected reasoning content in assertions, removed unnecessary warning handling
tests/otel_integrations/cassettes/test_langchain/test_instrument_langchain.yaml Updated cassette file with new API interactions including reasoning summaries and updated endpoint/request format
logfire/_internal/exporters/processor_wrapper.py Added logic to transform langchain messages: filter function_call items already in tool_calls, and transform reasoning summaries into a standardized format

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@alexmojaki alexmojaki merged commit 95e3e74 into main Jan 27, 2026
14 checks passed
@alexmojaki alexmojaki deleted the alex/langchain-reasoning branch January 27, 2026 12:23
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.

2 participants