Search by meaning for every element of your node
Every element keeps its texts here as vectors and asks for the closest ones to a question, in any language. The meaning is counted on your own computer, with no key and no internet.
OpenSource Web4 agent & app starter kitHow a search goes
An element sends a text
It names a collection and the text and sends them through the database element, the door every element already uses.
Embeddings counts it
The node's own embeddings element turns the text into 384 numbers on this computer. Nothing leaves it.
The store keeps it
The vector goes into its collection. A text with the same id replaces the old one.
A question finds it
A question is counted the same way and meets the closest texts of its own collection, each with its score.
A search reads only its own collection and only the nearest rows, then counts the exact score for them.
On, asleep only when memory is short
The element starts with the node. With less than 0.5 GB of free memory the node may put it to sleep; the first call or a calendar entry wakes it in seconds, and above 1 GB free it comes back by itself.
What changes for you
| Without it | With the vector store |
|---|---|
| Search finds only the exact words you typed | It finds texts close in meaning, in any language |
| Counting meaning needs a paid key and the internet | The node counts it itself, on your computer, with no key |
| Every element would build its own search | Every element keeps its collections in one store |
| Your texts sit on someone else's server | They stay on your computer, inside your node |
Whose vectors they are
The main agent of the node
Searches every collection of every element and sees whose each finding is.
Mom's element
Her element's collections, searched only with her element's key.
Son's element
His collections, never seen by another element.
Your site
Its own collections by its own names.
Each element opens the store with its own key, and a search never crosses into another element's collection.
An element names its collections in its own words: its faq is kept apart from every other element's faq, and the answer gives back its own names. The deep memory keeps each element's phrases the same way.
A search without a collection reads only the element's own collections. The main agent, with the node's key, searches them all and sees whose each finding is.
The store keeps the doors apart, not the disk: every collection lies in this element's folder on your computer, and all elements run as one user of it.
Connect your element
Every element of the node already has the database address and its own key. Store a text and find it again:
const base = process.env.REMOTE_DATA_URL
const headers = { 'X-Element-Key': process.env.ELEMENT_KEY, 'Content-Type': 'application/json' }
await fetch(`${base}/vectors`, { method: 'POST', headers,
body: JSON.stringify({ collection: 'faq', text: 'Delivery takes two days.', refTable: 'faq', refId: '17' }) })
const r = await fetch(`${base}/vectors/search`, { method: 'POST', headers,
body: JSON.stringify({ collection: 'faq', query: 'How long is shipping?', k: 3 }) })
const { results } = await r.json() // [{ id, collection, refTable, refId, text, score }]The answer lists the closest texts with their score. The same id replaces a text, and DELETE /vectors/:id removes it.
Under the hood
Part
What it does
- The index
- An sqlite-vec vec0 table split by collection: a search reads the nearest rows of its own collection and counts the exact cosine score for them
- The meaning
- The node's embeddings element: paraphrase-multilingual-MiniLM-L12-v2, 384 numbers, on this computer
- A new model
- The store counted by the old model is set aside whole beside the new one, never read again and never deleted
- The lock
- Each element's own key opens its own collections; the node's data key or a privileged session opens all; through the Cloudflare tunnel every door answers 404
- /vectors/status
- Whether the store is ready, its model and size, the index mode and how many vectors it holds
Your own builder comes with it
Every element of the node comes with its own Claude Code agent and can get its own Telegram bot. When something in this element should change, write to its bot from your phone, and the agent updates the logic or the design.
The agent works only in its element's folder and never reads the whole node, so each change costs fewer tokens. Your Claude Code subscription pays for it.
- The element's bot is connected in the core, on its «Telegram» page.
- The agent returns a commit; you look at it in «Preview» and accept it or turn it down.
- At the computer, the agent's terminal is in the core, in this element's «Build».
Open source
Built by Fractera for the Lagrix protocol and for any web2 project that needs search by meaning. MIT license, the code is at github.com/Fractera/fractera-vectors-starter.
Questions and answers
- Do I need an OpenAI key for search by meaning?
- No. The node's own element embeddings counts the meaning on this computer, with no key and no internet.
- Does search work across languages?
- Yes. A question finds texts close in meaning whatever language either of them is in.
- How do I replace a text?
- Send it again with the same id; DELETE /vectors/:id removes it.
- Can I keep backups?
- Yes. The element is ready for its programmer agent to set up backups on a schedule or by hand: tell the element's agent in Telegram or in the terminal. It makes no copies on its own until you ask.