wizit-context-ingestor 0.3.0b4__tar.gz → 0.3.0b5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of wizit-context-ingestor might be problematic. Click here for more details.
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/PKG-INFO +1 -1
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/pyproject.toml +1 -1
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/application/transcription_service.py +6 -3
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/README.md +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/.DS_Store +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/__init__.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/application/__init__.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/application/context_chunk_service.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/application/interfaces.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/data/__init__.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/data/kdb.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/data/prompts.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/data/storage.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/domain/__init__.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/domain/models.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/domain/services.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/__init__.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/aws_model.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/persistence/__init__.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/persistence/local_storage.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/persistence/s3_storage.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/rag/chroma_embeddings.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/rag/pg_embeddings.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/rag/redis_embeddings.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/rag/semantic_chunks.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/secrets/__init__.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/secrets/aws_secrets_manager.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/infra/vertex_model.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/main.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/services/.DS_Store +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/services/__init__.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/services/chunks.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/services/parse_doc.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/services/pg_embeddings_manager.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/utils/file_utils.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/workflows/context_nodes.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/workflows/context_state.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/workflows/context_tools.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/workflows/context_workflow.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/workflows/transcription_nodes.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/workflows/transcription_schemas.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/workflows/transcription_state.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/workflows/transcription_tools.py +0 -0
- {wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/workflows/transcription_workflow.py +0 -0
|
@@ -112,7 +112,7 @@ class TranscriptionService:
|
|
|
112
112
|
# raise
|
|
113
113
|
|
|
114
114
|
async def parse_doc_page_with_workflow(
|
|
115
|
-
self, document: ParsedDocPage
|
|
115
|
+
self, document: ParsedDocPage, retries: int = 0
|
|
116
116
|
) -> ParsedDocPage:
|
|
117
117
|
"""Transcribe an image to text using an agent.
|
|
118
118
|
Args:
|
|
@@ -120,6 +120,9 @@ class TranscriptionService:
|
|
|
120
120
|
Returns:
|
|
121
121
|
Processed text
|
|
122
122
|
"""
|
|
123
|
+
if retries > 1:
|
|
124
|
+
logger.info("Max retries exceeded")
|
|
125
|
+
return document
|
|
123
126
|
result = await self.compiled_transcription_workflow.ainvoke(
|
|
124
127
|
{
|
|
125
128
|
"messages": [
|
|
@@ -150,10 +153,10 @@ class TranscriptionService:
|
|
|
150
153
|
}
|
|
151
154
|
},
|
|
152
155
|
)
|
|
153
|
-
if
|
|
156
|
+
if "transcription" in result:
|
|
154
157
|
document.page_text = result["transcription"]
|
|
155
158
|
else:
|
|
156
|
-
|
|
159
|
+
await self.parse_doc_page_with_workflow(document, retries=retries + 1)
|
|
157
160
|
return document
|
|
158
161
|
|
|
159
162
|
# def process_document(self, file_key: str) -> Tuple[List[ParsedDocPage], ParsedDoc]:
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{wizit_context_ingestor-0.3.0b4 → wizit_context_ingestor-0.3.0b5}/src/wizit_context_ingestor/main.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|