Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Jul 16, 2024
1 parent 16e0405 commit ee907e6
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 13 deletions.
4 changes: 2 additions & 2 deletions DocIndexRetriever/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ DocRetriever are the most widely adopted use case for leveraging the different m

## We provided DocWriterAgent with different deployment infra

* [docker xeon version](docker/xeon/) => minimum endpoints, easy to setup
* [docker gaudi version](docker/gaudi/) => with extra tei_gaudi endpoint, faster
- [docker xeon version](docker/xeon/) => minimum endpoints, easy to setup
- [docker gaudi version](docker/gaudi/) => with extra tei_gaudi endpoint, faster
17 changes: 11 additions & 6 deletions DocIndexRetriever/docker/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,28 @@ DocRetriever are the most widely adopted use case for leveraging the different m

### 1. Build Images for necessary microservices. (This step will not needed after docker image released)

* Embedding TEI Image
- Embedding TEI Image

```bash
git clone https://github.com/opea-project/GenAIComps.git
cd GenAIComps
docker build --no-cache -t opea/embedding-tei:latest --build-arg https_proxy=$https_proxy --build-arg http_proxy=$http_proxy -f comps/embeddings/langchain/docker/Dockerfile .
```

* Retriever Vector store Image
- Retriever Vector store Image

```bash
docker build --no-cache -t opea/retriever-redis:latest --build-arg https_proxy=$https_proxy --build-arg http_proxy=$http_proxy -f comps/retrievers/langchain/redis/docker/Dockerfile .
```

* Rerank TEI Image
- Rerank TEI Image

```bash
docker build --no-cache -t opea/reranking-tei:latest --build-arg https_proxy=$https_proxy --build-arg http_proxy=$http_proxy -f comps/reranks/tei/docker/Dockerfile .
```

* Dataprep Image
- Dataprep Image

```bash
docker build --no-cache -t opea/dataprep-on-ray-redis:latest --build-arg https_proxy=$https_proxy --build-arg http_proxy=$http_proxy -f comps/dataprep/redis/langchain_ray/docker/Dockerfile .
```
Expand Down Expand Up @@ -85,6 +89,7 @@ curl http://${host_ip}:8889/v1/retrievaltool -X POST -H "Content-Type: applicati
### 4. Trouble shooting

1. check all containers are alive

```bash
# redis vector store
docker container logs redis-vector-db
Expand Down Expand Up @@ -116,6 +121,6 @@ curl http://${host_ip}:8000/v1/reranking \
-H 'Content-Type: application/json' > output
docker container logs reranking-tei-server

# megaservice gateway
# megaservice gateway
docker container logs doc-index-retriever-server
```
```
2 changes: 1 addition & 1 deletion DocIndexRetriever/docker/gaudi/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -122,4 +122,4 @@ services:

networks:
default:
driver: bridge
driver: bridge
6 changes: 3 additions & 3 deletions DocIndexRetriever/docker/retrieval_tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import asyncio
import os

from comps import RetrievalToolGateway, MicroService, ServiceOrchestrator, ServiceType
from comps import MicroService, RetrievalToolGateway, ServiceOrchestrator, ServiceType

MEGA_SERVICE_HOST_IP = os.getenv("MEGA_SERVICE_HOST_IP", "0.0.0.0")
MEGA_SERVICE_PORT = os.getenv("MEGA_SERVICE_PORT", 8889)
Expand Down Expand Up @@ -47,7 +47,7 @@ def add_remote_service(self):
use_remote_service=True,
service_type=ServiceType.RERANK,
)

self.megaservice.add(embedding).add(retriever).add(rerank)
self.megaservice.flow_to(embedding, retriever)
self.megaservice.flow_to(retriever, rerank)
Expand All @@ -56,4 +56,4 @@ def add_remote_service(self):

if __name__ == "__main__":
chatqna = RetrievalToolService(host=MEGA_SERVICE_HOST_IP, port=MEGA_SERVICE_PORT)
chatqna.add_remote_service()
chatqna.add_remote_service()
2 changes: 1 addition & 1 deletion DocIndexRetriever/docker/xeon/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -116,4 +116,4 @@ services:

networks:
default:
driver: bridge
driver: bridge

0 comments on commit ee907e6

Please sign in to comment.