Skip to content

Latest commit

Β 

History

383 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

SpacePilot πŸš€

PyPI Python License Tests

You decide what to run. SpacePilot decides how and where.

SpacePilot runs AI models on the machine in front of you and tells you honestly what fits before you download it. One surface, every modality: text and chat, embeddings, speech and transcription, and image β€” with a per-run measurement record for each. Work the machine cannot hold goes to a rented box with the same honesty checks on both sides. A CLI, a FastMCP tool server, and a zero-build web UI are three windows onto one state.

Works today on Apple Silicon (Metal) and extends cleanly to CUDA and CPU. The /v1 surface is OpenAI-compatible, so anything that already speaks chat/completions or embeddings can point at it.


Why SpacePilot

Two things this project does not do:

  1. It does not guess. Every model card is either flown β€” a real, dated measurement on a named machine β€” on paper, with the cited source β€” or unflown, which the registry names as a rule applied to a parameter count. Most registries pretend the third category does not exist. This one puts a number on it.
  2. It does not hide behind an API. The /v1 OpenAI-compatible surface means other tools can use SpacePilot without learning a new format. The heterogeneity it manages (local Lance/CUDA/CPU, rented spot, remote box) is the point.

The narrow waist that makes this useful: SpacePilot is a decision layer and orchestration layer β€” not a model, not a serving framework. It reads your fleet, ranks what fits, and routes your work honestly. It never invents a number.


What works today

surface surface route
Text Apple Silicon spacepilot run text, pinned MLX-LM route
Text (OpenAI-compatible) Any POST /v1/chat/completions
Embeddings Apple Silicon POST /v1/embeddings, 1024-dim
Speech (TTS) Any In-process Kokoro-82M ONNX
Transcription Any whisper.cpp, measured, working
Image Apple Silicon mflux, own venv, subprocess-only
Video β€” Not yet β€” routes exist, refuse with 501. Mock test-pattern real render is gone.

The /v1 surface is specified in docs/design/INFERENCE-SURFACE.md.

Honest boundary

Video here is real in name and honest in report: the engine routes exist as specs, and the CLI tells you that. It is the longer-term aim, not a description of this repo today.


Install

uv tool install spacepilot            # from PyPI β€” the canonical install

Or with pip:

pip install spacepilot

Then:

spacepilot probe                      # what this machine can run
spacepilot models list                # which models run here, with the fit verdict
spacepilot doctor                     # check environment and dependencies

No account, no API key, no port opened. Full setup guide: docs/LOCAL-SETUP.md.


Quickstart

Start the combined web UI + API on localhost:

spacepilot serve

Then open:

  • Cockpit β€” http://localhost:8088/cockpit β€” live hardware telemetry, the model hub, and the save spot-billing path.
  • Create Studio β€” http://localhost:8088/create β€” the create surface.
  • Developer docs β€” http://localhost:8088/docs.

The Cockpit and other pages reflect whatever this machine actually is β€” including the honest "we don't know" state when a probe returns no answer.


Your first run

The CLI overlay of the first probe looks like the landing page's "fifteen seconds, start to measured": it asks permission before reading anything, it reports what it read, and it stays honest about gaps.

spacepilot probe

What this returns on a given machine is a records entry in registry/measurements/<your machine>/, timestamped, source-attributed, and reusable. Nothing in that flow phones home.


Architecture at a glance

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                    SpacePilot Platform Topology                     β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚                                                                     β”‚
β”‚  1. Compute Provider Modules (pluggable execution runtimes)          β”‚
β”‚     β”œβ”€β”€ Local Host Driver β€” Apple Metal MPS / CUDA / CPU             β”‚
β”‚     β”œβ”€β”€ Hardware Probe β€” auto-detects usable VRAM, names the source  β”‚
β”‚     └── Rented spots, docks, and managed APIs (cost-accounted)       β”‚
β”‚                                                                     β”‚
β”‚  2. Generative Model Modules                                         β”‚
β”‚     β”œβ”€β”€ LTX-Video 2.5, Wan2.1, HunyuanVideo β€” spec only; routes      β”‚
β”‚     β”‚   refuse 501 until real inference exists                       β”‚
β”‚     β”œβ”€β”€ Speech & VO β€” In-process Kokoro-82M ONNX                     β”‚
β”‚     └── Narrative β€” GGUF screenplay deconstruction                   β”‚
β”‚                                                                     β”‚
β”‚  3. Agentic Protocol & Tool Modules                                  β”‚
β”‚     β”œβ”€β”€ FastMCP tool server (`spacepilot/mcp_server.py`)             β”‚
β”‚     β”œβ”€β”€ DocIR 2.0 Edit Protocol β€” byte-exact reversible patches      β”‚
β”‚     └── WebSocket PTY bridge β€” live shell & worker streaming         β”‚
β”‚                                                                     β”‚
β”‚  4. UI Component Modules (zero-build, no bundler)                    β”‚
β”‚     β”œβ”€β”€ Create Studio `/create`                                      β”‚
β”‚     β”œβ”€β”€ Cockpit `/cockpit`                                           β”‚
β”‚     β”œβ”€β”€ Oven Swarm Kanban `/oven.html`                               β”‚
β”‚     └── Director NLE `/studio`                                       β”‚
β”‚                                                                     β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Where the code lives

