WikifitaGitHub live67e8de5
projeto · infraestrutura/claude-desktop-infra-stack

Claude Desktop — Infrastructure Stack

Documentation: Claude Desktop — Infrastructure Stack

Baixar raw

Claude Desktop — Infrastructure Stack

Proposed architecture for the complete ecosystem: Claude Desktop 3p → Gateway → Providers.

Stack Atual

docker compose (bridge: probe-net)
├── gateway       :4000  → Litellm fork, Anthropic↔OpenAI translation, SSE, WebSocket voice
├── searxng       :8888  → Private meta-search
├── crawl4ai      :11235 → Web crawling
└── caddy         :8443  → HTTPS reverse proxy (localhost → gateway:4000)

Proposed Stack

docker compose (bridge: probe-net)
├── gateway       :4000  → Litellm fork
│   ├── /v1/models              → Model discovery with supports1m
│   ├── /v1/chat/completions    → Anthropic→MiMo/DeepSeek translation
│   ├── /v1/voice               → WebSocket STT/TTS (OPUS↔PCM via ffmpeg)
│   ├── /api/desktop/features   → GrowthBook adapter
│   └── /api/ws/voice/...       → Voice WebSocket (path Anthropic)
├── growthbook    :3000  → Feature flag management (web UI)
├── mongo         :27017 → GrowthBook database
├── searxng       :8888  → Private meta-search
├── crawl4ai      :11235 → Web crawling
└── caddy         :8443  → HTTPS reverse proxy

GrowthBook Integration

Why GrowthBook?

  • Ready-made Web UI for managing 226 feature flags
  • Open source, self-hosted
  • Simple docker compose (growthbook + mongo)
  • Enables iterative experimentation with flags
  • Reusable for future projects (Camdom, etc.)

Gateway Adapter

The app expects:

GET /api/desktop/features → { features: { "ID": { on, value, source } } }

GrowthBook returns a different format. A ~30-line adapter translates:

GrowthBook API → Anthropic Feature Format → app

Flags to Configure (Priority)

Feature IDNameAction
1985784543voice:setup-voice-skillEnable on:true
1928275548chillingSlothFeatEnable on:true (1p/3p gap)
4116586025computer-use-availabilityAdd on:true
2976814254ccd-builtin-toolsEnable on:true (V3i)
3246569822can-save-skillEnable on:true (V3i)
1696890383cowork-memory-guidelinesEnable on:true (V3i)
2307090146plugin-oauth-storageEnable on:true (V3i)

Model Reporting (/v1/models or discovery)

The buildConfig() expects each model to have:

{
  "id": "claude-opus-4-8",
  "name": "Claude Opus 4.8",
  "supports1m": true,
  "restricted": false
}

Model Config (W3i)

{
  "claude-opus-4-8": {
    "effortLevels": ["low", "medium", "high", "xhigh", "max"],
    "recommended": "high",
    "modes": ["auto"]
  },
  "claude-sonnet-4-6": {
    "effortLevels": ["low", "medium", "high", "max"],
    "recommended": "low",
    "modes": ["auto"]
  }
}

Gateway Mapping

Anthropic ModelBackendsupports1m
claude-haiku-4-5mimo-auto (free)false
claude-sonnet-4-6mimo-v2.5 (¥99)false
claude-opus-4-8 (low)mimo-v2.5-pro (¥99)false
claude-opus-4-8 (medium)deepseek-v4-flash[1m]true
claude-opus-4-8 (high)deepseek-v4-pro[1m]true

Final Repack

Once validated:

  1. Add extracted remote bundles to local ASAR
  2. Replace stubs _vt(), y4n, hardcodedMainGrowthBookFeatures()
  3. Repack + re-sign (ad-hoc signing)
  4. Bezetacil continues as development harness

References