AIToday
Large Language ModelsAmazon AI BlogPublished: Aug 20, 2026, 10:01 JST

AWS shows how to cut idle costs when AI agents process requests

AWS shows how to cut idle costs when AI agents process requests

3 Key Points

  1. What happened

    AWS published guidance on three asynchronous invocation patterns for Amazon Bedrock AgentCore agents in serverless pipelines—task-token callback, direct service integration, and durable functions—designed to eliminate idle compute costs while agents reason through tasks.

  2. Why it matters

    When a Lambda function or compute service calls an agent synchronously and waits for a response, it remains billed for its full compute allocation during that idle time, even though the agent itself is not consuming CPU. The three patterns release the caller's compute during the wait, resuming only when the agent returns a result, dramatically reducing costs for workflows like document validation in real-estate financing.

  3. What to watch

    Pattern 2 (direct service integration) removes the Lambda dispatcher entirely by having Step Functions invoke Amazon Bedrock AgentCore directly; Pattern 1 (task-token callback) keeps a Lambda for custom logic but returns in seconds; Pattern 3 (durable functions) expresses the same orchestration as code in a single Lambda using the durable-execution SDK.

Not sure about something? Ask the AI

Questions and answers are published on this page.

Summaries like this, in your inbox every morning.

Context & Analysis

AWS's guidance addresses a fundamental cost asymmetry in serverless AI agent workflows. Amazon Bedrock AgentCore uses a consumption-based model that charges only for memory (and model output tokens) while the agent is idle—it does not bill CPU time during waits on language model generation or external tool calls. The compute service that called the agent, however, has no such behavior: a Lambda, container, or EC2 instance that blocks on a synchronous call holds its entire allocation and incurs billing for every second of that idle time. This mismatch means the caller's cost tracks the agent's runtime, not the agent's actual work. The three patterns AWS describes—task-token callback, direct service integration, and durable functions—all follow the same principle: start the agent, release the caller's compute immediately, and resume only when the agent has a result. The differences are trade-offs in implementation: task-token callback keeps a Lambda in the path for custom logic; direct service integration removes the Lambda entirely by integrating Step Functions directly with AgentCore; and durable functions allow the same orchestration to be expressed as code in a single Lambda rather than a state machine.

FAQ
Why does a blocking Lambda function cost more than an asynchronous one?
A Lambda function that issues a synchronous call to an agent sits blocked on an open connection, holding and paying for its full compute allocation until the agent responds. In contrast, a function that starts the agent and returns is billed only for the brief dispatch—a few seconds—because the function has already shut down while the agent works in the background.
Which pattern removes the Lambda function entirely?
Pattern 2 (direct service integration) eliminates the dispatcher Lambda by having Step Functions call Amazon Bedrock AgentCore directly through its AWS SDK service integration, so the agent's response flows straight into the next state.
How does an agent resume a paused execution after it finishes thinking?
In Pattern 1, the agent calls a Lambda that posts the result and the task token back to Step Functions using SendTaskSuccess. In Pattern 3, the agent resumes the durable function using SendDurableExecutionCallbackSuccess with a callback ID.
Amazon AI BlogRead Original Article

AI news that matters for your work, delivered every morning.

Pick your industry and the AI tools you use, and get news related to your work every day.

Free · 30 seconds with Google · unsubscribe anytimeWhat is AIToday? →

Ask AI

Ask AI anything about this article. The AI reads this article, earlier AIToday articles, and Wikipedia, and cites its sources. Q&As are published on this page for other readers too.

Questions and answers are published on this page.

Related Articles

Next articleTempus AI Jumps on Merck-Moderna Cancer Trial Win