Skip to main content

Returns

Returns a list of InferenceResult objects.

Example

Parameters

string
The session ID to log the inference results to.
Instead of a session_id, you can reference an existing session by its own conversation id (see the section below). Provide exactly one of the two.
If you already created the session via the sessions API with your own custom_id, reference it here with session_custom_id plus a version_id or product_id to append inference results to it. If no matching session exists, the call returns a 400 error — create it first via the sessions API.
string
Your own conversation id, as an alternative to session_id. Galtea finds an existing session with this id (per version); the session is not created here. Requires version_id or product_id.
string
The version the session is anchored to when using session_custom_id. If both anchors are given, version_id wins and product_id is ignored.
string
Product anchor used when no version_id is given with session_custom_id: Galtea finds the session with this custom id under the product (across its versions).
If no session matches the session_custom_id and anchor, the call returns a 400 error. Create the session first via the sessions API.
list[dict]
required
A list of dictionaries, where each dictionary represents a conversation turn with role and content keys as mandatory and an optional retrieval_context key. The role key can only have these values: user or assistant.
The retrieval_context key is optional and can be sent to our platform if you have used it when calling your AI product. For this reason, it only makes sense to send it when we have a message with role assistant. When set, Galtea also records it as a RETRIEVER trace on that turn’s inference result.
Maximum batch size recommended: 100 turns. For longer conversations, split into multiple batches or use the individual create() method.
string
The version of Galtea’s conversation simulator used to generate the user messages. This should only be provided when logging a conversation that was generated using the simulator. This parameter helps with traceability and analytics for conversations created through Galtea’s simulation capabilities.