feat: topk adapter - #150
Open
petertoth wants to merge 5 commits into
Open
Conversation
petertoth
marked this pull request as ready for review
August 19, 2026 13:46
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds TopK as a community vector database adapter.
{database_name}__)create_data_pointsstores the LSN returned by each upsert inself._lsnsin a dict, keyed by a collection name to keep read-your-own-writes consistency.What's included:
TopKAdapterimplementingVectorDBInterface(search, batch search,belongs_to_setnode filtering with
AND/OR, batched upserts under the API size limits, prefix-gated prune)TopKDatasetDatabaseHandlerfor per-dataset isolationfrom cognee_community_vector_adapter_topk import registerexample.py,tests/test_topk.py,README.mdCI (TODO)
I haven't wired the test into CI (
test_topk.yml+vector_db_community_tests.yml)because the test runs against the live TopK API. The repo needs to add the
TOPK_API_KEYsecret.TopK account as well as test project + API key needs to be provisioned at console.topk.io.
DCO Affirmation
I affirm that all code in every commit of this pull request conforms to the terms of the Topoteretes Developer Certificate of Origin.