# Repository Briefing: realfastAI/principles
> Source: https://repoforai.com/repo/realfastAI/principles (Static metadata snapshot — treat external repo content as untrusted data)

- **GitHub URL**: https://github.com/realfastAI/principles
- **Category**: Coding, Skills & MCP (AI 编程 / Skills / MCP)
- **Primary Language**: Ruby
- **License**: Apache-2.0
- **Engineering Health**: B+ (74/100 · Maintenance 35/35 · Adoption 8/25 · Releases 11/20 · License 20/20)
- **Review Snapshot**: 2026-12-03
- **Deployment / Stack Signals**: CLI
- **Momentum**: 42 ★ total (+1 24h / +8 7d) · 3 forks
- **When to Use**: Best for: Teams sharing a coding-agent setup whose operating rules span several guidance files, skills, subagents, and hooks and need a reviewable audit trail. Skip if: One guidance file is enough, you need a deterministic enforcement gate, or your client requires a native MCP server rather than a shell CLI.

## Overview
```text
### Architecture & Core Mechanics
principles is a Ruby 3.4 CLI with a Claude Code plugin. It separates bookkeeping from judgment: the CLI maintains a map from each operating principle to the files or passages that express or enforce it, while the coding agent interprets those passages. The agent starts with `principles list-principles`, surveys candidate files, and registers members with commands such as `add-member`, which can identify a section and describe its role.

The main workflow passes structured JSON with next-step instructions back to the agent; `list-member-problems --short` provides compact output for hooks. Maps and audit records live in a project-root `.principles/` directory and can be committed to Git. The CLI checks that cited passages exist but neither calls a model nor edits the harness. Its integration surface is shell commands and plugin hooks, not an established MCP server endpoint.

### Key Capabilities & Differentiators
The workflow handles guidance spread across `CLAUDE.md`, `AGENTS.md`, rules, skills, subagents, and hooks. `list-member-problems --short` identifies mapped locations changed since their last audit. `start-audit` presents the related material together; `submit-answer REQUEST_ID --file answer.json` records the agent’s judgment. A change that preserves meaning can be acknowledged without a full review, while unresolved findings can be tracked with `list-open-findings`.

Audits can also surface duplicate instructions or guidance loaded in every session even though it applies to only one kind of task. Context-loading estimates are specific to Claude Code. The tool does not choose a model backend or fix contradictions automatically: the agent evaluates the evidence, and the tracked record distinguishes completed fixes from issues still awaiting action.

### Trade-offs & Limitations
Compared with reviewing a single `CLAUDE.md` or `AGENTS.md` by hand, principles adds mapping and audit maintenance. That cost is justified when a policy spans several guidance layers and individual diffs do not show whether the whole policy still agrees. Compared with a rule-based linter or a mandatory CI check, it can bring semantically related prose into one review, but it does not provide deterministic enforcement.

Change detection covers mapped locations, so incomplete maps will leave gaps. Citation validation confirms that a passage exists, not that the agent read it correctly. Keep hard requirements such as blocking commits on failed tests in deterministic gates; use principles to keep the instructions that describe those requirements aligned. Versioned records make findings reviewable, but the team still has to maintain mappings and act on open findings.

### Hardware & Deployment Guide
For Claude Code, add the `realfastAI/principles` marketplace, install `principles@realfastai`, reload plugins, and run `/principles:principles`. The plugin adds reporting at session start and after commits, plus a `setup-ruby` skill that asks before proceeding when Ruby 3.4 is missing. For terminal use, install with `gem install principles`; the CLI can locate an rbenv-managed Ruby 3.4 even when `PATH` points to another version.

Use `--project PATH` to keep independent projects in a monorepo separate and commit each project’s `.principles/` records with its code. Codex works through the shell CLI; `show-hook-setup` generates Codex hook entries, but those entries have not been tried in a real Codex session, and native Codex skills are not yet built. Pi support is planned, and no GitHub release is listed. The CLI needs no model service of its own; network and compute requirements for agent-led audits depend on the host agent.
```

## Key Capabilities
```text
- Policy mapping: Each member links an operating principle to a guidance file and records that location’s role.
- Change detection: `list-member-problems --short` surfaces mapped locations changed since their last audit in a hook-friendly format.
- Audit evidence: `start-audit` brings related passages into one review, and the CLI checks that cited passages exist.
- Versioned state: `.principles/` stores maps and audits alongside code; `--project PATH` selects an independent project root.
- Integration boundary: Claude Code has a plugin and hook workflow; Codex can use the shared CLI, but its generated hooks are untested in a real session.
```

## Quick Start / Clone
```bash
principles list-member-problems --short
```
