Skip to main content

qortex

Knowledge that learns

PyPI Python CI License: MIT

Your AI assistant forgets everything between conversations. qortex adds a knowledge graph that learns from every interaction. One command to install. Zero config.

Install

Claude Code

claude mcp add qortex -- uvx qortex mcp-serve

Cursor / Windsurf

uvx qortex mcp-serve  # add as stdio MCP server in settings

Any MCP client

pip install qortex[all] && qortex mcp-serve

What happens next

Once installed, your assistant automatically:

  1. Searches the knowledge graph before answering architecture questions
  2. Retrieves relevant concepts, relationships, and rules (not just similar text)
  3. Learns from your feedback: accepted results get boosted, rejected ones get suppressed
  4. Persists everything to SQLite so knowledge survives restarts

No config files. No API keys for the knowledge layer. Just start asking questions.

The difference

Vanilla RAG qortex
Retrieval Cosine similarity (what's textually similar) Graph-enhanced (what's structurally relevant)
Context Flat chunks Concepts + typed edges + rules
Learning Static Adapts from every accept/reject signal
Cross-references None Traverses REQUIRES, REFINES, USES edges

Prove it

Call qortex_compare to see the difference on your own data:

{
  "summary": "Graph-enhanced retrieval found 2 item(s) that cosine missed, surfaced 1 rule(s), replaced 1 distractor(s).",
  "diff": {
    "graph_found_that_cosine_missed": [
      {"rank": 3, "id": "security:JWTValidation", "score": 0.72}
    ],
    "cosine_found_that_graph_dropped": [
      {"rank": 4, "id": "security:PasswordHashing", "score": 0.68}
    ],
    "rank_changes": [
      {"id": "security:AuthMiddleware", "vec_rank": 3, "graph_rank": 1, "delta": 2}
    ]
  }
}

Graph retrieval promotes structurally connected concepts (AuthMiddleware depends on JWTValidation) and demotes textually similar but unrelated results.

How it works

  • Auto-ingest: Feed it docs, specs, or code. LLM extraction builds concepts, typed edges, and rules automatically.
  • Graph retrieval: Queries combine vector similarity with structural graph traversal. Related concepts get promoted even if they don't share keywords.
  • Adaptive learning: Every qortex_feedback call updates retrieval weights. The system gets smarter the more you use it.
  • Persistent by default: SQLite stores the knowledge graph, vector index, and learning state across restarts.

For framework authors

agno KnowledgeProtocol

from qortex.adapters.agno import QortexKnowledgeSource

knowledge = QortexKnowledgeSource(domains=["security"])
agent = Agent(knowledge=knowledge)

LangChain VectorStore

from langchain_qortex import QortexVectorStore

vs = QortexVectorStore.from_texts(texts, embedding, domain="security")
retriever = vs.as_retriever()

See langchain-qortex for the standalone package.

Mastra MastraVector

import { QortexVector } from "@peleke.s/mastra-qortex";

const qortex = new QortexVector({ id: "qortex" });
await qortex.createIndex({ indexName: "docs", dimension: 384 });
const results = await qortex.query({ indexName: "docs", queryVector: q, topK: 10 });

See @peleke.s/mastra-qortex for the standalone package.

Framework Package Language Interface
agno Built-in adapter Python KnowledgeProtocol
LangChain langchain-qortex Python VectorStore ABC
Mastra @peleke.s/mastra-qortex TypeScript MastraVector abstract class
Any MCP client Built-in MCP server Any MCP tools (JSON-RPC)

Install extras

Capability Install What you get
Core + MCP tools pip install qortex Knowledge graph, MCP server, vector-level tools. Consumers provide embeddings.
Text-level search pip install qortex[vec] qortex embeds text with sentence-transformers. Adds ~2GB for PyTorch + model weights.
Persistent vectors pip install qortex[vec-sqlite] SQLite-backed vector index. Without this, vectors are in-memory only.
Production graph pip install qortex[memgraph] Memgraph backend for production-scale graph operations.
Everything pip install qortex[all] All of the above.

License

MIT

Metadata

Release files for qortex 0.8.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for qortex 0.8.1
File Size Uploaded
qortex-0.8.1.tar.gz 9.3 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for qortex 0.8.1
File Interpreter ABI Platform
qortex-0.8.1-py3-none-any.whl Python 3 none any Details

Total release size: 9.6 MB

Release files / qortex-0.8.1.tar.gz

Download URL qortex-0.8.1.tar.gz
Size 9.3 MB
Tags Source
SHA-256 checksum
How to use checksums
1f14aaa5002aa3d7ea1cf9aec49b7e4765fa1c10aba1ee18146cac64e0f20825
BLAKE2b-256 checksum
How to use checksums
fc6fb9ef4b281d1f4cd014d66bd177b92ede1ceca3afed1b63b4def1a6b5f9fc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Feb 24, 2026.

Transparency log

Release files / qortex-0.8.1-py3-none-any.whl

Download URL qortex-0.8.1-py3-none-any.whl
Size 231.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
18582f2afad75e7082f03bc1442fce20130534f4054bc2c03b525879c93be2fb
BLAKE2b-256 checksum
How to use checksums
4f44339859e457cf95102dd1fd94356ab3fdd88f2e87d560f4d6c875e73b9c67
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Feb 24, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.8.1 This release

2 release files

0.7.8

2 release files

0.7.7

2 release files

0.7.6

2 release files

0.7.5

2 release files

0.7.4

2 release files

0.7.3

2 release files

0.7.2

2 release files

0.7.1

2 release files

0.7.0

2 release files

0.5.2

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.0

2 release files

0.3.8

2 release files

0.3.7

2 release files

0.3.6

2 release files

0.3.5

2 release files

0.3.4

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page