Decisions
- Parameters: http (HTTPClient)
create()
-
Parameters:
- audio (str |PathLike[str] | bytes *|*BinaryIO) – Path, bytes, or a binary stream. Streams are read from their current position; seekable streams are restored and never closed.
- state (str |dict[str, Any*]* | list*[str]*) – Shared context as a string, object, or list of strings.
- questions (Mapping*[str,* ChoiceQuestion |NoulQuestion |ChoiceQuestionParam |NoulQuestionParam]) – Question-ID map of choice/noul dictionaries or typed models.
- model (str) – Public model ID. Defaults to tazo-large.
- idempotency_key (str *|*None) – Retained operation key, or None to generate a new one. Every automatic retry reuses the same key and upload snapshot.
- filename (str *|*None) – Optional name for bytes or file objects.
- content_type (str *|*None) – Optional MIME type; otherwise inferred from filename.
- Returns: Typed result, including request_id and idempotency_key SDK metadata.
-
Raises:
- DecisionPendingError – Work continues after the retry budget is exhausted.
- TazoError – Authentication, validation, transport, or service failure.
- Return type: DecisionResponse
stream()
-
Parameters:
- state (str |dict[str, Any*]* | list*[str]*) – Context for the decision.
- questions (Mapping*[str,* ChoiceQuestion |NoulQuestion |ChoiceQuestionParam |NoulQuestionParam]) – Exactly one choice or noul question.
- model (str) – Public model ID; the model’s advertised capabilities apply.
- audio_scope (Literal*[‘turn’,* ‘chunk’**]) – chunk (default) evaluates new audio; turn evaluates cumulative audio.
- evaluation_interval_ms (int *|*None) – Integer from 250 to 30000, or server default.
- event_timeout (float) – Maximum seconds waiting for each server event.
- Returns: A StreamingSession; entering it authenticates and waits for readiness.
- Return type: StreamingSession
AsyncDecisions
- Parameters: http (AsyncHTTPClient)
create()
-
Parameters:
- audio (str |PathLike[str] | bytes *|*BinaryIO)
- state (str |dict[str, Any*]* | list*[str]*)
- questions (Mapping*[str,* ChoiceQuestion |NoulQuestion |ChoiceQuestionParam |NoulQuestionParam])
- model (str)
- idempotency_key (str *|*None)
- filename (str *|*None)
- content_type (str *|*None)
- Return type: DecisionResponse
stream()
async with client.decisions.stream(...) as session.
-
Parameters:
- state (str |dict[str, Any*]* | list*[str]*)
- questions (Mapping*[str,* ChoiceQuestion |NoulQuestion |ChoiceQuestionParam |NoulQuestionParam])
- model (str)
- audio_scope (Literal*[‘turn’,* ‘chunk’**])
- evaluation_interval_ms (int *|*None)
- event_timeout (float)
- Return type: AsyncStreamingSession
Models
- Parameters: http (HTTPClient)
list()
- Return type: ModelList
AsyncModels
- Parameters: http (AsyncHTTPClient)
list()
- Return type: ModelList
Health
- Parameters: http (HTTPClient)
check()
- Return type: HealthStatus
AsyncHealth
- Parameters: http (AsyncHTTPClient)
check()
- Return type: HealthStatus