open-mem 0.4.0 → 0.4.2
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 +116 -28
- package/dist/ai/compressor.d.ts +1 -0
- package/dist/ai/compressor.d.ts.map +1 -1
- package/dist/ai/parser.d.ts +1 -0
- package/dist/ai/parser.d.ts.map +1 -1
- package/dist/ai/provider.d.ts +2 -1
- package/dist/ai/provider.d.ts.map +1 -1
- package/dist/ai/rate-limiter.d.ts +9 -0
- package/dist/ai/rate-limiter.d.ts.map +1 -0
- package/dist/ai/summarizer.d.ts +1 -0
- package/dist/ai/summarizer.d.ts.map +1 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/context/builder.d.ts.map +1 -1
- package/dist/db/database.d.ts +4 -0
- package/dist/db/database.d.ts.map +1 -1
- package/dist/db/observations.d.ts +7 -0
- package/dist/db/observations.d.ts.map +1 -1
- package/dist/db/pending.d.ts.map +1 -1
- package/dist/db/schema.d.ts.map +1 -1
- package/dist/db/sessions.d.ts +1 -0
- package/dist/db/sessions.d.ts.map +1 -1
- package/dist/db/summaries.d.ts +1 -0
- package/dist/db/summaries.d.ts.map +1 -1
- package/dist/hooks/chat-capture.d.ts +20 -0
- package/dist/hooks/chat-capture.d.ts.map +1 -0
- package/dist/hooks/session-events.d.ts +3 -2
- package/dist/hooks/session-events.d.ts.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +90 -53
- package/dist/mcp.d.ts +3 -0
- package/dist/mcp.d.ts.map +1 -0
- package/dist/mcp.js +260 -0
- package/dist/queue/processor.d.ts +3 -1
- package/dist/queue/processor.d.ts.map +1 -1
- package/dist/search/embeddings.d.ts +9 -0
- package/dist/search/embeddings.d.ts.map +1 -0
- package/dist/search/hybrid.d.ts +11 -0
- package/dist/search/hybrid.d.ts.map +1 -0
- package/dist/servers/mcp-server.d.ts +33 -0
- package/dist/servers/mcp-server.d.ts.map +1 -0
- package/dist/tools/export.d.ts +6 -0
- package/dist/tools/export.d.ts.map +1 -0
- package/dist/tools/import.d.ts +6 -0
- package/dist/tools/import.d.ts.map +1 -0
- package/dist/tools/recall.d.ts.map +1 -1
- package/dist/tools/save.d.ts.map +1 -1
- package/dist/tools/search.d.ts +2 -1
- package/dist/tools/search.d.ts.map +1 -1
- package/dist/tools/timeline.d.ts.map +1 -1
- package/dist/types.d.ts +5 -0
- package/dist/types.d.ts.map +1 -1
- package/dist/utils/agents-md.d.ts +44 -0
- package/dist/utils/agents-md.d.ts.map +1 -0
- package/dist/utils/worktree.d.ts +10 -0
- package/dist/utils/worktree.d.ts.map +1 -0
- package/package.json +7 -8
package/README.md
CHANGED
|
@@ -70,12 +70,16 @@ Without any provider configured, open-mem still works — it falls back to a bas
|
|
|
70
70
|
|
|
71
71
|
## Key Features
|
|
72
72
|
|
|
73
|
-
- 🧠 **Automatic observation capture** from tool executions
|
|
73
|
+
- 🧠 **Automatic observation capture** from tool executions and user prompts
|
|
74
74
|
- 🤖 **AI-powered compression** via Vercel AI SDK — supports Anthropic, AWS Bedrock, OpenAI, Google (optional — works without API key)
|
|
75
|
-
- 🔍 **
|
|
76
|
-
- 💡 **Progressive disclosure** with token-cost-aware context injection
|
|
75
|
+
- 🔍 **Hybrid search** — FTS5 full-text search + vector embeddings with Reciprocal Rank Fusion
|
|
76
|
+
- 💡 **Progressive disclosure** with token-cost-aware context injection and ROI tracking
|
|
77
77
|
- 🔒 **Privacy controls** with `<private>` tag support
|
|
78
|
-
- 🛠️ **
|
|
78
|
+
- 🛠️ **Six custom tools**: mem-search, mem-save, mem-timeline, mem-recall, mem-export, mem-import
|
|
79
|
+
- 🌐 **MCP server mode** — expose memory tools to any MCP-compatible AI client
|
|
80
|
+
- 🌳 **Git worktree support** — shared memory across all worktrees
|
|
81
|
+
- 📂 **AGENTS.md generation** — auto-generated folder-level context on session end
|
|
82
|
+
- 📦 **Import/export** — portable JSON for backup and transfer between machines
|
|
79
83
|
- ⚡ **Zero-config setup** — works out of the box
|
|
80
84
|
- 📁 **All data stored locally** in your project directory
|
|
81
85
|
|
|
@@ -84,29 +88,40 @@ Without any provider configured, open-mem still works — it falls back to a bas
|
|
|
84
88
|
open-mem runs in the background as an OpenCode plugin. When you use tools (reading files, running commands, editing code), it captures what happened. During idle time, it compresses those captures into structured observations using AI. At the start of your next session, it injects a compact memory index into the system prompt — so your agent knows what you've been working on.
|
|
85
89
|
|
|
86
90
|
```
|
|
87
|
-
|
|
88
|
-
│
|
|
89
|
-
│
|
|
90
|
-
│ tool.execute.after ───> [Tool Capture Hook]
|
|
91
|
-
│
|
|
92
|
-
│
|
|
93
|
-
│
|
|
94
|
-
│
|
|
95
|
-
│
|
|
96
|
-
│
|
|
97
|
-
│
|
|
98
|
-
│
|
|
99
|
-
│
|
|
100
|
-
│
|
|
101
|
-
│
|
|
102
|
-
│
|
|
103
|
-
│
|
|
104
|
-
│
|
|
105
|
-
│
|
|
106
|
-
│
|
|
107
|
-
│
|
|
108
|
-
│
|
|
109
|
-
|
|
91
|
+
┌──────────────────────────────────────────────────────────────┐
|
|
92
|
+
│ OpenCode │
|
|
93
|
+
│ │
|
|
94
|
+
│ tool.execute.after ───> [Tool Capture Hook] │
|
|
95
|
+
│ chat.message ─────────> [Chat Capture Hook] │
|
|
96
|
+
│ │ │
|
|
97
|
+
│ v │
|
|
98
|
+
│ [Pending Queue] │
|
|
99
|
+
│ │ │
|
|
100
|
+
│ session.idle ─────────> [Queue Processor] │
|
|
101
|
+
│ │ │
|
|
102
|
+
│ ┌─────┴─────┐ │
|
|
103
|
+
│ v v │
|
|
104
|
+
│ [AI Compressor] [Embedding Gen] │
|
|
105
|
+
│ │ │ │
|
|
106
|
+
│ v v │
|
|
107
|
+
│ [SQLite + FTS5 + Vectors] │
|
|
108
|
+
│ │ │
|
|
109
|
+
│ system.transform <─── [Context Injector + ROI Footer] │
|
|
110
|
+
│ │
|
|
111
|
+
│ session.end ──────────> [AGENTS.md Generation] │
|
|
112
|
+
│ │
|
|
113
|
+
│ mem-search ─────────> [Hybrid Search (FTS5 + Vector/RRF)] │
|
|
114
|
+
│ mem-save ───────────> [Direct Save] │
|
|
115
|
+
│ mem-timeline ───────> [Session Query] │
|
|
116
|
+
│ mem-recall ─────────> [Full Observation Fetch] │
|
|
117
|
+
│ mem-export ─────────> [JSON Export] │
|
|
118
|
+
│ mem-import ─────────> [JSON Import] │
|
|
119
|
+
│ │
|
|
120
|
+
│ ┌──────────────────────────────────────────┐ │
|
|
121
|
+
│ │ MCP Server (stdin/stdout, JSON-RPC 2.0) │ │
|
|
122
|
+
│ │ Exposes tools to any MCP-compatible AI │ │
|
|
123
|
+
│ └──────────────────────────────────────────┘ │
|
|
124
|
+
└──────────────────────────────────────────────────────────────┘
|
|
110
125
|
```
|
|
111
126
|
|
|
112
127
|
### Observation Capture
|
|
@@ -142,11 +157,35 @@ Example of an injected index entry:
|
|
|
142
157
|
|
|
143
158
|
During session compaction (`experimental.session.compacting`), open-mem injects memory context to preserve important information across compaction boundaries.
|
|
144
159
|
|
|
160
|
+
### Hybrid Search
|
|
161
|
+
|
|
162
|
+
When an AI provider with embedding support is configured (Google, OpenAI, or AWS Bedrock), open-mem generates vector embeddings for observations and uses Reciprocal Rank Fusion (RRF) to merge FTS5 text search with vector similarity search. This significantly improves search relevance.
|
|
163
|
+
|
|
164
|
+
Embeddings are generated automatically during observation processing. If no embedding model is available (e.g., Anthropic, which doesn't offer embeddings), search falls back to FTS5-only — no degradation.
|
|
165
|
+
|
|
166
|
+
### User Prompt Capture
|
|
167
|
+
|
|
168
|
+
open-mem captures user messages via the `chat.message` hook, storing them as searchable observations. This preserves the *intent* behind tool executions — so future sessions can understand not just what happened, but why.
|
|
169
|
+
|
|
170
|
+
### Git Worktree Support
|
|
171
|
+
|
|
172
|
+
open-mem automatically detects git worktrees and resolves to the main repository root. All worktrees share the same memory database, so observations from one worktree are available in all others.
|
|
173
|
+
|
|
174
|
+
### Folder-Level Context (AGENTS.md)
|
|
175
|
+
|
|
176
|
+
On session end, open-mem auto-generates `AGENTS.md` files in project folders that were touched during the session. These files contain a managed section (between `<!-- open-mem-context -->` tags) with recent activity, key concepts, and decisions for that folder.
|
|
177
|
+
|
|
178
|
+
User content outside the managed tags is preserved. Disable with `OPEN_MEM_FOLDER_CONTEXT=false`.
|
|
179
|
+
|
|
180
|
+
### Token ROI Tracking
|
|
181
|
+
|
|
182
|
+
The context injector includes a "Memory Economics" footer showing how much context compression saves: read cost vs. original discovery cost, with a savings percentage. This helps you understand the value of AI compression at a glance.
|
|
183
|
+
|
|
145
184
|
## Custom Tools
|
|
146
185
|
|
|
147
186
|
### mem-search
|
|
148
187
|
|
|
149
|
-
Search through past observations and session summaries
|
|
188
|
+
Search through past observations and session summaries. Uses hybrid search (FTS5 + vector embeddings) when an embedding-capable provider is configured, or FTS5-only otherwise.
|
|
150
189
|
|
|
151
190
|
| Argument | Type | Required | Description |
|
|
152
191
|
|----------|------|----------|-------------|
|
|
@@ -184,6 +223,51 @@ Fetch full observation details by ID. Use after `mem-search` to get complete nar
|
|
|
184
223
|
| `ids` | string[] | yes | Observation IDs to fetch |
|
|
185
224
|
| `limit` | number | no | Maximum number of results (1–50, default: 10) |
|
|
186
225
|
|
|
226
|
+
### mem-export
|
|
227
|
+
|
|
228
|
+
Export project memories (observations and session summaries) as portable JSON for backup or transfer between machines.
|
|
229
|
+
|
|
230
|
+
| Argument | Type | Required | Description |
|
|
231
|
+
|----------|------|----------|-------------|
|
|
232
|
+
| `format` | enum | no | Export format (currently `json` only) |
|
|
233
|
+
| `type` | enum | no | Filter by observation type |
|
|
234
|
+
| `limit` | number | no | Maximum observations to export |
|
|
235
|
+
|
|
236
|
+
### mem-import
|
|
237
|
+
|
|
238
|
+
Import observations and summaries from a JSON export. Skips duplicates by ID.
|
|
239
|
+
|
|
240
|
+
| Argument | Type | Required | Description |
|
|
241
|
+
|----------|------|----------|-------------|
|
|
242
|
+
| `data` | string | yes | JSON string from a mem-export output |
|
|
243
|
+
|
|
244
|
+
## MCP Server Mode
|
|
245
|
+
|
|
246
|
+
open-mem includes a standalone MCP (Model Context Protocol) server that exposes memory tools to any MCP-compatible AI client — not just OpenCode.
|
|
247
|
+
|
|
248
|
+
### Setup
|
|
249
|
+
|
|
250
|
+
Run the MCP server:
|
|
251
|
+
|
|
252
|
+
```bash
|
|
253
|
+
bunx open-mem-mcp --project /path/to/your/project
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
Or add it to your MCP client config:
|
|
257
|
+
|
|
258
|
+
```json
|
|
259
|
+
{
|
|
260
|
+
"mcpServers": {
|
|
261
|
+
"open-mem": {
|
|
262
|
+
"command": "bunx",
|
|
263
|
+
"args": ["open-mem-mcp", "--project", "/path/to/your/project"]
|
|
264
|
+
}
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
```
|
|
268
|
+
|
|
269
|
+
The server communicates over stdin/stdout using JSON-RPC 2.0 and exposes: `mem-search`, `mem-save`, `mem-timeline`, `mem-recall`.
|
|
270
|
+
|
|
187
271
|
## Configuration
|
|
188
272
|
|
|
189
273
|
open-mem works out of the box with zero configuration. All settings can be customized via environment variables:
|
|
@@ -207,6 +291,8 @@ open-mem works out of the box with zero configuration. All settings can be custo
|
|
|
207
291
|
| `OPEN_MEM_CONTEXT_TYPES` | all | Observation types to include in context injection |
|
|
208
292
|
| `OPEN_MEM_CONTEXT_FULL_COUNT` | `3` | Number of recent observations shown in full |
|
|
209
293
|
| `OPEN_MEM_MAX_OBSERVATIONS` | `50` | Maximum observations to consider for context |
|
|
294
|
+
| `OPEN_MEM_FOLDER_CONTEXT` | `true` | Set to `false` to disable AGENTS.md generation |
|
|
295
|
+
| `OPEN_MEM_FOLDER_CONTEXT_MAX_DEPTH` | `5` | Max folder depth for AGENTS.md generation |
|
|
210
296
|
|
|
211
297
|
<details>
|
|
212
298
|
<summary><strong>Programmatic Configuration Reference</strong></summary>
|
|
@@ -232,6 +318,8 @@ If you need to configure open-mem programmatically (e.g. for testing or custom i
|
|
|
232
318
|
| `retentionDays` | number | `90` | Data retention period (0 = forever) |
|
|
233
319
|
| `maxDatabaseSizeMb` | number | `500` | Maximum database size |
|
|
234
320
|
| `logLevel` | string | `warn` | Log level: `debug`, `info`, `warn`, `error` |
|
|
321
|
+
| `folderContextEnabled` | boolean | `true` | Auto-generate AGENTS.md in active folders |
|
|
322
|
+
| `folderContextMaxDepth` | number | `5` | Max folder depth from project root |
|
|
235
323
|
|
|
236
324
|
</details>
|
|
237
325
|
|
package/dist/ai/compressor.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compressor.d.ts","sourceRoot":"","sources":["../../src/ai/compressor.ts"],"names":[],"mappings":"AAIA,OAAO,EAAsB,YAAY,EAAE,MAAM,IAAI,CAAC;AAEtD,OAAO,EAAE,KAAK,iBAAiB,EAA4B,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"compressor.d.ts","sourceRoot":"","sources":["../../src/ai/compressor.ts"],"names":[],"mappings":"AAIA,OAAO,EAAsB,YAAY,EAAE,MAAM,IAAI,CAAC;AAEtD,OAAO,EAAE,KAAK,iBAAiB,EAA4B,MAAM,UAAU,CAAC;AAU5E,MAAM,WAAW,gBAAgB;IAChC,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,uBAAuB,EAAE,MAAM,CAAC;IAChC,kBAAkB,EAAE,OAAO,CAAC;IAC5B,eAAe,EAAE,MAAM,CAAC;IACxB,mBAAmB,EAAE,OAAO,CAAC;CAC7B;AAMD;;;;GAIG;AACH,qBAAa,qBAAqB;IACjC,OAAO,CAAC,KAAK,CAAuB;IACpC,OAAO,CAAC,MAAM,CAAmB;IAGjC,SAAS,sBAAgB;gBAEb,MAAM,EAAE,gBAAgB;IAsBpC,+DAA+D;IAC/D,MAAM,CAAC,QAAQ,CAAC,gBAAgB,SAAU;IAE1C;;;;OAIG;IACG,QAAQ,CACb,QAAQ,EAAE,MAAM,EAChB,UAAU,EAAE,MAAM,EAClB,cAAc,CAAC,EAAE,MAAM,GACrB,OAAO,CAAC,iBAAiB,GAAG,IAAI,CAAC;IAqDpC;;;OAGG;IACG,aAAa,CAClB,KAAK,EAAE,aAAa,CAAC;QACpB,QAAQ,EAAE,MAAM,CAAC;QACjB,UAAU,EAAE,MAAM,CAAC;QACnB,MAAM,EAAE,MAAM,CAAC;QACf,cAAc,CAAC,EAAE,MAAM,CAAC;KACxB,CAAC,GACA,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,iBAAiB,GAAG,IAAI,CAAC,CAAC;IAqBjD;;;OAGG;IACH,yBAAyB,CAAC,QAAQ,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,iBAAiB;IAsB5E,WAAW,IAAI,OAAO,CAAC,OAAO,CAAC;CAarC"}
|
package/dist/ai/parser.d.ts
CHANGED
package/dist/ai/parser.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parser.d.ts","sourceRoot":"","sources":["../../src/ai/parser.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAMhD,MAAM,WAAW,iBAAiB;IACjC,IAAI,EAAE,eAAe,CAAC;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,EAAE,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,SAAS,EAAE,MAAM,EAAE,CAAC;IACpB,aAAa,EAAE,MAAM,EAAE,CAAC;
|
|
1
|
+
{"version":3,"file":"parser.d.ts","sourceRoot":"","sources":["../../src/ai/parser.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAMhD,MAAM,WAAW,iBAAiB;IACjC,IAAI,EAAE,eAAe,CAAC;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,EAAE,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,SAAS,EAAE,MAAM,EAAE,CAAC;IACpB,aAAa,EAAE,MAAM,EAAE,CAAC;IACxB,eAAe,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,MAAM,WAAW,aAAa;IAC7B,OAAO,EAAE,MAAM,CAAC;IAChB,YAAY,EAAE,MAAM,EAAE,CAAC;IACvB,aAAa,EAAE,MAAM,EAAE,CAAC;IACxB,QAAQ,EAAE,MAAM,EAAE,CAAC;IAEnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACnB;AAyCD;;;GAGG;AACH,wBAAgB,wBAAwB,CAAC,QAAQ,EAAE,MAAM,GAAG,iBAAiB,GAAG,IAAI,CA4BnF;AAMD;;;GAGG;AACH,wBAAgB,oBAAoB,CAAC,QAAQ,EAAE,MAAM,GAAG,aAAa,GAAG,IAAI,CA0B3E;AAMD,6DAA6D;AAC7D,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAEnD"}
|
package/dist/ai/provider.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { LanguageModel } from "ai";
|
|
1
|
+
import type { EmbeddingModel, LanguageModel } from "ai";
|
|
2
2
|
export type ProviderType = "anthropic" | "bedrock" | "openai" | "google" | string;
|
|
3
3
|
export interface ModelConfig {
|
|
4
4
|
provider: ProviderType;
|
|
@@ -15,4 +15,5 @@ export declare function resolveBedrockModel(model: string): string;
|
|
|
15
15
|
* Uses dynamic require() so provider packages not installed don't crash at import time.
|
|
16
16
|
*/
|
|
17
17
|
export declare function createModel(config: ModelConfig): LanguageModel;
|
|
18
|
+
export declare function createEmbeddingModel(config: ModelConfig): EmbeddingModel | null;
|
|
18
19
|
//# sourceMappingURL=provider.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"provider.d.ts","sourceRoot":"","sources":["../../src/ai/provider.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"provider.d.ts","sourceRoot":"","sources":["../../src/ai/provider.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,IAAI,CAAC;AAMxD,MAAM,MAAM,YAAY,GAAG,WAAW,GAAG,SAAS,GAAG,QAAQ,GAAG,QAAQ,GAAG,MAAM,CAAC;AAElF,MAAM,WAAW,WAAW;IAC3B,QAAQ,EAAE,YAAY,CAAC;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;CAChB;AAcD;;;GAGG;AACH,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAGzD;AAMD;;;GAGG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,WAAW,GAAG,aAAa,CA6B9D;AAED,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,WAAW,GAAG,cAAc,GAAG,IAAI,CA0B/E"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Enforce RPM rate limit for Gemini free tier.
|
|
3
|
+
* Waits the minimum delay between requests: (60s / RPM) + 100ms safety buffer.
|
|
4
|
+
* No-op if rate limiting is disabled.
|
|
5
|
+
*/
|
|
6
|
+
export declare function enforceRateLimit(model: string, enabled: boolean): Promise<void>;
|
|
7
|
+
/** Reset rate limiter state (for testing) */
|
|
8
|
+
export declare function resetRateLimiter(): void;
|
|
9
|
+
//# sourceMappingURL=rate-limiter.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rate-limiter.d.ts","sourceRoot":"","sources":["../../src/ai/rate-limiter.ts"],"names":[],"mappings":"AAgBA;;;;GAIG;AACH,wBAAsB,gBAAgB,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC,CAerF;AAED,6CAA6C;AAC7C,wBAAgB,gBAAgB,IAAI,IAAI,CAEvC"}
|
package/dist/ai/summarizer.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"summarizer.d.ts","sourceRoot":"","sources":["../../src/ai/summarizer.ts"],"names":[],"mappings":"AAIA,OAAO,EAAsB,YAAY,EAAE,MAAM,IAAI,CAAC;AACtD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAC5C,OAAO,EAAE,KAAK,aAAa,EAAwB,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"summarizer.d.ts","sourceRoot":"","sources":["../../src/ai/summarizer.ts"],"names":[],"mappings":"AAIA,OAAO,EAAsB,YAAY,EAAE,MAAM,IAAI,CAAC;AACtD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAC5C,OAAO,EAAE,KAAK,aAAa,EAAwB,MAAM,UAAU,CAAC;AASpE,MAAM,WAAW,gBAAgB;IAChC,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,uBAAuB,EAAE,MAAM,CAAC;IAChC,kBAAkB,EAAE,OAAO,CAAC;IAC5B,mBAAmB,EAAE,OAAO,CAAC;CAC7B;AAMD;;;GAGG;AACH,qBAAa,iBAAiB;IAC7B,OAAO,CAAC,KAAK,CAAuB;IACpC,OAAO,CAAC,MAAM,CAAmB;IAGjC,SAAS,sBAAgB;gBAEb,MAAM,EAAE,gBAAgB;IAsBpC;;;;OAIG;IACG,SAAS,CACd,SAAS,EAAE,MAAM,EACjB,YAAY,EAAE,aAAa,CAAC,WAAW,CAAC,GACtC,OAAO,CAAC,aAAa,GAAG,IAAI,CAAC;IAyChC;;OAEG;IACH,qBAAqB,CAAC,YAAY,EAAE,aAAa,CAAC,WAAW,CAAC,GAAG,aAAa;IAqC9E,yEAAyE;IACzE,eAAe,CAAC,gBAAgB,EAAE,MAAM,GAAG,OAAO;CAGlD"}
|
package/dist/config.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAmB,aAAa,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAmB,aAAa,EAAE,MAAM,SAAS,CAAC;AAsG9D;;;GAGG;AACH,wBAAgB,aAAa,CAC5B,UAAU,EAAE,MAAM,EAClB,SAAS,CAAC,EAAE,OAAO,CAAC,aAAa,CAAC,GAChC,aAAa,CAgDf;AAMD;;;GAGG;AACH,wBAAgB,cAAc,CAAC,MAAM,EAAE,aAAa,GAAG,MAAM,EAAE,CAuB9D;AAMD,8CAA8C;AAC9C,wBAAgB,gBAAgB,IAAI,aAAa,CAEhD;AAED,2CAA2C;AAC3C,wBAAsB,iBAAiB,CAAC,MAAM,EAAE,aAAa,GAAG,OAAO,CAAC,IAAI,CAAC,CAI5E"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"builder.d.ts","sourceRoot":"","sources":["../../src/context/builder.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAiC,eAAe,EAAE,MAAM,UAAU,CAAC;AAC/E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAMxD,MAAM,WAAW,oBAAoB;IACpC,cAAc,EAAE,OAAO,CAAC;IACxB,gBAAgB,EAAE,eAAe,EAAE,GAAG,KAAK,CAAC;IAC5C,oBAAoB,EAAE,MAAM,CAAC;IAC7B,eAAe,EAAE,OAAO,CAAC;CACzB;AA0BD,wBAAgB,kBAAkB,CACjC,OAAO,EAAE,kBAAkB,EAC3B,MAAM,GAAE,oBAA6C,GACnD,MAAM,
|
|
1
|
+
{"version":3,"file":"builder.d.ts","sourceRoot":"","sources":["../../src/context/builder.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAiC,eAAe,EAAE,MAAM,UAAU,CAAC;AAC/E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAMxD,MAAM,WAAW,oBAAoB;IACpC,cAAc,EAAE,OAAO,CAAC;IACxB,gBAAgB,EAAE,eAAe,EAAE,GAAG,KAAK,CAAC;IAC5C,oBAAoB,EAAE,MAAM,CAAC;IAC7B,eAAe,EAAE,OAAO,CAAC;CACzB;AA0BD,wBAAgB,kBAAkB,CACjC,OAAO,EAAE,kBAAkB,EAC3B,MAAM,GAAE,oBAA6C,GACnD,MAAM,CAoFR;AA4DD,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,kBAAkB,GAAG,MAAM,CAoBvE"}
|
package/dist/db/database.d.ts
CHANGED
|
@@ -13,9 +13,13 @@ export interface Migration {
|
|
|
13
13
|
*/
|
|
14
14
|
export declare class Database {
|
|
15
15
|
private db;
|
|
16
|
+
private dbPath;
|
|
16
17
|
constructor(dbPath: string);
|
|
17
18
|
private open;
|
|
18
19
|
private configure;
|
|
20
|
+
private applyPragmas;
|
|
21
|
+
private deleteSidecarFiles;
|
|
22
|
+
private deleteDatabaseFiles;
|
|
19
23
|
private ensureMigrationTable;
|
|
20
24
|
/**
|
|
21
25
|
* Run pending migrations in version order. Already-applied migrations
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"database.d.ts","sourceRoot":"","sources":["../../src/db/database.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,QAAQ,IAAI,WAAW,EAAE,KAAK,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAG5E,4CAA4C;AAC5C,KAAK,MAAM,GAAG,gBAAgB,EAAE,CAAC;AAMjC,MAAM,WAAW,SAAS;IACzB,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;CACX;AAMD;;;;GAIG;AACH,qBAAa,QAAQ;IACpB,OAAO,CAAC,EAAE,CAAc;
|
|
1
|
+
{"version":3,"file":"database.d.ts","sourceRoot":"","sources":["../../src/db/database.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,QAAQ,IAAI,WAAW,EAAE,KAAK,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAG5E,4CAA4C;AAC5C,KAAK,MAAM,GAAG,gBAAgB,EAAE,CAAC;AAMjC,MAAM,WAAW,SAAS;IACzB,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;CACX;AAMD;;;;GAIG;AACH,qBAAa,QAAQ;IACpB,OAAO,CAAC,EAAE,CAAc;IACxB,OAAO,CAAC,MAAM,CAAS;gBAEX,MAAM,EAAE,MAAM;IAU1B,OAAO,CAAC,IAAI;IAWZ,OAAO,CAAC,SAAS;IAiDjB,OAAO,CAAC,YAAY;IAWpB,OAAO,CAAC,kBAAkB;IAa1B,OAAO,CAAC,mBAAmB;IAe3B,OAAO,CAAC,oBAAoB;IAU5B;;;OAGG;IACI,OAAO,CAAC,UAAU,EAAE,SAAS,EAAE,GAAG,IAAI;IA0B7C,gFAAgF;IACzE,GAAG,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI;IAS9C,+CAA+C;IACxC,GAAG,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,CAAC,GAAG,IAAI;IAKrD,8BAA8B;IACvB,GAAG,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,CAAC,EAAE;IAKhD,uDAAuD;IAChD,IAAI,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI;IAI9B,2EAA2E;IACpE,WAAW,CAAC,CAAC,EAAE,EAAE,EAAE,MAAM,CAAC,GAAG,CAAC;IAQrC,oCAAoC;IAC7B,KAAK,IAAI,IAAI;IAIpB,mDAAmD;IACnD,IAAW,MAAM,IAAI,OAAO,CAO3B;IAED,iEAAiE;IACjE,IAAW,GAAG,IAAI,WAAW,CAE5B;CACD;AAMD,iEAAiE;AACjE,wBAAgB,cAAc,CAAC,MAAM,EAAE,MAAM,GAAG,QAAQ,CAEvD"}
|
|
@@ -4,6 +4,7 @@ export declare class ObservationRepository {
|
|
|
4
4
|
private db;
|
|
5
5
|
constructor(db: Database);
|
|
6
6
|
create(data: Omit<Observation, "id" | "createdAt">): Observation;
|
|
7
|
+
importObservation(data: Observation): void;
|
|
7
8
|
getById(id: string): Observation | null;
|
|
8
9
|
getBySession(sessionId: string): Observation[];
|
|
9
10
|
getCount(sessionId?: string): number;
|
|
@@ -12,6 +13,12 @@ export declare class ObservationRepository {
|
|
|
12
13
|
search(query: SearchQuery): SearchResult[];
|
|
13
14
|
searchByConcept(concept: string, limit?: number): Observation[];
|
|
14
15
|
searchByFile(filePath: string, limit?: number): Observation[];
|
|
16
|
+
setEmbedding(id: string, embedding: number[]): void;
|
|
17
|
+
getWithEmbeddings(projectPath: string, limit: number): Array<{
|
|
18
|
+
id: string;
|
|
19
|
+
embedding: number[];
|
|
20
|
+
title: string;
|
|
21
|
+
}>;
|
|
15
22
|
private mapRow;
|
|
16
23
|
}
|
|
17
24
|
//# sourceMappingURL=observations.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"observations.d.ts","sourceRoot":"","sources":["../../src/db/observations.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EACX,WAAW,EACX,gBAAgB,EAEhB,WAAW,EACX,YAAY,EACZ,MAAM,UAAU,CAAC;AAClB,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"observations.d.ts","sourceRoot":"","sources":["../../src/db/observations.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EACX,WAAW,EACX,gBAAgB,EAEhB,WAAW,EACX,YAAY,EACZ,MAAM,UAAU,CAAC;AAClB,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AA6C3C,qBAAa,qBAAqB;IACrB,OAAO,CAAC,EAAE;gBAAF,EAAE,EAAE,QAAQ;IAMhC,MAAM,CAAC,IAAI,EAAE,IAAI,CAAC,WAAW,EAAE,IAAI,GAAG,WAAW,CAAC,GAAG,WAAW;IA+BhE,iBAAiB,CAAC,IAAI,EAAE,WAAW,GAAG,IAAI;IA+B1C,OAAO,CAAC,EAAE,EAAE,MAAM,GAAG,WAAW,GAAG,IAAI;IAKvC,YAAY,CAAC,SAAS,EAAE,MAAM,GAAG,WAAW,EAAE;IAS9C,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM;IAYpC,mDAAmD;IACnD,QAAQ,CAAC,WAAW,EAAE,MAAM,EAAE,KAAK,SAAK,GAAG,gBAAgB,EAAE;IA0B7D,MAAM,CAAC,KAAK,EAAE,WAAW,GAAG,YAAY,EAAE;IA6B1C,eAAe,CAAC,OAAO,EAAE,MAAM,EAAE,KAAK,SAAK,GAAG,WAAW,EAAE;IAc3D,YAAY,CAAC,QAAQ,EAAE,MAAM,EAAE,KAAK,SAAK,GAAG,WAAW,EAAE;IAqBzD,YAAY,CAAC,EAAE,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,GAAG,IAAI;IAOnD,iBAAiB,CAChB,WAAW,EAAE,MAAM,EACnB,KAAK,EAAE,MAAM,GACX,KAAK,CAAC;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,EAAE,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC;IA6B5D,OAAO,CAAC,MAAM;CAmBd"}
|
package/dist/db/pending.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pending.d.ts","sourceRoot":"","sources":["../../src/db/pending.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"pending.d.ts","sourceRoot":"","sources":["../../src/db/pending.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAc3C,qBAAa,wBAAwB;IACxB,OAAO,CAAC,EAAE;gBAAF,EAAE,EAAE,QAAQ;IAMhC,MAAM,CACL,IAAI,EAAE,IAAI,CAAC,cAAc,EAAE,IAAI,GAAG,WAAW,GAAG,QAAQ,GAAG,YAAY,GAAG,OAAO,CAAC,GAChF,cAAc;IAuBjB,UAAU,CAAC,KAAK,SAAK,GAAG,cAAc,EAAE;IASxC,WAAW,CAAC,MAAM,EAAE,cAAc,CAAC,QAAQ,CAAC,GAAG,cAAc,EAAE;IAa/D,cAAc,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI;IAIhC,aAAa,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI;IAI/B,UAAU,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI;IAO3C;;;;OAIG;IACH,UAAU,CAAC,gBAAgB,SAAI,GAAG,MAAM;IAexC,OAAO,CAAC,MAAM;CAad"}
|
package/dist/db/schema.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../src/db/schema.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAMtD,eAAO,MAAM,MAAM;;;;;;;CAOT,CAAC;AAMX,eAAO,MAAM,UAAU,EAAE,SAAS,
|
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../src/db/schema.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAMtD,eAAO,MAAM,MAAM;;;;;;;CAOT,CAAC;AAMX,eAAO,MAAM,UAAU,EAAE,SAAS,EAgNjC,CAAC;AAMF,iEAAiE;AACjE,wBAAgB,gBAAgB,CAAC,EAAE,EAAE,QAAQ,GAAG,IAAI,CAEnD"}
|
package/dist/db/sessions.d.ts
CHANGED
|
@@ -7,6 +7,7 @@ export declare class SessionRepository {
|
|
|
7
7
|
getOrCreate(sessionId: string, projectPath: string): Session;
|
|
8
8
|
getById(id: string): Session | null;
|
|
9
9
|
getRecent(projectPath: string, limit?: number): Session[];
|
|
10
|
+
getAll(projectPath: string): Session[];
|
|
10
11
|
getActive(): Session[];
|
|
11
12
|
updateStatus(id: string, status: Session["status"]): void;
|
|
12
13
|
markCompleted(id: string): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sessions.d.ts","sourceRoot":"","sources":["../../src/db/sessions.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AACxC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"sessions.d.ts","sourceRoot":"","sources":["../../src/db/sessions.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AACxC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAY3C,qBAAa,iBAAiB;IACjB,OAAO,CAAC,EAAE;gBAAF,EAAE,EAAE,QAAQ;IAMhC,MAAM,CAAC,SAAS,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,GAAG,OAAO;IAWvD,WAAW,CAAC,SAAS,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,GAAG,OAAO;IAU5D,OAAO,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,GAAG,IAAI;IAKnC,SAAS,CAAC,WAAW,EAAE,MAAM,EAAE,KAAK,SAAK,GAAG,OAAO,EAAE;IASrD,MAAM,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,EAAE;IAQtC,SAAS,IAAI,OAAO,EAAE;IAUtB,YAAY,CAAC,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,QAAQ,CAAC,GAAG,IAAI;IAIzD,aAAa,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI;IAO/B,yBAAyB,CAAC,EAAE,EAAE,MAAM,GAAG,IAAI;IAI3C,UAAU,CAAC,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,IAAI;IAQtD,OAAO,CAAC,MAAM;CAWd"}
|
package/dist/db/summaries.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ export declare class SummaryRepository {
|
|
|
4
4
|
private db;
|
|
5
5
|
constructor(db: Database);
|
|
6
6
|
create(data: Omit<SessionSummary, "id" | "createdAt">): SessionSummary;
|
|
7
|
+
importSummary(data: SessionSummary): void;
|
|
7
8
|
getBySessionId(sessionId: string): SessionSummary | null;
|
|
8
9
|
getRecent(limit?: number): SessionSummary[];
|
|
9
10
|
search(query: string, limit?: number): SessionSummary[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"summaries.d.ts","sourceRoot":"","sources":["../../src/db/summaries.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"summaries.d.ts","sourceRoot":"","sources":["../../src/db/summaries.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAkB3C,qBAAa,iBAAiB;IACjB,OAAO,CAAC,EAAE;gBAAF,EAAE,EAAE,QAAQ;IAMhC,MAAM,CAAC,IAAI,EAAE,IAAI,CAAC,cAAc,EAAE,IAAI,GAAG,WAAW,CAAC,GAAG,cAAc;IA4BtE,aAAa,CAAC,IAAI,EAAE,cAAc,GAAG,IAAI;IA6BzC,cAAc,CAAC,SAAS,EAAE,MAAM,GAAG,cAAc,GAAG,IAAI;IAOxD,SAAS,CAAC,KAAK,SAAK,GAAG,cAAc,EAAE;IAUvC,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,SAAK,GAAG,cAAc,EAAE;IAkBnD,OAAO,CAAC,MAAM;CAiBd"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { ObservationRepository } from "../db/observations";
|
|
2
|
+
import type { SessionRepository } from "../db/sessions";
|
|
3
|
+
/**
|
|
4
|
+
* Factory for the `chat.message` hook.
|
|
5
|
+
*
|
|
6
|
+
* Captures user messages as searchable observations so the "why"
|
|
7
|
+
* behind tool executions is preserved in memory.
|
|
8
|
+
*
|
|
9
|
+
* The handler NEVER throws — errors are caught and logged.
|
|
10
|
+
*/
|
|
11
|
+
export declare function createChatCaptureHook(observations: ObservationRepository, sessions: SessionRepository, projectPath: string): (input: {
|
|
12
|
+
sessionID: string;
|
|
13
|
+
agent?: string;
|
|
14
|
+
model?: string;
|
|
15
|
+
messageID?: string;
|
|
16
|
+
}, output: {
|
|
17
|
+
message: unknown;
|
|
18
|
+
parts: unknown[];
|
|
19
|
+
}) => Promise<void>;
|
|
20
|
+
//# sourceMappingURL=chat-capture.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"chat-capture.d.ts","sourceRoot":"","sources":["../../src/hooks/chat-capture.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAChE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AA4CxD;;;;;;;GAOG;AACH,wBAAgB,qBAAqB,CACpC,YAAY,EAAE,qBAAqB,EACnC,QAAQ,EAAE,iBAAiB,EAC3B,WAAW,EAAE,MAAM,IAGlB,OAAO;IACN,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;CACnB,EACD,QAAQ;IAAE,OAAO,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,OAAO,EAAE,CAAA;CAAE,KAC5C,OAAO,CAAC,IAAI,CAAC,CAwChB"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import type { ObservationRepository } from "../db/observations";
|
|
1
2
|
import type { SessionRepository } from "../db/sessions";
|
|
2
3
|
import type { QueueProcessor } from "../queue/processor";
|
|
3
|
-
import type { OpenCodeEvent } from "../types";
|
|
4
|
+
import type { OpenCodeEvent, OpenMemConfig } from "../types";
|
|
4
5
|
/**
|
|
5
6
|
* Factory for the `event` hook.
|
|
6
7
|
*
|
|
@@ -12,7 +13,7 @@ import type { OpenCodeEvent } from "../types";
|
|
|
12
13
|
*
|
|
13
14
|
* The handler NEVER throws.
|
|
14
15
|
*/
|
|
15
|
-
export declare function createEventHandler(queue: QueueProcessor, sessions: SessionRepository, projectPath: string): (input: {
|
|
16
|
+
export declare function createEventHandler(queue: QueueProcessor, sessions: SessionRepository, projectPath: string, config: OpenMemConfig, observations: ObservationRepository): (input: {
|
|
16
17
|
event: OpenCodeEvent;
|
|
17
18
|
}) => Promise<void>;
|
|
18
19
|
//# sourceMappingURL=session-events.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session-events.d.ts","sourceRoot":"","sources":["../../src/hooks/session-events.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"session-events.d.ts","sourceRoot":"","sources":["../../src/hooks/session-events.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAChE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,KAAK,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAG7D;;;;;;;;;;GAUG;AACH,wBAAgB,kBAAkB,CACjC,KAAK,EAAE,cAAc,EACrB,QAAQ,EAAE,iBAAiB,EAC3B,WAAW,EAAE,MAAM,EACnB,MAAM,EAAE,aAAa,EACrB,YAAY,EAAE,qBAAqB,IAErB,OAAO;IAAE,KAAK,EAAE,aAAa,CAAA;CAAE,KAAG,OAAO,CAAC,IAAI,CAAC,CAyC7D"}
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AA0BA,OAAO,KAAK,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAOlD,wBAA8B,MAAM,CAAC,KAAK,EAAE,WAAW,GAAG,OAAO,CAAC,KAAK,CAAC,CAmFvE;AAMD,YAAY,EACX,aAAa,EACb,WAAW,EACX,OAAO,EACP,cAAc,GACd,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,aAAa,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC"}
|