gemstone-nexus · Phase 6

DOC26 — Bootstrap and Self-Hosting

← Documents

Metadata

iddoc_idtitlecategorysource_pathsummarycontent_hashindexed_at
40DOC26DOC26 — Bootstrap and Self-Hostingdoc_suiteDevResources/docs/DOC26-Bootstrap-Self-Hosting.mdThis document defines the maturity gates that move GemStone from Bootstrap (human-directed build with external AI workers proposing tasks) to Self-Hosting (GemStone may propose build tasks against itself) without ever relaxing the human-approval invariant. It is the executable reference named by DOCA1 and DOC06; phase product gates remain in DOC02.a3955d7b40a677ef85ba7b5f1cc6e02b22095e4d2026-07-22 18:33:18

Content

# DOC26 — Bootstrap and Self-Hosting

*Phase-gate criteria for GemStone's Bootstrap-to-Self-Hosting lifecycle*

**Initiative:** GemStone · **Version:** v2.0 (Rewrite) · **Status:** Approved for Build · **Date:** July 21, 2026

## 1. Purpose

This document defines the maturity gates that move GemStone from Bootstrap (human-directed build with external AI workers proposing tasks) to Self-Hosting (GemStone may propose build tasks against itself) without ever relaxing the human-approval invariant. It is the executable reference named by DOCA1 and DOC06; phase product gates remain in DOC02.

## 2. Standing Invariant

No Didymus task, from any source including GemStone itself, may enter RUNNING without human `approved_by` and `approved_at`. This invariant is permanent across Bootstrap, Self-Hosting, and any later maturity level. Schema enforcement is required (DOC03 Section 6); application-only checks are insufficient.

## 3. Phase Overview

| Phase | Name | GemStone role | Exit intent |
| --- | --- | --- | --- |
| Gate 0 | Foundation | Consumer of stack only | DOC02 Phase 0 closed |
| Gate 1 | Bootstrap | Approval surface for Cursor/Claude/Gemini workers | Phase 3C closed; three MVP workers stable |
| Gate 2 | Supervised Self-Hosting | GemStone may submit tasks with `requested_by="GemStone"` | N consecutive supervised cycles pass |
| Gate 3 | Operational Self-Hosting | Routine self-proposals allowed under the same approval UI | Blind-source review still required |

## 4. Gate 0 — Foundation

Entry: Stage 0 docs locked; T4 GoldenAMI reachable; Auth0 tenant provisioned.

Exit:

- DOC02 Phase 0 exit criteria all pass.
- Postgres, Redis (AOF), SQLite ledger, Ollama, Whisper, Piper, nginx, and MCP client health all green via `/healthz`.
- Capacitor project scaffolds and `cap sync` succeeds for Android and iOS (even if store binaries are not yet submitted).

## 5. Gate 1 — Bootstrap

Entry: Gate 0 closed; Didymus Hub reachable per DIDYMUS-ARCH-01.

Exit:

- DOC02 Phase 3C exit criteria all pass.
- Workers Cursor, Claude, and Gemini are registered, credentialed per DIDYMUS-PLAYBOOK, and lease only APPROVED tasks.
- Blind-source review: reviewers cannot distinguish task origin from UI chrome alone.
- `GATE2_SUPERVISED_CYCLE_N` is configured from an admin/dev session (not hardcoded); default recommended starting value is 5.

## 6. Gate 2 — Supervised Self-Hosting

Entry: Gate 1 closed; principal explicitly enables GemStone as a proposer.

Exit:

- At least `GATE2_SUPERVISED_CYCLE_N` consecutive cycles where GemStone submits a task, a human approves it, a worker executes it, and verification succeeds.
- Failed or rejected cycles reset the consecutive counter.
- DOC14 tests for "cannot reach RUNNING without approval" continue to pass with `requested_by="GemStone"`.

## 7. Gate 3 — Operational Self-Hosting

Entry: Gate 2 closed; principal sign-off recorded in the Project Ledger.

Exit:

- Self-proposed tasks appear in the same universal queue with identical approval UX.
- No separate "GemStone auto-apply" path exists in API, UI, or schema.
- DOC20 Universal Approval Queue UAT script passes with mixed human and GemStone sources.

## 8. Experimental Forks

Any experiment that appears to relax the approval invariant must live in a named experimental fork with no path to `main` until the invariant is proven intact. Forks are not phase gates.

## 9. Relationship to DOC02

DOC26 gates are maturity overlays. Closing DOC02 Phase 3C is necessary but not sufficient for Gate 2. Product phases 4–5 may proceed in parallel with Gate 2/3 once Gate 1 is closed, provided they do not introduce autonomous execution.

## 10. Term Definitions

| Term | Definition |
| --- | --- |
| Bootstrap Phase | Gates 0–1; GemStone does not propose self-build tasks |
| Self-Hosting Phase | Gates 2–3; GemStone may propose, never auto-execute |
| Phase Gate | Numeric/binary checkpoint verified by someone other than the implementer |
| Standing Invariant | Human approval before RUNNING, permanent |
| Experimental Fork | Isolated branch for risky experiments; no merge until invariant proven |


---
NEXTECH Business Technology Management LLC · nex-tech.biz · (941) 499-5505