Skip to content
v2.273.0

Experimental

@aws-cdk/aws-bedrock-alpha is an experimental (alpha) package: its API may change in any release, without a major version bump.

PromptPostProcessingConfigCustomParser Struct ​

Configuration for the post-processing step.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as bedrock_alpha from '@aws-cdk/aws-bedrock-alpha';
const promptPostProcessingConfigCustomParser: bedrock_alpha.PromptPostProcessingConfigCustomParser = {
  stepType: bedrock_alpha.AgentStepType.PRE_PROCESSING,

  // the properties below are optional
  customPromptTemplate: 'customPromptTemplate',
  inferenceConfig: {
    maximumLength: 123,
    stopSequences: ['stopSequences'],
    temperature: 123,
    topK: 123,
    topP: 123,
  },
  stepEnabled: false,
  useCustomParser: false,
};

Properties ​

customPromptTemplatestringcustom_prompt_templatestrcustomPromptTemplateStringCustomPromptTemplatestringCustomPromptTemplate*string= The default prompt template will…#
The custom prompt template to be used.
default

Default: The default prompt template will be used.

inferenceConfigInferenceConfigurationinference_configInferenceConfigurationinferenceConfigInferenceConfigurationInferenceConfigInferenceConfigurationInferenceConfigInferenceConfiguration= undefined - Default inference co…#
The inference configuration parameters to use.
default

Default: undefined - Default inference configuration will be used

stepEnabledbooleanstep_enabledboolstepEnabledBooleanStepEnabledboolStepEnabled*bool= The default state for each step …#
Whether to enable or skip this step in the agent sequence.
default

Default: The default state for each step type is as follows. PRE_PROCESSING – ENABLED ORCHESTRATION – ENABLED KNOWLEDGE_BASE_RESPONSE_GENERATION – ENABLED POST_PROCESSING – DISABLED

stepTypeAgentStepTypestep_typeAgentStepTypestepTypeAgentStepTypeStepTypeAgentStepTypeStepTypeAgentStepTyperequired#
The type of step this configuration applies to.
useCustomParserbooleanuse_custom_parserbooluseCustomParserBooleanUseCustomParserboolUseCustomParser*bool= false#
Whether to use the custom Lambda parser defined for the sequence.