Class CommonPromptOutputProperty
java.lang.Object
de.xima.fc.prompt.service.support.CommonPromptOutputProperty
Constants with common names for prompt output properties, see
computeQueryOutput.- Since:
- 8.5.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe name of the output parameter that contains the main text answer from a prompt query.static final StringThe name of the output parameter that contains the token usage statistics from a prompt query.static final StringThe name of the field in the output parameterOUTPUT_PARAMETER_TOKEN_USAGEthat contains the number of input tokens used, i.e. tokens in the prompt.static final StringThe name of the field in the output parameterOUTPUT_PARAMETER_TOKEN_USAGEthat contains the number of output tokens generated by the model, i.e. tokens in the response.static final StringThe name of the field in the output parameterOUTPUT_PARAMETER_TOKEN_USAGEthat contains the total number of tokens used, which is the sum of input and output tokens. -
Method Summary
-
Field Details
-
OUTPUT_PARAMETER_ANSWER
The name of the output parameter that contains the main text answer from a prompt query. We encourage implementations to use arecord value descriptorfor their output descriptor, so that more properties can be added later. If the query produces a single text answer that can be considered the main answer (e.g. when prompting the model for a text response; or when transcribing speech to text), it should be placed in a property with this name. By adhering to this convention, you can improve compatibility with other prompt service implementations.- See Also:
-
OUTPUT_PARAMETER_TOKEN_USAGE
The name of the output parameter that contains the token usage statistics from a prompt query. If the prompt service provides token usage information (e.g. number of input and output tokens used), it should be placed in a property with this name. The value associated with this property can be a complex type (e.g. a record value descriptor) that includes details such as input tokens, output tokens, and total tokens used. The exact structure of the value can vary depending on the prompt service implementation, but recommended fields include:- See Also:
-
OUTPUT_PARAMETER_TOKEN_USAGE_INPUT
The name of the field in the output parameterOUTPUT_PARAMETER_TOKEN_USAGEthat contains the number of input tokens used, i.e. tokens in the prompt. We encourage implementations to use these common field names to improve with other prompt service implementations.- See Also:
-
OUTPUT_PARAMETER_TOKEN_USAGE_OUTPUT
The name of the field in the output parameterOUTPUT_PARAMETER_TOKEN_USAGEthat contains the number of output tokens generated by the model, i.e. tokens in the response. We encourage implementations to use these common field names to improve compatibility with other prompt service implementations.- See Also:
-
OUTPUT_PARAMETER_TOKEN_USAGE_TOTAL
The name of the field in the output parameterOUTPUT_PARAMETER_TOKEN_USAGEthat contains the total number of tokens used, which is the sum of input and output tokens. We encourage implementations to use these common field names to improve compatibility with other prompt service implementations.- See Also:
-