This application is a simple web interface that allows users to generate Mermaid flowcharts using a local Ollama instance. It provides a basic login and a text area to input natural language descriptions which are then converted into Mermaid syntax by the Ollama model.
To run this application, you need the following installed and running on your system:
- Docker: Used to build and run the application container.
- Ollama: A running instance of Ollama with a suitable model (e.g.,
llama2,mistral) pulled and available. The application will attempt to connect to Ollama onhost.docker.internal.
The application now uses a .env file to manage credentials for the default guest user.
- Edit the
.envfile in the project root directory. - Set the
APP_USERNAMEandAPP_PASSWORDvariables to your desired username and password.APP_USERNAME=your_username APP_PASSWORD=your_password
- If the
.envfile is not present or these variables are not set, the application will default toAPP_USERNAME=guestandAPP_PASSWORD=your_password.
- DISABLE_AUTH: Set to
Trueto bypass authentication checks (useful for testing). Example:DISABLE_AUTH=True
Docker Compose simplifies the process of building and running the application. Navigate to the root directory of the project in your terminal (where the docker-compose.yml file is located).
Run the following command:
docker compose up --buildThis command will:
- Build the Docker image for the application if it hasn't been built yet or if you've made changes to the
Dockerfileor application code. - Start the application service defined in
docker-compose.yml.
After running the Docker container, open your web browser and navigate to:
http://localhost:5000
You will be presented with a login page.
- Username: The value of
APP_USERNAMEfrom your.envfile (defaults toguest). - Password: The value of
APP_PASSWORDfrom your.envfile (defaults toyour_password).
Log in to access the flowchart generator interface.