Skip to main content

CLI for interacting with LangChain

Project description

langchain-cli

Install CLI

pip install -U --pre langchain-cli

Create new langchain app

langchain serve new my-app

Go into app

cd my-app

Install a package

langchain serve add extraction-summary

(Activate virtualenv)

Install langserve

pip install "langserve[all]"

Install the langchain package

pip install -e packages/extraction-summary

Edit app/server.py to add that package to the routes

from fastapi import FastAPI
from langserve import add_routes 
from extraction_summary.chain import chain

app = FastAPI()

add_routes(app, chain)

Run the app

python app/server.py

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

langchain_cli-0.0.1rc4.tar.gz (8.5 kB view hashes)

Uploaded Source

Built Distribution

langchain_cli-0.0.1rc4-py3-none-any.whl (14.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page