# Deployment Contract (STEP 0)

## Purpose

This document defines the **deployment, transfer, and operational constraints** for the M4WD Otto system. It exists to lock foundational decisions **before any GPT wiring or runtime changes occur**.

This contract applies to all future work and is a prerequisite for STEP 1+.

---

## Canonical Runtime Structure

* `/otto/` is the **canonical runtime directory** for all shopper-facing logic.

  * Otto chat
  * Fitment UI / logic
  * (Future) GPT integration

* `/genie/` is **deprecated**.

  * It is transitional only
  * It will **not ship to buyers**
  * All buyer-facing references will ultimately point to `/otto/`

This decision is final for M4WD.

---

## Deployment Model (Buyer-Facing)

The M4WD site must be deployable by a buyer with **no development tooling**.

### Required Characteristics

* No Git required
* No CI/CD required
* No framework assumptions
* No shared infrastructure

### Deployment Method

* Upload PHP files to the buyer’s server
* Configure environment variables or local config files
* Install a fresh Shopify theme
* Add a minimal Liquid snippet / iframe pointing to `/otto/*`

The system must operate correctly after a simple file upload.

---

## GPT Integration Constraints

GPT is an **optional enhancement**, not a dependency.

### Ownership

* GPT API keys are **buyer-owned**
* Keys are **never hardcoded**
* Keys are **never committed to the repo**

### Optionality

* Otto must function fully with GPT disabled
* GPT failures must not block core functionality
* Graceful fallback behavior is required

---

## Authority Model

GPT is **language-only**.

Explicitly:

* GPT does **not** make decisions
* GPT does **not** determine fitment
* GPT does **not** enforce policy
* GPT does **not** invent or infer facts

Authoritative truth always comes from backend PHP logic and databases.

GPT may only:

* Explain backend results
* Provide conversational UX
* Improve clarity and tone

---

## IP and System Isolation

* Connie **never ships** with M4WD
* Connie **never communicates** with Otto
* No Paradigm-owned services are required to operate the site
* No phone-home behavior exists

M4WD must be a **standalone, transferable asset**.

---

## Design Rules for Future Steps

All future Jira tasks (STEP 1+) must comply with this contract:

* Artifacts must be file-based
* Artifacts must be readable and editable by a buyer
* Artifacts must be transferable via ZIP / upload
* No repo-only assumptions
* No hidden dependencies

If a task violates these rules, it must be redesigned or blocked.

---

## Status

* STEP 0: **Deployment Contract Locked**
* This document is the authoritative reference for transfer safety and deployment decisions.

No runtime code is modified as part of STEP 0.
