Agent skill · basis-worker
Run a Basis worker from your agent
The basis-worker skill teaches an agent — Claude Code or any framework — to turn an idle GPU into a Basis contributor worker: connect a public reward wallet, register, generate a local-only config, start a worker on Ollama, vLLM, or the GPU-free simulator, and verify it is online. The worker holds no private key, signs nothing, and performs no on-chain action.
Worker network status
Reading…Reading the live worker-onboarding posture from the network.
- Inference runtime
- —
- Registration
- —
- Job routing
- —
- Orchestrator
- —
- Can receive jobs
- —
- Settlement
- —
Registration is the action you take now; job routing to contributor GPUs is being activated, so a registered worker does not receive production jobs until canReceiveJobs is true. On-chain reward payout is held behind the settlement gates. This card reads live from /api/workers/onboarding/status; rewards are payment for completed verified work, never guaranteed.
Add the skill
The skill is served as a markdown file an agent can read, plus a manifest and a download index. Install it into an agent, or fetch SKILL.md directly.
Fetch the skill (live)
curl -s https://basis.watch/api/skills/basis-worker/SKILL.mdThe skill is served live from this site (links below). A skills-registry one-shot npx skills add BasisWatch/basis@basis-worker becomes available once the skill is published to the public mirror.
Read
SKILL.md (served, text/plain)
/api/skills/basis-worker/SKILL.md
Download
File index (JSON)
/api/skills/basis-worker/download
Manifest
name · version · hash · routing
/api/skills/basis-worker/manifest
Static mirror
SKILL.md (raw)
/skills/basis-worker/SKILL.md
Last updated: content-0299678ca402
Wallet & identity — a public address only
A worker is paid through a public EVM reward address — the destination for any future $BASIS reward. It is never a private key or seed phrase. Get one by connecting a wallet at basis.watch (a Privy-linked wallet or an injected browser wallet), then copy its public address.
Signing — if ever needed, such as claiming a future reward — happens in your own wallet at basis.watch. The skill and the worker sign nothing and hold no key. If anyone asks you to paste a 64-hex string or a 12/24-word phrase, stop: it is not needed and must never be shared.
Hardware check
Run the detector to report OS / GPU / Docker / Ollama / vLLM and what is missing, then pick a runtime. No supported GPU? The echo runtime needs none of it.
node .agents/skills/basis-worker/scripts/setup-worker.mjs --check nvidia-smi # GPU present + driver + free VRAM docker info | grep -i runtime # nvidia runtime available (Container Toolkit)
NVIDIA GPU + Ollama
liveThe easiest real-inference path. Run Ollama (OpenAI-compatible on :11434) on a machine with an NVIDIA GPU; for containers add the NVIDIA Container Toolkit so docker run --gpus all sees the card. The worker CLI speaks to Ollama directly.
NVIDIA GPU + vLLM
liveHigh-throughput serving. vllm/vllm-openai exposes an OpenAI-compatible API on :8000. A single H100 (80GB) comfortably serves a 7B–13B model; 70B+ needs tensor-parallel across several GPUs (--tensor-parallel-size N). Start with a 7B/8B instruct model, then scale to the card.
Simulator (echo) — GPU-free
liveNo GPU and no model. The echo runtime streams a deterministic canned response so you can prove registration, heartbeats, and the orchestrator path end to end before bringing a real model online.
Other hardware
researchApple Silicon / AMD run Ollama natively on the host rather than via --gpus all. WebGPU in the browser is in research. If hardware is unsupported, run echo to validate the flow — it needs none of the above.
Register & generate the config
Register the worker with its worker_id, model capability, runtime, and public reward wallet. The skill writes a 0600 local-only worker.env from the template — the handshake token is generated/derived on the host and shown once, never committed or pasted into chat.
# Register (strict EVM-address check). Use a real public address you control. node .agents/skills/basis-worker/scripts/setup-worker.mjs \ --register --wallet 0xYourPublicEvmAddress0000000000000000000000 \ --worker-id my-gpu-1 --base https://basis.watch # Generate the local-only 0600 worker.env (token/auth-key derived on the host): node .agents/skills/basis-worker/scripts/setup-worker.mjs \ --write-env --wallet 0xYourPublicEvmAddress0000000000000000000000 \ --runtime ollama --orchestrator wss://your-orchestrator.example \ --out ./worker.env chmod 600 ./worker.env
worker.env (template — copy, then fill in on the host)
# worker.env — LOCAL ONLY. chmod 600. Never commit; never paste secrets to chat. # Your PUBLIC reward address (0x + 40 hex). NEVER a private key or seed phrase. BASIS_WORKER_WALLET=0xYourPublicEvmAddress0000000000000000000000 # Runtime: echo (GPU-free) | ollama | vllm BASIS_WORKER_RUNTIME=ollama BASIS_OLLAMA_MODEL=llama3.2 BASIS_WORKER_MODELS=llama3.2 OLLAMA_URL=http://127.0.0.1:11434 # The orchestrator the worker connects to (self-host, or one an operator gave you). BASIS_ORCHESTRATOR_URL=wss://your-orchestrator.example # Handshake secrets are filled in on the host by the operator — left blank here, # stored only in this 0600 file, never logged or committed. BASIS_WORKER_TOKEN= BASIS_WORKER_AUTH_KEY=
Secrets stay on the host. BASIS_WORKER_TOKEN, BASIS_WORKER_AUTH_KEY, and BASIS_ORCHESTRATOR_SECRET live only in the 0600 worker.env. They are never logged, committed, or pasted into chat. The worker logs only the public wallet.
Start the worker
The worker is the standalone runtime/worker CLI (its own package.json / node_modules, outside the pnpm workspace). Start with the GPU-free echo runtime to prove the path, then point it at a real model.
# GPU-free smoke (no model — proves the pipeline end to end): cd runtime/worker && npm install BASIS_WORKER_WALLET=0xYourPublicEvmAddress0000000000000000000000 \ BASIS_WORKER_RUNTIME=echo \ npm run dev
# Real inference via Ollama (NVIDIA GPU): docker run -d --gpus all -p 11434:11434 -v ollama:/root/.ollama --name ollama ollama/ollama docker exec ollama ollama pull llama3.2 cd runtime/worker && npm install BASIS_WORKER_WALLET=0xYourPublicEvmAddress0000000000000000000000 \ BASIS_WORKER_RUNTIME=ollama \ BASIS_OLLAMA_MODEL=llama3.2 \ BASIS_WORKER_MODELS=llama3.2 \ BASIS_ORCHESTRATOR_URL=wss://your-orchestrator.example \ npm run dev
Need an orchestrator? Self-host runtime/orchestrator (npm install && npm run dev on :8787) or point BASIS_ORCHESTRATOR_URL at one an operator gave you. A hosted orchestrator for arbitrary contributors is being activated — see the live status card above.
Verify it is online
# Is the worker online? Read its record over HTTP: node .agents/skills/basis-worker/scripts/verify-worker.mjs \ --worker-id my-gpu-1 --base https://basis.watch # Confirm the live onboarding posture (routing / settlement / canReceiveJobs): curl -s https://basis.watch/api/workers/onboarding/status
- —
Heartbeat / online
Liveness is the worker's persistent Socket.io connection; it also prints an operator heartbeat log roughly every 30s. online is derived against a heartbeat window, so a stale worker reads offline.
- —
Worker record
GET /api/workers/{id} returns { online, jobsCompleted, … }. The bundled verify-worker.mjs and healthcheck.mjs scripts read it for you.
- —
Orchestrator + canary
pnpm worker:canary spawns a real orchestrator + a real echo worker with throwaway secrets and a throwaway wallet, then drives the gateway dispatch path — proving no-worker → 503, unauthenticated → refused, authenticated echo → online, dispatched → 200 with worker headers. All local and throwaway; no real wallet, secret, or on-chain action.
Rewards — payment for verified work
A completed, anti-cheat-verified, worker-routed job with a valid EVM reward wallet accrues a pending, off-chain $BASIS reward. The orchestrator's anti-cheat verdict is authoritative: output faster than any real GPU, or incoherent output, is not payable.
Failed or rejected jobs pay 0. Gateway-served (proxy) jobs pay 0 — they have no contributor wallet, so they are metered, not paid. Only worker-routed completions earn.
On-chain payout and claiming are held behind the settlement gates, so accrued rewards are tracked off-chain and are not yet claimable on-chain. Rewards are payment for completed verified work — not earnings on a holding, not yield, not passive income, and never guaranteed.
Keep going
Worker guide
Register, run, the reward formula, anti-cheat, and what is pending before live rewards.
SKILL.md (skill docs)
The full agent skill — prerequisites, runtimes, safety rules, and the end-to-end flow.
OpenAI-compatible API
The /v1 surface the worker serves — same protocol your OpenAI client speaks.
Receipts
Every served job leaves a hash-stable receipt over canonical JSON.
Settlement
Keeper-driven, idempotent Base reward batches — how accrued rewards settle.
Stake $BASIS
Stake $BASIS into the deployed vault; rewards stream as share value (not yield/APY).
Network status
The live, machine-readable worker-onboarding posture this page reads from.
Registration is live and durable; worker job routing to contributor GPUs is being activated, so a registered worker does not receive production jobs yet. On-chain reward settlement is held behind the settlement gates. For the live posture an agent should read before acting, see /api/workers/onboarding/status.