FROM python:3.10-slim WORKDIR /app ENV PYTHONUNBUFFERED=1 # تثبيت أدوات + build خفيف RUN apt-get update && apt-get install -y \ git \ build-essential \ cmake \ wget \ && rm -rf /var/lib/apt/lists/* # تحميل llama.cpp (نسخة صغيرة) RUN git clone --depth 1 https://github.com/ggerganov/llama.cpp.git WORKDIR /app/llama.cpp # build بخيوط قليلة لتجنب OOM 🔥 RUN cmake -B build -DLLAMA_BUILD_EXAMPLES=ON \ && cmake --build build -j2 WORKDIR /app # تحميل النموذج RUN wget -O model.gguf "https://huggingface.co/mradermacher/LFM2.5-1.2B-Thinking-Kimi-V2-Heretic-Uncensored-DISTILL-GGUF/resolve/main/LFM2.5-1.2B-Thinking-Kimi-V2-Heretic-Uncensored-DISTILL.Q4_K_M.gguf" # Gradio RUN pip install gradio COPY app.py . CMD ["python", "app.py"]