Repository navigation
Mock AgentCore GetEvaluator and Evaluate - #362
Haotian-Hu wants to merge 1 commit into
Conversation
|
|
Pull request dashboard statusWaiting on the author · refreshed 2026-10-23 20:44 UTC Respond to 2 review items (e.g. link a commit, explain why not, ask a follow-up): Status above doesn't look right?
|
There was a problem hiding this comment.
🟢 Approval recommended
The additions are straightforward and deterministic, with only a non-blocking suggestion to strengthen payload regression coverage.
1 open issue
What changed in this PR
Adds deterministic AgentCore evaluation responses to the GenAI mock server, supporting the reference scenario’s capture of evaluation results and rating scales.
Changes:
- Adds
GetEvaluatorwith a numerical rating scale andEvaluatewith a fixed result. - Adds both routes to the determinism tests.
- Documents evaluator lookup and evaluation support.
| File | Description |
|---|---|
tools/gen-ai/mock-server/tests/test_mock_server.py |
Adds deterministic-response checks for both routes. |
tools/gen-ai/mock-server/src/genai_mock_server/bedrock_agentcore.py |
Implements evaluator lookup and evaluation responses. |
tools/gen-ai/mock-server/README.md |
Documents the added AgentCore capabilities. |
Review effort: Balanced
| ] | ||
|
|
|
@Haotian-Hu One small API-fidelity point: AWS defines context as a required field in EvaluationResultContent, but the mocked evaluationResults entry doesn't include it. Could we add a minimal spanContext using the session and trace identifiers from the scenario? That would keep the mock aligned with the AWS response contract and make the evaluated-target correlation explicit. This seems like a small addition that could fit alongside the existing suggestion to strengthen the payload assertions. |

Adds deterministic mock routes for the AWS Bedrock AgentCore evaluation APIs,
GetEvaluator(control plane) andEvaluate(data plane), next to the existing AgentCore memory routes.The
aws-bedrock-agentcorereference scenario in open-telemetry/semantic-conventions-genai needs them to show howgen_ai.evaluation.resultevents, including the evaluator's rating scale, are captured from AgentCore (open-telemetry/semantic-conventions-genai#590). The evaluator returns a numerical 1–5 rating scale andEvaluatereturns one result with a value, label and explanation.