You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Return predefined response if available, otherwise default
39
34
forkey, responseinself.responses.items():
40
35
ifkey.lower() inprompt.lower():
41
-
returnMockAnthropicResponse(response)
42
-
returnself.default_response
36
+
returnresponse
37
+
returnjson.dumps(self.default_response)
43
38
44
39
45
40
@pytest.fixture(autouse=True)
@@ -50,6 +45,7 @@ def setup_env():
50
45
if"ANTHROPIC_API_KEY"inos.environ:
51
46
delos.environ["ANTHROPIC_API_KEY"]
52
47
48
+
53
49
@pytest.fixture
54
50
defmock_cache():
55
51
returnMockRedisCache()
@@ -59,7 +55,7 @@ def mock_cache():
59
55
defmock_anthropic_client():
60
56
returnMockAnthropicClient(
61
57
{
62
-
"Create a step-by-step plan": '[{"description": "Research AI agents", "requirements": "Access to documentation", "validation": "Comprehensive notes available"}, {"description": "Write introduction", "requirements": "Research notes", "validation": "Clear introduction exists"}]',
58
+
"Create a step-by-step plan": '{"steps": [{"description": "Research AI agents", "requirements": "Access to documentation", "validation": "Comprehensive notes available"}, {"description": "Write introduction", "requirements": "Research notes", "validation": "Clear introduction exists"}]}',
63
59
"Execute this step": "Step executed successfully with the following results:\n1. Actions: Researched AI agents\n2. Outcome: Comprehensive notes created\n3. Output: 5 pages of detailed notes",
64
60
"Evaluate if the step": "success - all validation criteria met",
65
61
"Analyze the execution history": "Analysis complete. Decision: continue - execution is proceeding as expected",
0 commit comments