Generate master-level research papers with real citations in minutes
Project description
OpenDraft Engine
The Python AI engine that powers thesis draft generation. Contains the 19-agent pipeline, citation research, and export functionality.
Structure
engine/
├── draft_generator.py # Main 19-stage pipeline orchestrator
├── config.py # Model settings, API keys, rate limits
├── utils/
│ ├── agent_runner.py # Agent execution engine
│ ├── api_citations/ # Citation APIs (CrossRef, Semantic Scholar)
│ ├── citation_*.py # Citation management & validation
│ ├── export_professional.py # PDF/DOCX export
│ ├── pdf_engines/ # Pandoc, WeasyPrint engines
│ └── deep_research.py # Research phase utilities
├── prompts/
│ ├── 00_WORKFLOW.md # Complete agent workflow
│ ├── 01_research/ # Deep Research, Scout, Scribe, Signal
│ ├── 02_structure/ # Architect, Citation Manager, Formatter
│ ├── 03_compose/ # Crafter, Thread, Narrator
│ ├── 04_validate/ # Skeptic, Verifier, Referee
│ ├── 05_refine/ # Citation Verifier, Voice, Entropy, Polish
│ └── 06_enhance/ # Abstract Generator, Enhancer
└── opendraft/ # CLI tools
Usage
Run Pipeline Directly
cd engine
python draft_generator.py --topic "Your research topic" --level master
Academic Levels
| Level | Words | Chapters | Time |
|---|---|---|---|
| research_paper | 3-5k | 3-4 | 5-10 min |
| bachelor | 10-15k | 5-7 | 8-15 min |
| master | 20-30k | 7-10 | 10-25 min |
| phd | 50-80k | 10-15 | 20-40 min |
Environment Variables
Required in ../.env.local:
GEMINI_API_KEY=your-key # Required
PROXY_LIST=... # Optional: for faster research
SCOUT_PARALLEL_WORKERS=32 # Optional: parallelism
Dependencies
Python packages
pip install -r requirements.txt
PDF Export (required for PDF generation)
macOS:
# LaTeX (for Pandoc PDF export)
brew install --cask mactex
sudo tlmgr install relsize setspace
# WeasyPrint system dependencies (alternative PDF engine)
brew install pango gdk-pixbuf libffi
Ubuntu/Debian:
# LaTeX
sudo apt install texlive-full
# WeasyPrint
sudo apt install libpango-1.0-0 libpangocairo-1.0-0 libgdk-pixbuf2.0-0
Verify Installation
opendraft setup # or: python -m opendraft.verify
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
opendraft-1.6.16.tar.gz
(449.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
opendraft-1.6.16-py3-none-any.whl
(465.5 kB
view details)
File details
Details for the file opendraft-1.6.16.tar.gz.
File metadata
- Download URL: opendraft-1.6.16.tar.gz
- Upload date:
- Size: 449.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.8.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c20600b27515fb5950f05b3672e562e79704fddbc04c3f2455ae88e4096aab00
|
|
| MD5 |
b15f7ec0dfa324439227036b3aad5ab2
|
|
| BLAKE2b-256 |
bf7187b0d1dbbe86c04fdbf7b51e9ea91310134eb5a3250f66c491bada3c1a31
|
File details
Details for the file opendraft-1.6.16-py3-none-any.whl.
File metadata
- Download URL: opendraft-1.6.16-py3-none-any.whl
- Upload date:
- Size: 465.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.8.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f636ed437b919dc7582d182ebd416efbc4281b28a4095524c41fbed8819ad9ad
|
|
| MD5 |
8226a6b93f6d0041386967617ef11ebc
|
|
| BLAKE2b-256 |
14978c6eb4870e8c6e9cf771eb26b3915c08880e6eec53a0eb381232a98d89e8
|