Skip to content

Conversation

@samnoyes
Copy link
Contributor

@samnoyes samnoyes commented Oct 3, 2025

Description: OpenAI stores message IDs in their ChatCompletion objects. However, other formats (like langchain serialized) store the ids directly inside the message objects. In some cases it is useful to preserve these IDs (e.g. for deduplication). This adds the option to do so within the convert_to_openai_messages function.

@samnoyes samnoyes requested a review from eyurtsev as a code owner October 3, 2025 00:27
@github-actions github-actions bot added feature core Related to the package `langchain-core` labels Oct 3, 2025
@codspeed-hq
Copy link

codspeed-hq bot commented Oct 3, 2025

CodSpeed WallTime Performance Report

Merging #33242 will not alter performance

Comparing sam/add-message-ids-to-convert-to-openai-messages (f6d7b91) with master (5a016de)

⚠️ Unknown Walltime execution environment detected

Using the Walltime instrument on standard Hosted Runners will lead to inconsistent data.

For the most accurate results, we recommend using CodSpeed Macro Runners: bare-metal machines fine-tuned for performance measurement consistency.

Summary

✅ 13 untouched

@ccurme ccurme merged commit 99361e6 into master Oct 3, 2025
70 checks passed
@ccurme ccurme deleted the sam/add-message-ids-to-convert-to-openai-messages branch October 3, 2025 12:22
ccurme pushed a commit that referenced this pull request Oct 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core Related to the package `langchain-core` feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants