| |
| FROM python:3.10-slim |
|
|
| |
| RUN apt-get update && apt-get install -y \ |
| build-essential \ |
| git \ |
| cmake \ |
| wget \ |
| && rm -rf /var/lib/apt/lists/* |
|
|
| |
| RUN git clone --depth 1 https://github.com/PrismML-Eng/llama.cpp.git && \ |
| cd llama.cpp && \ |
| mkdir build && cd build && \ |
| cmake .. -DGGML_NATIVE=ON -DCMAKE_BUILD_TYPE=Release && \ |
| make -j$(nproc) |
|
|
| |
| WORKDIR /app |
| COPY . /app |
| RUN pip install --no-cache-dir gradio huggingface_hub |
|
|
| |
| RUN cp /llama.cpp/build/bin/llama-cli /app/llama-cli && chmod +x /app/llama-cli |
|
|
| CMD ["python", "app.py"] |
|
|