8.4 KiB
8.4 KiB
Claude Code Context — 2026-04-29
Last Updated: 2026-04-29 ~20:30 (Session ongoing)
Session Type: LLM Gateway / Codex Bridge Handoff
Working Directory: /Users/renefichtmueller/Desktop/Claude Code
Model: Haiku 4.5 (default), Opus for deep reasoning
Context Window: Using lean-ctx MCP for compression
Session Status
Latest Verified State — 2026-05-12
- Public gateway is reachable:
/api/dashboard/healthreturnsok, databaseconnected./v1/modelsreturns the configured model list./v1/chat/completionsaccepted a live smoke request from callercodex-live-gateway-checkand returnedgateway-check-ok.
- Tracking works for requests that actually enter the gateway:
- Smoke request was recorded in
/api/dashboard/requests. - 24h metrics showed
8tracked requests, all routed toqwen2.5:14b. - Compression metrics are recorded, but current 24h savings were low:
25tokens saved across3compression operations.
- Smoke request was recorded in
- Not everything is currently going through the gateway:
codex-desktopis markedlivebecause of tracked gateway callers, but the configured MacStudio bridgehttp://192.168.178.213:3253was unreachable from Erik during the check.microsoft-copilotis running locally but has0gateway requests and the configured MacStudio bridgehttp://192.168.178.213:3257was unreachable from Erik.- GitHub Copilot bridge is running but returns
auth_required. - M365 Copilot bridge is running but returns
auth_required/ missing Microsoft Graph auth. - Claude bridge is healthy and ready.
- Security note:
- Starting local Codex Bridge on
0.0.0.0via PM2 was blocked by policy because it would expose local Codex access on the LAN. Use explicit approval plus a narrow network rule or a safer tunnel approach before enabling this persistently.
- Starting local Codex Bridge on
Active Work
- Scope: Sync all chat history + context into
sync/handoff folder for Codex integration - Repos Modified: llm-gateway (sync/* only, no code changes)
- Branch: main (no branching, sync/* only)
Current Tasks
- ✅ Create
sync/README.md— handoff format documentation - ⏳ Create
sync/CURRENT.md— this file, current status - ⏳ Create
sync/history/2026-04-29-sync-handoff.md— session snapshot - ⏳ Git commit sync/* files
- ⏳ Git push to Gitea (origin main)
- ⏳ Notify Codex via handoff mechanism
Blockers
- None — proceed with autonomous execution (per Memory: no confirmations needed)
Key Context
Projects Active
-
LLM Gateway (
/llm-gateway/)- Stack: Fastify TypeScript monorepo (gateway + learning + client + fine-tuner)
- Live: https://llm-gateway.context-x.org (Port 3103 on Erik)
- DB: PostgreSQL llm_gateway on Erik (user: llm, pw: llm_secure_2026)
- Last Deploy: 2026-04-09 (23-dimension request scoring + free LLM fallback chain)
- Status: ✅ Running (PM2 id 19+20)
- Codex Bridge: New in this session —
/copilot-bridge/server.jsfor Codex integration
-
Transceiver Intelligence Platform (TIP) (
github-repos/transceiver-db/)- Live: https://transceiver-db.fichtmueller.org
- Stack: PostgreSQL 17 + TimescaleDB + Qdrant + Cloudflare R2
- Features: Real-time pricing, Norton-Bass Hype Cycle, FAQ/KB, MCP Server
- Blog LLM: claude-bridge provider (switched from Ollama 2026-04-09)
- Status: ✅ Functional
-
MAGATAMA Security Platform (in planning)
- Status: S6 SHIN (ShieldX) + S2 TEN (ShieldY) functional
- Next: S1/S3/S4/S5/S7 planning
- Obsidian Docs:
/Users/renefichtmueller/Documents/ObsidianBrain/projects/magatama/wiki/
Erik / Infrastructure Status
SSH Access
- Primary: Port 22 (via UFW ALLOW from Rene home IP 83.135.64.79)
- Backup: Port 2222 (systemd drop-in)
- WireGuard: jumphost for remote access
- Serial Console: sossh-rhr.online-server.cloud (IONOS OOB)
Running Services (Erik .82)
- ✅ PostgreSQL 17 (llm_gateway, ctxmeet, others)
- ✅ Proxmox (infrastructure, .10)
- ✅ Ollama (via https://ollama.fichtmueller.org)
- ✅ PM2 Services:
- id 19+20: LLM Gateway (port 3103)
- id 41: claude-bridge (port 3250)
- peercortex (port 3101)
- ctxevent/nognet (port 3001)
- ⚠️ ShieldY: Unknown status — 846 restarts on Mac Studio (blocked until fixed)
Security Notes
- ✅ SSH UFW rules: home IP whitelisted (Rule #1, #2 before LIMIT)
- ✅ Backups: Daily to Fearghas (12h,
/opt/scripts/daily-backup-fearghas.sh) - ⚠️ SFTP: Disabled on Synology (workaround:
scp -Olegacy mode in backup script)
Changed Files (Uncommitted)
From git status in llm-gateway:
Modified (code changes — NOT STAGED for sync commit):
- Dockerfile, docker-compose.yaml
- copilot-bridge/server.js
- deploy/ecosystem.config.cjs, package-lock.json
- packages/gateway/package.json, public/dashboard.html
- packages/gateway/src/config/models.yaml
- packages/gateway/src/modules/request-logger.ts
- packages/gateway/src/pipeline/* (3 files)
- packages/gateway/src/routes/* (3 files)
- packages/gateway/src/security/tls-config.ts
- packages/gateway/src/server.ts
- packages/gateway/src/utils/tokenvault-hooks.ts
Untracked Dirs (NEW):
- codex-bridge/
- m365-copilot-bridge/
- packages/browser-extension/
- packages/companion/
- packages/mcp-router/, packages/mcp-server/, packages/mcp-tools/
Untracked Files (DB migrations + modules):
- 004-semantic-cache.sql, 005-fuzzy-cache.sql, 006-mcp-tool-calls.sql
- admin-auth.ts, bridge-spawner.ts, caller-detection.ts, caller-stats.ts
- context-compressor.ts, embedding-client.ts, gamification.ts
- knowledge-memory.ts, memory-graph.ts, race-leaderboard.ts, race-mode.ts
- report-generator.ts, response-cache.ts, savings-calculator.ts
- settings-store.ts, share-card.ts, subscription-discovery.ts
- subscription-wallet.ts
⚠️ POLICY: Only sync/* files committed/pushed in this session. Code changes staged separately (AFTER code review).
Next Safe Steps (for Codex / Next Claude Session)
Immediate (Safe to Execute)
- ✅
git add sync/*— stage handoff files only - ✅
git commit -m "sync: add chat handoff for Codex integration (2026-04-29)"— commit - ✅
git push origin main— push to Gitea
Code Review (After Handoff)
- Review copilot-bridge/server.js + new packages/* (code-reviewer agent)
- Security scan all new modules (security-reviewer agent)
- Stage + commit code changes in separate PR (per development-workflow.md)
- Deploy to Erik after approval
Codex Integration
- Codex reads this CURRENT.md on session start
- Codex continues with code review workflow (not skipping security)
- Codex pushes new history entry at session end
Warnings / Blockers
🔴 CRITICAL
- ShieldY Mac Studio: 846 restarts — MUST FIX before production deployment
- Issue: Unknown crash pattern
- Next: Use debug skill to diagnose, then build-fix agent
- Blocked: MAGATAMA deployment until resolved
🟡 MEDIUM
- Codex Bridge: New component, needs security scan + testing
- m365-copilot-bridge: New (untracked), purpose unknown — document + review
- UFW SSH Rate Limiting: Rene home IP whitelisted, but new IPs could get blocked
- Workaround:
ufw insert 1 allow from <ip> to any port 22
- Workaround:
🟢 LOW
- SFTP disabled on Synology — currently using scp -O workaround (acceptable)
- Ollama tunnel via Cloudflare (no direct IP) — acceptable for current load
Instructions for Codex / Next Session
On Session Start:
cd /Users/renefichtmueller/Desktop/Claude\ Code/llm-gateway- Read
sync/CURRENT.md(this file) — has all context git status— should show only modifications (code) + untracked (code)- Proceed with code review workflow (DON'T skip security)
On Session End:
- Create new
sync/history/YYYY-MM-DD-topic.mdentry (copy template below) - Update
sync/CURRENT.mdwith new status git add sync/* && git commit ... && git push(sync/* only)- Code commits handled separately (per development-workflow.md)
History Entry Template:
# Session: [Topic] — 2026-04-DD
**Duration:** HH:MM
**Agent:** Codex / Claude Code Opus
**Status:** ✅ Complete / ⏳ Ongoing / ❌ Blocked
## Achievements
- [ ] Task 1
- [ ] Task 2
## Remaining
- [ ] Task 3 (blockers: X)
- [ ] Task 4 (next: Y)
## Files Changed
- code/* — staged for review
- sync/* — handoff updated
## Context Used
- ~XXX tokens (Haiku / Opus)
- Lean-ctx compression: Y% savings
End of CURRENT.md