@agi-cli/server 0.1.88 → 0.1.89

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agi-cli/server",
3
- "version": "0.1.88",
3
+ "version": "0.1.89",
4
4
  "description": "HTTP API server for AGI CLI",
5
5
  "type": "module",
6
6
  "main": "./src/index.ts",
@@ -29,8 +29,8 @@
29
29
  "typecheck": "tsc --noEmit"
30
30
  },
31
31
  "dependencies": {
32
- "@agi-cli/sdk": "0.1.88",
33
- "@agi-cli/database": "0.1.88",
32
+ "@agi-cli/sdk": "0.1.89",
33
+ "@agi-cli/database": "0.1.89",
34
34
  "drizzle-orm": "^0.44.5",
35
35
  "hono": "^4.9.9",
36
36
  "zod": "^4.1.8"
@@ -424,6 +424,16 @@ async function runAssistant(opts: RunOpts) {
424
424
  if (part.type === 'reasoning-end') {
425
425
  const state = reasoningStates.get(part.id);
426
426
  if (!state) continue;
427
+ // Delete the reasoning part if it's empty
428
+ if (!state.text || state.text.trim() === '') {
429
+ try {
430
+ await db
431
+ .delete(messageParts)
432
+ .where(eq(messageParts.id, state.partId));
433
+ } catch {}
434
+ reasoningStates.delete(part.id);
435
+ continue;
436
+ }
427
437
  try {
428
438
  await db
429
439
  .update(messageParts)