This script is an automated AI-driven report-generating tool designed to help complete assignments in minutes. With its local or cloud-based AI integration, users can produce detailed reports effortlessly.
To use this tool, ensure you have the following:
- Python 3 installed on your system.
- A basic understanding of Python programming.
If you're looking to use a local LLM (Large Language Model), this section is for you. I have a locally installed LLM, but if you don't, you'll need to modify the AI interaction method to suit your provider.
- File to update:
./utils/ai.py
- Method: Replace the
prompt
method with your AI provider's API call.
If you decide to run the LLM locally, be aware that it may consume significant system resources, so proceed with caution.
Follow these steps to set up a local LLM:
- Install Ollama: Download and install Ollama from here.
- Choose an LLM Model: Select a model from the Ollama library. I am using the Llama 3.1 model, which is relatively lightweight.
- Install the Ollama Python package: This is required to interact with the local LLM model.
- Update the Model: If you use a different LLM model, update the reference at
./utils/ai.py:3
with your chosen model.
To set up the project and make the script executable:
-
Make the setup file executable by running:
chmod +x setup.sh
-
Execute the setup script:
./setup.sh
This will configure the environment and install any necessary dependencies.
If you're using a Unix-based system and want to convert .docx
files to .pdf
, you need to run a Gotenberg instance locally via Docker. Here are the steps to do so:
- Ensure Docker is installed on your system.
- Run the following command to start the Gotenberg container:
docker run --rm -p 3000:3000 gotenberg/gotenberg:8
- The script will send a request to the local Gotenberg instance for converting
.docx
to.pdf
.
Converting to PDF may not work on macOS if there's no active Office instance running. Ensure you have the necessary dependencies installed or consider using the Gotenberg approach if you're on a Unix-like system.