lewtun HF Staff Codex commited on
Commit
a727a3e
·
1 Parent(s): f2bbd92

Document uv local setup and ignore local runtime files

Browse files
Files changed (2) hide show
  1. .gitignore +4 -0
  2. README.md +14 -0
.gitignore ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ .venv/
2
+ __pycache__/
3
+ *.py[cod]
4
+ scratch/
README.md CHANGED
@@ -13,3 +13,17 @@ which of PyBot's modules and files produced each reply. Pinned to commit `64eb2c
13
 
14
  `app.py` serves `site/` and `POST /api/chat` / `POST /api/trace`; `bot/bot-<sha12>.zip` holds the bot's source (`bot/**.py` only);
15
  `bot_runner.py` runs it in a fresh worker per request. Built by `build_pybot.py` in the swarmchat-release workspace.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
13
 
14
  `app.py` serves `site/` and `POST /api/chat` / `POST /api/trace`; `bot/bot-<sha12>.zip` holds the bot's source (`bot/**.py` only);
15
  `bot_runner.py` runs it in a fresh worker per request. Built by `build_pybot.py` in the swarmchat-release workspace.
16
+
17
+ ## Run locally
18
+
19
+ Use Python 3.12 (required by the trace endpoint) on macOS or Linux:
20
+
21
+ ```sh
22
+ uv venv --python 3.12 .venv
23
+ source .venv/bin/activate
24
+ uv pip install -r requirements.txt
25
+ uvicorn app:app --host 127.0.0.1 --port 7860
26
+ ```
27
+
28
+ Open http://127.0.0.1:7860. The health endpoint is `/health`.
29
+ Keep local logs and temporary files in `scratch/`, which is ignored by Git.