Getting Started with OpenLingu

Requires Python 3.12.0 or older

OpenLingu uses an older version of the Google Translate API wrapper that implements a synchronous language translation approach for lections. This older version is not compatible with Python 3.13 and newer.

The translation functionality is a core feature that allows live translation of learning materials to your native language, and maintaining compatibility with the older version ensures reliable and consistent translation behavior.

Quick Start

Get up and running with OpenLingu in just a few simple steps:

1. Clone the Repository

git clone https://github.com/MariusAngermann08/OpenLingu.git
cd OpenLingu

2. Set Up Virtual Environment (Optional but Recommended)

We recommend using a virtual environment to manage dependencies. Choose your operating system:

# Create a virtual environment
python -m venv venv

# Activate the virtual environment
.\venv\Scripts\activate
# Create a virtual environment
python3 -m venv venv

# Activate the virtual environment
source venv/bin/activate

On some Linux distributions, you might need to install the Python virtual environment package first: sudo apt-get install python3-venv (Debian/Ubuntu) or sudo dnf install python3-venv (Fedora)

3. Install Dependencies

Run the installation script to set up all required dependencies:

python install.py

4. Run the Application

Start the OpenLingu application:

python run.py

Or use the web interface:

python run.py --web

If you encounter database connection errors when running the application, you may need to reset and reinitialize the database. Follow these steps:

Warning: This will delete all existing data in the database. Only proceed if you don't need the current data or are experiencing issues.

First, navigate to the server directory:

cd server

Then, reset the database:

python reset_databases.py

Finally, reinitialize the database:

python init_db.py

After completing these steps, you can return to the project root and start the application again.

6. Next Steps

You've successfully set up and run the OpenLingu client application! 🎉

To learn more about using the client application and its features, check out the client documentation: