Production Readiness Policies
This is the Company OS contract for three VertiSwarm commercialization blockers:
- production database writes and rollback;
- OAuth connector polish;
- customer-specific evidence packs.
The backend exposes the machine-readable contract at:
http
GET /api/company/production-readiness/contractImplementation: src/company_os/production_readiness.rs.
Production Write / Rollback Policy
Default mode is dry-run shadow. Agents may inspect schemas, generate mutation plans, run validation queries, and prepare rollback plans without human approval. They may not perform production writes until a workflow has an explicit mutation policy and evidence trail.
Required gates before a production write:
- Schema catalog describes the target source, tables, columns, and sensitive fields.
- Mutation policy declares allowed tables, columns, verbs, and risk class.
- Idempotency key is present.
- Human approval exists for non-reversible, high-value, customer-facing, or permission-changing actions.
- Pre-write snapshot or compensating rollback plan exists.
- Post-write verification query is defined.
- Run execution event records actor, before/after evidence, and outcome.
- Governance event records approval or rejection.
Blocked until explicit policy:
- delete;
- bulk update;
- external payment or purchase;
- customer email send;
- credential or permission change;
- cross-tenant data move.
Evidence artifacts:
mutation_plan.jsondry_run_result.jsonapproval_event.jsonrollback_plan.jsonpost_write_verification.jsontrace.jsonl
OAuth Polish Policy
OAuth-backed connectors should be treated as not production-polished until the operator experience covers account health, granted scopes, refresh state, and disconnect/revocation.
Required gates:
- Provider template declares auth mode and scopes.
- OAuth2 uses PKCE or server-side exchange.
- State nonce is bound to company and user.
- Tokens are encrypted at rest or stored in an external credential provider.
- Refresh worker status is visible.
- Revocation/disconnect path exists.
- Scope changes require reapproval.
Token handling rules:
- never return raw access tokens to the browser;
- redact access tokens, refresh tokens, API keys, secrets, passwords, and private keys;
- store only access-token hints in public responses;
- record token expiry and refresh status;
- support strict credential-encryption mode.
Evidence artifacts:
oauth_provider_manifest.jsonconnector_account_redacted.jsonrefresh_health.jsonscope_review.jsondisconnect_or_revocation_log.json
Customer-Specific Evidence Policy
Customer evidence must be scenario-specific. Generic platform screenshots are not enough to claim productivity savings or production readiness.
Minimum artifacts:
customer_context.mdworkflow_baseline.mddemo_task.ndjsontrace.jsonlgovernance.jsonrollback_or_repair_evidence.jsonlscreenshots/metrics.md
Minimum demo surfaces:
- Dashboard or browser session.
- Schema-aware database read or guarded write.
- External API, portal, email, or document.
- Human approval gate.
- Trace export.
Metrics to capture:
- manual baseline minutes;
- agent runtime minutes;
- human interventions;
- tool calls;
- error count before and after;
- rollback or recovery time;
- estimated cost per run.
Forbidden claims without pilot data:
- proven 40-60% savings;
- fully autonomous recovery;
- liability eliminated;
- production-ready for regulated enterprise.
Next Wiring Steps
- Add a
mutation_policytable or runtime-policy section for allowed write scopes. - Add a guarded write endpoint that only accepts
mutation_plan.jsonplus approval id. - Persist rollback and post-write verification artifacts beside run execution events.
- Complete OAuth connect/disconnect UX against the connector account contract.
- Generate a dated customer evidence folder from one logistics or finance demo workflow.