Update completion handler documentation to clarify that reasoning config is not injected for completions, as it is only supported in chat completions.

This commit is contained in:
teknium 2026-01-15 06:44:55 +00:00
parent 0316cac8d1
commit 0e187d7869

View file

@ -547,8 +547,8 @@ class APIServer(ABC):
"""
Completion handler, waits for the server to be healthy and then calls the completion wrapper.
Automatically injects reasoning config if configured. Pass `skip_reasoning=True`
to bypass reasoning injection for this specific call.
Note: Reasoning config is NOT injected for completions as the completion API
does not support reasoning features (only chat completions do).
"""
if not self.initialized:
if self.config.health_check:
@ -567,9 +567,6 @@ class APIServer(ABC):
kwargs["model"] = self.config.model_name
split = kwargs.pop("split", "train")
# Inject reasoning config if enabled (can be skipped via skip_reasoning=True)
kwargs = self._inject_reasoning_kwargs(kwargs)
stat_dict = {}
stat_dict["attempts"] = 0
if split == "train":