radicalxdev / kai-ai-backend

This is the Kai Teaching Assistant ai repo.
MIT License
12 stars 46 forks source link

Epic 7.1 Added Various Loaders for Quizzify (AI Avengers) #57

Open Abhinav-Telukunta opened 1 week ago

Abhinav-Telukunta commented 1 week ago

Pull Request - File Loaders Extension for Quizzify

Summary

Added loaders for the following file types:

  1. CSV
  2. DOCX
  3. PPTX
  4. Youtube
  5. WebPage
  6. TXT
  7. PDF

Added filtering as well. For example for csv, user can mention startRow and endRow and specific columns and based on that content, quiz questions would be generated.

Changes

Testing

Each loader was tested using Adhoc Testing.

Results

All six loaders are working perfectly fine with and without filtering criteria.

Notes

Screenshots

YouTube Sample Request and Response

sample_request_youtube sample_response_youtube

Webpage Sample Request and Response

sample_request_webpage sample_response_webpage

TXT Sample Request and Response

sample_request_txt sample_response_txt

DOCX Sample Request and Response

sample_request_docx sample_response_docx

PPTX Sample Request and Response

sample_request_pptx sample_response_pptx

CSV Sample Request and Response

sample_request_csv sample_response_csv

PDF Sample Request and Response

sample_request_pdf sample_response_pdf

How to Test

  1. Clone the repo in your local

  2. Create and activate virtual environment

  3. Use pip install -r requirements.txt to install required libraries.

  4. Create .env file with ENV_TYPE, GCP_PROJECT_ID and GOOGLE_API_KEY fields. Env type is dev, gcp_project_id is your project id from cloud console project, google_api_key is your api key from AI studio.

  5. Then type ./local-start.sh to start the application.

  6. Add sample requests and responses for each file type as mentioned above in screenshots and test it.