-
Notifications
You must be signed in to change notification settings - Fork 9.5k
New resource: aws_bedrockagent_flow #42201
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
…ditionalModel types
Community GuidelinesThis comment is added to every new Pull Request to provide quick reference to how the Terraform AWS Provider is maintained. Please review the information below, and thank you for contributing to the community that keeps the provider thriving! 🚀 Voting for Prioritization
Pull Request Authors
|
}, | ||
NestedObject: schema.NestedBlockObject{ | ||
Blocks: map[string]schema.Block{ | ||
"chat": schema.ListNestedBlock{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems impossible to get an inline chat prompt working. It's not possible from the UI and the api returns an invalid template configuration error without saying why. The chat configuration I send to the API is one I got from bedrock prompt management, which uses the exact same structure plus a few more fields - will attach here soon
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Get prompt output:
% aws bedrock-agent get-prompt --prompt-identifier <prompt-id>
{
"arn": "<arn>",
"createdAt": "2025-04-12T12:57:54.406693+00:00",
"defaultVariant": "variantOne",
"id": "<prompt-id>",
"name": "TestPrompt",
"updatedAt": "2025-04-12T12:58:44.601940+00:00",
"variants": [
{
"inferenceConfiguration": {
"text": {
"maxTokens": 2048,
"stopSequences": [
"User:"
],
"temperature": 0.0,
"topP": 0.8999999761581421
}
},
"modelId": "amazon.titan-text-express-v1",
"name": "variantOne",
"templateConfiguration": {
"chat": {
"inputVariables": [
{
"name": "topic"
}
],
"messages": [
{
"content": [
{
"text": "This is my first text prompt. Please summarize on {{topic}}."
}
],
"role": "user"
},
{
"content": [
{
"text": "Test"
}
],
"role": "assistant"
}
],
"system": [
{
"text": "You are a friendly customer service agent."
}
]
}
},
"templateType": "CHAT"
}
],
"version": "DRAFT"
}
Using the same template configuration in the inline prompt:
% aws bedrock-agent update-flow --flow-identifier <flow-id> --execution-role-arn <role-arn> --name test --definition \
'{
"nodes": [
{
"configuration": {
"prompt": {
"sourceConfiguration": {
"inline": {
"modelId": "amazon.titan-text-express-v1",
"templateConfiguration": {
"chat": {
"inputVariables": [
{
"name": "topic"
}
],
"messages": [
{
"content": [
{
"text": "This is my first text prompt. Please summarize on {{topic}}."
}
],
"role": "user"
},
{
"content": [
{
"text": "Test"
}
],
"role": "assistant"
}
],
"system": [
{
"text": "You are a friendly customer service agent."
}
]
}
},
"templateType": "CHAT"
}
}
}
},
"name": "Prompt_1",
"type": "Prompt"
}
]
}'
An error occurred (ValidationException) when calling the UpdateFlow operation: Invalid prompt template configuration field CHAT provided for the prompt node
✅ Thank you for correcting the previously detected issues! The maintainers appreciate your efforts to make the review process as smooth as possible. |
Description
This implements the resource for AWS Bedrock Flows.
Relations
Closes #41353
References
AWS - Flows User Guide
awscli - create-flow
Output from Acceptance Testing