CORTEX

Sovereign memory engine — decay-aware agent memory on Arkiv, compressed, cited to survive, encrypted with your wallet.

Darwinian memory
for AI agentsOwned by your wallet.

Observations are RaBitQ-compressed and sealed before they reach Braga. When an agent cites a memory in a decision, Cortex extends its expiration. What never gets cited decays — no manual cleanup.

[ 01 ]What you get

Memories that behave like human memory — forget like humans do.

recall(query, k)act(action, citations[])Wallet-derived encryption
[ 02 ]Memory lifecycle
01 / 04
Working1-hour lease
Extends on citation
Working

New observations start here: RaBitQ-compressed, sealed, written to Arkiv. Uncited memories expire within about an hour.

01 · 1-hour lease
Episodic
02 · +7 days
Semantic
03 · 1-year rule
Cold archive
04 · local mirror
[ 03 ]Install

1 · Add it to Claude Code (once)

Cortex ships as a Claude Code plugin. Two commands, then it auto-loads in every session — no flags, no manual steps.

# in Claude Code:
/plugin marketplace add LingSiewWin/Cortex
/plugin install cortex-memory

Requires bun. At session start it recalls your project's memory; as you work it captures to Arkiv before context compacts.

2 · Point it at your wallet

Memories are sealed with a key derived from your wallet and written to Arkiv — owned by you, not us.

SESSION_KEY_PRIVATE_KEY=0x…   # signs Arkiv writes (pays GLM gas)
CORTEX_USER_SIGNATURE=0x…     # derives your encryption key
OPENROUTER_API_KEY=…          # embeddings (or COHERE_API_KEY)

Need test GLM? Braga faucet. Prefer to watch first?

[ 04 ]On Braga testnet
Cost per memory
Ultra-low
GLM gas on Braga testnet · priced as bytes × expiration, not flat storage rent
Your memory
Privacy
Wallet-owned on Arkiv — connect in the console to see your graph, tiers, and recall
Compression
RaBitQ · 1536-d embeddings
[ 05 ]How it fits Arkiv

Arkiv stores bytes × lifetime. Agent embeddings are naturally large (~6 KB each at full float width). Cortex stores a RaBitQ-compressed fingerprint (~200 B) plus attributes, and only pays to extend entities the agent cites — accumulative extend, not a naive “add 24 hours”.

Payloads are encrypted client-side; Braga holds ciphertext. Your local SQLite mirror catches every event so you can rebuild if a host goes away — see bun scripts/sovereignty-proof.ts.

[ 06 ]Trust assumptions
  • Session-key relayer. The autonomous loop signs with a backend session key, bounded by EIP-712 SessionAuthorization. Your wallet remains $owner.
  • Browser uploads are yours. File store and key adoption use your wallet on Braga; we never hold your derivation secret.
  • Semantic tier capped at one year. Until Arkiv's fee model is final, we do not promise multi-year leases.
  • No “fully decentralised” marketing. Braga is a testnet with operated infrastructure. We describe what ships today.