@tpsdev-ai/flair 0.9.0 → 0.10.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/README.md +17 -19
- package/dist/cli.js +1480 -437
- package/dist/rem/restore.js +62 -2
- package/dist/render.js +168 -0
- package/dist/resources/A2AAdapter.js +33 -3
- package/dist/resources/AdminInstance.js +44 -8
- package/dist/resources/AgentCard.js +5 -14
- package/dist/resources/Federation.js +64 -33
- package/dist/resources/agentcard-fields.js +40 -0
- package/dist/resources/auth-middleware.js +37 -29
- package/dist/resources/federation-classify.js +29 -0
- package/dist/resources/health.js +12 -7
- package/package.json +11 -2
- package/schemas/federation.graphql +6 -3
- package/schemas/schema.graphql +1 -1
package/README.md
CHANGED
|
@@ -4,9 +4,9 @@
|
|
|
4
4
|
[](https://github.com/tpsdev-ai/flair/actions/workflows/docker-test.yml)
|
|
5
5
|
[](https://opensource.org/licenses/Apache-2.0)
|
|
6
6
|
|
|
7
|
-
> **The memory
|
|
7
|
+
> **The identity and memory substrate for AI agents. Crypto-pinned. Federated. Self-hosted.**
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
Flair is the **identity + memory substrate for AI agents**. Cryptographic per-agent identity (Ed25519). Soul as a first-class primitive, separate from memory. Federation across hosts (hub/spoke). Same agent, every orchestrator — memory follows.
|
|
10
10
|
|
|
11
11
|
```
|
|
12
12
|
┌──────────────────────────────────────────────────────────────────┐
|
|
@@ -17,7 +17,7 @@ Most agent memory systems store *facts*. Flair stores facts AND the agent's iden
|
|
|
17
17
|
│ Codex CLI ─┼─[ flair-mcp ]─┐ │
|
|
18
18
|
│ Gemini CLI ─┤ │ │
|
|
19
19
|
│ Continue.dev ─┤ │ ┌──────────────────────┐ │
|
|
20
|
-
│ Goose ─┘ ├─▶ │ Flair (
|
|
20
|
+
│ Goose ─┘ ├─▶ │ Flair (self-hosted) │ │
|
|
21
21
|
│ LangGraph ─[ langgraph-flair ]──│ Ed25519 / HNSW / │ │
|
|
22
22
|
│ OpenClaw ─[ openclaw-flair ]──│ Soul + Memory │ │
|
|
23
23
|
│ n8n ─[ n8n-nodes-flair ]──└──────────┬───────────┘ │
|
|
@@ -42,22 +42,18 @@ Most agent memory systems store *facts*. Flair stores facts AND the agent's iden
|
|
|
42
42
|
|
|
43
43
|

|
|
44
44
|
|
|
45
|
-
Same Ed25519 identity, same memory store, three different MCP-capable CLIs (Claude Code, Codex CLI, Gemini CLI). A memory written from one is immediately retrievable from the next.
|
|
45
|
+
Same Ed25519 identity, same memory store, three different MCP-capable CLIs (Claude Code, Codex CLI, Gemini CLI). A memory written from one is immediately retrievable from the next. Your agent's identity and history aren't bound to a single orchestrator's runtime.
|
|
46
46
|
|
|
47
47
|
## How Flair compares
|
|
48
48
|
|
|
49
49
|
| | Flair | Mem0 | Honcho | Letta (MemGPT) | Built-ins (OAI/Anthropic/Google) |
|
|
50
50
|
|---|---|---|---|---|---|
|
|
51
|
-
| **License** | Apache 2.0 | Apache 2.0 | AGPL-3.0 | Apache 2.0 | proprietary |
|
|
52
|
-
| **Self-host** | yes | yes (Docker) | yes (Docker) | yes | no |
|
|
53
|
-
| **Managed cloud also offered** | no | yes (app.mem0.ai) | yes (app.honcho.dev) | no | only mode |
|
|
54
51
|
| **Identity model** | **Ed25519 per agent (crypto-pinned)** | tenant-isolation | per-user soft tenant | runtime-bound | account-scoped |
|
|
55
52
|
| **Federation (peer-to-peer)** | **yes — hub/spoke validated** | no | no | no | no |
|
|
56
53
|
| **Cross-orchestrator** | **11+ harnesses, same memory** | several | several | runtime-bound | vendor-locked |
|
|
57
|
-
| **Semantic search** | in-process (nomic-embed, no API calls) | yes | yes | yes | varies |
|
|
58
54
|
| **Soul / persistent character** | **first-class** | optional | persona-shaped | optional | no |
|
|
59
55
|
|
|
60
|
-
|
|
56
|
+
Four rows where Flair holds a cell no other system holds cleanly today. Parity rows (license, self-host, semantic search) are table-stakes for this neighborhood — Mem0, Honcho, and Letta are all open-source and self-hostable — so they're omitted to keep the moat visible.
|
|
61
57
|
|
|
62
58
|
The honest gaps:
|
|
63
59
|
|
|
@@ -71,11 +67,13 @@ If you need any of those specifically, use them. If you need crypto-pinned ident
|
|
|
71
67
|
|
|
72
68
|
Anthropic shipped [Claude Dreams](https://platform.claude.com/docs/en/managed-agents/dreams) (research preview, April 2026) — async pipeline that reads a memory store + session transcripts and produces a curated output store: duplicates merged, stale entries replaced, insights surfaced. Validates the category: agent memory accumulates drift and needs cleanup.
|
|
73
69
|
|
|
74
|
-
Flair ships
|
|
70
|
+
Flair ships both the on-demand curation surface (`flair rem rapid`) AND the scheduled nightly cycle in v0.9.0, per the [FLAIR-NIGHTLY-REM spec](specs/FLAIR-NIGHTLY-REM.md).
|
|
75
71
|
|
|
76
|
-
- **`flair rem rapid`**
|
|
77
|
-
- **`flair rem candidates` / `flair rem promote <id> --rationale "<why>"` / `flair rem reject <id>`**
|
|
78
|
-
- **`flair rem nightly
|
|
72
|
+
- **`flair rem rapid`** — on-demand reflection. `--focus {lessons_learned, patterns, decisions, errors}` mirrors Dreams' `instructions` parameter. Outputs *candidates*, not a wholesale store swap.
|
|
73
|
+
- **`flair rem candidates` / `flair rem promote <id> --rationale "<why>"` / `flair rem reject <id>`** — review and promote distilled candidates with required rationale.
|
|
74
|
+
- **`flair rem nightly enable [--at HH:MM]`** — scheduled automation via platform-native scheduler (launchd / systemd). Pre-cycle snapshot to `~/.flair/snapshots/<agent>/<iso>.tar.gz`. Maintenance step (soft-delete expired + soft-archive stale). Audit log to `~/.flair/logs/rem-nightly.jsonl`. `flair rem pause` / `resume` for emergency stop.
|
|
75
|
+
- **`flair rem restore <date> --apply`** — rewinds Harper state to a snapshot. Takes a pre-restore snapshot of current state first, so the rewind itself is reversible.
|
|
76
|
+
- *Slice-3 (1.1)* — automated server-side distillation (requires pluggable LLM provider), trust-tier filter on REM input, cross-agent restore. Until then, distillation is operator-triggered via `flair rem rapid` followed by manual promote/reject.
|
|
79
77
|
|
|
80
78
|
The substantive difference is the **promotion contract**:
|
|
81
79
|
|
|
@@ -83,7 +81,7 @@ The substantive difference is the **promotion contract**:
|
|
|
83
81
|
|---|---|---|
|
|
84
82
|
| **Output** | New memory store — accept or discard | Staged candidates — per-candidate decision |
|
|
85
83
|
| **Promotion gate** | None — accept the whole store | `flair rem promote <id> --rationale "<why>"` |
|
|
86
|
-
| **Reversibility** | Input store is never modified (real safety property) |
|
|
84
|
+
| **Reversibility** | Input store is never modified (real safety property) | Pre-cycle snapshot + `rem restore <date> --apply` (rewinds Harper state, takes a pre-restore snapshot too) |
|
|
87
85
|
| **Where it runs** | Anthropic Managed Agents (SaaS, Anthropic models only) | Self-hosted, any model |
|
|
88
86
|
|
|
89
87
|
Dreams is easier to start with — one API call, and the input-never-modified contract gives you a clean rollback by simply not accepting the output. REM is the more granular surface — per-candidate decisions with required rationale — for operators who want to merge what's right and reject what's wrong on the same nightly cycle. Both are legitimate choices; the right one depends on whether you want store-level or candidate-level review.
|
|
@@ -148,7 +146,7 @@ Not all memories are equal:
|
|
|
148
146
|
Memories can be time-bounded with `validFrom` and `validTo` fields. Expired memories are excluded from search and bootstrap automatically — no manual cleanup.
|
|
149
147
|
|
|
150
148
|
### Relationship Graph
|
|
151
|
-
Entity-to-entity triples with temporal bounds. Model structured knowledge — "
|
|
149
|
+
Entity-to-entity triples with temporal bounds. Model structured knowledge — "Alice works-with Bob since 2024-01-01" — queryable alongside semantic memory.
|
|
152
150
|
|
|
153
151
|
### Real-Time Feeds
|
|
154
152
|
Subscribe to memory or soul changes via WebSocket/SSE. Useful for dashboards, cross-agent sync, or audit trails.
|
|
@@ -360,7 +358,7 @@ flair/
|
|
|
360
358
|
- **Harper-native** — No Express, no middleware frameworks. Harper IS the runtime.
|
|
361
359
|
- **In-process embeddings** — Native [nomic-embed-text](https://huggingface.co/nomic-ai/nomic-embed-text-v1.5-GGUF) (768 dimensions) via [llama.cpp](https://github.com/ggerganov/llama.cpp). Runs on CPU or GPU (Metal, CUDA). No API calls, no OpenAI key needed.
|
|
362
360
|
- **Schema-driven** — GraphQL schemas with `@table @export` auto-generate REST CRUD. Custom resources extend behavior (durability guards, auto-embedding, search).
|
|
363
|
-
- **
|
|
361
|
+
- **Admin credentials** — `flair init` auto-generates an admin password stored at `~/.flair/admin-pass` (mode 0600). Can also be set via `HDB_ADMIN_PASSWORD`. See [SECURITY.md](SECURITY.md) for the full model.
|
|
364
362
|
|
|
365
363
|
## Deployment
|
|
366
364
|
|
|
@@ -392,9 +390,9 @@ FLAIR_URL=https://your-server:19926 flair agent add mybot
|
|
|
392
390
|
|
|
393
391
|
Good for teams with multiple machines or always-on agents.
|
|
394
392
|
|
|
395
|
-
### Harper Fabric
|
|
393
|
+
### Harper Fabric
|
|
396
394
|
|
|
397
|
-
|
|
395
|
+
Deploy Flair on [Harper Fabric](https://www.harperdb.io/) for managed hosting with multi-region replication and failover. Federation runs against Harper Fabric hubs (e.g. `flair.your-org.harperfabric.com`) — pair your local instance to sync memories across nodes.
|
|
398
396
|
|
|
399
397
|
## Security
|
|
400
398
|
|
|
@@ -403,7 +401,7 @@ See [SECURITY.md](SECURITY.md) for the full security model, threat analysis, and
|
|
|
403
401
|
**Key points:**
|
|
404
402
|
- Ed25519 cryptographic identity — agents sign every request
|
|
405
403
|
- Collection-level data isolation — agents can't read each other's memories
|
|
406
|
-
- Admin
|
|
404
|
+
- Admin password auto-generated on init, stored at `~/.flair/admin-pass` (mode 0600)
|
|
407
405
|
- Key rotation via `flair agent rotate-key`
|
|
408
406
|
- Cross-agent access requires explicit grants
|
|
409
407
|
|