Skip to content

Commit 4112cd6

Browse files
authored
Properly pass quality preset in TLMChatCompletion (#97)
1 parent a8c8a2f commit 4112cd6

File tree

3 files changed

+15
-3
lines changed

3 files changed

+15
-3
lines changed

CHANGELOG.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [1.1.18] - 2025-07-25
11+
12+
### Fixed
13+
14+
- Properly pass quality preset in `TLMChatCompletion`
15+
1016
## [1.1.17] - 2025-07-18
1117

1218
### Changed
@@ -259,7 +265,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
259265
- Release of the Cleanlab TLM Python client.
260266

261267

262-
[Unreleased]: https://github.com/cleanlab/cleanlab-tlm/compare/v1.1.16...HEAD
268+
[Unreleased]: https://github.com/cleanlab/cleanlab-tlm/compare/v1.1.18...HEAD
269+
[1.1.18]: https://github.com/cleanlab/cleanlab-tlm/compare/v1.1.17...v1.1.18
270+
[1.1.17]: https://github.com/cleanlab/cleanlab-tlm/compare/v1.1.16...v1.1.17
263271
[1.1.16]: https://github.com/cleanlab/cleanlab-tlm/compare/v1.1.15...v1.1.16
264272
[1.1.15]: https://github.com/cleanlab/cleanlab-tlm/compare/v1.1.14...v1.1.15
265273
[1.1.14]: https://github.com/cleanlab/cleanlab-tlm/compare/v1.1.13...v1.1.14

src/cleanlab_tlm/__about__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
# SPDX-License-Identifier: MIT
2-
__version__ = "1.1.17"
2+
__version__ = "1.1.18"

src/cleanlab_tlm/utils/chat_completions.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,11 @@ def score(
8888
if (messages := openai_kwargs.get("messages")) is None:
8989
raise ValueError("messages is a required OpenAI input argument.")
9090

91-
combined_kwargs = {**openai_kwargs, **self._options}
91+
combined_kwargs = {
92+
"quality_preset": self._quality_preset,
93+
**openai_kwargs,
94+
**self._options,
95+
}
9296

9397
# handle structured outputs differently
9498
if openai_kwargs.get("response_format"):

0 commit comments

Comments
 (0)