ai-being 0.1.0
Sovereign Automation Framework - Doctrine-driven composable automation primitives
License: MIT
Requires Python: >=3.9
Keywords: automation, framework, cells, stateless, composable

# 💀 AI BEING — Sovereign Automation Grimoire

**Status:** Infrastructure Phase (Q1 2026)
**Architecture:** Cell → Tissue → Organ → Organ System → Being → AI Being
**Doctrine Version:** v1.0 (January 2026)

---

## 🎯 PURPOSE

This is a **personal automation ecosystem** built on strict architectural discipline.

**NOT** a framework. **NOT** a library. **NOT** a product.

This is a **grimoire** - a systematically constructed intelligence system that compounds over time.

---

## 📐 ARCHITECTURE OVERVIEW

```
┌─────────────────────────────────────────────┐
│  AI_BEING (Sovereign Intelligence)          │
│  - Supervises systems                       │
│  - Proposes changes, never enforces blindly │
│  - Built LAST (after 3+ systems proven)     │
└────────────┬────────────────────────────────┘
             │
┌────────────▼────────────────────────────────┐
│  ORGAN SYSTEMS (Complete Business Outcomes) │
│  - restaurant_marketing_organ_system        │
│  - booking_operations_organ_system          │
│  - Pricing: ₹1-1.5L per system              │
└────────────┬────────────────────────────────┘
             │
        ┌────┴────┬────────┬────────┐
        │         │        │        │
┌───────▼──┐  ┌──▼────┐ ┌─▼─────┐ ┌▼────────┐
│ ORGANS   │  │ORGANS │ │ORGANS │ │ORGANS   │
│ (5-7 per │  │HTTP   │ │Deploy-│ │n8n+     │
│  system) │  │APIs   │ │able   │ │Python   │
└───────┬──┘  └──┬────┘ └─┬─────┘ └┬────────┘
        │        │        │        │
        └────────┴────┬───┴────────┘
                      │
             ┌────────▼────────┐
             │  TISSUES        │
             │  (Structural    │
             │   Glue)         │
             └────────┬────────┘
                      │
             ┌────────▼────────┐
             │  CELLS          │
             │  (Atomic        │
             │   Functions)    │
             └─────────────────┘
```

---

## 🗂️ REPOSITORY STRUCTURE

```
/ai_being/
├── cells/              # Atomic capabilities (stateless functions)
│   ├── json_cell.py
│   ├── file_cell.py
│   ├── converter_cell.py
│   └── phone_cell.py
│
├── tissues/            # Structural glue (composed of 2+ cells)
│   └── (emerges naturally when repetition appears)
│
├── organs/             # HTTP interfaces (deployable services)
│   └── (n8n + Python workflows, NOT importable libraries)
│
├── organ_systems/      # Complete business solutions (5-7 organs)
│   └── (client-facing packages, ₹1-1.5L pricing)
│
├── docs/               # Doctrine, naming conventions, migration logs
│   ├── DOCTRINE.md
│   ├── NAMING.md
│   └── MIGRATION_LOG.md
│
└── sandbox/            # Isolated exploration (5% rule)
    └── (time-boxed experiments, 1-2 weeks max)
```

---

## 🔒 CANONICAL CALLING MODEL

**ENFORCED PATTERN:**

```python
# ✅ CORRECT - Module-level namespace
from cells import json_cell, file_cell

data = json_cell.modify(response)
file_cell.save('output', data, folder='./data')
```

**FORBIDDEN:**

```python
# ❌ FORBIDDEN - Direct function import
from cells.json_cell import modify

# ❌ FORBIDDEN - Star import
from cells import *

# ❌ FORBIDDEN - Importing organs as libraries
from organs import review_generation_n_organ
```

**Why This Enforces Discipline:**
- Clear layer boundaries (always know what layer code comes from)
- Prevents circular dependencies
- Makes refactoring traceable (grep for `from cells import`)
- Organs are services (HTTP), not libraries

---

## 📖 CORE PRINCIPLES

### 1. **NAMING IS ARCHITECTURE**
Every component follows strict naming conventions:
- Cells: `<action>_<object>_cell.py`
- Tissues: `<function>_tissue.py`
- Organs (concept): `<problem>_organ`
- Organs (implementation): `<problem>_n_organ` or `<problem>_nj_organ`
- Systems: `<domain>_<goal>_organ_system`

### 2. **COMPOSITION IS STRICT**
```
cell → tissue → organ → organ_system → being → ai_being
```
No layer skipping. No premature abstraction.

### 3. **INTELLIGENCE IS LAYERED**

| Layer | Intelligence |
|-------|-------------|
| Cell | ❌ Never |
| Tissue | ❌ Never |
| Organ | ✅ Allowed (local, scoped) |
| Organ System | ⚠️ Limited (coordination only) |
| AI_Being | ✅ Sovereign |

