A new evolution of Vector Database, add to your toolkit

grecinto2 pts0 comments

GitHub - grecinto/tensortree: ensorTree is a Zero-Ops vector database built on an SOP transactional B-tree. By embedding categories and items as tensors, it hits \(O(\log n)\) search speeds with zero index optimization. It uses relativity-inspired domain centroids to warp semantic space, removing the pigeonhole edge-case error and completely preventing LLM hallucinations. · GitHub

/" data-turbo-transient="true" />

Skip to content

Search or jump to...

Search code, repositories, users, issues, pull requests...

-->

Search

Clear

Search syntax tips

Provide feedback

--><br>We read every piece of feedback, and take your input very seriously.

Include my email address so I can be contacted

Cancel

Submit feedback

Saved searches

Use saved searches to filter your results more quickly

-->

Name

Query

To see all available qualifiers, see our documentation.

Cancel

Create saved search

Sign in

/;ref_cta:Sign up;ref_loc:header logged out"}"<br>Sign up

Appearance settings

Resetting focus

You signed in with another tab or window. Reload to refresh your session.<br>You signed out in another tab or window. Reload to refresh your session.<br>You switched accounts on another tab or window. Reload to refresh your session.

Dismiss alert

{{ message }}

grecinto

tensortree

Public

Notifications<br>You must be signed in to change notification settings

Fork

Star

main

BranchesTags

Go to file

CodeOpen more actions menu

Folders and files<br>NameNameLast commit message<br>Last commit date<br>Latest commit

History<br>4 Commits<br>4 Commits

docs

docs

src/examples/cli_kb_demo

src/examples/cli_kb_demo

LICENSE

LICENSE

README.md

README.md

go.mod

go.mod

go.sum

go.sum

View all files

Repository files navigation

TensorTree

TensorTree is a developer-friendly approach to semantic memory built on top of SOP’s KnowledgeBase architecture.

Repository layout

docs/architecture.md — high-level architecture notes

src/examples/cli_kb_demo/ — the single runnable KnowledgeBase example

src/ — source snapshot from the SOP memory subsystem

Example

The repository currently includes one runnable example:

src/examples/cli_kb_demo/main.go — creates a small category hierarchy, inserts content, refreshes semantic vectors, and then queries a simpler, semantically related path such as Root/Knowledge to demonstrate the breakthrough semantic category-path matching feature.

Run it with:

go run ./src/examples/cli_kb_demo

The example writes its demo data under ./data/demo-cli-kb and can be reset by removing that directory.

TensorTree In-Depth

Instead of treating memory as a flat pile of vectors, TensorTree lets you organize knowledge into meaningful categories, nest those categories into a hierarchy, and retrieve content through either path-based navigation or semantic similarity.

The breakthrough feature in this example is semantic category-path matching: a simpler path like Root/Knowledge can still resolve to a more concrete category such as Root/Engineering because the system compares the meaning of the path components rather than requiring an exact lookup.

A key part of making semantic search work is vectorization. TensorTree uses the Vectorize API to turn content into embeddings on demand, so the system can compare meaning without requiring a heavy reindexing workflow. In practice, this means a simple vectorization step can be applied to new content, and the resulting vectors are used immediately for semantic retrieval.

A key idea behind TensorTree is that categories are not just labels for retrieval—they are inherently visualizable. In SOP, KnowledgeBases can be surfaced through the SOP Data Manager, where Spaces add a visual layer that makes the category graph and its relationships easier to explore, understand, and reason about.

This makes it a strong fit for:

RAG systems

copilots and agents

documentation search

internal knowledge tools

domain-specific AI assistants

Why TensorTree?

Most vector databases are great at similarity search, but they can feel too low-level for application developers. TensorTree adds structure to the experience:

categories act as semantic anchors,

items live under those categories,

nested paths make the knowledge base readable and explainable,

retrieval can be guided by both taxonomy and meaning.

The result is a semantic memory layer that is easier to reason about and easier to build with.

Getting started

TensorTree can be used from Go with a simple KnowledgeBase flow:

create a KnowledgeBase,

define categories,

upsert items into those categories,

list or search them.

kb, err := database.NewKnowledgeBase(ctx, "demo-kb", sop.DatabaseOptions{<br>Type: sop.Standalone,<br>StoresFolders: []string{"./data/demo-kb"},<br>}, nil, nil, false)

From there, you can create a category tree, add content, and retrieve relevant items with a small, high-level API.

Key idea

TensorTree is not just a vector store. It is a practical semantic memory layer that helps AI applications remember and retrieve information...

tensortree semantic search categories content category

Related Articles