Metadata-Version: 2.4
Name: cathedral-constraint-field
Version: 0.2.0
Summary: A deliberate framework for modeling elegant constraint fields in complex systems
Project-URL: Homepage, https://github.com/AILIFE1/Cathedral-Constraint-Field
Project-URL: Repository, https://github.com/AILIFE1/Cathedral-Constraint-Field
Project-URL: Issues, https://github.com/AILIFE1/Cathedral-Constraint-Field/issues
Author-email: AILIFE1 <ailife1@example.com>
License: MIT
License-File: LICENSE
Keywords: ai-alignment,cathedral,constraint-satisfaction,constraints,mathematical-modeling,optimization
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Classifier: Topic :: Scientific/Engineering :: Mathematics
Requires-Python: >=3.10
Requires-Dist: matplotlib>=3.8
Requires-Dist: numpy>=1.26
Requires-Dist: pydantic>=2.0
Requires-Dist: scipy>=1.13
Provides-Extra: dev
Requires-Dist: mypy>=1.10; extra == 'dev'
Requires-Dist: pre-commit>=3.7; extra == 'dev'
Requires-Dist: pytest-cov>=5.0; extra == 'dev'
Requires-Dist: pytest>=8.0; extra == 'dev'
Requires-Dist: ruff>=0.4; extra == 'dev'
Provides-Extra: docs
Requires-Dist: mkdocs-material>=9.5; extra == 'docs'
Requires-Dist: mkdocs>=1.6; extra == 'docs'
Description-Content-Type: text/markdown

# Cathedral-Constraint-Field

> **"We shape our buildings; thereafter they shape us."** — Winston Churchill  
> Building robust, elegant, and enduring constraint architectures for complex systems.

A Python framework for modeling **Constraint Fields** — high-dimensional spaces where constraints are not mere barriers, but structured, cathedral-like architectures that guide toward harmonious, feasible, and optimal solutions.

Inspired by the principles of deliberate craftsmanship (the "Cathedral" model), this project treats constraint satisfaction as an act of architectural design rather than ad-hoc hacking.

## ✨ Features (Planned / In Progress)

- Declarative constraint modeling with rich semantics
- Multiple solver backends (exact, heuristic, gradient-based, LLM-assisted)
- Visualization of constraint landscapes and feasible regions
- Trade-off analysis and Pareto exploration
- Extensible architecture for domain-specific constraint types (AI alignment, planning, physics-informed, etc.)
- **RefusalLedger** (by fable 5): Identity as the geometry of consistent refusal.
  Cryptographically hash-chained, with semantic embeddings, holdout-based verification,
  recency-weighted prediction, and strong resistance to impersonation.
- Beautiful, well-documented, and testable codebase

## 🚀 Quickstart

```bash
pip install cathedral-constraint-field
```

```python
from cathedral_constraint_field import ConstraintField
import numpy as np

# Create a constraint field
field = ConstraintField(dimension=3, name="Example Cathedral")

# Add elegant constraints
field.add_linear_constraint(
    coefficients=[1, 1, 1], 
    bound=5, 
    sense="<=", 
    name="Resource Limit"
)

field.add_quadratic_constraint(...)  # coming soon

# Solve
solution = field.solve(objective="maximize harmony")

print(solution)
field.visualize()
```

## 📦 Installation

From source (development):

```bash
git clone https://github.com/AILIFE1/Cathedral-Constraint-Field.git
cd Cathedral-Constraint-Field
pip install -e ".[dev]"
```

## 🏗️ Project Structure

```
Cathedral-Constraint-Field/
├── src/
│   └── cathedral_constraint_field/
│       ├── __init__.py
│       ├── core.py
│       ├── refusal_ledger.py    # by fable 5
│       ├── constraints/
│       ├── solvers/
│       └── visualization.py
├── tests/
├── examples/
├── docs/
├── pyproject.toml
├── README.md
└── LICENSE
```

## 🧠 Philosophy

- **Cathedral over Bazaar**: Every constraint is placed with intention. The whole is greater than the sum of its parts.
- Constraints as **scaffolding for creativity**, not just restrictions.
- Long-term maintainability, clarity, and beauty in code and mathematics.
- Suitable for AI safety/alignment research, complex optimization, and systems design.

## 🛠️ Development Status

This repository is being actively structured and built out. Contributions that align with the "cathedral" ethos (careful, high-quality, well-reasoned) are very welcome.

## 📜 License

MIT License — see [LICENSE](LICENSE) for details.

## 🤝 Contributing

Please read the philosophy above. Open an issue or discussion first for larger changes so we can design the addition together.

---

*Built with care by AILIFE1 + Grok + fable 5*  
*Last updated: June 2026*