- Rewrote extractUsageFromSSE() to parse data: lines directly instead of
buggy indexOf-based event/data pairing that silently failed for Z.ai
and DeepSeek SSE formats
- Always call recordUsage() on successful responses even when token
extraction yields 0 — ensures request counts are tracked
- Added console.warn when token extraction fails for debugging
- Use wildcard notation in routing table (claude-opus-*, claude-sonnet-*, etc.)
with note about prefix matching and pointer to CONTEXT.md for full table
- Clarify that deploy.sh runs on mini-server, not the laptop
- Add .gitignore to the Files table
- Add .clinerules symlink → CLAUDE.md so Roo Code reads same project context
- Add sync-context.sh: copies global context to ~/.claude/ for Claude Code
and prints content for manual paste into Roo Code Custom Instructions
- Update CLAUDE.md: note .clinerules symlink, add sync-context.sh to file list
- Update CONTEXT.md: add AI context file mapping table, update file structure
- Update README.md: rewrite AI Context Files section to cover both tools,
document symlink strategy and sync workflow
Add 'AI Context Files' section to README explaining the three-tier
context system (global, project-level, detailed reference) and the
workflow for updating and deploying the global CLAUDE.md file.
- Renumber deploy.sh steps from [1/5]-[4/5] to [1/4]-[4/4] (step 5 was removed)
- Add 'Finding Your Auth Token' section to README.md explaining how to
retrieve the authToken from config.json on mini-server
- Architecture flow diagram showing how requests are routed
- Complete routing table with cost model info
- Setup instructions (install, run, deploy as service)
- Caddy reverse proxy example with SSE flush_interval note
- Client configuration for Claude Code CLI and Roo Code
- API documentation (health check, messages endpoint)
- Important notes: thinking-block switching, MCP client-side, adding routes
- Updated file listing with all new context files
- Add CONTEXT.md: Full infrastructure documentation with architecture diagram,
routing table, network details, common operations, and important limitations
- Add CLAUDE.md: Project-level context for AI agents working in this codebase
- Add global-claude-md/CLAUDE.md: User-level global context for ~/.claude/
- Delete nginx-ai-proxy.conf: Unused, Caddy replaced nginx on big-server
- Update deploy.sh: Remove stale nginx setup step, update domain to ai.ein-softworks.com
- Update README.md: Remove nginx-ai-proxy.conf from files list, update domain,
and remove leaked auth token from example
Context files provide persistent reference for AI coding sessions across
all projects and the ein-ai-proxy codebase specifically.
Anthropic-compatible API proxy that routes requests to multiple
providers (Anthropic, Z.ai/GLM-4.7, DeepSeek V3.2) based on
model name. Zero dependencies, SSE streaming, bearer token auth.
Designed to run behind Caddy/nginx on a home server, enabling
Claude Code and Roo Code clients to connect from anywhere.