### 4. **STATELESS PRIMITIVES, STATEFUL ORGANS**
- **Cells/Tissues:** Pure functions (no memory)
- **Organs:** May have state (sessions, queues)
- **Systems:** May have persistence (databases)

### 5. **ZERO INTERNAL CONFUSION**
If the next action is unclear, **the system is incomplete, not the operator.**

Confusion is a signal → stop → consult doctrine.

---

## 🚀 CURRENT PHASE: Q1 2026 (INFRASTRUCTURE)

### Goals:
- ✅ Refactor Python grimoire to cell/tissue/organ naming
- ⏳ Build 3 new Restaurant Organs
- ⏳ Deploy to 3-5 clients for validation
- ⏳ Zero internal confusion by March 31

### Forbidden:
- ❌ Scaling before coherence
- ❌ New Systems before Organs proven
- ❌ The AI_Being (not this quarter)

---

## 📋 TIER-1 CELLS (MIGRATION IN PROGRESS)

| Cell | Source | Status |
|------|--------|--------|
| `converter_cell.py` | `internet/converter.py` | ⏳ Pending |
| `phone_cell.py` | `phone_validator.py` | ⏳ Pending |
| `file_cell.py` | `simple_file.py` | ⏳ Pending |
| `json_cell.py` | `json_mage.py` | ⏳ Pending |

**Migration Order:** converter → phone → file → json (simplest to most complex)

---

## 🎯 THE 5% RULE

**95% of time:** Doctrine-bound execution (building cells, organs, deploying to clients)

**5% of time:** Sandboxed exploration (testing new tools, architectures)

All exploration happens in `/sandbox/` with:
- Explicit declaration (named goal)
- Isolation (separate from production)
- Time-box (1-2 weeks max)
- Decision (absorb into grimoire OR discard and log)

**Violation Signal:** If exploration >2 weeks without integration path → ABORT

---

## 🤝 CLIENT ACCEPTANCE CRITERIA

**ACCEPT if:**
- Problem solvable with existing organs (deploy immediately)
- Problem solvable with NEW organ that strengthens grimoire
- Payment validates organ economics (₹40-60K minimum per organ)

**REJECT if:**
- Requires breaking naming conventions
- Requires framework lock-in
- Requires custom one-off work outside grimoire
- Payment too low to justify organ development

**Positioning:** "Grimoire deployment," NOT "custom development"

---

## 📚 DOCUMENTATION

- **[DOCTRINE.md](docs/DOCTRINE.md)** - Sovereign Automation Doctrine (v1.0)
- **[NAMING.md](docs/NAMING.md)** - Naming & Responsibility Foundation
- **[MIGRATION_LOG.md](docs/MIGRATION_LOG.md)** - What was migrated, when, why

**Full PDFs:**
- `/Users/farhanahmedmudgal/Desktop/Ai Automation /Full Doctrine.pdf`
- `/Users/farhanahmedmudgal/Desktop/Ai Automation /Every Naming convention summary.pdf`

---

## ⚠️ ABORT CONDITIONS

**ABORT WORK IF:**
1. Naming is unclear → System incomplete (consult doctrine)
2. Exploration exceeds time-box → Discard and log
3. Client demands violate doctrine → Reject or renegotiate
4. Pattern repeated 3+ times → Missing primitive (build it)
5. Confusion lasts >24 hours → Doctrine gap (escalate)

**ABORT CLIENT IF:**
1. Payment below organ economics (₹40K minimum)
2. Requires custom work outside grimoire
3. Urgency demands breaking architecture

---

## 🔄 EVOLUTION PROTOCOL

Doctrine changes **ONLY** through deliberate upgrade:

1. **Document tension** (why current doctrine fails)
2. **Propose modification** (new rule or update)
3. **Test in sandbox** (isolated, time-boxed)
4. **Update doctrine** (version number + migration guide)
5. **Refactor grimoire** (align code with new doctrine)

**Forbidden:**
- Ad-hoc exceptions ("just this once")
- Retroactive justification ("it worked so it's fine")
- Mid-client delivery changes

---

## 🔒 CLOSING STATEMENT

**This grimoire exists to eliminate the question:**

> "What should I do now?"

**If the answer is unclear, the doctrine is incomplete, not you.**

---

**The grimoire is sovereign.**
**Clients are interfaces.**
**Frameworks are temporary.**
**Doctrine compounds.**

---

**Repository Status:** Phase 2 Complete (Scaffold Created)
**Next Phase:** Phase 3 (Tier-1 Cell Migration)
**Authority:** DragoHan (Shadow Monarch)
**Last Updated:** 2026-01-13