docs(agent): align event JSDoc with shipped behavior

- agent/error: drop the stale "(plus the logger)" claim; the machine only
  emits the event.
- agent/inbox/claimed: document that a rejected turn boundary ends the
  claimed message without discard or re-emission, and that a later batch
  may reuse the turn number.
- steer(): document that a rejected step leaves steering parked until the
  next wake.
- Fix stray double-space in the inbox inserted/discarded callbacks.
- Sync core.md/core.zh.md mirrors and regenerate the cordis catalog.
This commit is contained in:
_Kerman
2026-08-03 16:09:58 +08:00
parent cb2f01f48c
commit 8171936082
6 changed files with 36 additions and 27 deletions

View File

@@ -80,8 +80,8 @@ export class ReactLoopAgent implements Agent {
public readonly session: Session,
) {
this.inbox = new Inbox(session, {
inserted: (message) =>{ emitAgentEvent(loopCtx, this, 'agent/inbox/inserted', { message }) },
discarded: (message) =>{ emitAgentEvent(loopCtx, this, 'agent/inbox/discarded', { message }) },
inserted: (message) => { emitAgentEvent(loopCtx, this, 'agent/inbox/inserted', { message }) },
discarded: (message) => { emitAgentEvent(loopCtx, this, 'agent/inbox/discarded', { message }) },
})
const lastTurn = session.events.findLast(event => event.type === 'turn/start')?.data.turn ?? 0
this.phase = { kind: 'idle', lastTurn }