Skip to content

Commit

Permalink
[ChatQnA] Add no_wrapper benchmarking and update legacy manifests (#767)
Browse files Browse the repository at this point in the history
Co-authored-by: Zhenzhong1 <[email protected]>
  • Loading branch information
Spycsh and Zhenzhong1 authored Sep 14, 2024
1 parent bc4bbfa commit 06696c8
Show file tree
Hide file tree
Showing 27 changed files with 8,728 additions and 1,943 deletions.
2 changes: 0 additions & 2 deletions ChatQnA/Dockerfile.no_wrapper
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,4 @@ USER user

WORKDIR /home/user

RUN echo 'ulimit -S -n 999999' >> ~/.bashrc

ENTRYPOINT ["python", "chatqna_no_wrapper.py"]
34 changes: 34 additions & 0 deletions ChatQnA/Dockerfile.no_wrapper_without_rerank
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@


# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0

FROM python:3.11-slim

RUN apt-get update -y && apt-get install -y --no-install-recommends --fix-missing \
libgl1-mesa-glx \
libjemalloc-dev \
vim \
git

RUN useradd -m -s /bin/bash user && \
mkdir -p /home/user && \
chown -R user /home/user/

WORKDIR /home/user/
RUN git clone https://github.com/opea-project/GenAIComps.git

WORKDIR /home/user/GenAIComps
RUN pip install --no-cache-dir --upgrade pip && \
pip install --no-cache-dir -r /home/user/GenAIComps/requirements.txt && \
pip install --no-cache-dir langchain_core

COPY ./chatqna_no_wrapper.py /home/user/chatqna_no_wrapper.py

ENV PYTHONPATH=$PYTHONPATH:/home/user/GenAIComps

USER user

WORKDIR /home/user

ENTRYPOINT ["python", "chatqna_no_wrapper.py", "--without-rerank"]
11 changes: 11 additions & 0 deletions ChatQnA/benchmark/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,17 @@ Results will be displayed in the terminal and saved as CSV file named `1_stats.c
- Set up kubectl on the master node with access to the Kubernetes cluster.
- Install Python 3.8+ on the master node for running the stress tool.
- Ensure all nodes have a local /mnt/models folder, which will be mounted by the pods.
- Ensure that the container's ulimit can meet the the number of requests.

```bash
# The way to modify the containered ulimit:
sudo systemctl edit containerd
# Add two lines:
[Service]
LimitNOFILE=65536:1048576

sudo systemctl daemon-reload; sudo systemctl restart containerd
```

### Kubernetes Cluster Example

Expand Down
Loading

0 comments on commit 06696c8

Please sign in to comment.