All model types return an output object which has the following properties. This object is made available to the scoring functions.

How to use this?

  • Generation
    • Hosted models are pre-configured to respond with this object
    • If you are using Custom scripts, the execute method is expected to return this object
  • Scoring: If you are writing a custom scorer in Python, you can use this as a reference for the output object sent to the scorer.

Output structure

value
string
required

The value from the model (for chat models, this is the message content from the assistant’s response.)

metadata
object

An arbitrary key (string), value (string) object that can be used to store additional metadata (e.g. retrieved context from a RAG pipeline, or result of a pre-processing step). The metadata is shown on the web reporter and can also be scored.

tool_calls
object[]

List of tool call objects in the response from the model.

Tool call

This mirrors the OpenAI tool call object.

id
string
required

A unique identifier for the tool call.

type
string

Equal to “function”, since only one type is supported.

function
object

The function object.

Function

name
string
required

Name of the function

arguments
string

The arguments to call the function with in a string-ified JSON format