mirror of
https://github.com/langchain-ai/langchain.git
synced 2026-10-09 03:15:19 +03:00
+26









Erick Friis
Harrison Chase
jacoblee93
Leonid Ganeline
Leonid Kuligin
Averi Kitsch
Nuno Campos
Nuno Campos
Bagatur
Eugene Yurtsev
Martín Gotelli Ferenaz
Fayfox
Eugene Yurtsev
Dawson Bauer
Ravindu Somawansa
Dhruv Chawla
ccurme
Bagatur
WeichenXu
Benito Geordie
kartikTAI
Kartik Sarangmath
Sevin F. Varoglu
MacanPN
Prashanth Rao
Hyeongchan Kim
sdan
Guangdong Liu
Rahul Triptahi
Rahul Tripathi
pjb157
Eun Hye Kim
kaijietti
Pengcheng Liu
Tomer Cagan
Christophe Bornet
21d14549a9
current python.langchain.com is building from branch `v0.1`. Iterate on v0.2 docs here. --------- Signed-off-by: Weichen Xu <weichen.xu@databricks.com> Signed-off-by: Rahul Tripathi <rauhl.psit.ec@gmail.com> Co-authored-by: Harrison Chase <hw.chase.17@gmail.com> Co-authored-by: jacoblee93 <jacoblee93@gmail.com> Co-authored-by: Leonid Ganeline <leo.gan.57@gmail.com> Co-authored-by: Leonid Kuligin <lkuligin@yandex.ru> Co-authored-by: Averi Kitsch <akitsch@google.com> Co-authored-by: Nuno Campos <nuno@langchain.dev> Co-authored-by: Nuno Campos <nuno@boringbits.io> Co-authored-by: Bagatur <22008038+baskaryan@users.noreply.github.com> Co-authored-by: Eugene Yurtsev <eyurtsev@gmail.com> Co-authored-by: Martín Gotelli Ferenaz <martingotelliferenaz@gmail.com> Co-authored-by: Fayfox <admin@fayfox.com> Co-authored-by: Eugene Yurtsev <eugene@langchain.dev> Co-authored-by: Dawson Bauer <105886620+djbauer2@users.noreply.github.com> Co-authored-by: Ravindu Somawansa <ravindu.somawansa@gmail.com> Co-authored-by: Dhruv Chawla <43818888+Dominastorm@users.noreply.github.com> Co-authored-by: ccurme <chester.curme@gmail.com> Co-authored-by: Bagatur <baskaryan@gmail.com> Co-authored-by: WeichenXu <weichen.xu@databricks.com> Co-authored-by: Benito Geordie <89472452+benitoThree@users.noreply.github.com> Co-authored-by: kartikTAI <129414343+kartikTAI@users.noreply.github.com> Co-authored-by: Kartik Sarangmath <kartik@thirdai.com> Co-authored-by: Sevin F. Varoglu <sfvaroglu@octoml.ai> Co-authored-by: MacanPN <martin.triska@gmail.com> Co-authored-by: Prashanth Rao <35005448+prrao87@users.noreply.github.com> Co-authored-by: Hyeongchan Kim <kozistr@gmail.com> Co-authored-by: sdan <git@sdan.io> Co-authored-by: Guangdong Liu <liugddx@gmail.com> Co-authored-by: Rahul Triptahi <rahul.psit.ec@gmail.com> Co-authored-by: Rahul Tripathi <rauhl.psit.ec@gmail.com> Co-authored-by: pjb157 <84070455+pjb157@users.noreply.github.com> Co-authored-by: Eun Hye Kim <ehkim1440@gmail.com> Co-authored-by: kaijietti <43436010+kaijietti@users.noreply.github.com> Co-authored-by: Pengcheng Liu <pcliu.fd@gmail.com> Co-authored-by: Tomer Cagan <tomer@tomercagan.com> Co-authored-by: Christophe Bornet <cbornet@hotmail.com>
84 lines
2.8 KiB
Makefile
84 lines
2.8 KiB
Makefile
# we build the docs in these stages:
|
|
# 1. install vercel and python dependencies
|
|
# 2. copy files from "source dir" to "intermediate dir"
|
|
# 2. generate files like model feat table, etc in "intermediate dir"
|
|
# 3. copy files to their right spots (e.g. langserve readme) in "intermediate dir"
|
|
# 4. build the docs from "intermediate dir" to "output dir"
|
|
|
|
SOURCE_DIR = docs/
|
|
INTERMEDIATE_DIR = build/intermediate/docs
|
|
|
|
OUTPUT_NEW_DIR = build/output-new
|
|
OUTPUT_NEW_DOCS_DIR = $(OUTPUT_NEW_DIR)/docs
|
|
|
|
PYTHON = .venv/bin/python
|
|
|
|
PARTNER_DEPS_LIST := $(shell ls -1 ../libs/partners | grep -vE "airbyte|ibm" | xargs -I {} echo "../libs/partners/{}" | tr '\n' ' ')
|
|
|
|
PORT ?= 3001
|
|
|
|
clean:
|
|
rm -rf build
|
|
|
|
install-vercel-deps:
|
|
yum -y update
|
|
yum install gcc bzip2-devel libffi-devel zlib-devel wget tar gzip rsync -y
|
|
|
|
install-py-deps:
|
|
python3 -m venv .venv
|
|
$(PYTHON) -m pip install --upgrade pip
|
|
$(PYTHON) -m pip install --upgrade uv
|
|
$(PYTHON) -m uv pip install -r vercel_requirements.txt
|
|
$(PYTHON) -m uv pip install --editable $(PARTNER_DEPS_LIST)
|
|
|
|
generate-files:
|
|
mkdir -p $(INTERMEDIATE_DIR)
|
|
cp -r $(SOURCE_DIR)/* $(INTERMEDIATE_DIR)
|
|
mkdir -p $(INTERMEDIATE_DIR)/templates
|
|
cp ../templates/docs/INDEX.md $(INTERMEDIATE_DIR)/templates/index.md
|
|
cp ../cookbook/README.md $(INTERMEDIATE_DIR)/cookbook.mdx
|
|
|
|
$(PYTHON) scripts/model_feat_table.py $(INTERMEDIATE_DIR)
|
|
|
|
$(PYTHON) scripts/copy_templates.py $(INTERMEDIATE_DIR)
|
|
|
|
wget -q https://raw.githubusercontent.com/langchain-ai/langserve/main/README.md -O $(INTERMEDIATE_DIR)/langserve.md
|
|
$(PYTHON) scripts/resolve_local_links.py $(INTERMEDIATE_DIR)/langserve.md https://github.com/langchain-ai/langserve/tree/main/
|
|
|
|
wget -q https://raw.githubusercontent.com/langchain-ai/langgraph/main/README.md -O $(INTERMEDIATE_DIR)/langgraph.md
|
|
$(PYTHON) scripts/resolve_local_links.py $(INTERMEDIATE_DIR)/langgraph.md https://github.com/langchain-ai/langgraph/tree/main/
|
|
|
|
$(PYTHON) scripts/generate_api_reference_links.py --docs_dir $(INTERMEDIATE_DIR)
|
|
|
|
copy-infra:
|
|
mkdir -p $(OUTPUT_NEW_DIR)
|
|
cp -r src $(OUTPUT_NEW_DIR)
|
|
cp vercel.json $(OUTPUT_NEW_DIR)
|
|
cp babel.config.js $(OUTPUT_NEW_DIR)
|
|
cp -r data $(OUTPUT_NEW_DIR)
|
|
cp docusaurus.config.js $(OUTPUT_NEW_DIR)
|
|
cp package.json $(OUTPUT_NEW_DIR)
|
|
cp sidebars.js $(OUTPUT_NEW_DIR)
|
|
cp -r static $(OUTPUT_NEW_DIR)
|
|
cp yarn.lock $(OUTPUT_NEW_DIR)
|
|
|
|
render:
|
|
$(PYTHON) scripts/notebook_convert.py $(INTERMEDIATE_DIR) $(OUTPUT_NEW_DOCS_DIR)
|
|
|
|
md-sync:
|
|
rsync -avm --include="*/" --include="*.mdx" --include="*.md" --include="*.png" --exclude="*" $(INTERMEDIATE_DIR)/ $(OUTPUT_NEW_DOCS_DIR)
|
|
|
|
build: install-py-deps generate-files copy-infra render md-sync
|
|
|
|
vercel-build: install-vercel-deps build
|
|
rm -rf docs
|
|
mv $(OUTPUT_NEW_DOCS_DIR) docs
|
|
rm -rf build
|
|
yarn run docusaurus build
|
|
mv build v0.2
|
|
mkdir build
|
|
mv v0.2 build
|
|
|
|
start:
|
|
cd $(OUTPUT_NEW_DIR) && yarn && yarn start --port=$(PORT)
|