SilverElixir commited on
Commit
f843552
·
1 Parent(s): b367f07

Add session hygiene rules and lumen_model_speed to AGENTS.md

Browse files
Files changed (1) hide show
  1. AGENTS.md +6 -1
AGENTS.md CHANGED
@@ -9,7 +9,7 @@
9
 
10
  ## What this repo is
11
  - Lumen: a Telegram bot (persona styled after Claude) running as a single FastAPI + aiogram webhook service on a Hugging Face Space (Docker). LLM backbone: Google Gemini + free OpenRouter models with per-message routing.
12
- - Entry point is bot.py (orchestrator, ~5000 lines). Focused modules sit next to it: lumen_router_config.py (model routing), lumen_formatting.py (markdown to Telegram HTML), lumen_security.py (injection/leak defenses), lumen_images.py, lumen_tts.py, lumen_tiktok.py, lumen_telegram_transport.py, lumen_state_storage.py, lumen_typing_pace.py, plus system_prompt.py.
13
 
14
  ## Commands (verified against CI, .github/workflows/ci.yml)
15
  - Full gate: pip install -r requirements.txt -r requirements-dev.txt; pyflakes bot.py lumen_*.py system_prompt.py conftest.py test_*.py; pytest -q; pip-audit -r requirements.txt
@@ -19,3 +19,8 @@
19
  ## Gotchas
20
  - Every push to main that passes CI auto-deploys to the live HF Space (.github/workflows/sync-to-hf.yml waits for the CI workflow, then force-pushes the checked commit). A green CI run is a deploy.
21
  - Versions in requirements.txt are pinned with == (HF rebuilds the image from scratch on every deploy; see the file header comment). Bumping a version is a deliberate decision followed by a manual smoke test (/diag + main commands), not a side effect.
 
 
 
 
 
 
9
 
10
  ## What this repo is
11
  - Lumen: a Telegram bot (persona styled after Claude) running as a single FastAPI + aiogram webhook service on a Hugging Face Space (Docker). LLM backbone: Google Gemini + free OpenRouter models with per-message routing.
12
+ - Entry point is bot.py (orchestrator, ~5000 lines). Focused modules sit next to it: lumen_router_config.py (model routing), lumen_formatting.py (markdown to Telegram HTML), lumen_security.py (injection/leak defenses), lumen_images.py, lumen_tts.py, lumen_tiktok.py, lumen_telegram_transport.py, lumen_state_storage.py, lumen_typing_pace.py, lumen_model_speed.py (measured model latency), plus system_prompt.py.
13
 
14
  ## Commands (verified against CI, .github/workflows/ci.yml)
15
  - Full gate: pip install -r requirements.txt -r requirements-dev.txt; pyflakes bot.py lumen_*.py system_prompt.py conftest.py test_*.py; pytest -q; pip-audit -r requirements.txt
 
19
  ## Gotchas
20
  - Every push to main that passes CI auto-deploys to the live HF Space (.github/workflows/sync-to-hf.yml waits for the CI workflow, then force-pushes the checked commit). A green CI run is a deploy.
21
  - Versions in requirements.txt are pinned with == (HF rebuilds the image from scratch on every deploy; see the file header comment). Bumping a version is a deliberate decision followed by a manual smoke test (/diag + main commands), not a side effect.
22
+
23
+ ## Session hygiene (guide the owner proactively, they don't track this)
24
+ - Effort: at the start of each task, state which effort fits and why, then proceed on their OK. Low: read/explain/rename; Medium (default): single-module fixes, tests, docs; High: streaming/security/refactor; XHigh: audits, architecture, prod incidents.
25
+ - New chat: suggest starting one when the topic changes completely or the session mixes several unrelated tasks.
26
+ - Compactness: suggest `/compact` (or a fresh chat) when the session gets long — many files read, repeated re-reads, or signs of lost context.