Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

replace langchain/langchain:latest with python:3.11-slim #669

Merged
merged 2 commits into from
Sep 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion comps/embeddings/mosec/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
libgl1-mesa-glx \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
libgl1-mesa-glx \
Expand Down
2 changes: 1 addition & 1 deletion comps/embeddings/multimodal_clip/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ARG ARCH="cpu"

Expand Down
2 changes: 1 addition & 1 deletion comps/embeddings/tei/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ARG ARCH="cpu"

Expand Down
2 changes: 1 addition & 1 deletion comps/guardrails/llama_guard/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ENV LANG=C.UTF-8

Expand Down
2 changes: 1 addition & 1 deletion comps/guardrails/toxicity_detection/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ENV LANG=C.UTF-8

Expand Down
2 changes: 1 addition & 1 deletion comps/intent_detection/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
libgl1-mesa-glx \
Expand Down
2 changes: 1 addition & 1 deletion comps/knowledgegraphs/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ARG ARCH="cpu" # Set this to "cpu" or "gpu"

Expand Down
2 changes: 1 addition & 1 deletion comps/llms/faq-generation/tgi/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
libgl1-mesa-glx \
Expand Down
2 changes: 1 addition & 1 deletion comps/llms/summarization/tgi/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
libgl1-mesa-glx \
Expand Down
2 changes: 1 addition & 1 deletion comps/llms/text-generation/ollama/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
curl \
Expand Down
2 changes: 1 addition & 1 deletion comps/llms/text-generation/tgi/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
libgl1-mesa-glx \
Expand Down
2 changes: 1 addition & 1 deletion comps/llms/text-generation/vllm/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ARG ARCH="cpu" # Set this to "cpu" or "gpu"

Expand Down
2 changes: 1 addition & 1 deletion comps/llms/text-generation/vllm/ray/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
libgl1-mesa-glx \
Expand Down
2 changes: 1 addition & 1 deletion comps/ragas/tgi/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
libgl1-mesa-glx \
Expand Down
2 changes: 1 addition & 1 deletion comps/reranks/mosec/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
libgl1-mesa-glx \
Expand Down
2 changes: 1 addition & 1 deletion comps/retrievers/multimodal/redis/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ARG ARCH="cpu"

Expand Down
2 changes: 1 addition & 1 deletion comps/retrievers/pathway/langchain/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ARG ARCH="cpu"

Expand Down
2 changes: 1 addition & 1 deletion comps/retrievers/pgvector/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
libgl1-mesa-glx \
Expand Down
2 changes: 1 addition & 1 deletion comps/retrievers/pinecone/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ARG ARCH="cpu"

Expand Down
2 changes: 1 addition & 1 deletion comps/retrievers/redis/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ARG ARCH="cpu"

Expand Down
2 changes: 1 addition & 1 deletion comps/retrievers/vdms/langchain/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ARG ARCH="cpu"

Expand Down
2 changes: 1 addition & 1 deletion comps/web_retrievers/chroma/langchain/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM langchain/langchain:latest
FROM python:3.11-slim

ARG ARCH="cpu" # Set this to "cpu" or "gpu"

