Node.js
安装官方 Node.js / TypeScript SDK:arbitrator,在 Memorose 服务启动时配置。SDK 请求不会选择 reranker 模型。Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
面向当前 Memorose /v1 运行时的 Node.js / TypeScript SDK。
npm install memorose-client
import { MemoroseClient } from "memorose-client";
const client = new MemoroseClient("http://127.0.0.1:3000", "your_api_key");
const streamId = "11111111-1111-1111-1111-111111111111";
await client.ingestEvent("user_123", streamId, {
content: "Dylan prefers concise summaries.",
org_id: "default",
});
const response = await client.retrieveMemory("user_123", streamId, {
query: "What does Dylan prefer?",
limit: 5,
org_id: "default",
});
console.log(response.results);
arbitrator,在 Memorose 服务启动时配置。SDK 请求不会选择 reranker 模型。