sidmaz666 commited on
Commit
c64596d
·
verified ·
1 Parent(s): 2a63be5

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +7 -5
Dockerfile CHANGED
@@ -9,15 +9,17 @@ ENV PYTHONDONTWRITEBYTECODE=1 \
9
  TOKENIZERS_PARALLELISM=false
10
 
11
  RUN apt-get update && apt-get install -y --no-install-recommends \
12
- gcc g++ make cmake git \
13
- libopenblas-dev \
14
  && rm -rf /var/lib/apt/lists/*
15
 
16
  WORKDIR /app
17
 
18
- # Pre-built llama-cpp-python wheel with OpenBLAS
19
- RUN pip install --no-cache-dir \
20
- https://huggingface.co/Luigi/llama-cpp-python-wheels-hf-spaces-free-cpu/resolve/main/llama_cpp_python-0.3.22-cp310-cp310-linux_x86_64.whl
 
 
 
21
 
22
  COPY requirements.txt .
23
  RUN pip install --no-cache-dir -r requirements.txt
 
9
  TOKENIZERS_PARALLELISM=false
10
 
11
  RUN apt-get update && apt-get install -y --no-install-recommends \
12
+ git build-essential cmake libopenblas-dev \
 
13
  && rm -rf /var/lib/apt/lists/*
14
 
15
  WORKDIR /app
16
 
17
+ # Clone PrismML's llama.cpp fork and build llama-cpp-python from source
18
+ RUN git clone --depth 1 https://github.com/PrismML-Eng/llama-cpp-python.git && \
19
+ cd llama-cpp-python && \
20
+ git submodule update --init --recursive && \
21
+ CMAKE_ARGS="-DGGML_OPENBLAS=ON" pip install --no-cache-dir -e . && \
22
+ cd .. && rm -rf llama-cpp-python
23
 
24
  COPY requirements.txt .
25
  RUN pip install --no-cache-dir -r requirements.txt