@pyxmate/memory 0.20.4 → 0.21.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/LICENSE +1 -1
- package/README.md +63 -34
- package/dist/chunk-7P6ASYW6.mjs +9 -0
- package/dist/cli/pyx-mem.mjs +15705 -0
- package/dist/dashboard.mjs +1 -0
- package/dist/index.mjs +1 -0
- package/dist/react.mjs +1 -0
- package/package.json +7 -4
- package/bin/init.mjs +0 -63
- package/skills/pyx-memory/SKILL.md +0 -143
- package/skills/pyx-memory/examples/disabled-memory.ts +0 -53
- package/skills/pyx-memory/examples/minimal-embedded.ts +0 -37
- package/skills/pyx-memory/examples/minimal-sidecar.ts +0 -14
- package/skills/pyx-memory/patterns/access-control.md +0 -586
- package/skills/pyx-memory/patterns/consumer.md +0 -129
- package/skills/pyx-memory/patterns/embedded.md +0 -249
- package/skills/pyx-memory/patterns/file-uploads.md +0 -78
- package/skills/pyx-memory/reference/advanced.md +0 -274
- package/skills/pyx-memory/reference/http-api.md +0 -526
- package/skills/pyx-memory/reference/parity.md +0 -74
- package/skills/pyx-memory/reference/sdk-guide.md +0 -233
- package/skills/pyx-memory/reference/types.md +0 -344
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -1,69 +1,98 @@
|
|
|
1
1
|
# @pyxmate/memory
|
|
2
2
|
|
|
3
|
-
SDK for **pyx-memory** — Memory as a Service for AI agents.
|
|
3
|
+
SDK + CLI for **pyx-memory** — Memory as a Service for AI agents.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
This package ships:
|
|
6
|
+
|
|
7
|
+
- **`pyx-mem` CLI** — log in once, install the MCP server into Claude Code (or any
|
|
8
|
+
MCP-aware host), inspect status, diagnose problems. Credentials live in the OS
|
|
9
|
+
credential store; no plaintext token files.
|
|
10
|
+
- **`MemoryClient` HTTP SDK** — programmatic Node/Bun client for pyx-memory.
|
|
11
|
+
- **Headless dashboard + React hooks** — `@pyxmate/memory/dashboard`,
|
|
12
|
+
`@pyxmate/memory/react`.
|
|
6
13
|
|
|
7
14
|
## Install
|
|
8
15
|
|
|
9
16
|
```bash
|
|
17
|
+
npm install -g @pyxmate/memory
|
|
18
|
+
# or, in a project:
|
|
10
19
|
npm install @pyxmate/memory
|
|
11
20
|
```
|
|
12
21
|
|
|
13
|
-
|
|
22
|
+
ESM-only. Node ≥ 18. Native credential storage via
|
|
23
|
+
[`@napi-rs/keyring`](https://www.npmjs.com/package/@napi-rs/keyring) (macOS
|
|
24
|
+
Keychain, Linux libsecret / Secret Service, Windows Credential Manager). If a
|
|
25
|
+
package manager omitted optional binaries, re-install with
|
|
26
|
+
`npm install --include=optional`.
|
|
14
27
|
|
|
15
|
-
|
|
28
|
+
## Use it from Claude Code
|
|
16
29
|
|
|
17
30
|
```bash
|
|
18
|
-
|
|
31
|
+
pyx-mem login
|
|
32
|
+
pyx-mem mcp install claude-code --scope user
|
|
19
33
|
```
|
|
20
34
|
|
|
21
|
-
|
|
35
|
+
Restart Claude Code. The 7 memory tools (`search_memories`, `store_memory`,
|
|
36
|
+
`get_memory`, `list_memories`, `delete_memory`, `ingest_memory_file`,
|
|
37
|
+
`summarize_memory_entity`) are auto-discovered via MCP Tool Search.
|
|
22
38
|
|
|
23
|
-
|
|
39
|
+
Drop the [agent-template snippet](https://github.com/pyx-corp/pyx-memory-v1/blob/main/docs/agent-template.md)
|
|
40
|
+
into your project's `CLAUDE.md` / `AGENTS.md` to tell the agent WHEN to search
|
|
41
|
+
vs store.
|
|
24
42
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
import type { MemoryEntry } from '@pyxmate/memory';
|
|
43
|
+
See the [getting-started guide](https://github.com/pyx-corp/pyx-memory-v1/blob/main/packages/sdk/docs/getting-started.md)
|
|
44
|
+
for the full CLI contract and exit codes.
|
|
28
45
|
|
|
29
|
-
|
|
30
|
-
const client = new MemoryClient('https://your-pyx-memory-endpoint', process.env.MEMORY_API_KEY);
|
|
46
|
+
## Use it programmatically
|
|
31
47
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
apiKey: process.env.MEMORY_API_KEY,
|
|
35
|
-
defaultHeaders: { 'X-Tenant-Id': 'tenant-abc' },
|
|
36
|
-
});
|
|
48
|
+
```ts
|
|
49
|
+
import { MemoryClient } from '@pyxmate/memory';
|
|
37
50
|
|
|
38
|
-
|
|
51
|
+
const memory = new MemoryClient('https://memory.api.pyxmate.com', process.env.MEMORY_API_KEY);
|
|
52
|
+
await memory.initialize();
|
|
39
53
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
agentId: 'my-agent',
|
|
54
|
+
await memory.store({
|
|
55
|
+
content: 'The project deadline is 2026-03-15',
|
|
56
|
+
metadata: { topic: 'planning', project: 'orca', source: 'agent' },
|
|
44
57
|
});
|
|
45
58
|
|
|
46
|
-
|
|
47
|
-
const results = await client.search({ query: 'deadline', limit: 5 });
|
|
59
|
+
const results = await memory.search({ query: 'deadline', limit: 5 });
|
|
48
60
|
```
|
|
49
61
|
|
|
50
62
|
## Entry Points
|
|
51
63
|
|
|
52
|
-
| Import |
|
|
64
|
+
| Import | What you get |
|
|
53
65
|
|--------|-------------|
|
|
54
|
-
| `@pyxmate/memory` |
|
|
55
|
-
| `@pyxmate/memory/dashboard` | Headless dashboard utilities —
|
|
56
|
-
| `@pyxmate/memory/react` | React hooks — `useMemoryStats`, `useMemoryHealth`, `useKnowledgeGraph
|
|
66
|
+
| `@pyxmate/memory` | `MemoryClient`, shared types, constants |
|
|
67
|
+
| `@pyxmate/memory/dashboard` | Headless dashboard utilities — aggregations, graph transforms (no React) |
|
|
68
|
+
| `@pyxmate/memory/react` | React hooks — `useMemoryStats`, `useMemoryHealth`, `useKnowledgeGraph` (requires React ≥ 18) |
|
|
57
69
|
|
|
58
|
-
|
|
70
|
+
Bin entry: `pyx-mem`.
|
|
71
|
+
|
|
72
|
+
## Docs
|
|
59
73
|
|
|
60
|
-
|
|
74
|
+
These links point at the source repo because the npm tarball ships only the
|
|
75
|
+
built `dist/` (no markdown docs):
|
|
61
76
|
|
|
62
|
-
|
|
77
|
+
- [getting-started](https://github.com/pyx-corp/pyx-memory-v1/blob/main/packages/sdk/docs/getting-started.md) — CLI + SDK quickstart, exit codes
|
|
78
|
+
- [advanced](https://github.com/pyx-corp/pyx-memory-v1/blob/main/packages/sdk/docs/advanced.md) — RAG strategies, bi-temporal queries, confidence/abstention
|
|
79
|
+
- [types](https://github.com/pyx-corp/pyx-memory-v1/blob/main/packages/sdk/docs/types.md) — public TypeScript types
|
|
80
|
+
- [consumer-patterns](https://github.com/pyx-corp/pyx-memory-v1/blob/main/packages/sdk/docs/consumer-patterns.md) — how to wire `MemoryClient` into a consumer project
|
|
81
|
+
- [parity](https://github.com/pyx-corp/pyx-memory-v1/blob/main/packages/sdk/docs/parity.md) — embedded vs sidecar feature parity
|
|
82
|
+
- [agent-template](https://github.com/pyx-corp/pyx-memory-v1/blob/main/docs/agent-template.md) — `CLAUDE.md` / `AGENTS.md` snippet
|
|
83
|
+
- [file-ingestion](https://github.com/pyx-corp/pyx-memory-v1/blob/main/docs/file-ingestion.md) — file/image ingest caveats
|
|
84
|
+
- [access-control](https://github.com/pyx-corp/pyx-memory-v1/blob/main/docs/access-control.md) — multi-tenant, ReBAC, sensitivity
|
|
85
|
+
- [http-api](https://github.com/pyx-corp/pyx-memory-v1/blob/main/docs/http-api.md) — HTTP endpoints reference
|
|
86
|
+
|
|
87
|
+
## Managed Cloud
|
|
63
88
|
|
|
64
|
-
-
|
|
65
|
-
|
|
89
|
+
pyx-memory is deployed as a managed cloud service at
|
|
90
|
+
**[memory.pyxmate.com](https://memory.pyxmate.com)**.
|
|
66
91
|
|
|
67
92
|
## License
|
|
68
93
|
|
|
69
|
-
MIT
|
|
94
|
+
MIT. This SDK package and its bundled `client`/`shared`/`dashboard` code are
|
|
95
|
+
MIT-licensed; see [LICENSE](./LICENSE). The repository as a whole is a
|
|
96
|
+
mixed-license monorepo — server, engine, and internal apps are proprietary. See
|
|
97
|
+
the [per-package license map](https://github.com/pyx-corp/pyx-memory-v1/blob/main/LICENSES/README.md)
|
|
98
|
+
for the full mapping.
|