SmarText PDF is an intelligent PDF proofreading tool powered by GPT-4o. It extracts and analyzes text from PDF documents, detects grammatical and stylistic issues, and provides high-quality suggestions for improvement.
- 🔍 Extracts text from PDF documents
- 🤖 Uses GPT-4o for grammar, spelling, and tone correction
- 💡 Smart suggestions for improved phrasing and wording
- 📄 Paragraph-by-paragraph correction with side-by-side comparison
- 📤 Export options for cleaned text or revision summaries
- 🗂 Upload, compare, and manage your PDF files
- 🗣 Text-to-speech for revised content
- Python 3.8+
- Microsoft Word (for PDF to Word conversion)
- Windows OS (required for Word automation)
- OpenAI API Key (set as
API_KEYin your.envfile) - The following Python packages (see
requirements.txt):fastapiuvicornpython-docxdocx2pdfpywin32openaipython-dotenvasyncio
-
Clone the repository
cd C:/xampp/htdocs git clone https://github.com/marksxiety/thesis-smarText-PDF.git -
Install Python dependencies
pip install -r requirements.txt
-
Set your OpenAI API key Create a
.envfile in your project directory with:API_KEY=sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx -
Start the API server
python grammar_checker.py
The server will run at http://localhost:5000.
-
Set up the database
- Open phpMyAdmin.
- Create a new schema/database.
- Import the
database.sqlfile provided in the project.
-
Start XAMPP and run Apache & MySQL
-
Access the web app
- Visit http://localhost/SmarTextPDF_NewUI in your browser.
- Upload PDFs: Go to the Upload page to add new PDF files for proofreading.
- Compare PDFs: Use the Compare page to review original and revised text side-by-side, accept suggestions, and export results.
- Dashboard: View your recent uploads and proofreading statistics.
- Ensure Microsoft Word is installed and properly licensed on your system.
- The API server (
grammar_checker.py) must be running for proofreading features to work. - If you encounter issues with file uploads, check folder permissions for
/uploadsand/processed_pdfs. - For OpenAI API errors, verify your API key in the
.envfile.
This project is for educational and research purposes only.
- OpenAI for GPT-4o
- pdf-lib for PDF manipulation
- FastAPI for the backend API
- XAMPP for local PHP/MySQL development
Enjoy using SmarText PDF!