Follow the conda documentation: Installing Conda. See also Conda getting started
Setup your terminal (zsh example):
source ~/miniconda3/bin/activate
conda init zsh
eval "$(/home/slks/miniconda3/bin/conda shell.zsh hook)"
conda env update --file backend/env.yml --name langchain --prune
NOTE: if dependencies added should be exported to env.yml
:
conda env export > backend/env.yml --no-builds
Other Conda commands:
conda create langchain
conda deactivate # deactivate any active conda environment
conda activate langchain
conda env create -f backend/env.yml
#todo: try setting python version
conda create -n tf_env python=3.8
cd backend && python api.py
cd backend
# run tests
python -m pytest
# run coverage
coverage run --source=src -m pytest
coverage report -m
# see coverage
coverage html
All in one:
pytest && coverage run --source=src -m pytest && coverage report -m
cd backend
coverage-badge -o ../README.md_images/coverage.svg -f
NOTE: pipeline generation don't work
Default host/port is set in host.py.
You'll see operations' logs in console (see logUtil.py).
Flask api is implemented in api.py, this is also the main entry point.
OpenAi/langchain implementation in iaService.py.