Expand Down
8 changes: 4 additions & 4 deletions tests/llms/test_llms_text-generation_tgi.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ function build_docker_images() {

function start_service() {
tgi_endpoint_port=5004
export your_hf_llm_model=$1
export hf_llm_model=$1
# Remember to set HF_TOKEN before invoking this test!
export HF_TOKEN=${HF_TOKEN}
docker run -d --name="test-comps-llm-tgi-endpoint" -p $tgi_endpoint_port:80 -v ./data:/data --shm-size 1g -e HF_TOKEN=${HF_TOKEN} ghcr.io/huggingface/text-generation-inference:2.1.0 --model-id ${your_hf_llm_model} --max-input-tokens 1024 --max-total-tokens 2048
docker run -d --name="test-comps-llm-tgi-endpoint" -p $tgi_endpoint_port:80 -v ~/.cache/huggingface/hub:/data --shm-size 1g -e HF_TOKEN=${HF_TOKEN} ghcr.io/huggingface/text-generation-inference:2.1.0 --model-id ${hf_llm_model} --max-input-tokens 1024 --max-total-tokens 2048
export TGI_LLM_ENDPOINT="http://${ip_address}:${tgi_endpoint_port}"

llm_port=5005
Expand All @@ -34,9 +34,9 @@ function start_service() {
# check whether tgi is fully ready
n=0
until [[ "$n" -ge 100 ]] || [[ $ready == true ]]; do
docker logs test-comps-llm-tgi-endpoint >> ${LOG_PATH}/llm-tgi.log
docker logs test-comps-llm-tgi-endpoint >> ${LOG_PATH}/${hf_llm_model}-llm-tgi.log
n=$((n+1))
if grep -q Connected ${LOG_PATH}/llm-tgi.log; then
if grep -q Connected ${LOG_PATH}/${hf_llm_model}-llm-tgi.log; then
break
fi
sleep 5s
Expand Down
2 changes: 1 addition & 1 deletion tests/retrievers/test_retrievers_pinecone_langchain.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ function start_service() {
export HUGGINGFACEHUB_API_TOKEN=$HF_TOKEN
retriever_port=5054
unset http_proxy
docker run -d --name="test-comps-retriever-pinecone-server" -p ${retriever_port}:7000 --ipc=host -e TEI_EMBEDDING_ENDPOINT=$TEI_EMBEDDING_ENDPOINT -e http_proxy=$http_proxy -e https_proxy=$https_proxy -e PINECONE_API_KEY=$PINECONE_API_KEY -e PINECONE_INDEX_NAME=$PINECONE_INDEX_NAME -e INDEX_NAME=$PINECONE_INDEX_NAME opea/retriever-pinecone:comps
docker run -d --name="test-comps-retriever-pinecone-server" -p ${retriever_port}:7000 --ipc=host -e HUGGINGFACEHUB_API_TOKEN=${HUGGINGFACEHUB_API_TOKEN} -e TEI_EMBEDDING_ENDPOINT=$TEI_EMBEDDING_ENDPOINT -e http_proxy=$http_proxy -e https_proxy=$https_proxy -e PINECONE_API_KEY=$PINECONE_API_KEY -e PINECONE_INDEX_NAME=$PINECONE_INDEX_NAME -e INDEX_NAME=$PINECONE_INDEX_NAME opea/retriever-pinecone:comps

sleep 2m
}
Expand Down
3 changes: 2 additions & 1 deletion tests/retrievers/test_retrievers_redis_langchain.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,10 @@ function start_service() {
# redis retriever
export REDIS_URL="redis://${ip_address}:5010"
export INDEX_NAME="rag-redis"
export HUGGINGFACEHUB_API_TOKEN=$HF_TOKEN
retriever_port=5435
# unset http_proxy
docker run -d --name="test-comps-retriever-redis-server" -p ${retriever_port}:7000 --ipc=host -e TEI_EMBEDDING_ENDPOINT=$TEI_EMBEDDING_ENDPOINT -e http_proxy=$http_proxy -e https_proxy=$https_proxy -e REDIS_URL=$REDIS_URL -e INDEX_NAME=$INDEX_NAME opea/retriever-redis:comps
docker run -d --name="test-comps-retriever-redis-server" -p ${retriever_port}:7000 --ipc=host -e HUGGINGFACEHUB_API_TOKEN=${HUGGINGFACEHUB_API_TOKEN} -e TEI_EMBEDDING_ENDPOINT=$TEI_EMBEDDING_ENDPOINT -e http_proxy=$http_proxy -e https_proxy=$https_proxy -e REDIS_URL=$REDIS_URL -e INDEX_NAME=$INDEX_NAME opea/retriever-redis:comps

sleep 3m
}
Expand Down
Loading