Skip to content

Commit 22383a9

Browse files
committed
Minor fixes
1 parent 219cab2 commit 22383a9

File tree

4 files changed

+10
-7
lines changed

4 files changed

+10
-7
lines changed

WorkflowExecAgent/tests/2_start_vllm_service.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ function build_vllm_docker_image() {
2626
else
2727
cd ./vllm
2828
fi
29-
docker build -f Dockerfile.cpu -t vllm-cpu-env --shm-size=100g .
29+
docker build -f docker/Dockerfile.cpu -t vllm-cpu-env --shm-size=100g .
3030
if [ $? -ne 0 ]; then
3131
echo "opea/vllm:cpu failed"
3232
exit 1
@@ -43,9 +43,12 @@ function start_vllm_service() {
4343
echo "Waiting vllm ready"
4444
n=0
4545
until [[ "$n" -ge 100 ]] || [[ $ready == true ]]; do
46+
if docker logs test-comps-vllm-service| grep "Error response from daemon: No such container:"; then
47+
exit 1
48+
fi
4649
docker logs test-comps-vllm-service &> ${LOG_PATH}/vllm-service.log
4750
n=$((n+1))
48-
if grep -q "Uvicorn running on" ${LOG_PATH}/vllm-service.log; then
51+
if grep -q "Application startup complete." ${LOG_PATH}/vllm-service.log; then
4952
break
5053
fi
5154
if grep -q "No such container" ${LOG_PATH}/vllm-service.log; then

WorkflowExecAgent/tests/3_launch_agent_service.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ function start_agent() {
2727
cd $WORKDIR/GenAIExamples/WorkflowExecAgent/docker_compose/intel/cpu/xeon
2828
WORKDIR=$WORKPATH/docker_image_build/ docker compose -f compose_vllm.yaml up -d
2929
echo "Waiting agent service ready"
30-
sleep 5s
30+
sleep 10s
3131
}
3232

3333
function main() {

WorkflowExecAgent/tests/test_compose_vllm_example_wf_on_xeon.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ wf_api_port=${wf_api_port}
77
api_server_url=http://$(hostname -I | awk '{print $1}'):${wf_api_port}/
88
workflow_id=10071
99
query="I have a data with gender Female, tenure 55, MonthlyCharges 103.7, TotalCharges 1840.75. Predict if this entry will churn. My workflow id is ${workflow_id}."
10-
validate_result="the prediction is No"
10+
validate_result="is No"
1111

1212
function stop_agent_and_api_server() {
1313
echo "Stopping Agent services"
@@ -42,9 +42,9 @@ echo "=================== #5 Start validate agent ===================="
4242
bash 4_validate_agent.sh "$query" "$validate_result"
4343
echo "=================== #5 Validate agent completed ===================="
4444

45-
echo "=================== #4 Stop all services ===================="
45+
echo "=================== #6 Stop all services ===================="
4646
stop_agent_and_api_server
4747
stop_vllm_docker
48-
echo "=================== #4 All services stopped ===================="
48+
echo "=================== #6 All services stopped ===================="
4949

5050
echo "ALL DONE!"

WorkflowExecAgent/tools/utils/handle_requests.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ def __init__(self, base_url: str, api_key: str):
2121
def _make_request(self, endpoint, method="GET", data=None, stream=False):
2222
url = f"{self.base_url}{endpoint}"
2323
headers = {"Content-Type": "application/json", "Authorization": f"Bearer {self.api_key}"}
24-
2524
error = ""
25+
print(f"Making {method} request to {url}")
2626

2727
if method == "GET":
2828
response = requests.get(url, headers=headers)

0 commit comments

Comments
 (0)