Skip to content

armgit / ax

Public Imported from GitHub
0

Agent Executor (AX) is Google's open agentic orchestration runtime

Go

refactor: ADK agent: rename approved field to confirmed in confirmation response (#340)

zbl94ba9f026f0070
diff --git a/python/adk/content_conversion.py b/python/adk/content_conversion.py
index 96d142b..d973377 100644
--- a/python/adk/content_conversion.py
+++ b/python/adk/content_conversion.py
@@ -43,7 +43,7 @@ def ax_content_to_adk_part(content: content_pb2.Content) -> types.Part:
function_response=types.FunctionResponse(
id=content.confirmation.id,
name="adk_request_confirmation",
- response={"approved": True}
+ response={"confirmed": True}
)
)
elif decision == 'decline':
@@ -51,7 +51,7 @@ def ax_content_to_adk_part(content: content_pb2.Content) -> types.Part:
function_response=types.FunctionResponse(
id=content.confirmation.id,
name="adk_request_confirmation",
- response={"approved": False}
+ response={"confirmed": False}
)
)
else:
diff --git a/python/adk/content_conversion_test.py b/python/adk/content_conversion_test.py
index 4c253e4..c349e6a 100644
--- a/python/adk/content_conversion_test.py
+++ b/python/adk/content_conversion_test.py
@@ -85,7 +85,7 @@ class TestContentConversion(unittest.TestCase):
self.assertIsNotNone(part.function_response)
self.assertEqual(part.function_response.name, "adk_request_confirmation")
self.assertEqual(part.function_response.id, "conf-123")
- self.assertEqual(part.function_response.response["approved"], True)
+ self.assertEqual(part.function_response.response["confirmed"], True)
def test_ax_content_to_adk_part_confirmation_decline(self):
content = content_pb2.Content(
@@ -98,7 +98,7 @@ class TestContentConversion(unittest.TestCase):
self.assertIsNotNone(part.function_response)
self.assertEqual(part.function_response.name, "adk_request_confirmation")
self.assertEqual(part.function_response.id, "conf-123")
- self.assertEqual(part.function_response.response["approved"], False)
+ self.assertEqual(part.function_response.response["confirmed"], False)
def test_adk_part_to_ax_content_confirmation(self):
class MockFunctionCall: