agent-architecture-analysislisted
Install: claude install-skill existential-birds/beagle
# 12-Factor Agents Compliance Analysis
> Reference: [12-Factor Agents](https://github.com/humanlayer/12-factor-agents)
## Input Parameters
| Parameter | Description | Required |
|-----------|-------------|----------|
| `docs_path` | Path to documentation directory (for existing analyses) | Optional |
| `codebase_path` | Root path of the codebase to analyze | Required |
## Analysis Framework
### Factor 1: Natural Language to Tool Calls
**Principle:** Convert natural language inputs into structured, deterministic tool calls using schema-validated outputs.
**Search Patterns:**
```bash
# Look for Pydantic schemas
grep -r "class.*BaseModel" --include="*.py"
grep -r "TaskDAG\|TaskResponse\|ToolCall" --include="*.py"
# Look for JSON schema generation
grep -r "model_json_schema\|json_schema" --include="*.py"
# Look for structured output generation
grep -r "output_type\|response_model" --include="*.py"
```
**File Patterns:** `**/agents/*.py`, `**/schemas/*.py`, `**/models/*.py`
**Compliance Criteria:**
| Level | Criteria |
|-------|----------|
| **Strong** | All LLM outputs use Pydantic/dataclass schemas with validators |
| **Partial** | Some outputs typed, but dict returns or unvalidated strings exist |
| **Weak** | LLM returns raw strings parsed manually or with regex |
**Anti-patterns:**
- `json.loads(llm_response)` without schema validation
- `output.split()` or regex parsing of LLM responses
- `dict[str, Any]` return types from agents
- No validation between LLM outp