From db19770c867b41ec1f70c7e7961e182f367ae3b9 Mon Sep 17 00:00:00 2001 From: ch-liuzhide Date: Mon, 25 Aug 2025 14:35:20 +0800 Subject: [PATCH] feat: add tenant_id parameter to tag and tagging methods chore: bump version to 0.3.1 --- pyproject.toml | 2 +- .../interface/db_engine_plugin_interface.py | 20 +++++++++++++------ 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 470c2c7..b9a250b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "whiskerrag" -version = "0.3.0" +version = "0.3.1" description = "A utlity package for RAG operations" authors = ["petercat.ai "] readme = "README.md" diff --git a/src/whiskerrag_types/interface/db_engine_plugin_interface.py b/src/whiskerrag_types/interface/db_engine_plugin_interface.py index 5819851..313c98e 100644 --- a/src/whiskerrag_types/interface/db_engine_plugin_interface.py +++ b/src/whiskerrag_types/interface/db_engine_plugin_interface.py @@ -303,7 +303,9 @@ async def agent_invoke(self, params: Any) -> AsyncIterator[Any]: # =================== tag =================== @abstractmethod - async def add_tag_list(self, tag_list: List[TagCreate]) -> List[Tag]: + async def add_tag_list( + self, tenant_id: str, tag_list: List[TagCreate] + ) -> List[Tag]: pass @abstractmethod @@ -313,21 +315,27 @@ async def get_tag_list( pass @abstractmethod - async def delete_tag_by_id(self, tenant_id: str, tag_id: str) -> Union[Tag, None]: + async def get_tag_by_id(self, tenant_id: str, tag_id: str) -> Union[Tag, None]: pass @abstractmethod - async def update_tag(self, tag: Tag) -> None: + async def delete_tag_by_id(self, tenant_id: str, tag_id: str) -> Union[Tag, None]: pass @abstractmethod - async def get_tag_by_id(self, tenant_id: str, tag_id: str) -> Union[Tag, None]: + async def update_tag_name_description( + self, + tenant_id: str, + tag_id: str, + name: Optional[str], + description: Optional[str], + ) -> Tag: pass # =================== tagging =================== @abstractmethod async def add_tagging_list( - self, tagging_list: List[TaggingCreate] + self, tenant_id: str, tagging_list: List[TaggingCreate] ) -> List[Tagging]: pass @@ -340,7 +348,7 @@ async def get_tagging_list( @abstractmethod async def delete_tagging_by_id( self, tenant_id: str, tagging_id: str - ) -> Union[Tag, None]: + ) -> Union[Tagging, None]: pass # =================== dashboard ===================