Refresh reviewer runtime visibility
All checks were successful
build / build (push) Successful in 33s

This commit is contained in:
robert
2026-06-08 09:25:53 -03:00
parent d039ee225b
commit 9758c5588d
5 changed files with 16 additions and 5 deletions

View File

@@ -30,7 +30,7 @@ class AgentReviewer(A2AAgent[ReviewerConfig, NoAuth]):
"repo from Gitea, applies security / best-practice / grant-scope "
"skill bundles, and returns a structured ReviewReport."
)
version = "0.1.0"
version = "0.1.1"
config_model = ReviewerConfig
auth_model = NoAuth
@@ -115,6 +115,7 @@ class AgentReviewer(A2AAgent[ReviewerConfig, NoAuth]):
llm_temperature_mode=creds.temperature_mode,
llm_temperature=creds.temperature,
llm_extra_body=creds.extra_body,
llm_metadata=getattr(creds, "metadata", None),
),
completion_box=completion_box,
)
@@ -134,6 +135,7 @@ class AgentReviewer(A2AAgent[ReviewerConfig, NoAuth]):
heartbeat_task = asyncio.create_task(_heartbeat())
last_reply = ""
try:
await ctx.emit_progress(f"review graph starting for {gitea_owner}/{agent_name}@{ref}")
async for event in graph.astream_events(
{"messages": [{"role": "user", "content": user_msg}]},
version="v2",
@@ -168,6 +170,7 @@ class AgentReviewer(A2AAgent[ReviewerConfig, NoAuth]):
report = completion_box.get("report")
if report is None:
await ctx.emit_progress(f"review finished without structured report for {agent_name}@{ref}")
return {
"ok": False,
"agent_name": agent_name,
@@ -175,6 +178,10 @@ class AgentReviewer(A2AAgent[ReviewerConfig, NoAuth]):
"warning": "reviewer finished without submitting a structured report",
"reply": last_reply[:2000],
}
await ctx.emit_progress(
"review submitted "
f"ok={report.ok} findings={len(report.findings)} agent={agent_name}@{ref}"
)
return report.model_dump()