[FEATURE] Papers Library BibTeX Importer#107
Merged
Merged
Conversation
- Marked the completion of the document upload job system in the tasks documentation. - Improved the `upload_document_job` function to include retry capabilities and enhanced error handling. - Updated the import execution logic to support bulk document uploads, including file handling and progress tracking. - Added detailed logging for document processing and error scenarios to facilitate debugging.
- Marked the completion of the document upload job system in the tasks documentation. - Improved the `upload_document_job` function to include retry capabilities and enhanced error handling. - Updated the import execution logic to support bulk document uploads, including file handling and progress tracking. - Added detailed logging for document processing and error scenarios to facilitate debugging.
- Removed redundant comments and improved code clarity in the BibTeX import function. - Introduced helper functions for parsing authors and years from BibTeX entries. - Streamlined the matching of PDF files to BibTeX entries and the construction of document payloads. - Enhanced error handling and user prompts during the bulk upload process. - Updated the import analysis logic to improve readability and maintainability.
- Removed redundant comments and improved code clarity in the BibTeX import function. - Introduced helper functions for parsing authors and years from BibTeX entries. - Streamlined the matching of PDF files to BibTeX entries and the construction of document payloads. - Enhanced error handling and user prompts during the bulk upload process. - Updated the import analysis logic to improve readability and maintainability.
- Updated the bulk upload endpoint to validate JSON metadata and check for existing workspaces before processing uploads. - Improved error handling for invalid metadata formats and missing documents. - Refactored the `process_bulk_upload` function to accept `BulkUploadMetadata` directly, streamlining the upload logic. - Enhanced the `upload_document_job` to handle document creation and error logging more effectively.
- Updated the bulk upload endpoint to validate JSON metadata and check for existing workspaces before processing uploads. - Improved error handling for invalid metadata formats and missing documents. - Refactored the `process_bulk_upload` function to accept `BulkUploadMetadata` directly, streamlining the upload logic. - Enhanced the `upload_document_job` to handle document creation and error logging more effectively.
- Renamed and updated schemas for document metadata, including `FileMetadataInfo` to `DocumentMetadata` and `BulkUploadMetadata` to `DocumentsBulkCreate`. - Adjusted the bulk upload endpoint to utilize the new schema and improved response handling with `DocumentsBulkResponse`. - Enhanced validation logic for document metadata during import analysis and bulk uploads. - Updated related tests to reflect schema changes and ensure proper validation of document uploads.
- Renamed and updated schemas for document metadata, including `FileMetadataInfo` to `DocumentMetadata` and `BulkUploadMetadata` to `DocumentsBulkCreate`. - Adjusted the bulk upload endpoint to utilize the new schema and improved response handling with `DocumentsBulkResponse`. - Enhanced validation logic for document metadata during import analysis and bulk uploads. - Updated related tests to reflect schema changes and ensure proper validation of document uploads.
- Updated the bulk upload endpoint to accept `documents_metadata` as a form field, improving clarity in the API. - Added JSON validation for `documents_metadata` to ensure proper format before processing. - Introduced a new `bulk_create` method in `DocumentPolicy` to manage authorization for bulk uploads based on workspace membership. - Refactored related functions to streamline the handling of document uploads and improve error handling.
- Updated the bulk upload endpoint to accept `documents_metadata` as a form field, improving clarity in the API. - Added JSON validation for `documents_metadata` to ensure proper format before processing. - Introduced a new `bulk_create` method in `DocumentPolicy` to manage authorization for bulk uploads based on workspace membership. - Refactored related functions to streamline the handling of document uploads and improve error handling.
… tracking - Created the ImportHistory model in the database with relationships to Workspace and User models. - Added fields for tracking import details such as bib_filename and import_summary. - Updated the factories to include ImportHistoryFactory for generating test data. - Marked the completion of the ImportHistory model in the tasks documentation.
… tracking - Created the ImportHistory model in the database with relationships to Workspace and User models. - Added fields for tracking import details such as bib_filename and import_summary. - Updated the factories to include ImportHistoryFactory for generating test data. - Marked the completion of the ImportHistory model in the tasks documentation.
- Modified the Alembic command in the documentation and `.env` files to streamline migration processes. - Added `HF_HUB_DISABLE_TELEMETRY=1` to both development and test environment configurations to disable telemetry. - Updated the `pyproject.toml` to include a new command for generating Alembic revisions with autogeneration.
- Modified the Alembic command in the documentation and `.env` files to streamline migration processes. - Added `HF_HUB_DISABLE_TELEMETRY=1` to both development and test environment configurations to disable telemetry. - Updated the `pyproject.toml` to include a new command for generating Alembic revisions with autogeneration.
…ments` table during the upgrade and downgrade processes.
…ments` table during the upgrade and downgrade processes.
- Renamed `ImportExecuteRequest` to `DocumentImportExecuteRequest` and updated its fields to include `workspace_id`. - Changed `ImportAction` to `DocumentImportAction` with enhanced action descriptions. - Modified the `ImportHistory` model to replace `bib_filename` and `document_info` with `filename` and `metadata`, respectively, for improved data tracking. - Updated related factories and tests to reflect changes in the import history structure and ensure accurate metadata handling. - Adjusted bulk upload logic to align with new request and response schemas.
- Renamed `ImportExecuteRequest` to `DocumentImportExecuteRequest` and updated its fields to include `workspace_id`. - Changed `ImportAction` to `DocumentImportAction` with enhanced action descriptions. - Modified the `ImportHistory` model to replace `bib_filename` and `document_info` with `filename` and `metadata`, respectively, for improved data tracking. - Updated related factories and tests to reflect changes in the import history structure and ensure accurate metadata handling. - Adjusted bulk upload logic to align with new request and response schemas.
87e6167 to
529ea22
Compare
…s and remove deprecated argilla-v1 workflow
… feat/bib-importer
…s and remove deprecated argilla-v1 workflow
…nability; update various styles for consistency across import-related components; enhance error handling in DocumentRepository; adjust document metadata handling in API schemas and contexts.
…ty; implement batch processing in GetJobStatusUseCase to optimize job status polling and reduce connection load.
…UseCase - update related methods and components for consistency in handling Hugging Face datasets - improve author separator logic in ImportFileUpload component.
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.
This pull request implements the Papers Library Importer feature as described in issue #102:
POST /imports/analyze) for parsing.biband matching PDFsPOST /documents/bulk) with async job queueCompletes analysis, preview, and execution phases. Please review and let me know any feedback.