@rlabs-inc/memory 0.1.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/bun.lock +102 -0
- package/dist/core/curator.d.ts +61 -0
- package/dist/core/engine.d.ts +111 -0
- package/dist/core/index.d.ts +4 -0
- package/dist/core/retrieval.d.ts +36 -0
- package/dist/core/store.d.ts +113 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +12147 -0
- package/dist/index.mjs +12130 -0
- package/dist/server/index.d.ts +31 -0
- package/dist/server/index.js +12363 -0
- package/dist/server/index.mjs +12346 -0
- package/dist/types/index.d.ts +2 -0
- package/dist/types/memory.d.ts +105 -0
- package/dist/types/schema.d.ts +21 -0
- package/dist/utils/index.d.ts +1 -0
- package/dist/utils/logger.d.ts +65 -0
- package/package.json +56 -0
- package/src/core/curator.ts +433 -0
- package/src/core/engine.ts +404 -0
- package/src/core/index.ts +8 -0
- package/src/core/retrieval.ts +518 -0
- package/src/core/store.ts +505 -0
- package/src/index.ts +58 -0
- package/src/server/index.ts +262 -0
- package/src/types/index.ts +6 -0
- package/src/types/memory.ts +170 -0
- package/src/types/schema.ts +83 -0
- package/src/utils/index.ts +5 -0
- package/src/utils/logger.ts +208 -0
- package/test-retrieval.ts +91 -0
- package/tsconfig.json +16 -0
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { MemoryEngine, type EngineConfig } from '../core/engine.ts';
|
|
2
|
+
import { Curator, type CuratorConfig } from '../core/curator.ts';
|
|
3
|
+
/**
|
|
4
|
+
* Server configuration
|
|
5
|
+
*/
|
|
6
|
+
export interface ServerConfig extends EngineConfig {
|
|
7
|
+
/**
|
|
8
|
+
* Port to listen on
|
|
9
|
+
* Default: 8765 (same as Python)
|
|
10
|
+
*/
|
|
11
|
+
port?: number;
|
|
12
|
+
/**
|
|
13
|
+
* Host to bind to
|
|
14
|
+
* Default: 'localhost'
|
|
15
|
+
*/
|
|
16
|
+
host?: string;
|
|
17
|
+
/**
|
|
18
|
+
* Curator configuration
|
|
19
|
+
*/
|
|
20
|
+
curator?: CuratorConfig;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Create and start the memory server
|
|
24
|
+
* Uses Bun.serve() for high performance
|
|
25
|
+
*/
|
|
26
|
+
export declare function createServer(config?: ServerConfig): {
|
|
27
|
+
server: Bun.Server<undefined>;
|
|
28
|
+
engine: MemoryEngine;
|
|
29
|
+
curator: Curator;
|
|
30
|
+
stop: () => Promise<void>;
|
|
31
|
+
};
|