deadbits / vigil-llm

⚡ Vigil ⚡ Detect prompt injections, jailbreaks, and other potentially risky Large Language Model (LLM) inputs
https://vigil.deadbits.ai/
Apache License 2.0
304 stars 35 forks source link

Docker image is not building #46

Closed Murat-U-Saglam closed 10 months ago

Murat-U-Saglam commented 11 months ago

Describe the bug When building the container I get the following error.

Processing /app/data/datasets/vigil-jailbreak-ada-002/embeddings.parquet... Traceback (most recent call last): File "/app/vigil-server.py", line 10, in from flask import Flask, request, jsonify, abort File "/usr/local/lib/python3.10/site-packages/flask/init.py", line 5, in from .app import Flask as Flask File "/usr/local/lib/python3.10/site-packages/flask/app.py", line 30, in from werkzeug.urls import url_quote ImportError: cannot import name 'url_quote' from 'werkzeug.urls' (/usr/local/lib/python3.10/site-packages/werkzeug/urls.py)

To Reproduce As per - https://vigil.deadbits.ai/overview/install-vigil/docker-quick-start git clone https://github.com/deadbits/vigil-llm cd vigil-llm docker build -t vigil .

set your openai_api_key in docker.conf

vim conf/docker.conf

docker run -v pwd/conf/docker.conf:/app/conf/server.conf -p5000:5000 vigil

Expected behavior Build the image

Screenshots image

Environment:

deadbits commented 11 months ago

Thanks for opening this issue! I’ll take a look at this deeper tomorrow and I should have a fix pushed pretty quickly. It looks like the requirements.txt file might be missing a library or have some conflict that’s causing the error.

deadbits commented 10 months ago

Hey @Murat-U-Saglam , sorry this took so long but it should be fixed now!

The issue you found was due to an oudated Flask library. I've fixed this and some other dependency issues, so should be good now.

I've also pushed several other updates since then, including making the data loading process in the Docker entrypoint much easier.

Let me know if you run into any more problems! Thanks again for the report :+1: