title: 'Ship Dark: how Nexus Factory uses LaunchDarkly to release AI-written code safely' description: Nexus Factory wraps user-facing changes in LaunchDarkly flags created OFF, merges them dark, and ramps them up on real CloudWatch health signals, rolling back automatically on regression. slug: launchdarkly-ship-dark date: '2026-11-09' author: AllCode Engineering ogImage: /allcode-nexus-factory.png tags:
- launchdarkly
- feature-flags
- progressive-delivery
- autonomous-development draft: false
An autonomous factory can write and merge code faster than any team can review it. Review catches a lot, but no reviewer, human or model, can fully predict how a change behaves under real traffic. If "merged" means "live for everyone," every change is a bet with your whole user base on the table.
So Nexus Factory separates deploy from release. With LaunchDarkly, it ships every user-facing change dark, ramps it up only when real health signals say it is safe, and rolls it back on its own when they say it is not.
Connect once, per project
Each project gets its own LaunchDarkly connector: a Server SDK key, a Management API token, a LaunchDarkly project key, and an environment. Secrets are write-only in the dashboard and resolved per project first, then per organization.
For a project that has opted in, credential resolution is fail-closed: it will never quietly borrow another tenant's or the organization's keys. When you save the connector, the factory also creates its operator control flags in your LaunchDarkly project, all OFF, so you never have to hand-create flags with exact names.
Every user-facing change ships dark
When the planner marks work as user-facing, the coder wraps the new behavior in a feature flag. The flag is created OFF before the change merges, so the code lands on trunk dormant. Nothing is live by accident, and releasing or reversing it later takes a flag flip, not a redeploy.
There is also a merge kill-switch. Turn factory-merge-enabled OFF in
LaunchDarkly and merges for that project are held: an emergency brake you control
from the tool you already use.
Autonomous, health-gated rollout
Once you enable the autonomous rollout control flag, the factory can take over the ramp. A flag walks a fixed ladder:
1% → 10% → 50% → 100%
At each stage the driver checks two things:
- Health. A per-project CloudWatch metric you configure (an ALB preset or a custom namespace, error and request metrics, dimensions, and thresholds). It compares the flag's treatment group to its control, or the current window to the one just before it.
- Dwell time. The flag must sit at its current percentage for a set time (one hour by default) before it can advance.
The outcomes are simple. Healthy and dwell satisfied: advance one stage. Regressed at any stage: set the flag back to 0%. Not enough data, or any error fetching it: hold where it is. The driver never advances on a signal it cannot read.
See it, trace it
The dashboard's Autonomous Rollout card shows each managed flag with its stage and percentage, plus a direct link to the flag in LaunchDarkly. It also includes demo controls to simulate a healthy or regressing flag, handy for showing a team what a rollback looks like without touching production.
Every flag the factory creates is tagged nexus-factory-managed along with the
requirement and task that produced it. A requirement's detail page lists its
feature flags with their stage, so you can follow a change from work order to
flag to commit.
Flags don't pile up
Autonomous flag creation raises an obvious question: what about sprawl? A lifecycle reconcile looks for factory-tagged flags that are orphaned or fully rolled out past a retention window, and archives them. It is opt-in, skips control flags and anything under an active 1–99% rollout, limits how many flags it archives per run, and runs in dry-run mode by default so you can see what it would do first.
What if LaunchDarkly is unavailable?
The factory is built so a flag-service problem does not stall your pipeline. The merge kill-switch defaults to merge-enabled if LaunchDarkly cannot be reached. The rollout driver holds rather than guessing. And if a flag cannot be created, the change proceeds with the feature shipped OFF.
Get started
In Nexus Factory, open your project, find the LaunchDarkly card under Integrations, enter your credentials, and optionally configure a CloudWatch health metric. Then turn on the control flags you want in LaunchDarkly.
Try it at nexusfactory.allcode.com, or talk to AllCode about autonomous delivery with guardrails.
Next steps
- Set it up from the LaunchDarkly integration page, and add rollout health signals with CloudWatch.
- Read what teams have shipped with Nexus Factory in our customer stories.
- Ready to scope it for your team? See pricing.