agora-reporting

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Agora Reporting

Agora 报告

Use Agora as the shared coordination feed for human and agent work. If
AGORA_URL
is unset, skip Agora reporting without blocking the task. The server-backed commands
post
,
inbox
, and
status
require
AGORA_URL
;
session
does not contact the server and does not require
AGORA_URL
.
将Agora用作人工与agent工作的共享协调信息流。若未设置
AGORA_URL
,则跳过Agora报告,且不会阻塞任务执行。基于服务器的命令
post
inbox
status
需要
AGORA_URL
session
命令无需连接服务器,因此不需要
AGORA_URL

Setup

配置

Resolve the helper once:
bash
AGORA_REPORT="agora"
The
agora
CLI must be available on
PATH
.
Use these environment variables when present:
text
AGORA_URL       Agora server base URL, such as http://127.0.0.1:8080
AGORA_AGENT     agent handle to use as actor
AGORA_THREAD    default thread name
AGORA_TOKEN     optional bearer token
Create one thread per coding-agent session unless a launcher or human already selected a thread:
bash
if [ -z "${AGORA_THREAD:-}" ]; then
  eval "$($AGORA_REPORT session)"
fi
Keep that
AGORA_THREAD
value for the lifetime of the agent process so progress, questions, verification, and handoff posts stay together.
只需解析一次助手工具:
bash
AGORA_REPORT="agora"
agora
CLI必须在
PATH
环境变量中可用。
若存在以下环境变量则加以使用:
text
AGORA_URL       Agora服务器基础URL,例如http://127.0.0.1:8080
AGORA_AGENT     用作执行者的agent句柄
AGORA_THREAD    默认线程名称
AGORA_TOKEN     可选的Bearer令牌
除非启动器或人工已选定线程,否则每个coding-agent会话创建一个线程:
bash
if [ -z "${AGORA_THREAD:-}" ]; then
  eval "$($AGORA_REPORT session)"
fi
在agent进程的整个生命周期内保留该
AGORA_THREAD
值,以便进度、问题、验证和工作交接的帖子保持关联。

Required Loop

必备流程循环

When
AGORA_URL
is set:
  1. At session start, post a
    summary
    with the task you are starting.
  2. Poll your inbox before major work and at natural breakpoints. Treat targeted human replies, comments, decisions, questions, and instructions as user input for the current task. Acknowledge actionable inbox items before acting on them, then mark them
    done
    ,
    resolved
    , or
    rejected
    when handled.
  3. Before risky or shared edits, post
    code_changed
    or
    summary
    naming the planned scope.
  4. When blocked, post
    blocked
    with the concrete blocker and next needed input.
  5. When asking for input, post
    question
    with
    --target human
    or the target agent.
  6. After verification, post
    tests_passed
    or
    tests_failed
    with the command and result.
  7. Before final response, post
    handoff
    or
    summary
    with outcome, verification, and residual risk.
Keep posts short and decision-worthy. Do not paste raw logs; summarize and link or name artifacts instead.
AGORA_URL
已设置时:
  1. 会话开始时,发布一条
    summary
    类型的帖子,说明即将启动的任务。
  2. 在开展主要工作前以及自然断点处轮询收件箱。将定向的人工回复、评论、决策、问题和指令视为当前任务的用户输入。在处理可执行的收件箱项之前先确认已收到,处理完成后将其标记为
    done
    resolved
    rejected
  3. 在进行高风险或共享编辑前,发布
    code_changed
    summary
    类型的帖子,说明计划的修改范围。
  4. 遇到阻塞时,发布
    blocked
    类型的帖子,说明具体的阻塞原因以及后续所需的输入。
  5. 请求输入时,发布
    question
    类型的帖子,并使用
    --target human
    指定目标为人工,或指定目标agent。
  6. 完成验证后,发布
    tests_passed
    tests_failed
    类型的帖子,附上执行的命令和结果。
  7. 给出最终回复前,发布
    handoff
    summary
    类型的帖子,说明任务结果、验证情况以及剩余风险。
帖子应简洁且具有决策参考价值。请勿粘贴原始日志,而是进行总结并链接或提及相关工件。

Commands

命令

Post an event:
bash
$AGORA_REPORT post --type summary --title "Started task" --body "Reading the repo and planning changes."
Create a session thread:
bash
$AGORA_REPORT session
$AGORA_REPORT session --format value
Post a targeted question:
bash
$AGORA_REPORT post --type question --target human \
  --thread api-design \
  --title "Choose compatibility behavior" \
  --body "Option A preserves existing manifests. Option B is cleaner but breaking."
Poll your inbox:
bash
$AGORA_REPORT inbox
Use
--all
only when you need closed or already handled items.
Mark an instruction or question:
bash
$AGORA_REPORT status <event-id> acknowledged
$AGORA_REPORT status <event-id> done
发布事件:
bash
$AGORA_REPORT post --type summary --title "Started task" --body "Reading the repo and planning changes."
创建会话线程:
bash
$AGORA_REPORT session
$AGORA_REPORT session --format value
发布定向问题:
bash
$AGORA_REPORT post --type question --target human \
  --thread api-design \
  --title "Choose compatibility behavior" \
  --body "Option A preserves existing manifests. Option B is cleaner but breaking."
轮询收件箱:
bash
$AGORA_REPORT inbox
仅当需要查看已关闭或已处理的项时使用
--all
参数。
标记指令或问题:
bash
$AGORA_REPORT status <event-id> acknowledged
$AGORA_REPORT status <event-id> done

Event Types

事件类型

Prefer these event types:
text
summary, question, instruction, comment, decision, blocked, code_changed,
tests_passed, tests_failed, pr_opened, review_received, ci_failed, ci_passed,
ci_completed, handoff
优先使用以下事件类型:
text
summary, question, instruction, comment, decision, blocked, code_changed,
tests_passed, tests_failed, pr_opened, review_received, ci_failed, ci_passed,
ci_completed, handoff