Skip to content
This repository was archived by the owner on Feb 8, 2026. It is now read-only.

designgrade/latex-gen

Repository files navigation

DISCLAIMER

This software is provided to you "as is", use at your own risk and without warranties of any kind. It is your responsibility to read and understand how latex-gen works and the implications of running this software. The usage of latex-gen involves various risks, including, but not limited to: API costs associated with OpenAI usage, potential generation of inaccurate content, and reliance on third-party AI models. No developers or entity involved will be liable for any claims and damages associated with your use, inability to use, or your interaction with other nodes or the software.

Works Anywhere

# Clone or copy the project to any machine
cd latex-gen
pip install -e .   # Install dependencies
./latex-gen "Create a report"   # Run

Interactive Mode

latex-gen

CLI Mode

# Generate a document
latex-gen "Create a technical report about machine learning"

# Generate and compile PDF
latex-gen "Create a report" --pdf

# Specify output file
latex-gen "Create a report" -o my_report

Programmatic Usage

from latex_gen import generate_with_ollama, extract_latex_and_save

result = generate_with_ollama("Create a document about AI")
filename, latex_code = extract_latex_and_save(result)
print(f"Saved: {filename}")

Configuration

Create a .env file:

# Use Ollama (true) or OpenAI (false)
USE_OLLAMA=true
OLLAMA_MODEL=llama3.2

# OpenAI configuration (when USE_OLLAMA=false)
OPENAI_API_KEY=sk-your-key-here

License

MIT License - see LICENSE file

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors