-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathDockerfile
More file actions
22 lines (15 loc) · 864 Bytes
/
Dockerfile
File metadata and controls
22 lines (15 loc) · 864 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
FROM python:3.12-slim
LABEL maintainer="Lyon. <lyonzin@users.noreply.github.com>"
LABEL description="Local RAG System for Claude Code — Hybrid search + Cross-encoder Reranking + 12 MCP Tools"
LABEL org.opencontainers.image.source="https://github.com/lyonzin/knowledge-rag"
WORKDIR /app
COPY pyproject.toml requirements.txt ./
COPY mcp_server/ ./mcp_server/
COPY documents/examples/ ./documents/examples/
COPY LICENSE README.md ./
RUN pip install --no-cache-dir -r requirements.txt
# Pre-download embedding + reranker models (cached in image)
RUN python -c "from fastembed import TextEmbedding; TextEmbedding('BAAI/bge-small-en-v1.5')" && \
python -c "from fastembed.rerank.cross_encoder import TextCrossEncoder; TextCrossEncoder('Xenova/ms-marco-MiniLM-L-6-v2')"
VOLUME ["/app/documents", "/app/data"]
ENTRYPOINT ["python", "-m", "mcp_server.server"]