Python version recommendation: 3.11
Install the LangChain CLI if you haven't yet
pip install -U langchain-cli
poetry install
python importer\save_notion_html.py
then
python importer\html_process.py
python3 importer/load_and_process.py
poetry run python importer/load_and_process.py
poetry run python app/server.py
poetry run python bot.py
poetry add package_name
LangSmith will help us trace, monitor and debug LangChain applications. LangSmith is currently in private beta, you can sign up here. If you don't have access, you can skip this section
export langchain_tracing_v2=true
export LANGCHAIN_API_KEY=<your-api-key>
export LANGCHAIN_PROJECT=<your-project> # if not specified, defaults to "default"
langchain serve
This project folder includes a Dockerfile that allows you to easily build and host your LangServe app.
To build the image, you simply:
docker build . -t my-langserve-app
If you tag your image with something other than my-langserve-app
,
note it for use in the next step.
To run the image, you'll need to include any environment variables necessary for your application.
In the below example, we inject the OPENAI_API_KEY
environment
variable with the value set in my local environment
($OPENAI_API_KEY
)
We also expose port 8080 with the -p 8080:8080
option.
docker run -e OPENAI_API_KEY=$OPENAI_API_KEY -p 8080:8080 my-langserve-app