diff --git a/tools/indexer/requirements.txt b/tools/indexer/requirements.txt index 94a83b7d9..9faca9b40 100644 --- a/tools/indexer/requirements.txt +++ b/tools/indexer/requirements.txt @@ -1,4 +1,4 @@ # Add your dependencies here # Required for all unstract tools -unstract-sdk~=0.11.1 +unstract-sdk~=0.13.0 diff --git a/tools/indexer/src/config/properties.json b/tools/indexer/src/config/properties.json index b3ed95dc9..d2376b378 100644 --- a/tools/indexer/src/config/properties.json +++ b/tools/indexer/src/config/properties.json @@ -2,7 +2,7 @@ "schemaVersion": "0.0.1", "displayName": "Document Indexer", "functionName": "document_indexer", - "toolVersion": "0.0.1", + "toolVersion": "0.0.2", "description": "Used to index documents in the specified vector DB / embedding.", "input": { "description": "Document that needs to be indexed" diff --git a/tools/indexer/src/main.py b/tools/indexer/src/main.py index 05a7edfa1..eb8e81bf6 100644 --- a/tools/indexer/src/main.py +++ b/tools/indexer/src/main.py @@ -34,7 +34,7 @@ def run( tool_index = ToolIndex(tool=self) self.stream_log("Indexing document...") try: - tool_index.index_file( + index_key = tool_index.index_file( tool_id=self.workflow_id, embedding_type=settings[ToolSettingsKey.EMBEDDING_ADAPTER_ID], vector_db=settings[ToolSettingsKey.VECTOR_DB_ADAPTER_ID], @@ -47,15 +47,6 @@ def run( ) except Exception as e: self.stream_error_and_exit(f"Error fetching data and indexing: {e}") - index_key = ToolIndex.generate_file_id( - tool_id=self.workflow_id, - file_hash=file_hash, - vector_db=settings[ToolSettingsKey.VECTOR_DB_ADAPTER_ID], - embedding=settings[ToolSettingsKey.EMBEDDING_ADAPTER_ID], - x2text=settings[ToolSettingsKey.X2TEXT_ADAPTER_ID], - chunk_size=settings[SettingsKeys.CHUNK_SIZE], - chunk_overlap=settings[SettingsKeys.CHUNK_OVERLAP], - ) # Update GUI input_log = ( "### Indexing file\n" diff --git a/tools/structure/requirements.txt b/tools/structure/requirements.txt index 94a83b7d9..9faca9b40 100644 --- a/tools/structure/requirements.txt +++ b/tools/structure/requirements.txt @@ -1,4 +1,4 @@ # Add your dependencies here # Required for all unstract tools -unstract-sdk~=0.11.1 +unstract-sdk~=0.13.0 diff --git a/tools/structure/src/config/properties.json b/tools/structure/src/config/properties.json index 7ce7b0094..20ebd1e7c 100644 --- a/tools/structure/src/config/properties.json +++ b/tools/structure/src/config/properties.json @@ -2,7 +2,7 @@ "schemaVersion": "0.0.1", "displayName": "Structure Tool", "functionName": "structure_tool", - "toolVersion": "0.0.1", + "toolVersion": "0.0.2", "description": "This is a template tool which can answer set of input prompts designed in the Prompt Studio", "input": { "description": "File that needs to be indexed and parsed for answers" diff --git a/tools/text_extractor/requirements.txt b/tools/text_extractor/requirements.txt index 94a83b7d9..9faca9b40 100644 --- a/tools/text_extractor/requirements.txt +++ b/tools/text_extractor/requirements.txt @@ -1,4 +1,4 @@ # Add your dependencies here # Required for all unstract tools -unstract-sdk~=0.11.1 +unstract-sdk~=0.13.0 diff --git a/tools/text_extractor/src/config/properties.json b/tools/text_extractor/src/config/properties.json index c06041a30..fe9a32571 100644 --- a/tools/text_extractor/src/config/properties.json +++ b/tools/text_extractor/src/config/properties.json @@ -2,7 +2,7 @@ "schemaVersion": "0.0.1", "displayName": "Text Extractor", "functionName": "text_extractor", - "toolVersion": "0.0.2-v2", + "toolVersion": "0.0.2", "description": "The Text Extractor is a powerful tool designed to convert documents to its text form or Extract texts from documents", "input": { "description": "Document"