@danielzfliu/memory 2.0.0 → 2.2.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
@@ -1,362 +1,20 @@
1
1
  [![npm version](https://img.shields.io/npm/v/@danielzfliu/memory.svg)](https://www.npmjs.com/package/@danielzfliu/memory)
2
+ [![License: GPL v3](https://img.shields.io/badge/License-GPLv3-red.svg)](LICENSE)
2
3
 
3
4
  # Memory
4
5
 
5
- A fully local MCP server and Node.js library for storing, semantically searching, and querying tagged/titled text with ChromaDB (vector storage) and Ollama (embeddings and generation).
6
+ A fully local MCP server, Node.js library, and REST API for storing, semantically searching, and querying tagged or titled text with ChromaDB and Ollama.
6
7
 
7
- Three ways to use Memory:
8
+ ## Documentation
8
9
 
9
- - MCP Server — Run Memory as a Model Context Protocol server over stdio and expose memory tools to MCP-compatible clients.
10
- - npm Package — Install `@danielzfliu/memory` in your own project and use the classes directly (store, embeddings, RAG, and MCP server class).
11
- - REST API Server — Run the standalone HTTP server with CRUD, semantic search, and RAG endpoints.
10
+ - [Docs index](./docs/README.md)
12
11
 
13
- ---
12
+ Use [Configuration](./docs/configuration.md) for runtime options and environment variable overrides.
14
13
 
15
- ## Prerequisites
14
+ ## Development
16
15
 
17
- - **Node.js** ≥ 18
18
- - **Ollama** running locally
19
- - **ChromaDB** server running locally
20
-
21
- ### Setting up Ollama
22
-
23
- Install Ollama ([install](https://ollama.com)) and pull the default models:
24
-
25
- ```bash
26
- ollama pull nomic-embed-text-v2-moe:latest
27
- ollama pull gemma3:latest
28
- ```
29
-
30
- Then run:
31
- ```bash
32
- npm run ollama # start Ollama on default port 11434
33
- npm run ollama:port -- 11435 # start Ollama on a custom port
34
- ```
35
-
36
- ### Setting up ChromaDB
37
-
38
- **Option 1: Docker**
39
-
40
- The repo includes a Docker Compose file that runs ChromaDB and stores its data in `./chroma/`.
41
-
42
- ```bash
43
- npm run docker:up # start ChromaDB on port 8000
44
- npm run docker:logs # view logs
45
- npm run docker:down # stop ChromaDB
46
- ```
47
-
48
- **Option 2: pip**
49
-
50
- ```bash
51
- pip install chromadb
52
- chroma run --port 8000 # start ChromaDB on port 8000
53
- ```
54
-
55
- Note: You may need to add Python's Scripts folder to your PATH after installing.
56
-
57
- ---
58
-
59
- ## Option A: MCP Server
60
-
61
- Use this option to run Memory as a standalone MCP server.
62
-
63
- ### 1. Setup
64
-
65
- ```bash
66
- git clone https://github.com/DanielZFLiu/memory.git
67
- cd memory
68
- npm install
69
- ```
70
-
71
- ### 2. Build and run the MCP server
72
-
73
- ```bash
74
- npm run build
75
- node ./dist/main.js
76
- ```
77
-
78
- Memory MCP communicates over stdio, so it does not bind an HTTP port.
79
-
80
- ### MCP Client Configuration
81
-
82
- #### Claude Desktop (example)
83
-
84
- ```json
85
- {
86
- "mcpServers": {
87
- "memory": {
88
- "command": "npx",
89
- "args": ["-y", "@danielzfliu/memory"]
90
- }
91
- }
92
- }
93
- ```
94
-
95
- If you are running from a local clone instead of npm:
96
-
97
- ```json
98
- {
99
- "mcpServers": {
100
- "memory": {
101
- "command": "node",
102
- "args": ["c:/path/to/memory/dist/main.js"]
103
- }
104
- }
105
- }
106
- ```
107
-
108
- ### MCP Tools
109
-
110
- | Tool | Description |
111
- |------|-------------|
112
- | `add_piece` | Add a new piece with optional title and tags |
113
- | `get_piece` | Retrieve a piece by id |
114
- | `update_piece` | Update piece content, title, and/or tags (`title: null` clears title) |
115
- | `delete_piece` | Delete a piece by id |
116
- | `query_pieces` | Semantic search over content, plus title when present. Supports hybrid search (vector + keyword via RRF). |
117
- | `rag_query` | Retrieve + generate answer with citations using content and title context. Supports hybrid search. |
118
- | `list_collections` | List all collection names in the memory store |
119
- | `delete_collection` | Delete an entire collection and all its pieces |
120
-
121
- All piece-level tools accept an optional `collection` parameter to target a specific collection instead of the default. This allows multiple agents to use isolated memory stores.
122
-
123
- ---
124
-
125
- ## Option B: npm Package
126
-
127
- Use this option to integrate Memory into your own Node.js/TypeScript project.
128
-
129
- ### 1. Install
130
-
131
- ```bash
132
- npm install @danielzfliu/memory
133
- ```
134
-
135
- ### 2. Programmatic usage
136
-
137
- #### Using PieceStore and RagPipeline directly
138
-
139
- ```typescript
140
- import { PieceStore, RagPipeline, MemoryConfig } from "@danielzfliu/memory";
141
-
142
- async function main() {
143
- const config: MemoryConfig = {
144
- chromaUrl: "http://localhost:8000",
145
- ollamaUrl: "http://localhost:11434",
146
- embeddingModel: "nomic-embed-text-v2-moe:latest",
147
- };
148
-
149
- // Store: CRUD + semantic search
150
- const store = new PieceStore(config);
151
- await store.init();
152
-
153
- await store.addPiece(
154
- "TypeScript is a typed superset of JavaScript.",
155
- ["typescript", "programming"],
156
- "TypeScript overview",
157
- );
158
- await store.addPiece("Python is great for data science.", [
159
- "python",
160
- "data-science",
161
- ]);
162
-
163
- const results = await store.queryPieces("typed languages", { topK: 5 });
164
- console.log("results", results);
165
-
166
- const filtered = await store.queryPieces("typed languages", {
167
- tags: ["typescript"],
168
- topK: 5,
169
- });
170
- console.log("filtered", filtered);
171
-
172
- // Hybrid search: combines vector similarity with keyword matching via RRF
173
- const hybrid = await store.queryPieces("typed languages", {
174
- topK: 5,
175
- useHybridSearch: true,
176
- });
177
- console.log("hybrid", hybrid);
178
-
179
- // RAG: retrieve relevant pieces → generate an answer via Ollama
180
- const rag = new RagPipeline(store, config.ollamaUrl!, "gemma3:latest");
181
- const answer = await rag.query("What is TypeScript?", {
182
- tags: ["programming"],
183
- });
184
- console.log("answer", answer);
185
- }
186
-
187
- main().catch((err) => {
188
- console.error(err);
189
- process.exit(1);
190
- });
191
- ```
192
-
193
- #### Embedding the REST API in your own Express app
194
-
195
- `createServer` returns a configured Express app you can mount or extend:
196
-
197
- ```typescript
198
- import { createServer } from "@danielzfliu/memory";
199
-
200
- const app = createServer({
201
- chromaUrl: "http://localhost:8000",
202
- ollamaUrl: "http://localhost:11434",
203
- });
204
-
205
- app.listen(4000, () => console.log("Running on :4000"));
206
- ```
207
-
208
- ---
209
-
210
- ## Option C: REST API Server
211
-
212
- Use this option to run Memory as a standalone HTTP service.
213
-
214
- ### 1. Setup
215
-
216
- ```bash
217
- git clone https://github.com/DanielZFLiu/memory.git
218
- cd memory
219
- npm install
220
- ```
221
-
222
- ### 2. Start the REST server
223
-
224
- ```bash
225
- npm run dev:http
226
- ```
227
-
228
- Server starts on `http://localhost:3000` by default (set `PORT` env var to change).
229
-
230
- ### API Endpoints
231
-
232
- #### Add a piece
233
- ```bash
234
- curl -X POST http://localhost:3000/pieces \
235
- -H "Content-Type: application/json" \
236
- -d '{"title": "TypeScript overview", "content": "TypeScript is a typed superset of JavaScript.", "tags": ["typescript", "programming"]}'
237
- ```
238
-
239
- With a specific collection:
240
- ```bash
241
- curl -X POST http://localhost:3000/pieces \
242
- -H "Content-Type: application/json" \
243
- -d '{"content": "Agent-specific memory.", "tags": ["agent"], "collection": "agent-alice"}'
244
- ```
245
-
246
- #### Get a piece by ID
247
- ```bash
248
- curl http://localhost:3000/pieces/<id>
249
- curl http://localhost:3000/pieces/<id>?collection=agent-alice
250
- ```
251
-
252
- #### Update a piece
253
- ```bash
254
- curl -X PUT http://localhost:3000/pieces/<id> \
255
- -H "Content-Type: application/json" \
256
- -d '{"title": "Updated title", "content": "Updated content.", "tags": ["new-tag"]}'
257
- ```
258
-
259
- Set `title` to `null` to clear it.
260
-
261
- #### Delete a piece
262
16
  ```bash
263
- curl -X DELETE http://localhost:3000/pieces/<id>
264
- curl -X DELETE http://localhost:3000/pieces/<id>?collection=agent-alice
17
+ npm test
18
+ npm run test:watch
19
+ npm run test:coverage
265
20
  ```
266
-
267
- #### Semantic search
268
- ```bash
269
- curl -X POST http://localhost:3000/query \
270
- -H "Content-Type: application/json" \
271
- -d '{"query": "What is TypeScript?", "topK": 5}'
272
- ```
273
-
274
- With tag filtering:
275
- ```bash
276
- curl -X POST http://localhost:3000/query \
277
- -H "Content-Type: application/json" \
278
- -d '{"query": "What is TypeScript?", "tags": ["programming"], "topK": 5}'
279
- ```
280
-
281
- With hybrid search (vector + keyword via Reciprocal Rank Fusion):
282
- ```bash
283
- curl -X POST http://localhost:3000/query \
284
- -H "Content-Type: application/json" \
285
- -d '{"query": "What is TypeScript?", "topK": 5, "useHybridSearch": true}'
286
- ```
287
-
288
- #### RAG query (retrieve + generate)
289
- ```bash
290
- curl -X POST http://localhost:3000/rag \
291
- -H "Content-Type: application/json" \
292
- -d '{"query": "Explain TypeScript", "tags": ["programming"], "topK": 5}'
293
- ```
294
-
295
- Returns:
296
- ```json
297
- {
298
- "answer": "Generated answer based on retrieved context...",
299
- "sources": [
300
- {
301
- "piece": { "id": "...", "title": "...", "content": "...", "tags": ["..."] },
302
- "score": 0.87
303
- }
304
- ]
305
- }
306
- ```
307
-
308
- #### List collections
309
- ```bash
310
- curl http://localhost:3000/collections
311
- ```
312
-
313
- #### Delete a collection
314
- ```bash
315
- curl -X DELETE http://localhost:3000/collections/agent-alice
316
- ```
317
-
318
- > **Multi-collection:** All piece and query endpoints accept an optional `collection` parameter (in the request body for POST/PUT, as a query string for GET/DELETE) to target a specific collection. Omitting it uses the default collection.
319
-
320
- ---
321
-
322
- ## Exports
323
-
324
- | Export | Description |
325
- |--------|-------------|
326
- | `PieceStore` | CRUD + semantic search over tagged text pieces |
327
- | `RagPipeline` | Retrieve-then-generate pipeline using `PieceStore` + Ollama |
328
- | `EmbeddingClient` | Low-level Ollama embedding wrapper |
329
- | `MemoryMcpServer` | MCP server class (stdio transport) exposing memory tools |
330
- | `createServer` | Express app factory with all REST endpoints pre-configured |
331
- | `MemoryConfig` | Configuration interface (all fields optional with defaults) |
332
- | `DEFAULT_MEMORY_CONFIG` | The default values for `MemoryConfig` |
333
- | `Piece` | `{ id, content, title?, tags }` |
334
- | `QueryOptions` | `{ tags?, topK?, useHybridSearch? }` |
335
- | `QueryResult` | `{ piece, score }` |
336
- | `RagResult` | `{ answer, sources }` |
337
-
338
- ---
339
-
340
- ## Configuration (`MemoryConfig`)
341
-
342
- All fields are optional. Defaults are applied automatically.
343
-
344
- | Option | Default | Description |
345
- |--------|---------|-------------|
346
- | `chromaUrl` | `http://localhost:8000` | ChromaDB server URL |
347
- | `ollamaUrl` | `http://localhost:11434` | Ollama server URL |
348
- | `embeddingModel` | `nomic-embed-text-v2-moe:latest` | Ollama model for embeddings |
349
- | `generationModel` | `gemma3:latest` | Ollama model for RAG generation |
350
- | `collectionName` | `pieces` | ChromaDB collection name |
351
-
352
- > **Note:** `generationModel` is used by `createServer` and `MemoryMcpServer`. When constructing `RagPipeline` directly, you pass the model name to its constructor.
353
-
354
- Environment variables with the names above can override these defaults at runtime.
355
-
356
- ## Testing
357
-
358
- ```bash
359
- npm test # run all tests
360
- npm run test:watch # watch mode
361
- npm run test:coverage # with coverage report
362
- ```
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAEvC,eAAO,MAAM,qBAAqB,EAAE,QAAQ,CAAC,YAAY,CAMxD,CAAC;AAqBF,wBAAgB,aAAa,CAAC,MAAM,GAAE,YAAiB,GAAG,QAAQ,CAAC,YAAY,CAAC,CAuB/E"}
1
+ {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAsB,MAAM,SAAS,CAAC;AAE3D,eAAO,MAAM,qBAAqB,EAAE,QAAQ,CAAC,YAAY,CAQxD,CAAC;AAmDF,wBAAgB,aAAa,CAAC,MAAM,GAAE,YAAiB,GAAG,QAAQ,CAAC,YAAY,CAAC,CAmC/E"}
package/dist/config.js CHANGED
@@ -8,6 +8,8 @@ exports.DEFAULT_MEMORY_CONFIG = {
8
8
  embeddingModel: "nomic-embed-text-v2-moe:latest",
9
9
  generationModel: "gemma3:latest",
10
10
  collectionName: "pieces",
11
+ requestLogging: "off",
12
+ corsOrigins: [],
11
13
  };
12
14
  const ENV_CONFIG_KEYS = {
13
15
  chromaUrl: ["MEMORY_CHROMA_URL", "CHROMA_URL"],
@@ -15,6 +17,8 @@ const ENV_CONFIG_KEYS = {
15
17
  embeddingModel: ["MEMORY_EMBEDDING_MODEL", "EMBEDDING_MODEL"],
16
18
  generationModel: ["MEMORY_GENERATION_MODEL", "GENERATION_MODEL"],
17
19
  collectionName: ["MEMORY_COLLECTION_NAME", "COLLECTION_NAME"],
20
+ requestLogging: ["MEMORY_REQUEST_LOGGING", "REQUEST_LOGGING"],
21
+ corsOrigins: ["MEMORY_CORS_ORIGINS", "CORS_ORIGINS"],
18
22
  };
19
23
  function resolveEnvOverride(keys) {
20
24
  for (const key of keys) {
@@ -25,7 +29,36 @@ function resolveEnvOverride(keys) {
25
29
  }
26
30
  return undefined;
27
31
  }
32
+ function resolveRequestLoggingEnvOverride(keys) {
33
+ const value = resolveEnvOverride(keys);
34
+ if (value === undefined) {
35
+ return undefined;
36
+ }
37
+ const normalized = value.toLowerCase();
38
+ if (normalized === "off" || normalized === "metadata" || normalized === "body") {
39
+ return normalized;
40
+ }
41
+ return undefined;
42
+ }
43
+ function resolveCorsOriginsEnvOverride(keys) {
44
+ const value = resolveEnvOverride(keys);
45
+ if (value === undefined) {
46
+ return undefined;
47
+ }
48
+ const origins = value
49
+ .split(",")
50
+ .map((origin) => origin.trim())
51
+ .filter((origin) => origin.length > 0);
52
+ return origins.length > 0 ? origins : undefined;
53
+ }
28
54
  function resolveConfig(config = {}) {
55
+ const envRequestLogging = resolveRequestLoggingEnvOverride(ENV_CONFIG_KEYS.requestLogging);
56
+ const requestLogging = config.requestLogging ??
57
+ envRequestLogging ??
58
+ exports.DEFAULT_MEMORY_CONFIG.requestLogging;
59
+ const corsOrigins = config.corsOrigins ??
60
+ resolveCorsOriginsEnvOverride(ENV_CONFIG_KEYS.corsOrigins) ??
61
+ exports.DEFAULT_MEMORY_CONFIG.corsOrigins;
29
62
  return {
30
63
  chromaUrl: config.chromaUrl ??
31
64
  resolveEnvOverride(ENV_CONFIG_KEYS.chromaUrl) ??
@@ -42,6 +75,8 @@ function resolveConfig(config = {}) {
42
75
  collectionName: config.collectionName ??
43
76
  resolveEnvOverride(ENV_CONFIG_KEYS.collectionName) ??
44
77
  exports.DEFAULT_MEMORY_CONFIG.collectionName,
78
+ requestLogging,
79
+ corsOrigins,
45
80
  };
46
81
  }
47
82
  //# sourceMappingURL=config.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":";;;AA6BA,sCAuBC;AAlDY,QAAA,qBAAqB,GAA2B;IACzD,SAAS,EAAE,uBAAuB;IAClC,SAAS,EAAE,wBAAwB;IACnC,cAAc,EAAE,gCAAgC;IAChD,eAAe,EAAE,eAAe;IAChC,cAAc,EAAE,QAAQ;CAC3B,CAAC;AAEF,MAAM,eAAe,GAAmD;IACpE,SAAS,EAAE,CAAC,mBAAmB,EAAE,YAAY,CAAC;IAC9C,SAAS,EAAE,CAAC,mBAAmB,EAAE,YAAY,CAAC;IAC9C,cAAc,EAAE,CAAC,wBAAwB,EAAE,iBAAiB,CAAC;IAC7D,eAAe,EAAE,CAAC,yBAAyB,EAAE,kBAAkB,CAAC;IAChE,cAAc,EAAE,CAAC,wBAAwB,EAAE,iBAAiB,CAAC;CAChE,CAAC;AAEF,SAAS,kBAAkB,CAAC,IAAc;IACtC,KAAK,MAAM,GAAG,IAAI,IAAI,EAAE,CAAC;QACrB,MAAM,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,IAAI,EAAE,CAAC;QACvC,IAAI,KAAK,EAAE,CAAC;YACR,OAAO,KAAK,CAAC;QACjB,CAAC;IACL,CAAC;IAED,OAAO,SAAS,CAAC;AACrB,CAAC;AAED,SAAgB,aAAa,CAAC,SAAuB,EAAE;IACnD,OAAO;QACH,SAAS,EACL,MAAM,CAAC,SAAS;YAChB,kBAAkB,CAAC,eAAe,CAAC,SAAS,CAAC;YAC7C,6BAAqB,CAA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AAC,cAAc;QACrB,iBAAiB;QACjB,6BAAqB,CAAC,cAAc,CAAC;IACzC,MAAM,WAAW,GACb,MAAM,CAAC,WAAW;QAClB,6BAA6B,CAAC,eAAe,CAAC,WAAW,CAAC;QAC1D,6BAAqB,CAAC,WAAW,CAAC;IAEtC,OAAO;QACH,SAAS,EACL,MAAM,CAAC,SAAS;YAChB,kBAAkB,CAAC,eAAe,CAAC,SAAS,CAAC;YAC7C,6BAAqB,CAAC,SAAS;QACnC,SAAS,EACL,MAAM,CAAC,SAAS;YAChB,kBAAkB,CAAC,eAAe,CAAC,SAAS,CAAC;YAC7C,6BAAqB,CAAC,SAAS;QACnC,cAAc,EACV,MAAM,CAAC,cAAc;YACrB,kBAAkB,CAAC,eAAe,CAAC,cAAc,CAAC;YAClD,6BAAqB,CAAC,cAAc;QACxC,eAAe,EACX,MAAM,CAAC,eAAe;YACtB,kBAAkB,CAAC,eAAe,CAAC,eAAe,CAAC;YACnD,6BAAqB,CAAC,eAAe;QACzC,cAAc,EACV,MAAM,CAAC,cAAc;YACrB,kBAAkB,CAAC,eAAe,CAAC,cAAc,CAAC;YAClD,6BAAqB,CAAC,cAAc;QACxC,cAAc;QACd,WAAW;KACd,CAAC;AACN,CAAC"}
package/dist/index.d.ts CHANGED
@@ -3,6 +3,6 @@ export { RagPipeline } from "./rag";
3
3
  export { EmbeddingClient } from "./embeddings";
4
4
  export { MemoryMcpServer } from "./mcp";
5
5
  export { createServer } from "./server";
6
- export { Piece, MemoryConfig, QueryOptions, QueryResult, RagResult, } from "./types";
6
+ export { Piece, MemoryConfig, RequestLoggingMode, QueryOptions, QueryResult, RagResult, } from "./types";
7
7
  export { DEFAULT_MEMORY_CONFIG } from "./config";
8
8
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AACpC,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,EAAE,eAAe,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AACxC,OAAO,EACH,KAAK,EACL,YAAY,EACZ,YAAY,EACZ,WAAW,EACX,SAAS,GACZ,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AACpC,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,EAAE,eAAe,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AACxC,OAAO,EACH,KAAK,EACL,YAAY,EACZ,kBAAkB,EAClB,YAAY,EACZ,WAAW,EACX,SAAS,GACZ,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAC"}
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,iCAAqC;AAA5B,mGAAA,UAAU,OAAA;AACnB,6BAAoC;AAA3B,kGAAA,WAAW,OAAA;AACpB,2CAA+C;AAAtC,6GAAA,eAAe,OAAA;AACxB,6BAAwC;AAA/B,sGAAA,eAAe,OAAA;AACxB,mCAAwC;AAA/B,sGAAA,YAAY,OAAA;AAQrB,mCAAiD;AAAxC,+GAAA,qBAAqB,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,iCAAqC;AAA5B,mGAAA,UAAU,OAAA;AACnB,6BAAoC;AAA3B,kGAAA,WAAW,OAAA;AACpB,2CAA+C;AAAtC,6GAAA,eAAe,OAAA;AACxB,6BAAwC;AAA/B,sGAAA,eAAe,OAAA;AACxB,mCAAwC;AAA/B,sGAAA,YAAY,OAAA;AASrB,mCAAiD;AAAxC,+GAAA,qBAAqB,OAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAiBvC,wBAAgB,YAAY,CAAC,MAAM,GAAE,YAAiB,+CA4MrD"}
1
+ {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AA6OvC,wBAAgB,YAAY,CAAC,MAAM,GAAE,YAAiB,+CA8UrD"}