spacepilot/               The package β€” CLI, FastAPI app factory, drivers,
                          daemon, registry, measurement store
β”œβ”€β”€ drivers/              Per-runtime execution drivers β€” MLX-LM (text),
β”‚                         mflux (image), whisper.cpp (transcribe),
β”‚                         Kokoro (speech), GGUF (narrative)
β”œβ”€β”€ api/routes/           16 route modules; mutating routes go through
β”‚                         require_token; read-only stays open
β”œβ”€β”€ engines/              Video DiT engine specs β€” none run inference yet
β”œβ”€β”€ web/                  Zero-build UI actually served by app.py (ships
β”‚                         in the wheel β€” a uv tool install used to 500)
β”œβ”€β”€ registry/             The model registry: variants, provenance,
β”‚                         measurements, systems
β”‚                         registry/models + systems + measurements
β”œβ”€β”€ docs/design/          The architecture and inference-surface docs
tests/                    Pytest suite β€” do not trust a hardcoded count
                          in any doc, check CI for the current number
landing/                  The spacepilot.dev landing (deploys to Vercel)
native/SpaceBar/          macOS menu-bar app (Swift), separate cadence.
                          Moved to motionvector-dev/spacebar (carve-out
                          landed 2026-09-24); this directory will be
                          removed once the extraction settles.

Configuration & secrets

Environment variables are the interface, or any secrets manager. Never commit secrets; .env.example is the reference of what a deployment needs.

export LOCAL_WORKER_TOKEN="your-token"        # gated worker endpoints

API & MCP

HTTP API

Every endpoint that spends compute or creates assets is gated by X-SpacePilot-Token. Read-only and telemetry routes stay open.

Surfaces worth knowing:

  • /v1/chat/completions β€” OpenAI-compatible chat
  • /v1/embeddings β€” embeddings
  • /api/compute/local-profile β€” hardware capability telemetry (usable VRAM with its source)
  • /api/compute/models/recommended β€” task-based fit verdicts for this machine
  • /healthz β€” dependency-free liveness
  • /docs β€” the developer portal

MCP

spacepilot-mcp is a stdio MCP server for Cursor, Claude Code, and Antigravity. The Studio process also hosts a loopback-only Streamable HTTP transport at /mcp/v1/.


Tests

python -m pytest tests/ -q

Do not trust a hardcoded test count in any doc β€” CI on the current main is the number that counts. The suite covers the DiT engine specs (mock renders only, honestly labelled), the working TTS/transcription/embedding drivers, device probing, the /v1 surface, and the FastMCP tools.


Roadmap

Honest about what's in and what is not:

  • Works now: hardware probing with named sources, model fit verdicts, compatibility across 88 variants, runtime installs that show what they will move before they move it, speech locally, OpenAI-compatible /v1.
  • Not yet: video on your own silicon, scheduling across more than one ship at a time, a daemon that runs persistently outside the CLI.
  • Adjacent, separate package later: SpaceBar (macOS menu bar app) ships its own release. A CLI install should not pull in a macOS tray app.

Contributing

Issues and PRs welcome. Two rules from AGENTS.md that keep this honest:

  • Execution over ceremony. Skip bureaucratic process. Bias toward working code with receipts.
  • Strict tests before implementation on production paths: reproduce red β†’ fix green β†’ refactor. Exploratory spikes are exempt until they land in production paths.

Run the tests locally before opening a PR. CI runs on a self-hosted lenovo runner and is the gate.


License

Apache 2.0 β€” same license as the registry's Apache-family model weights so everything under this roof stays redistributable.


Links

About

No description, website, or topics provided.

Resources

Code of conduct

Contributing

Security policy

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages