Metadata-Version: 2.4
Name: authgraph
Version: 0.3.1
Summary: authgraph — advisory execution intelligence; TrigGuard remains the authorization authority.
Author: TrigGuard AI
License-Expression: Apache-2.0
Project-URL: Homepage, https://www.trigguardai.com
Project-URL: Repository, https://github.com/TrigGuard-AI/TrigGuard
Project-URL: Documentation, https://trigguardai.com/docs
Project-URL: Issues, https://github.com/TrigGuard-AI/TrigGuard/issues
Keywords: authgraph,trigguard,permit,execution-graph,dag,orchestration,authorization,ai-governance,workflow-engine,simulation,explainability
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
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 :: Software Development :: Libraries
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Classifier: Typing :: Typed
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: trigguard>=0.2.1
Provides-Extra: dev
Requires-Dist: pytest>=7.0; extra == "dev"
Requires-Dist: pytest-cov>=4.0; extra == "dev"
Requires-Dist: ruff>=0.4.0; extra == "dev"
Requires-Dist: mypy>=1.8; extra == "dev"
Dynamic: license-file

# AuthGraph 0.3.1

**Execution intelligence for autonomous systems — advisory, not authorization truth.**

AuthGraph discovers execution surfaces, maps architecture, scores risk, and recommends
policy-preserving remediation. **TrigGuard** remains the sole authorization authority
(PERMIT / DENY / ESCALATE / SILENCE).

```bash
pip install authgraph==0.3.1
```

```
architecture → analyze → install → protect → simulate → explain → score → recommend
                              ↓
                        human review
                              ↓
                     TrigGuard authorize
```

**0.3.1 does not rewrite repositories.** No `patch` / `apply` / `undo`.

```python
from authgraph import Plan, simulate, analyze_repository, guard

# Discovery (read-only)
report = analyze_repository(".")

# Simulation asks TrigGuard — never executes callables
plan = Plan()
plan.add("deploy.release", ship, title="ship")
print(simulate(plan))
```

CLI (advisory):

```bash
authgraph architecture .
authgraph analyze .
authgraph install .          # writes .authgraph/ plan only
authgraph protect .          # human review of plan (no source edits)
authgraph score .
authgraph recommend .        # structured remediation — never bypass suggestions
authgraph report .
authgraph simulate examples/deployment.py
authgraph explain <receipt> --action deploy.release
authgraph doctor .
authgraph why AG-0001
```

Hard guarantees:

| Guarantee | Value |
|-----------|-------|
| `AUTHGRAPH_POLICY_PRESERVATION` | `TRUE` |
| Local decisions without TrigGuard | `decision = null` / `REQUIRES_TRIGGUARD_POLICY` |
| Source mutation by advisory CLI | **ZERO** (only `.authgraph/`) |
| Circumvention suggestions | **Forbidden** |

Requires `TRIGGUARD_API_KEY`, `TRIGGUARD_ORG_ID` for live simulation/authorization.
Gateway default: `https://api.trigguardai.com`.

Full guide: [`docs/QUICKSTART.md`](docs/QUICKSTART.md) · Policy preservation: [`docs/POLICY_PRESERVATION.md`](docs/POLICY_PRESERVATION.md)

---

## APIs

| API | Role |
|-----|------|
| `analyze_repository()` / `authgraph analyze` | Classify execution surfaces (read-only) |
| `Plan` + `simulate()` | Preview TrigGuard decisions (no side effects) |
| `explain()` | Explain a receipt / decision |
| `@guard()` / `authorization()` | Call-site instrumentation helper |
| `run_step` / `run_step_async` / `run_many` | Runtime execution after PERMIT |
| `authgraph recommend` | Scores + policy-preserving remediation |

```python
from authgraph import guard, authorization, run_step, run_step_async, run_many
from authgraph import Plan, simulate, explain, analyze_repository
```

Not a CrewAI/LangGraph/Quanta product. Optional integration hooks live under
`authgraph.integrations` and do **not** bundle external runtimes.

Demos: [`examples/demos/`](examples/demos/)

---

## License

Apache-2.0 · TrigGuard AI
