Files
auto_agent/README.md
T

26 lines
902 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
python -m venv myenv
source myenv/bin/activate || myenv/Scripts/activate
python -m pip install --upgrade pip
pip install -U langchain langchain-openai dotenv
pip install -e .(详情见pyproject.toml)
pip install langgraph-cli[inmem]
pip install sqlalchemy pymysql loguru psycopg2-binary(postgresql) *可选数据库开发
# Environment
Copy `.env.example` to `.env` and fill in the required values before running the app.
cp .env.example .env
# Required variables
# - LLM_BASE_URL
# - LLM_API_KEY
# - LLM_MODEL
# Web 对话(推荐):在 ``Agent`` 目录下保证 ``PYTHONPATH`` 包含 ``src`` 后执行
cd ./Agent
uvicorn agent.web.server:app --host 127.0.0.1 --port 8765
# 发送消息为两阶段 API:``POST /api/chat/start``(立即落盘用户消息)+ ``POST /api/chat/complete``(推理);前端已按此顺序调用。
cloudflared tunnel --url http://localhost:8765开公网