# maxart/rails-with-ai architecture

> Architecture diagram of the GitHub repository maxart/rails-with-ai, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-26). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/maxart/rails-with-ai
- Repository: https://github.com/maxart/rails-with-ai

## Overview

Rails-with-AI is a pair of drop-in Claude Code instruction templates, not a Rails application or executable library. A developer chooses FULL or SHORT, places it in a Rails project as CLAUDE.md, and Claude Code loads its rules for project work. The templates cover Rails conventions across application design, security, testing, and operations; a companion guide expands on the rules. Relationships shown here are documented in the README; template internals were not sampled.

Main entry points: [`CLAUDE.md.FULL`](https://github.com/maxart/rails-with-ai/blob/main/CLAUDE.md.FULL) (FULL template), [`CLAUDE.md.SHORT`](https://github.com/maxart/rails-with-ai/blob/main/CLAUDE.md.SHORT) (SHORT template), [`docs/RAILS_BEST_PRACTICES_GUIDE.md`](https://github.com/maxart/rails-with-ai/blob/main/docs/RAILS_BEST_PRACTICES_GUIDE.md) (Best practices guide)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_use["Adoption"]
  node_project["Rails project"]
  node_claude["Claude Code"]
end

subgraph group_templates["Instruction templates"]
  node_full["FULL template<br/>[CLAUDE.md.FULL]"]
  node_short["SHORT template<br/>[CLAUDE.md.SHORT]"]
  node_guidance["Rails guidance<br/>[CLAUDE.md.FULL]"]
end

subgraph group_learning["Learning resource"]
  node_guide["Best practices guide"]
end

node_developer(("Developer"))

node_developer -->|"chooses or downloads"| node_full
node_developer -->|"chooses or downloads"| node_short
node_full -->|"installs as CLAUDE.md"| node_project
node_short -->|"installs as CLAUDE.md"| node_project
node_project -->|"provides instructions"| node_claude
node_claude -->|"applies rules"| node_guidance
node_guide -->|"explains rules"| node_guidance

click node_full "https://github.com/maxart/rails-with-ai/blob/main/CLAUDE.md.FULL"
click node_short "https://github.com/maxart/rails-with-ai/blob/main/CLAUDE.md.SHORT"
click node_guidance "https://github.com/maxart/rails-with-ai/blob/main/CLAUDE.md.FULL"
click node_guide "https://github.com/maxart/rails-with-ai/blob/main/docs/RAILS_BEST_PRACTICES_GUIDE.md"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_project,node_claude toneBlue
class node_full,node_short,node_guidance toneAmber
class node_guide toneMint
class node_developer toneIndigo
```

## Components

### Adoption

- **Rails project**
- **Claude Code**

### Instruction templates

- [FULL template](https://github.com/maxart/rails-with-ai/blob/main/CLAUDE.md.FULL): `CLAUDE.md.FULL`
- [SHORT template](https://github.com/maxart/rails-with-ai/blob/main/CLAUDE.md.SHORT): `CLAUDE.md.SHORT`
- [Rails guidance](https://github.com/maxart/rails-with-ai/blob/main/CLAUDE.md.FULL): `CLAUDE.md.FULL`

### Learning resource

- [Best practices guide](https://github.com/maxart/rails-with-ai/blob/main/docs/RAILS_BEST_PRACTICES_GUIDE.md): `docs/RAILS_BEST_PRACTICES_GUIDE.md`

### Other components

- **Developer**

## Connections

- Developer → FULL template: chooses or downloads (evidence: `README.md`)
- Developer → SHORT template: chooses or downloads (evidence: `README.md`)
- FULL template → Rails project: installs as CLAUDE.md (evidence: `README.md`)
- SHORT template → Rails project: installs as CLAUDE.md (evidence: `README.md`)
- Rails project → Claude Code: provides instructions (evidence: `README.md`)
- Claude Code → Rails guidance: applies rules (evidence: `README.md`)
- Best practices guide → Rails guidance: explains rules (evidence: `README.md`)
