a2a-source-edit: write agent.py
This commit is contained in:
7
agent.py
7
agent.py
@@ -42,12 +42,13 @@ APPROVAL_PHRASE = "I_APPROVE_THE_LISTED_STEPS"
|
||||
OUTPUT_ROOT = "outputs/integrations"
|
||||
SECRET_WORDS = ("secret", "token", "password", "passwd", "apikey", "api_key", "authorization", "bearer")
|
||||
|
||||
_PUBLIC_REQUEST_SCHEMA: dict[str, Any] = {
|
||||
def _tool_input_schema(request_model: type[BaseModel]) -> dict[str, Any]:
|
||||
return {
|
||||
"type": "object",
|
||||
"required": ["request"],
|
||||
"additionalProperties": False,
|
||||
"properties": {"request": {"type": "object", "additionalProperties": True}},
|
||||
}
|
||||
"properties": {"request": request_model.model_json_schema()},
|
||||
}
|
||||
|
||||
|
||||
class StrictModel(BaseModel):
|
||||
|
||||
Reference in New Issue
Block a user