@dudousxd/nestjs-agent 1.5.0 → 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -130,6 +130,20 @@ nobody is streaming (including one that has already finished). In-process caller
130
130
  authorized elsewhere use `AgentService.subscribe(runId)`; anything reachable from a request must go
131
131
  through `AgentService.subscribeAs(actor, runId)`.
132
132
 
133
+ ### Resuming a dropped stream
134
+
135
+ Every event frame of `POST /agent/chat` and `GET /agent/chat/:runId/stream` carries an SSE `id:` —
136
+ its 1-based position in the run, the same on every attach. `GET …/stream?after=<n>` (or the
137
+ `Last-Event-ID` header) skips what a reconnecting client already has; the React transport uses it to
138
+ continue a message after a network drop. See docs/stream-protocol.md.
139
+
140
+ ### Message feedback
141
+
142
+ `POST /agent/messages/:id/feedback` `{ value: 'up' | 'down' | null, comment? }` rates a message in
143
+ one of the caller's threads (`null` clears it) and answers `{ feedback }`; `GET /agent/threads/:id`
144
+ returns it on the message. It needs a store with `threadOfMessage` + `setMessageFeedback` (both
145
+ bundled stores and `InMemoryAgentStore` have them) — `501` otherwise.
146
+
133
147
  ### Who approves an action, and for how long
134
148
 
135
149
  Every `action` tool call waits on the person chatting by default. `approvalPolicy` changes that per