codekingpro/portable-devtools
114k
1from abc import abstractmethod
2
3from chromadb.api.types import GetResult, QueryResult
4from chromadb.config import Component
5from chromadb.execution.expression.plan import CountPlan, GetPlan, KNNPlan
6
7
8class Executor(Component):
9 @abstractmethod
10 def count(self, plan: CountPlan) -> int:
11 pass
12
13 @abstractmethod
14 def get(self, plan: GetPlan) -> GetResult:
15 pass
16
17 @abstractmethod
18 def knn(self, plan: KNNPlan) -> QueryResult:
19 pass
20 