This pull request introduces enhancements and modifications to the existing codebase to support a wider range of document types, including PDF, text, and CSV files.
Changes Made
Added functions (process_pdf, process_text, and process_csv) to handle various document types (PDF, text, and CSV) and extract text content from them.
Modified the main function to utilize the uploaded_file variable for file uploading and type checking.
Removed the "Process" button and spinner logic, leading to a cleaner and more intuitive user interface.
Updated the page title and header to better reflect the application's capabilities ("Ask your Document" instead of "Ask your PDF").
How to Test
Run the application.
Use the sidebar to upload different types of documents (PDF, text, and CSV).
The application will automatically process the uploaded document, split it into chunks, and create embeddings.
Enter a question related to the document's content.
The application will display relevant information based on the provided question.
This pull request aims to enhance usability and support multiple document formats, making the application more versatile and user-friendly.
Description
This pull request introduces enhancements and modifications to the existing codebase to support a wider range of document types, including PDF, text, and CSV files.
Changes Made
process_pdf
,process_text
, andprocess_csv
) to handle various document types (PDF, text, and CSV) and extract text content from them.main
function to utilize theuploaded_file
variable for file uploading and type checking.How to Test
This pull request aims to enhance usability and support multiple document formats, making the application more versatile and user-friendly.