@t2000/engine 0.36.0 → 0.36.1
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 +43 -3
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -87,7 +87,7 @@ QueryEngine.submitMessage()
|
|
|
87
87
|
|
|
88
88
|
## Built-in Tools
|
|
89
89
|
|
|
90
|
-
### Read Tools (
|
|
90
|
+
### Read Tools (38 — parallel, auto-approved)
|
|
91
91
|
|
|
92
92
|
| Tool | Description |
|
|
93
93
|
|------|-------------|
|
|
@@ -120,8 +120,17 @@ QueryEngine.submitMessage()
|
|
|
120
120
|
| `toggle_allowance` | Pause or resume agent autonomous spending |
|
|
121
121
|
| `update_daily_limit` | Change the daily USDC spending cap |
|
|
122
122
|
| `update_permissions` | Update which service categories the agent can act on |
|
|
123
|
-
|
|
124
|
-
|
|
123
|
+
| `spending_analytics` | Spending breakdown by service/category over time period |
|
|
124
|
+
| `yield_summary` | Yield earned + projections with sparkline data |
|
|
125
|
+
| `activity_summary` | Activity breakdown by action type |
|
|
126
|
+
| `create_schedule` | Create a recurring scheduled action (DCA) |
|
|
127
|
+
| `list_schedules` | List scheduled actions with trust stage |
|
|
128
|
+
| `cancel_schedule` | Cancel a scheduled action |
|
|
129
|
+
| `render_canvas` | Generate interactive HTML canvas visualizations |
|
|
130
|
+
| `pattern_status` | View behavioral pattern proposals and trust stage |
|
|
131
|
+
| `record_advice` | Record financial advice given for outcome tracking |
|
|
132
|
+
|
|
133
|
+
### Write Tools (12 — serial, confirmation required)
|
|
125
134
|
|
|
126
135
|
| Tool | Description |
|
|
127
136
|
|------|-------------|
|
|
@@ -136,6 +145,34 @@ QueryEngine.submitMessage()
|
|
|
136
145
|
| `volo_stake` | Stake SUI for vSUI (VOLO liquid staking) |
|
|
137
146
|
| `volo_unstake` | Unstake vSUI back to SUI |
|
|
138
147
|
| `save_contact` | Save a contact name + address for quick sends |
|
|
148
|
+
| `pause_pattern` | Pause an autonomous behavioral pattern |
|
|
149
|
+
|
|
150
|
+
## Audric 2.0 Engine Features
|
|
151
|
+
|
|
152
|
+
### Streaming Tool Execution (Early Dispatch)
|
|
153
|
+
|
|
154
|
+
`EarlyToolDispatcher` dispatches read-only tools mid-stream before `message_stop`. Tools with `isReadOnly && isConcurrencySafe` fire as soon as their `tool_use` block completes. Write tools still go through the permission gate.
|
|
155
|
+
|
|
156
|
+
### Tool Result Budgeting
|
|
157
|
+
|
|
158
|
+
Tools can set `maxResultSizeChars` to cap output size. Results exceeding the limit are truncated with a hint to narrow parameters. Custom `summarizeOnTruncate` callbacks supported.
|
|
159
|
+
|
|
160
|
+
### Microcompact
|
|
161
|
+
|
|
162
|
+
`microcompact(messages)` deduplicates identical tool calls (same name + input) in conversation history, replacing repeated results with `[Same result as turn N]`.
|
|
163
|
+
|
|
164
|
+
### Granular Permissions (USD-aware)
|
|
165
|
+
|
|
166
|
+
Write tool permission resolved dynamically via `resolvePermissionTier(operation, amountUsd, config)`. Small amounts auto-execute; large amounts require confirmation. Three presets: `conservative`, `balanced`, `aggressive`.
|
|
167
|
+
|
|
168
|
+
### Reasoning Engine
|
|
169
|
+
|
|
170
|
+
- **Adaptive thinking** — routes queries to `low`/`medium`/`high` effort based on financial complexity
|
|
171
|
+
- **Guard runner** — 9 guards across 3 priority tiers (Safety > Financial > UX)
|
|
172
|
+
- **Skill recipes** — YAML recipe files with longest-trigger-match-wins
|
|
173
|
+
- **Context compaction** — 200k limit, 85% compact trigger, LLM summarizer fallback
|
|
174
|
+
- **Tool flags** — `mutating`, `requiresBalance`, `affectsHealth`, `irreversible` etc.
|
|
175
|
+
- **Preflight validation** — input validation on `send_transfer`, `swap_execute`, `pay_api`, `borrow`, `save_deposit`
|
|
139
176
|
|
|
140
177
|
## Configuration
|
|
141
178
|
|
|
@@ -165,9 +202,12 @@ The `submitMessage()` async generator yields `EngineEvent`:
|
|
|
165
202
|
| Event | Fields | When |
|
|
166
203
|
|-------|--------|------|
|
|
167
204
|
| `text_delta` | `text` | LLM streams a text chunk |
|
|
205
|
+
| `thinking_delta` | `text` | Extended thinking chunk (reasoning accordion) |
|
|
206
|
+
| `thinking_done` | — | Extended thinking complete |
|
|
168
207
|
| `tool_start` | `toolName`, `toolUseId`, `input` | Tool execution begins |
|
|
169
208
|
| `tool_result` | `toolName`, `toolUseId`, `result`, `isError` | Tool execution completes |
|
|
170
209
|
| `pending_action` | `action` (PendingAction) | Write tool awaiting client-side execution |
|
|
210
|
+
| `canvas` | `html` | Interactive HTML visualization from `render_canvas` |
|
|
171
211
|
| `turn_complete` | `stopReason` | Conversation turn finished |
|
|
172
212
|
| `usage` | `inputTokens`, `outputTokens`, `cacheReadTokens?`, `cacheWriteTokens?` | Token usage report |
|
|
173
213
|
| `error` | `error` | Unrecoverable error |
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@t2000/engine",
|
|
3
|
-
"version": "0.36.
|
|
3
|
+
"version": "0.36.1",
|
|
4
4
|
"description": "Agent engine for conversational finance — QueryEngine, financial tools, LLM orchestration",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"@modelcontextprotocol/sdk": "^1.28.0",
|
|
38
38
|
"js-yaml": "^4.1.1",
|
|
39
39
|
"zod": "^3.25.0",
|
|
40
|
-
"@t2000/sdk": "0.36.
|
|
40
|
+
"@t2000/sdk": "0.36.1"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
43
|
"@types/js-yaml": "^4.0.9",
|