Skip to content

Add support for context_length_exceeded_behavior option #439

@umberto-fontanazza

Description

@umberto-fontanazza

API docs mention support for context_length_exceeded_behavior option which is not supported by the Python SDK.

def create(
self,
*,
messages: List[Dict[str, Any]],
model: str,
max_tokens: int | None = None,
stop: List[str] | None = None,
temperature: float | None = None,
top_p: float | None = None,
top_k: int | None = None,
repetition_penalty: float | None = None,
presence_penalty: float | None = None,
frequency_penalty: float | None = None,
min_p: float | None = None,
logit_bias: Dict[str, float] | None = None,
seed: int | None = None,
stream: bool = False,
logprobs: int | None = None,
echo: bool | None = None,
n: int | None = None,
safety_model: str | None = None,
response_format: Dict[str, Any] | None = None,
tools: List[Dict[str, Any]] | None = None,
tool_choice: str | Dict[str, str | Dict[str, str]] | None = None,
**kwargs: Any,
) -> ChatCompletionResponse | Iterator[ChatCompletionChunk]:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions