feat: persist orchestrator sessions + user service + docs update

- Orchestrator now saves turns to session store so history survives page refresh
- UI session_id updated from job result; history controls attached to agent turns
- Cortex migrated from system service to systemd user service (no more sudo)
- Update README.md and CLAUDE.md with correct service commands

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Scott Idem
2026-03-18 23:08:38 -04:00
parent 5b5586656f
commit aaac3e1353
4 changed files with 44 additions and 16 deletions

View File

@@ -23,22 +23,26 @@ Cortex is a self-hosted multi-agent orchestration layer. Inara is the primary co
## Running Cortex
Cortex runs as a **systemd user service** (no sudo required).
```bash
# Start (Docker)
cd ~/agents_sync/projects/Cortex_and_Inara_dev
docker compose up -d
# Start / stop / restart
systemctl --user start cortex
systemctl --user stop cortex
systemctl --user restart cortex
# Restart service only (after backend changes)
sudo systemctl restart cortex
# Logs
journalctl -u cortex -f
# Status and logs
systemctl --user status cortex
journalctl --user -u cortex -f
# Web UI
http://localhost:8000 (or cortex.dgrzone.com on WireGuard)
```
Config lives in `cortex/config.py` and a `.env` file at the project root (not tracked — see `env.default`).
The service starts automatically at boot via `loginctl enable-linger`.
Service file: `~/.config/systemd/user/cortex.service`
Config lives in `cortex/config.py` and a `.env` file at the project root (not tracked — see `.env.default`).
---