From 0546d8966dbf980ccf516ffc62d595059ed4ab9c Mon Sep 17 00:00:00 2001 From: Matthew Harris Date: Sun, 7 Jul 2024 18:09:19 -0500 Subject: [PATCH] Tested interactively on runner, now trying e2e again --- .github/workflows/e2e_tests.yml | 43 +++++++++++++++++---------------- 1 file changed, 22 insertions(+), 21 deletions(-) diff --git a/.github/workflows/e2e_tests.yml b/.github/workflows/e2e_tests.yml index 1e736e4c..26578650 100644 --- a/.github/workflows/e2e_tests.yml +++ b/.github/workflows/e2e_tests.yml @@ -82,15 +82,16 @@ jobs: echo "Starting docker containers for dbs and server ..." docker-compose -f ./docker-compose-github.yml pull docker-compose -f ./docker-compose-github.yml up -d --build - echo "logs datadb ..." - docker-compose -f docker-compose-github.yml logs datadb - # TODO: For some reason, maybe buildkit, in Github docker compose builds the image differently, and it doesn't work. Local build works. + # TODO: For some reason, maybe buildkit, in Github docker compose builds the image differently, and it doesn't work. Individual image build works. docker build --build-arg OPENAI_API_KEY=$OPENAI_API_KEY --build-arg CHAT_URL=$CHAT_URL --build-arg OPENAI_API_ENDPOINT=$OPENAI_API_ENDPOINT --no-cache -t promptflow -f ./flows/chainlit-ui-evaluation/Dockerfile . docker run --env USER_LOGIN=${USER_LOGIN} --env USER_PASSWORD=${USER_PASSWORD} --env CHAT_URL=${CHAT_URL} --network=data-recipes-ai_default -d --name promptflow promptflow docker ps + echo "logs datadb ..." + docker-compose -f docker-compose-github.yml logs datadb + echo "logs promptflow ..." docker logs promptflow docker ps @@ -99,22 +100,22 @@ jobs: # See here https://github.com/marketplace/actions/debugging-with-ssh # Basically, uncomment this, then get connection string in actions output, then connect with #ssh -i - - name: Setup upterm session - uses: lhotari/action-upterm@v1 - - # - name: Run tests - # run: | - # env > .env - # #docker-compose -f ./docker-compose-github.yml exec -T promptflow pf run create --flow . --data ./data.jsonl --stream --column-mapping query='${data.query}' context='${data.context}' chat_history='${data.chat_history}' --name base_run - # docker-compose exec -T promptflow pf run create --flow . --data ./data.jsonl --stream --column-mapping query='${data.query}' context='${data.context}' chat_history='${data.chat_history}' --name base_run - - - # - name: Show results - # run: | - # docker-compose -f ./docker-compose-github.yml exec -T promptflow pf run show-details -n base_run - # echo "Getting metrics ..." - # docker-compose -f ./docker-compose-github.yml exec -T promptflow pf run show-metrics -n base_run - # ##docker-compose -f ./docker-compose-github.yml exec -T promptflow pf run visualize -n base_run - # echo "Checking results ..." - # docker-compose -f ./docker-compose-github.yml exec -T promptflow python3 check_evaluation_results.py + #- name: Setup upterm session + # uses: lhotari/action-upterm@v1 + + - name: Run tests + run: | + env > .env + #docker-compose -f ./docker-compose-github.yml exec -T promptflow pf run create --flow . --data ./data.jsonl --stream --column-mapping query='${data.query}' context='${data.context}' chat_history='${data.chat_history}' --name base_run + docker-compose exec -T promptflow pf run create --flow . --data ./data.jsonl --stream --column-mapping query='${data.query}' context='${data.context}' chat_history='${data.chat_history}' --name base_run + + + - name: Show results + run: | + docker-compose exec -T promptflow pf run show-details -n base_run + echo "Getting metrics ..." + docker-compose exec -T promptflow pf run show-metrics -n base_run + ##docker-compose exec -T promptflow pf run visualize -n base_run + echo "Checking results ..." + docker-compose exec -T promptflow python3 check_evaluation_results.py \ No newline at end of file