mistral_common.protocol.base
BaseCompletionRequest(**data)
Bases: MistralBase
Base class for completion requests.
Holds sampling parameters shared by all completion request types (chat, FIM, transcription, speech).
Attributes:
| Name | Type | Description |
|---|---|---|
temperature |
float
|
Sampling temperature in [0, 1]. Higher values (e.g., 0.8) make the output more random; lower values (e.g., 0.2) make it more focused and deterministic. Defaults to 0.7. |
top_p |
float
|
Nucleus sampling probability mass in [0, 1]. The model samples from
the smallest set of tokens whose cumulative probability exceeds |
max_tokens |
int | None
|
Maximum number of tokens to generate. If |
random_seed |
int | None
|
Seed for reproducible sampling. If |
Examples: