From 74013daf1ce6b38adb0e9d6209dceb47b3ebfe7b Mon Sep 17 00:00:00 2001 From: Abigail Hartman Date: Tue, 16 Apr 2024 11:51:06 -0700 Subject: [PATCH] intermediate changes --- .backup.requirements-dev.txt | 13 ++++ .backup.requirements.txt | 11 ++++ README.md | 10 +++ poetry.lock | 2 +- requirements-dev.txt | 114 +++++++++++++++++++++++++++++++---- requirements.txt | 75 +++++++++++++++++++---- start.cmd | 3 +- 7 files changed, 202 insertions(+), 26 deletions(-) create mode 100644 .backup.requirements-dev.txt create mode 100644 .backup.requirements.txt diff --git a/.backup.requirements-dev.txt b/.backup.requirements-dev.txt new file mode 100644 index 0000000000..0fbb1c4472 --- /dev/null +++ b/.backup.requirements-dev.txt @@ -0,0 +1,13 @@ +-r requirements.txt +azure-ai-formrecognizer==3.2.1 +Markdown==3.4.4 +requests==2.31.0 +tqdm==4.66.1 +tiktoken==0.4.0 +langchain==0.0.340 +bs4==0.0.1 +urllib3==2.1.0 +pytest==7.4.0 +pytest-asyncio==0.23.2 +azure-storage-blob +chardet \ No newline at end of file diff --git a/.backup.requirements.txt b/.backup.requirements.txt new file mode 100644 index 0000000000..047642ce2e --- /dev/null +++ b/.backup.requirements.txt @@ -0,0 +1,11 @@ +azure-identity==1.15.0 +# Flask[async]==2.3.2 +openai==1.6.1 +azure-search-documents==11.4.0b6 +azure-storage-blob==12.17.0 +python-dotenv==1.0.0 +azure-cosmos==4.5.0 +quart==0.19.4 +uvicorn==0.24.0 +aiohttp==3.9.2 +gunicorn==20.1.0 diff --git a/README.md b/README.md index 5b77b8f37f..b6dfe7581a 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,16 @@ This repo contains sample code for a simple chat webapp that integrates with Azu - Pinecone index (preview) - AzureML index (preview) +### Developer Prerequisites +The following tools should be installed prior to running the project locally. + +#### Frontend tools +- nodejs 21+ + +#### Backend tools +- Python 3.10+ +- [Poetry](https://python-poetry.org/docs/#installation) + ## Deploy the app ### Deploy with Azure Developer CLI diff --git a/poetry.lock b/poetry.lock index 7e146bec2d..887c2ac12b 100644 --- a/poetry.lock +++ b/poetry.lock @@ -2547,4 +2547,4 @@ multidict = ">=4.0" [metadata] lock-version = "2.0" python-versions = "^3.10" -content-hash = "7ee5c9222525cdb1b4099b590200cee99a9b7ae1a937122638c51750a4ab7fee" +content-hash = "a1882efb78658c2511959e1e74d093964359f73980ae6c1b41a74f119e6d264f" diff --git a/requirements-dev.txt b/requirements-dev.txt index 0fbb1c4472..f9aaab7d99 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -1,13 +1,101 @@ --r requirements.txt -azure-ai-formrecognizer==3.2.1 -Markdown==3.4.4 -requests==2.31.0 -tqdm==4.66.1 -tiktoken==0.4.0 -langchain==0.0.340 -bs4==0.0.1 -urllib3==2.1.0 -pytest==7.4.0 -pytest-asyncio==0.23.2 -azure-storage-blob -chardet \ No newline at end of file +aiofiles==23.2.1 ; python_version >= "3.10" and python_version < "4.0" +aiohttp==3.9.2 ; python_version >= "3.10" and python_version < "4.0" +aiosignal==1.3.1 ; python_version >= "3.10" and python_version < "4.0" +annotated-types==0.6.0 ; python_version >= "3.10" and python_version < "4.0" +anyio==3.7.1 ; python_version >= "3.10" and python_version < "4.0" +async-timeout==4.0.3 ; python_version >= "3.10" and python_version < "3.11" +attrs==23.2.0 ; python_version >= "3.10" and python_version < "4.0" +azure-ai-formrecognizer==3.2.1 ; python_version >= "3.10" and python_version < "4.0" +azure-common==1.1.28 ; python_version >= "3.10" and python_version < "4.0" +azure-core==1.30.1 ; python_version >= "3.10" and python_version < "4.0" +azure-cosmos==4.5.0 ; python_version >= "3.10" and python_version < "4.0" +azure-identity==1.15.0 ; python_version >= "3.10" and python_version < "4.0" +azure-search-documents==11.4.0b6 ; python_version >= "3.10" and python_version < "4.0" +azure-storage-blob==12.17.0 ; python_version >= "3.10" and python_version < "4.0" +beautifulsoup4==4.12.3 ; python_version >= "3.10" and python_version < "4.0" +blinker==1.7.0 ; python_version >= "3.10" and python_version < "4.0" +bs4==0.0.1 ; python_version >= "3.10" and python_version < "4.0" +certifi==2024.2.2 ; python_version >= "3.10" and python_version < "4.0" +cffi==1.16.0 ; python_version >= "3.10" and python_version < "4.0" and platform_python_implementation != "PyPy" +cfgv==3.4.0 ; python_version >= "3.10" and python_version < "4.0" +chardet==5.2.0 ; python_version >= "3.10" and python_version < "4.0" +charset-normalizer==3.3.2 ; python_version >= "3.10" and python_version < "4.0" +click==8.1.7 ; python_version >= "3.10" and python_version < "4.0" +colorama==0.4.6 ; python_version >= "3.10" and python_version < "4.0" and (platform_system == "Windows" or sys_platform == "win32") +cryptography==42.0.5 ; python_version >= "3.10" and python_version < "4.0" +dataclasses-json==0.6.4 ; python_version >= "3.10" and python_version < "4.0" +distlib==0.3.8 ; python_version >= "3.10" and python_version < "4.0" +distro==1.9.0 ; python_version >= "3.10" and python_version < "4.0" +exceptiongroup==1.2.0 ; python_version >= "3.10" and python_version < "3.11" +filelock==3.13.4 ; python_version >= "3.10" and python_version < "4.0" +flask==3.0.3 ; python_version >= "3.10" and python_version < "4.0" +frozenlist==1.4.1 ; python_version >= "3.10" and python_version < "4.0" +greenlet==3.0.3 ; python_version >= "3.10" and python_version < "4.0" and (platform_machine == "aarch64" or platform_machine == "ppc64le" or platform_machine == "x86_64" or platform_machine == "amd64" or platform_machine == "AMD64" or platform_machine == "win32" or platform_machine == "WIN32") +gunicorn==20.1.0 ; python_version >= "3.10" and python_version < "4.0" +h11==0.14.0 ; python_version >= "3.10" and python_version < "4.0" +h2==4.1.0 ; python_version >= "3.10" and python_version < "4.0" +hpack==4.0.0 ; python_version >= "3.10" and python_version < "4.0" +httpcore==1.0.5 ; python_version >= "3.10" and python_version < "4.0" +httpx==0.27.0 ; python_version >= "3.10" and python_version < "4.0" +hypercorn==0.16.0 ; python_version >= "3.10" and python_version < "4.0" +hyperframe==6.0.1 ; python_version >= "3.10" and python_version < "4.0" +identify==2.5.35 ; python_version >= "3.10" and python_version < "4.0" +idna==3.7 ; python_version >= "3.10" and python_version < "4.0" +iniconfig==2.0.0 ; python_version >= "3.10" and python_version < "4.0" +isodate==0.6.1 ; python_version >= "3.10" and python_version < "4.0" +itsdangerous==2.1.2 ; python_version >= "3.10" and python_version < "4.0" +jinja2==3.1.3 ; python_version >= "3.10" and python_version < "4.0" +jsonpatch==1.33 ; python_version >= "3.10" and python_version < "4.0" +jsonpointer==2.4 ; python_version >= "3.10" and python_version < "4.0" +langchain==0.0.340 ; python_version >= "3.10" and python_version < "4.0" +langsmith==0.0.92 ; python_version >= "3.10" and python_version < "4.0" +markdown==3.4.4 ; python_version >= "3.10" and python_version < "4.0" +markupsafe==2.1.5 ; python_version >= "3.10" and python_version < "4.0" +marshmallow==3.21.1 ; python_version >= "3.10" and python_version < "4.0" +msal-extensions==1.1.0 ; python_version >= "3.10" and python_version < "4.0" +msal==1.28.0 ; python_version >= "3.10" and python_version < "4.0" +msrest==0.7.1 ; python_version >= "3.10" and python_version < "4.0" +multidict==6.0.5 ; python_version >= "3.10" and python_version < "4.0" +mypy-extensions==1.0.0 ; python_version >= "3.10" and python_version < "4.0" +nodeenv==1.8.0 ; python_version >= "3.10" and python_version < "4.0" +numpy==1.26.4 ; python_version >= "3.10" and python_version < "4.0" +oauthlib==3.2.2 ; python_version >= "3.10" and python_version < "4.0" +openai==1.6.1 ; python_version >= "3.10" and python_version < "4.0" +packaging==24.0 ; python_version >= "3.10" and python_version < "4.0" +platformdirs==4.2.0 ; python_version >= "3.10" and python_version < "4.0" +pluggy==1.4.0 ; python_version >= "3.10" and python_version < "4.0" +portalocker==2.8.2 ; python_version >= "3.10" and python_version < "4.0" +pre-commit==3.7.0 ; python_version >= "3.10" and python_version < "4.0" +priority==2.0.0 ; python_version >= "3.10" and python_version < "4.0" +pycparser==2.22 ; python_version >= "3.10" and python_version < "4.0" and platform_python_implementation != "PyPy" +pydantic-core==2.18.1 ; python_version >= "3.10" and python_version < "4.0" +pydantic==2.7.0 ; python_version >= "3.10" and python_version < "4.0" +pyjwt[crypto]==2.8.0 ; python_version >= "3.10" and python_version < "4.0" +pytest-asyncio==0.23.2 ; python_version >= "3.10" and python_version < "4.0" +pytest==7.4.0 ; python_version >= "3.10" and python_version < "4.0" +python-dotenv==1.0.0 ; python_version >= "3.10" and python_version < "4.0" +pywin32==306 ; python_version >= "3.10" and python_version < "4.0" and platform_system == "Windows" +pyyaml==6.0.1 ; python_version >= "3.10" and python_version < "4.0" +quart==0.19.4 ; python_version >= "3.10" and python_version < "4.0" +regex==2023.12.25 ; python_version >= "3.10" and python_version < "4.0" +requests-oauthlib==2.0.0 ; python_version >= "3.10" and python_version < "4.0" +requests==2.31.0 ; python_version >= "3.10" and python_version < "4.0" +ruff==0.3.7 ; python_version >= "3.10" and python_version < "4.0" +setuptools==69.2.0 ; python_version >= "3.10" and python_version < "4.0" +six==1.16.0 ; python_version >= "3.10" and python_version < "4.0" +sniffio==1.3.1 ; python_version >= "3.10" and python_version < "4.0" +soupsieve==2.5 ; python_version >= "3.10" and python_version < "4.0" +sqlalchemy==2.0.29 ; python_version >= "3.10" and python_version < "4.0" +taskgroup==0.0.0a4 ; python_version >= "3.10" and python_version < "3.11" +tenacity==8.2.3 ; python_version >= "3.10" and python_version < "4.0" +tiktoken==0.4.0 ; python_version >= "3.10" and python_version < "4.0" +tomli==2.0.1 ; python_version >= "3.10" and python_version < "3.11" +tqdm==4.66.1 ; python_version >= "3.10" and python_version < "4.0" +typing-extensions==4.11.0 ; python_version >= "3.10" and python_version < "4.0" +typing-inspect==0.9.0 ; python_version >= "3.10" and python_version < "4.0" +urllib3==2.1.0 ; python_version >= "3.10" and python_version < "4.0" +uvicorn==0.24.0 ; python_version >= "3.10" and python_version < "4.0" +virtualenv==20.25.1 ; python_version >= "3.10" and python_version < "4.0" +werkzeug==3.0.2 ; python_version >= "3.10" and python_version < "4.0" +wsproto==1.2.0 ; python_version >= "3.10" and python_version < "4.0" +yarl==1.9.4 ; python_version >= "3.10" and python_version < "4.0" diff --git a/requirements.txt b/requirements.txt index 047642ce2e..db23fb1514 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,11 +1,64 @@ -azure-identity==1.15.0 -# Flask[async]==2.3.2 -openai==1.6.1 -azure-search-documents==11.4.0b6 -azure-storage-blob==12.17.0 -python-dotenv==1.0.0 -azure-cosmos==4.5.0 -quart==0.19.4 -uvicorn==0.24.0 -aiohttp==3.9.2 -gunicorn==20.1.0 +aiofiles==23.2.1 ; python_version >= "3.10" and python_version < "4.0" +aiohttp==3.9.2 ; python_version >= "3.10" and python_version < "4.0" +aiosignal==1.3.1 ; python_version >= "3.10" and python_version < "4.0" +annotated-types==0.6.0 ; python_version >= "3.10" and python_version < "4.0" +anyio==3.7.1 ; python_version >= "3.10" and python_version < "4.0" +async-timeout==4.0.3 ; python_version >= "3.10" and python_version < "3.11" +attrs==23.2.0 ; python_version >= "3.10" and python_version < "4.0" +azure-common==1.1.28 ; python_version >= "3.10" and python_version < "4.0" +azure-core==1.30.1 ; python_version >= "3.10" and python_version < "4.0" +azure-cosmos==4.5.0 ; python_version >= "3.10" and python_version < "4.0" +azure-identity==1.15.0 ; python_version >= "3.10" and python_version < "4.0" +azure-search-documents==11.4.0b6 ; python_version >= "3.10" and python_version < "4.0" +azure-storage-blob==12.17.0 ; python_version >= "3.10" and python_version < "4.0" +blinker==1.7.0 ; python_version >= "3.10" and python_version < "4.0" +certifi==2024.2.2 ; python_version >= "3.10" and python_version < "4.0" +cffi==1.16.0 ; python_version >= "3.10" and python_version < "4.0" and platform_python_implementation != "PyPy" +charset-normalizer==3.3.2 ; python_version >= "3.10" and python_version < "4.0" +click==8.1.7 ; python_version >= "3.10" and python_version < "4.0" +colorama==0.4.6 ; python_version >= "3.10" and python_version < "4.0" and platform_system == "Windows" +cryptography==42.0.5 ; python_version >= "3.10" and python_version < "4.0" +distro==1.9.0 ; python_version >= "3.10" and python_version < "4.0" +exceptiongroup==1.2.0 ; python_version >= "3.10" and python_version < "3.11" +flask==3.0.3 ; python_version >= "3.10" and python_version < "4.0" +frozenlist==1.4.1 ; python_version >= "3.10" and python_version < "4.0" +gunicorn==20.1.0 ; python_version >= "3.10" and python_version < "4.0" +h11==0.14.0 ; python_version >= "3.10" and python_version < "4.0" +h2==4.1.0 ; python_version >= "3.10" and python_version < "4.0" +hpack==4.0.0 ; python_version >= "3.10" and python_version < "4.0" +httpcore==1.0.5 ; python_version >= "3.10" and python_version < "4.0" +httpx==0.27.0 ; python_version >= "3.10" and python_version < "4.0" +hypercorn==0.16.0 ; python_version >= "3.10" and python_version < "4.0" +hyperframe==6.0.1 ; python_version >= "3.10" and python_version < "4.0" +idna==3.7 ; python_version >= "3.10" and python_version < "4.0" +isodate==0.6.1 ; python_version >= "3.10" and python_version < "4.0" +itsdangerous==2.1.2 ; python_version >= "3.10" and python_version < "4.0" +jinja2==3.1.3 ; python_version >= "3.10" and python_version < "4.0" +markupsafe==2.1.5 ; python_version >= "3.10" and python_version < "4.0" +msal-extensions==1.1.0 ; python_version >= "3.10" and python_version < "4.0" +msal==1.28.0 ; python_version >= "3.10" and python_version < "4.0" +multidict==6.0.5 ; python_version >= "3.10" and python_version < "4.0" +openai==1.6.1 ; python_version >= "3.10" and python_version < "4.0" +packaging==24.0 ; python_version >= "3.10" and python_version < "4.0" +portalocker==2.8.2 ; python_version >= "3.10" and python_version < "4.0" +priority==2.0.0 ; python_version >= "3.10" and python_version < "4.0" +pycparser==2.22 ; python_version >= "3.10" and python_version < "4.0" and platform_python_implementation != "PyPy" +pydantic-core==2.18.1 ; python_version >= "3.10" and python_version < "4.0" +pydantic==2.7.0 ; python_version >= "3.10" and python_version < "4.0" +pyjwt[crypto]==2.8.0 ; python_version >= "3.10" and python_version < "4.0" +python-dotenv==1.0.0 ; python_version >= "3.10" and python_version < "4.0" +pywin32==306 ; python_version >= "3.10" and python_version < "4.0" and platform_system == "Windows" +quart==0.19.4 ; python_version >= "3.10" and python_version < "4.0" +requests==2.31.0 ; python_version >= "3.10" and python_version < "4.0" +setuptools==69.2.0 ; python_version >= "3.10" and python_version < "4.0" +six==1.16.0 ; python_version >= "3.10" and python_version < "4.0" +sniffio==1.3.1 ; python_version >= "3.10" and python_version < "4.0" +taskgroup==0.0.0a4 ; python_version >= "3.10" and python_version < "3.11" +tomli==2.0.1 ; python_version >= "3.10" and python_version < "3.11" +tqdm==4.66.1 ; python_version >= "3.10" and python_version < "4.0" +typing-extensions==4.11.0 ; python_version >= "3.10" and python_version < "4.0" +urllib3==2.1.0 ; python_version >= "3.10" and python_version < "4.0" +uvicorn==0.24.0 ; python_version >= "3.10" and python_version < "4.0" +werkzeug==3.0.2 ; python_version >= "3.10" and python_version < "4.0" +wsproto==1.2.0 ; python_version >= "3.10" and python_version < "4.0" +yarl==1.9.4 ; python_version >= "3.10" and python_version < "4.0" diff --git a/start.cmd b/start.cmd index 061131c028..15da260142 100644 --- a/start.cmd +++ b/start.cmd @@ -3,7 +3,8 @@ echo. echo Restoring backend python packages echo. -call python -m pip install -r requirements.txt + +call poetry install if "%errorlevel%" neq "0" ( echo Failed to restore backend python packages exit /B %errorlevel%