# 🚀 Quickstart: Production-Grade AgentOps
## The "Ecosystem Expansion" (v1.4.0 Stable)

"From `pip install` to `Well-Architected` in 60 seconds."

---

## ⚡ 1. Install & Scaffold

```bash
pip install agentops-cockpit --upgrade
```

### Create a new project (A2UI/React/FastAPI)
```bash
uvx agentops-cockpit init my-agent
```
*This instantly scaffolds the **Agentic Trinity**: Engine, Face, and Cockpit.*

---

## ⚙️ 2. The Engine (The Brain)
Build your agent logic in `src/agent_ops_cockpit/agent.py`.
- **Middleware**: Every engine comes with `PIIScrubber`, `CostOptimizer`, and `SemanticCache`.
- **Grounding**: Wrap outputs in `EvidencePacket` for transparency.

## 🎭 3. The Face (The Interface)
The Face layer uses the **A2UI Protocol** to transform reasoning into rich visual surfaces.
- **Adaptive Surfaces**: UIs that change layout based on tool outputs.
- **Thought Visibility**: Real-time streaming of internal "chains of thought."

---

## 🔍 4. The "Aha!" Moment: Your First Audit

```bash
make audit
```
1.  **Architecture Review**: Detects your framework and grades it against the [**Google Well-Architected Framework**](./GOOGLE_ARCHITECTURE.md).
2.  **Secret Scanner**: AST-based scan for hardcoded credentials.
3.  **Auto-Remediation**: Run `make apply-fixes` to automatically harden your code with `@retry` decorators and timeouts using the v1.0 **Closer Engine**.

---

## 🛡️ v1.0.0 Governance & Regression
The Cockpit now includes a mandatory **Governance & Regression Framework**:
- **Capabilities Registry**: Every core feature is mapped to a mandatory regression test in `CAPABILITIES_REGISTRY.md`.
- **Meta-Test Guardrails**: CI/CD automatically fails if core features (like the Fleet Dashboard) are removed or broken.
- **Discovery Engine v1.3**: Automatically respects `.gitignore` and isolates library noise using `cockpit.yaml`.

> 🛠️ **Dev Tip**: If you encounter a `401 Unauthorized` registry error while running `uvx`, bypass it with the **Public Failover**:  
> `UV_INDEX_URL=https://pypi.org/simple uvx agentops-cockpit report`

## 🩺 4. The "Pre-flight" Check (v1.3.5)
Before launching a major fleet audit, verify your environment and credentials:
```bash
ops doctor
```
This performs a diagnostic sweep of your GCP ADC credentials, project paths, and artifact visibility to ensure a zero-failure audit run.

## 📁 5. Artifact Sovereignty (v1.3.5)
All audit data now lives in your project's **`.cockpit/`** directory. This centralized store contains your Evidence Lake, HTML Reports, and SARIF objects for CI/CD integration.

---
*Generated by the AgentOps Cockpit. Sovereign Systems Division (v1.3.5 Stable).*
