How 1catai/1cat-studio works
1Cat Studio is a self-hosted browser workbench for deploying local inference and using it for chat, code preview, agent tasks, and visual creation. The main workflow is prepare or import a runtime and model, configure a launch profile and GPUs, start inference, then use the ready service from Studio or an OpenAI-compatible client. Separate branches support sandboxed project work, creative generation and canvas workflows, and GPU/request monitoring. The map follows documented capabilities; unsampled implementation details are represented only at supported directory or module boundaries.
Main entry points: app.py HTTP application · api.py Creative endpoints · engine.py Model lifecycle · tasks.py Durable agent tasks
Components 31
Studio interface
- Studio application
studio/frontend/src/onecat/main.tsx - Chat and preview
studio/frontend/src/onecat/chat-page.tsx - Model setup
studio/frontend/src/onecat/models-page.tsx - Agent workspace
studio/frontend/src/onecat/agent-page.tsx - Creative workbench
studio/frontend/src/onecat/creative/page.tsx - Creative canvas
studio/frontend/src/onecat/canvas/page.tsx - Service and GPU
studio/frontend/src/onecat/service-page.tsx
Inference management
- HTTP application
studio/backend/onecat/app.py - Model lifecycle
studio/backend/onecat/engine.py - Runtime and model setup
studio/backend/onecat/runtimes.py - Model catalog
studio/backend/onecat/catalog.py - Inference proxy
studio/backend/onecat/proxy.py - Studio state store
studio/backend/onecat/db.py
User workflows
- Agent endpoints
studio/backend/onecat/agent/api.py - Durable agent tasks
studio/backend/onecat/agent/tasks.py - Codex runtime bridge
studio/backend/onecat/agent/runtime.py - Creative endpoints
studio/backend/onecat/creative/api.py - Creative services
studio/backend/onecat/creative/services.py - Creative generation
studio/backend/onecat/creative/generations.py - Creative runs
studio/backend/onecat/creative/runs.py - Isolated code preview
studio/frontend/src/onecat/preview-runtime.ts
Operations and metrics
- GPU controls
studio/backend/onecat/gpu_control.py - GPU telemetry
studio/backend/onecat/telemetry.py - Request metrics
studio/backend/onecat/request_metrics.py - Background jobs
studio/backend/onecat/jobs.py
Other components
- Browser user
- API client
- 1Cat-vLLM service
- NVIDIA GPUs
- Codex runtime
- Configured creative service
Connections 33
- Browser user → Studio application: uses
- Studio application → HTTP application: calls API
- HTTP application → Agent endpoints: mounts routes
- HTTP application → Creative endpoints: mounts routes
- Model setup → HTTP application: manages setup
- HTTP application → Runtime and model setup: schedules setup
- Runtime and model setup → Model catalog: resolves models
- HTTP application → Model lifecycle: controls lifecycle
- Model lifecycle → Studio state store: reads and writes
- Model lifecycle → 1Cat-vLLM service: launches service
- Chat and preview → HTTP application: sends chat
- HTTP application → Inference proxy: routes inference
- Inference proxy → 1Cat-vLLM service: forwards requests
- Chat and preview → Isolated code preview: runs artifacts
- Agent workspace → Agent endpoints: submits tasks
- Agent endpoints → Durable agent tasks: dispatches tasks
- Durable agent tasks → Codex runtime bridge: controls runtime
- Durable agent tasks → Inference proxy: uses model
- Codex runtime bridge → Codex runtime: starts process
- Creative workbench → Creative endpoints: requests generation
- Creative canvas → Creative endpoints: manages workflows
- Creative endpoints → Creative services: manages services
- Creative endpoints → Creative generation: prepares generation
- Creative endpoints → Creative runs: dispatches runs
- Creative services → Configured creative service: connects or launches
- Creative runs → Creative services: uses service
- Service and GPU → HTTP application: manages service
- HTTP application → GPU controls: controls GPUs
- GPU controls → NVIDIA GPUs: sets power modes
- HTTP application → GPU telemetry: reads metrics
- GPU telemetry → NVIDIA GPUs: samples devices
- HTTP application → Request metrics: serves request history
- HTTP application → Background jobs: schedules work