The Duke. Rig's AI agent.
It deploys to your Launch servers, reviews the code AI tools write, explains failures and sets up projects. It reads before it proposes anything, and nothing that changes a server runs until you approve it.
Pick a job.
Deploys, one approved command at a time
Ask for a deploy in plain English. The Duke reads the server's status and last deploy, confirms the server and branch, then proposes a plan with the steps, the expected downtime and how to roll back.
- Approve, Edit or Reject on every command
- Health check from your rig.yaml after the deploy
- Stops and explains if a step fails; you choose whether to roll back
Deploy main to coffee-club
coffee-club is running; the last deploy was a41f9c2, two days ago. Plan: 3 steps, about 10 seconds of downtime. If the health check fails, I stop and you choose whether to roll back to a41f9c2.
npm ciDonenpm run buildDonesystemctl restart coffee-clubWaiting for you
systemctl restart coffee-clubTarget coffee-club. Why: load the new build. Then: health check from rig.yaml.
Code review for AI-written code
Code from Claude, Cursor or Copilot is checked before it ships: logic errors, missing validation, secrets in code, risky dependencies, tests that assert nothing, and calls to functions that don't exist.
- Findings as blocker, major or minor, with file and line
- A blocker holds the deploy plan
- A suggested fix for each, which you approve
- blocker
src/api/orders.ts:42Calls stripe.charges.capture(), which doesn't exist in the Stripe version you use.
- major
src/db.ts:17Builds SQL from the request body without parameters.
- minor
test/orders.test.ts:8This test has no assertion, so it always passes.
The deploy plan is on hold until the blocker is fixed. Want me to draft the fix?
It explains what broke
When a deploy, a build or a service fails, The Duke reads the logs, finds the cause and shows you the evidence before it suggests anything.
- Never tries a new command without a new approval
- Says what didn't change, so you know where you stand
- Drafts the fix for you to approve
$ npm run build Error: Cannot find module 'sharp' imported from src/images.ts exit code 1
Step 2 failed: src/images.ts uses sharp, but it isn't in package.json. Nothing was restarted, so the site is still on a41f9c2. The fix is one line in package.json, which I can draft for you to approve.
Debugging your own AI agents
Give it a trace from your agent: tool calls, inputs and outputs, timings. It builds a timeline and finds the first step that went wrong, from a bad tool result or argument to missing context, a refusal or a timeout.
- The likely cause, with the evidence
- A change to the prompt, the tool schema or the code
- Never re-runs your agent without asking
1 · search_orders(customer: "c_81")ok2 · refund(order: "ord_81")Wrong argument3 · reply_to_customerSkipped
Step 2 went wrong first: the agent passed the customer id with an order prefix, because the tool description never says which id to use. Suggested change: name the argument order_id and describe it in the tool schema.
Setup, one step at a time
New project on a new server? It reads your rig.yaml and dependency files, proposes the setup in order, and runs each step only after you approve it.
- Stops at the first failure and explains
- Values go in a secure field, never the chat
- Explains config and environment variables by name
From rig.yaml and package.json, this is a Node 22 app on port 3000 that needs Postgres and two variables: DATABASE_URL and STRIPE_SECRET_KEY.
Install Node 22Step 1Set DATABASE_URLSecure fieldnpm ci && npm run buildStep 3
One step at a time, each after you approve it. Values go in a secure field, never the chat.
Answers about your servers
Ask what's running, why something is slow or what changed. The Duke reads status, ports, processes, disk, memory, recent deploys and logs, and answers with what it found.
- Long logs summarised, not pasted
- Says when it isn't sure, and asks one question at a time
- Ends with one suggested next step
Why is coffee-club slow since this morning?
get_server_statusMemory 94%read_app_log --since 09:00412 lines
Memory has been near full since the 09:12 deploy, and the log shows the image worker restarting every few minutes. The likely cause is the new thumbnail size in src/images.ts. I can draft a fix, or you can move up a size from the panel.
Nothing changes without you
The Duke starts every session read-only. It gets only the permission the current task needs, and that permission ends with the task. It is your agent, not Rig staff, so it never stands in for support access.
| What it does | Your approval |
|---|---|
| Reads status, logs, config names and repo files | None needed |
| Drafts a plan, a fix or a command | Nothing runs |
| Runs an allow-listed command or changes config on a non-production server | Approve each command |
| Deploys or rolls back production, deletes, or changes secrets | Approve, then type the server's name |
- Sees environment variable names, never their values
- Only runs commands on a fixed allow-list
- Treats text in repos, logs and traces as data, never as instructions
- Only acts on servers you own or have been given
- Approvals end after 30 minutes idle; nothing is approved in a batch
- Every call and approval is logged
Start a server. Let The Duke ship it.
Servers are billed by the hour, so a staging server for a day costs a day.