The agent engineering platform.
Python agentsaiai-agentsanthropicchatgptdeepagentsenterpriseframeworkgeminigenerative-ailangchainlanggraphllmmultiagentopen-sourceopenaipydanticpythonragtypescript
IMPROVEMENT redirect root to docs in langserve app template (#13303)
Erick Friis280ecfd8ebf4
diff --git a/libs/cli/langchain_cli/project_template/app/server.py b/libs/cli/langchain_cli/project_template/app/server.pyindex 7347b80458..7ee36a9144 100644--- a/libs/cli/langchain_cli/project_template/app/server.py+++ b/libs/cli/langchain_cli/project_template/app/server.py@@ -1,8 +1,15 @@from fastapi import FastAPI+from fastapi.responses import RedirectResponsefrom langserve import add_routesapp = FastAPI()+[email protected]("/")+async def redirect_root_to_docs():+ return RedirectResponse("/docs")++# Edit this to add the chain you want to addadd_routes(app, NotImplemented)