Class Trace
- All Implemented Interfaces:
Serializable,SdkPojo,ToCopyableBuilder<Trace.Builder,Trace>
Contains one part of the agent's reasoning process and results from calling API actions and querying knowledge bases. You can use the trace to understand how the agent arrived at the response it provided the customer. For more information, see Trace enablement.
- See Also:
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic Trace.Builderbuilder()final CustomOrchestrationTraceDetails about the custom orchestration step in which the agent determines the order in which actions are executed.final booleanfinal booleanequalsBySdkFields(Object obj) final FailureTraceContains information about the failure of the interaction.static TracefromCustomOrchestrationTrace(Consumer<CustomOrchestrationTrace.Builder> customOrchestrationTrace) Create an instance of this class withcustomOrchestrationTrace()initialized to the given value.static TracefromCustomOrchestrationTrace(CustomOrchestrationTrace customOrchestrationTrace) Create an instance of this class withcustomOrchestrationTrace()initialized to the given value.static TracefromFailureTrace(Consumer<FailureTrace.Builder> failureTrace) Create an instance of this class withfailureTrace()initialized to the given value.static TracefromFailureTrace(FailureTrace failureTrace) Create an instance of this class withfailureTrace()initialized to the given value.static TracefromGuardrailTrace(Consumer<GuardrailTrace.Builder> guardrailTrace) Create an instance of this class withguardrailTrace()initialized to the given value.static TracefromGuardrailTrace(GuardrailTrace guardrailTrace) Create an instance of this class withguardrailTrace()initialized to the given value.static TracefromOrchestrationTrace(Consumer<OrchestrationTrace.Builder> orchestrationTrace) Create an instance of this class withorchestrationTrace()initialized to the given value.static TracefromOrchestrationTrace(OrchestrationTrace orchestrationTrace) Create an instance of this class withorchestrationTrace()initialized to the given value.static TracefromPostProcessingTrace(Consumer<PostProcessingTrace.Builder> postProcessingTrace) Create an instance of this class withpostProcessingTrace()initialized to the given value.static TracefromPostProcessingTrace(PostProcessingTrace postProcessingTrace) Create an instance of this class withpostProcessingTrace()initialized to the given value.static TracefromPreProcessingTrace(Consumer<PreProcessingTrace.Builder> preProcessingTrace) Create an instance of this class withpreProcessingTrace()initialized to the given value.static TracefromPreProcessingTrace(PreProcessingTrace preProcessingTrace) Create an instance of this class withpreProcessingTrace()initialized to the given value.static TracefromRoutingClassifierTrace(Consumer<RoutingClassifierTrace.Builder> routingClassifierTrace) Create an instance of this class withroutingClassifierTrace()initialized to the given value.static TracefromRoutingClassifierTrace(RoutingClassifierTrace routingClassifierTrace) Create an instance of this class withroutingClassifierTrace()initialized to the given value.final <T> Optional<T>getValueForField(String fieldName, Class<T> clazz) final GuardrailTraceThe trace details for a trace defined in the Guardrail filter.final inthashCode()final OrchestrationTraceDetails about the orchestration step, in which the agent determines the order in which actions are executed and which knowledge bases are retrieved.final PostProcessingTraceDetails about the post-processing step, in which the agent shapes the response..final PreProcessingTraceDetails about the pre-processing step, in which the agent contextualizes and categorizes user inputs.final RoutingClassifierTraceA routing classifier's trace.static Class<? extends Trace.Builder>final StringtoString()Returns a string representation of this object.type()Retrieve an enum value representing which member of this object is populated.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
Method Details
-
customOrchestrationTrace
Details about the custom orchestration step in which the agent determines the order in which actions are executed.
- Returns:
- Details about the custom orchestration step in which the agent determines the order in which actions are executed.
-
failureTrace
Contains information about the failure of the interaction.
- Returns:
- Contains information about the failure of the interaction.
-
guardrailTrace
The trace details for a trace defined in the Guardrail filter.
- Returns:
- The trace details for a trace defined in the Guardrail filter.
-
orchestrationTrace
Details about the orchestration step, in which the agent determines the order in which actions are executed and which knowledge bases are retrieved.
- Returns:
- Details about the orchestration step, in which the agent determines the order in which actions are executed and which knowledge bases are retrieved.
-
postProcessingTrace
Details about the post-processing step, in which the agent shapes the response..
- Returns:
- Details about the post-processing step, in which the agent shapes the response..
-
preProcessingTrace
Details about the pre-processing step, in which the agent contextualizes and categorizes user inputs.
- Returns:
- Details about the pre-processing step, in which the agent contextualizes and categorizes user inputs.
-
routingClassifierTrace
A routing classifier's trace.
- Returns:
- A routing classifier's trace.
-
toBuilder
- Specified by:
toBuilderin interfaceToCopyableBuilder<Trace.Builder,Trace>
-
builder
-
serializableBuilderClass
-
hashCode
public final int hashCode() -
equals
-
equalsBySdkFields
- Specified by:
equalsBySdkFieldsin interfaceSdkPojo
-
toString
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value. -
getValueForField
-
fromCustomOrchestrationTrace
Create an instance of this class withcustomOrchestrationTrace()initialized to the given value.Details about the custom orchestration step in which the agent determines the order in which actions are executed.
- Parameters:
customOrchestrationTrace- Details about the custom orchestration step in which the agent determines the order in which actions are executed.
-
fromCustomOrchestrationTrace
public static Trace fromCustomOrchestrationTrace(Consumer<CustomOrchestrationTrace.Builder> customOrchestrationTrace) Create an instance of this class withcustomOrchestrationTrace()initialized to the given value.Details about the custom orchestration step in which the agent determines the order in which actions are executed.
- Parameters:
customOrchestrationTrace- Details about the custom orchestration step in which the agent determines the order in which actions are executed.
-
fromFailureTrace
Create an instance of this class withfailureTrace()initialized to the given value.Contains information about the failure of the interaction.
- Parameters:
failureTrace- Contains information about the failure of the interaction.
-
fromFailureTrace
Create an instance of this class withfailureTrace()initialized to the given value.Contains information about the failure of the interaction.
- Parameters:
failureTrace- Contains information about the failure of the interaction.
-
fromGuardrailTrace
Create an instance of this class withguardrailTrace()initialized to the given value.The trace details for a trace defined in the Guardrail filter.
- Parameters:
guardrailTrace- The trace details for a trace defined in the Guardrail filter.
-
fromGuardrailTrace
Create an instance of this class withguardrailTrace()initialized to the given value.The trace details for a trace defined in the Guardrail filter.
- Parameters:
guardrailTrace- The trace details for a trace defined in the Guardrail filter.
-
fromOrchestrationTrace
Create an instance of this class withorchestrationTrace()initialized to the given value.Details about the orchestration step, in which the agent determines the order in which actions are executed and which knowledge bases are retrieved.
- Parameters:
orchestrationTrace- Details about the orchestration step, in which the agent determines the order in which actions are executed and which knowledge bases are retrieved.
-
fromOrchestrationTrace
Create an instance of this class withorchestrationTrace()initialized to the given value.Details about the orchestration step, in which the agent determines the order in which actions are executed and which knowledge bases are retrieved.
- Parameters:
orchestrationTrace- Details about the orchestration step, in which the agent determines the order in which actions are executed and which knowledge bases are retrieved.
-
fromPostProcessingTrace
Create an instance of this class withpostProcessingTrace()initialized to the given value.Details about the post-processing step, in which the agent shapes the response..
- Parameters:
postProcessingTrace- Details about the post-processing step, in which the agent shapes the response..
-
fromPostProcessingTrace
public static Trace fromPostProcessingTrace(Consumer<PostProcessingTrace.Builder> postProcessingTrace) Create an instance of this class withpostProcessingTrace()initialized to the given value.Details about the post-processing step, in which the agent shapes the response..
- Parameters:
postProcessingTrace- Details about the post-processing step, in which the agent shapes the response..
-
fromPreProcessingTrace
Create an instance of this class withpreProcessingTrace()initialized to the given value.Details about the pre-processing step, in which the agent contextualizes and categorizes user inputs.
- Parameters:
preProcessingTrace- Details about the pre-processing step, in which the agent contextualizes and categorizes user inputs.
-
fromPreProcessingTrace
Create an instance of this class withpreProcessingTrace()initialized to the given value.Details about the pre-processing step, in which the agent contextualizes and categorizes user inputs.
- Parameters:
preProcessingTrace- Details about the pre-processing step, in which the agent contextualizes and categorizes user inputs.
-
fromRoutingClassifierTrace
Create an instance of this class withroutingClassifierTrace()initialized to the given value.A routing classifier's trace.
- Parameters:
routingClassifierTrace- A routing classifier's trace.
-
fromRoutingClassifierTrace
public static Trace fromRoutingClassifierTrace(Consumer<RoutingClassifierTrace.Builder> routingClassifierTrace) Create an instance of this class withroutingClassifierTrace()initialized to the given value.A routing classifier's trace.
- Parameters:
routingClassifierTrace- A routing classifier's trace.
-
type
Retrieve an enum value representing which member of this object is populated. When this class is returned in a service response, this will beTrace.Type.UNKNOWN_TO_SDK_VERSIONif the service returned a member that is only known to a newer SDK version. When this class is created directly in your code, this will beTrace.Type.UNKNOWN_TO_SDK_VERSIONif zero members are set, andnullif more than one member is set. -
sdkFields
-
sdkFieldNameToField
- Specified by:
sdkFieldNameToFieldin interfaceSdkPojo
-