Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

AI-Powered Thesis and Document Summarizer

A comprehensive full-stack application designed to extract text from documents, generate AI-powered summaries in various formats, manage an approval workflow, prioritize revisions, and generate text-to-speech audio.

Architecture & Tech Stack

  • Backend: FastAPI (Python), SQLAlchemy, and PostgreSQL. Handles document parsing (.pdf, .docx, .txt), summarization logic, audio generation (OpenAI TTS API), and API provisioning.
  • Frontend: React 19, TypeScript, and Vite. Provides an interactive dashboard with modular components (e.g. AudioList, DocumentList, SummaryList) and modal-driven UI for handling the document flows.
  • Database: PostgreSQL (Dockerized). Tracks document files, summaries with varying statuses (pending, approved, rejected), and audio references.
  • Semantic search: On upload, extracted text is chunked and embedded with Ollama (embeddinggemma); GET /search?q=... ranks documents by cosine similarity and the dashboard search bar links results to their summaries. See project-docs/backend.md.
  • Testing: Playwright for end-to-end (E2E) testing (tests-e2e), Pytest for backend tests (backend/tests).

Project links

  • Implement features:
    • Summary comparison view #39
    • Access relevant summaries by clicking on the original document #30
    • Various UI refinements #58
  • Implement features:
    • Add audio generation and playback functionality using OpenAI TTS API #35
    • Implement audio management UI with player and controls #34
    • Implement audio summary download option #45
  • Implement features:
    • Implemented comprehensive summary approval workflow with status-based action buttons (Approve, Reject, Regenerate, Download, Edit, Delete) #25 #26 #27
    • Added multi-format summary generation with three format options: short_text, bullet_points, and academic_tone #23 #40
    • Enhanced UI/UX with improved table styling (alternating row colors, color-coded status indicators), delete functionality for documents, and format selection during upload #29
    • Updated database schema to track approval status with three states: pending, approved, rejected #31
    • Replaced full page reloads with callback-based data refresh mechanism for better user experience
  • Implement core features for Iteration 2:
    • Documents, Summaries, Audio sections available in dashboard #29
    • Document upload functionality #16 #17 #32
    • Document auto-extraction #18
    • Document table view with a search bar and sorting options #20
    • Summarization engine #22
    • Summary editing capability #26

Installation

Backend

  1. cd backend
  2. python -m venv .venv
  3. source .venv/Scripts/activate
  4. pip install -r requirements.txt on first-time use
  5. Install Docker desktop and have it running, then run the following command. NB! replace user and password with your own postgres credentials.
    docker run -d --name postgres16 -e POSTGRES_DB=summarizer -e POSTGRES_USER=postgres -e POSTGRES_PASSWORD=password -p 5432:5432 postgres:16
  6. Set DATABASE_URL (required, no default), e.g. in backend/.env: DATABASE_URL=postgresql://postgres:password@localhost:5432/summarizer
  7. alembic upgrade head to create/upgrade the schema (run again after pulling new migrations)
  8. uvicorn app.main:app --reload pip install pydantic-settings, if any errors → runs at http://localhost:8000 / http://127.0.0.1:8000 Swagger UI is available at http://localhost:8000/docs

Backend tests (need a reachable Postgres; the test database is dropped/recreated): pip install -r requirements-dev.txt && TEST_DATABASE_URL=postgresql://postgres:password@localhost:5432/summarizer_test pytest

Frontend

  1. cd frontend
  2. npm install on first-time use
  3. npm run dev → runs at http://localhost:5173 / http://127.0.0.1:5173

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages