@tangle-network/create-agent-app 2.0.5 → 2.0.8

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": "@tangle-network/create-agent-app",
3
- "version": "2.0.5",
3
+ "version": "2.0.8",
4
4
  "description": "Create a tested Tangle agent application with either a tool loop or a complete chat interface.",
5
5
  "keywords": [
6
6
  "tangle",
@@ -24,15 +24,15 @@
24
24
  "@tangle-network/agent-eval": "1.0.0",
25
25
  "@tangle-network/agent-integrations": "0.76.2",
26
26
  "@tangle-network/agent-interface": "5.10.20",
27
- "@tangle-network/agent-runtime": "2.0.3"
27
+ "@tangle-network/agent-runtime": "3.0.24"
28
28
  },
29
29
  "devDependencies": {
30
30
  "@tangle-network/agent-eval": "1.0.0",
31
31
  "@tangle-network/agent-integrations": "0.76.2",
32
32
  "@tangle-network/agent-interface": "5.10.20",
33
33
  "@tangle-network/agent-knowledge": "23.0.0",
34
- "@tangle-network/agent-runtime": "2.0.3",
35
- "@tangle-network/sandbox": "1.0.40",
34
+ "@tangle-network/agent-runtime": "3.0.24",
35
+ "@tangle-network/sandbox": "1.0.264",
36
36
  "@types/node": "^22.20.1",
37
37
  "typescript": "^7.0.2",
38
38
  "viem": "^2.0.0",
@@ -25,8 +25,8 @@
25
25
  "@tangle-network/agent-app": "__AGENT_APP_VERSION__",
26
26
  "@tangle-network/agent-gateway": "0.11.5",
27
27
  "@tangle-network/agent-interface": "5.10.20",
28
- "@tangle-network/agent-runtime": "2.0.3",
29
- "@tangle-network/sandbox": "1.0.40",
28
+ "@tangle-network/agent-runtime": "3.0.24",
29
+ "@tangle-network/sandbox": "1.0.264",
30
30
  "better-auth": "^1.7.2",
31
31
  "drizzle-orm": "^0.45.2",
32
32
  "hono": "4.13.13",
@@ -0,0 +1,2 @@
1
+ -- cost_usd is the Platform ledger charge; this is the harness's own reported token cost.
2
+ ALTER TABLE message ADD COLUMN harness_cost_usd REAL;
@@ -14,7 +14,7 @@
14
14
  * — see `@tangle-network/agent-app/teams`.
15
15
  */
16
16
 
17
- import { createChatTables } from '@tangle-network/agent-app/chat-store'
17
+ import { createChatTables, harnessCostColumns } from '@tangle-network/agent-app/chat-store'
18
18
  import { integer, sqliteTable, text } from 'drizzle-orm/sqlite-core'
19
19
 
20
20
  // ── better-auth tables ──────────────────────────────────────────────────────
@@ -69,4 +69,4 @@ export const verifications = sqliteTable('verifications', {
69
69
 
70
70
  // ── chat tables (shell-owned columns) ───────────────────────────────────────
71
71
 
72
- export const { threads, messages } = createChatTables({ messageExtraColumns: { turnStreamId: text('turn_stream_id'), backendTerminal: integer('backend_terminal', { mode: 'boolean' }).notNull().default(false) } })
72
+ export const { threads, messages } = createChatTables({ messageExtraColumns: { ...harnessCostColumns(), turnStreamId: text('turn_stream_id'), backendTerminal: integer('backend_terminal', { mode: 'boolean' }).notNull().default(false) } })
@@ -386,7 +386,8 @@ describe('e2e: fake sandbox producer → streamed turn → persisted transcript'
386
386
  expect(assistant.inputTokens).toBe(40)
387
387
  expect(assistant.outputTokens).toBe(20)
388
388
  expect(assistant.reasoningTokens).toBe(5)
389
- expect(assistant.costUsd).toBeCloseTo(0.0123)
389
+ expect(assistant.costUsd).toBeNull()
390
+ expect(assistant.harnessCostUsd).toBeCloseTo(0.0123)
390
391
  expect(assistant.parts?.some((p) => p.type === 'reasoning')).toBe(true)
391
392
  const tool = assistant.parts?.find((p) => p.type === 'tool')
392
393
  expect(tool).toMatchObject({ tool: 'record_search', state: { status: 'completed' } })