Skip to Content

Encrypted Memory

Opt-in, end-to-end, yours

By default, stacknet AI models run stateless: every request is independent, and nothing about you is remembered between sessions.

For users who want a model that knows them, their preferences, their projects, their history, stacknet ships with encrypted memory. It’s opt-in per request, end-to-end encrypted under a key that never leaves the user, and portable across the network.

The opt-in is explicit

Memory is never on by default. Enable it per request:

curl https://api.stacknet.org/v1/chat/completions \ -H 'X-StackNet-Memory: true' \ -H 'Authorization: Bearer gk_...' \ -d '{"messages":[{"role":"user","content":"what did we decide about auth?"}]}'

Or in the request body: {"memory": true, "messages": [...]}.

Without the flag, the node skips every memory lookup. No context is injected, no embeddings are fetched, no knowledge-graph queries run. The request behaves exactly like the public API’s minimal path.

What memory actually looks like (the country model)

Stacknet’s memory is organized like a map: a country of states, each containing cities, each carved into districts by memory type, with highways linking cities across state lines. This isn’t ornamental: scoped retrieval beats flat search by 34% on benchmarks.

Country → your entire memory ├── State: "work" / "personal" │ ├── City: "auth-migration" (a project) │ │ ├── District: facts │ │ ├── District: events │ │ ├── District: discoveries │ │ ├── District: preferences │ │ └── District: advice │ └── City: "ci-pipeline" └── Highways ────── cross-state routes between cities

Five standard district types, facts, events, discoveries, preferences, advice, are auto-assigned by pattern-matching during extraction. “I work at X” → facts. “I prefer Y” → preferences. “The fix was Z” → advice.

Last updated on