7bfb9946
tangwang
向量化模块
|
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
EMBEDDING_SERVICE_HOST=$(python -c "from embeddings.config import CONFIG; print(CONFIG.HOST)")
EMBEDDING_SERVICE_PORT=$(python -c "from embeddings.config import CONFIG; print(CONFIG.PORT)")
echo "========================================"
echo "Starting Local Embedding Service"
echo "========================================"
echo "Host: ${EMBEDDING_SERVICE_HOST}"
echo "Port: ${EMBEDDING_SERVICE_PORT}"
echo
echo "Tips:"
echo " - Use a single worker (GPU models cannot be safely duplicated across workers)."
echo " - Clients can set EMBEDDING_SERVICE_URL=http://localhost:${EMBEDDING_SERVICE_PORT}"
echo
exec python -m uvicorn embeddings.server:app \
--host "${EMBEDDING_SERVICE_HOST}" \
--port "${EMBEDDING_SERVICE_PORT}" \
--workers 1
|