Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Agentica server + Claude proxy setup - architecture, startup sequence, debugging
.claude/skills/agentica-server/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-01 | ✗→✓ | ▲ Improved | 1% | 0% |
| case-02 | ✗→✓ | ▲ Improved | 3% | 0% |
| case-03 | ✗→✓ | ▲ Improved | 1% | 0% |
| case-04 | ✗→✓ | ▲ Improved | 4% | 0% |
| case-05 | ✗→✓ | ▲ Improved | 9% | 0% |
Complete reference for running Agentica SDK with a local Claude proxy. This enables Python agents to use Claude CLI as their inference backend.
Use this skill when:
Agentica SDK (client code)
| S_M_BASE_URL=http://localhost:2345
v
ClientSessionManager
|
v
Agentica Server (agentica-server)
| INFERENCE_ENDPOINT_URL=http://localhost:8080/v1/chat/completions
v
Claude Proxy (claude_proxy.py)
|
v
Claude CLI (claude -p)| Variable | Set By | Used By | Purpose | |----------|--------|---------|---------| | INFERENCE_ENDPOINT_URL | Human | agentica-server | Where server sends LLM inference requests | | S_M_BASE_URL | Human | Agentica SDK client | Where SDK connects to session manager |
KEY: These are NOT the same endpoint!
Must start in this order (each in a separate terminal):
bashuv run python scripts/agentica/claude_proxy.py --port 8080
MUST run from its directory:
bashcd workspace/agentica-research/agentica-server INFERENCE_ENDPOINT_URL=http://localhost:8080/v1/chat/completions uv run agentica-server --port 2345
bashS_M_BASE_URL=http://localhost:2345 uv run python scripts/agentica/your_script.py
bash# Claude proxy health curl http://localhost:8080/health # Agentica server health curl http://localhost:2345/health
Symptom: Agent spawns successfully but fails on first call with connection error.
Cause: Claude proxy returning plain JSON instead of SSE format.
Fix: Proxy must return Server-Sent Events format:
data: {"choices": [...]}\n\nSymptom: ModuleNotFoundError: No module named 'agentica_server'
Cause: Running uv run agentica-server from wrong directory.
Fix: Must cd workspace/agentica-research/agentica-server first.
Symptom: Agent asks for file contents instead of reading them.
Cause: Missing --allowedTools in claude_proxy.py CLI call.
Fix: Proxy must pass tool permissions:
bashclaude -p ... --allowedTools Read Write Edit Bash
Symptom: Agent says "I've created the file" but file doesn't exist.
Cause: Hallucination - agent describing intended actions without executing.
Fix: Added emphatic anti-hallucination prompt in REPL_BASELINE:
CRITICAL: Use ACTUAL tools. Never DESCRIBE using tools.Symptom: Call hangs for 30+ seconds then times out.
Cause: Claude CLI taking too long or stuck in a loop.
Fix: Check proxy logs for the actual CLI output. May need to simplify prompt.
| File | Purpose | |------|---------| | scripts/agentica/claude_proxy.py | OpenAI-compatible proxy with SSE streaming | | workspace/agentica-research/agentica-server/ | Local agentica-server installation | | scripts/agentica/PATTERNS.md | Multi-agent pattern documentation |
Test the full stack:
bash# 1. Verify proxy responds curl http://localhost:8080/health # 2. Verify server responds curl http://localhost:2345/health # 3. Test inference through proxy curl http://localhost:8080/v1/chat/completions \ -H "Content-Type: application/json" \ -d '{"model":"claude","messages":[{"role":"user","content":"Say hello"}]}'
Before running agents:
S_M_BASE_URL set for client scriptsINFERENCE_ENDPOINT_URL set for server| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-01 | fail→pass | 13,187 | 6,769 | -49% | 1 | 1 | 0% | 2,719 | 2,739 | +1% | 0 | 0 | — |
case-02 | fail→pass | 18,663 | 9,572 | -49% | 1 | 1 | 0% | 2,885 | 2,965 | +3% | 0 | 0 | — |
case-03 | fail→pass | 13,350 | 7,538 | -44% | 1 | 1 | 0% | 2,829 | 2,847 | +1% | 0 | 0 | — |
case-04 | fail→pass | 9,819 | 2,816 | -71% | 1 | 1 | 0% | 1,736 | 1,798 | +4% | 0 | 0 | — |
case-05 | fail→pass | 7,633 | 1,839 | -76% | 1 | 1 | 0% | 1,393 | 1,519 | +9% | 0 | 0 | — |
case-06 | fail→pass | 9,011 | 2,357 | -74% | 1 | 1 | 0% | 1,688 | 1,510 | -11% | 0 | 0 | — |
case-07 | fail→pass | 8,252 | 1,631 | -80% | 1 | 1 | 0% | 1,571 | 1,448 | -8% | 0 | 0 | — |
case-08 | fail→pass | 7,798 | 1,519 | -81% | 1 | 1 | 0% | 1,493 | 1,421 | -5% | 0 | 0 | — |
case-09 | fail→pass | 5,827 | 2,911 | -50% | 1 | 1 | 0% | 1,091 | 1,532 | +40% | 0 | 0 | — |
case-10 | fail→pass | 13,313 | 2,129 | -84% | 1 | 1 | 0% | 2,344 | 1,563 | -33% | 0 | 0 | — |
case-11 | pass→pass | 5,954 | 2,509 | -58% | 1 | 1 | 0% | 1,150 | 1,637 | +42% | 0 | 0 | — |
case-12 | fail→pass | 15,459 | 1,799 | -88% | 1 | 1 | 0% | 3,061 | 1,468 | -52% | 0 | 0 | — |
case-13 | fail→pass | 9,178 | 1,257 | -86% | 1 | 1 | 0% | 1,431 | 1,376 | -4% | 0 | 0 | — |
case-14 | fail→pass | 13,223 | 1,427 | -89% | 1 | 1 | 0% | 1,341 | 1,406 | +5% | 0 | 0 | — |
case-15 | fail→pass | 5,802 | 2,365 | -59% | 1 | 1 | 0% | 972 | 1,542 | +59% | 0 | 0 | — |
case-16 | fail→pass | 8,564 | 3,785 | -56% | 1 | 1 | 0% | 1,747 | 1,939 | +11% | 0 | 0 | — |
case-17 | fail→pass | 9,509 | 3,004 | -68% | 1 | 1 | 0% | 1,530 | 1,726 | +13% | 0 | 0 | — |
case-18 | fail→pass | 4,050 | 1,327 | -67% | 1 | 1 | 0% | 646 | 1,381 | +114% | 0 | 0 | — |
case-19 | fail→pass | 10,409 | 2,893 | -72% | 1 | 1 | 0% | 1,790 | 1,820 | +2% | 0 | 0 | — |
case-20 | pass→pass | 13,999 | 9,693 | -31% | 1 | 1 | 0% | 2,909 | 3,298 | +13% | 0 | 0 | — |
case-21 | pass→pass | 8,590 | 7,460 | -13% | 1 | 1 | 0% | 1,626 | 2,731 | +68% | 0 | 0 | — |
case-22 | pass→pass | 8,883 | 6,595 | -26% | 1 | 1 | 0% | 1,881 | 2,641 | +40% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 22 cases were attempted. The headline lift of +82 percentage points is the difference between those two pass rates over the 22 comparable cases.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
| Model | Method | Date | Lift |
|---|---|---|---|
| gemini-3.6-flash | verified | 7/30/2026 | +55% |
Other measured skills in the registry, with their headline benchmark lift.