rules-normalize

$npx mdskill add Fr-e-d/GAAI-framework/rules-normalize

Convert implicit conventions into governed GAAI rule files with integrity.

  • Solves scattered or undocumented project conventions that need explicit governance.
  • Depends on detected rule files, existing conventions, and project guidelines.
  • Classifies conventions by domain and translates them into standard GAAI rules.
  • Outputs normalized rule files into contexts/rules/ directory.

SKILL.md

.github/skills/rules-normalizeView on GitHub ↗
---
name: rules-normalize
description: Convert implicit or scattered project conventions into governed GAAI rule files, and create or modify rule files with integrity. Activate during Bootstrap, when creating a new rule, or when modifying an existing rule.
license: ELv2
compatibility: Works with any filesystem-based AI coding agent
metadata:
  author: gaai-framework
  version: "1.0"
  category: cross
  track: cross-cutting
  id: SKILL-RULES-NORMALIZE-001
  updated_at: 2026-02-26
  status: stable
inputs:
  - detected_rule_files
  - existing_conventions  (linters, security configs, style guides, CI constraints)
  - project_guidelines
outputs:
  - contexts/rules/**
---

# Rules Normalize

## Purpose / When to Activate

Activate when:
- **Bootstrap** — project has existing conventions (linters, security policies, style guides, architecture docs, CI constraints) that need to become explicit governance
- **Creating a new rule** — any agent or human intends to add a new `.rules.md` file
- **Modifying an existing rule** — any agent or human intends to change the content or structure of an existing rule file

Converts all implicit conventions into explicit GAAI governance rules. Ensures rule integrity on creation and modification.

---

## Process

### When normalizing existing conventions (Bootstrap)

1. Locate all rule-like files and convention sources
2. Classify by domain: architecture / code quality / security / testing / performance
3. Translate each convention into standard GAAI rule format:
   - Explicit condition
   - Scope of application
   - Enforcement level
4. Store normalized rules under `contexts/rules/`
5. Remove ambiguity and duplication

### When creating or modifying a rule file

1. Read `contexts/rules/README.rules.md` — verify no existing rule already covers the intent
2. If creating: assign the correct `category` and next `id` in sequence; add entry to index
3. If modifying: confirm the change is a constraint refinement, not a workflow or agent behavior addition
4. Apply the standard rule file format (YAML frontmatter + markdown body)
5. Verify no overlap or contradiction with other rule files

---

## Quality Checks

- All critical project constraints are explicit
- Rules are machine-checkable
- No important convention remains implicit
- Governance coverage is clear
- No duplication across rule files

---

## Non-Goals

This skill must NOT:
- Create new architectural decisions
- Modify business logic
- Enforce rules during delivery (enforcement is handled by workflows and validation stages)

**No silent assumptions. Every constraint becomes explicit and governed.**

More from Fr-e-d/GAAI-framework

SkillDescription
abort-safe-handlerOrchestrator-level Stage 4 entry gate for /gaai:bootstrap. Presents a pre-loop "Skip Q&A entirely" option, delegates to qa-loop-ui when the user proceeds, and returns a unified abort_safe_result with telemetry on every path. Guarantees no partial state on skip or abort.
ambiguity-detectorTakes surface scan results, optional LLM synthesis open-question entries, and optional tree-sitter AST signals to score project ambiguities (1-10). Outputs structured ambiguity_feed for smart-question-generator. Pure heuristic — no LLM calls. Designed for Stage 3.5 of the /gaai:bootstrap pipeline (between LLM synthesis and Q&A).
approach-evaluationResearch industry standards and best practices, identify viable approaches for a given technical or architectural problem, and produce a structured factual comparison against project-specific constraints. Reports options — does not decide.
architecture-extractConvert raw project structure into clear architectural understanding — module boundaries, data flows, service relationships, and architectural patterns. Activate after codebase-scan during Bootstrap.
bootstrap-llm-synthesisConstruct the LLM synthesis prompt from project surface scan + optional tree-sitter context + optional Q&A answers. Call the LLM. Parse and validate the response into 6-8 structured memory entries with clarity tags and source traceability. Used as Stage 3 of the /gaai:bootstrap pipeline.
bootstrap-memory-ingest-cloudWrite structured memory entries to the Cloud workspace via gaai_memory.store MCP tool with source='bootstrap'. Loops over entries from bootstrap-llm-synthesis, calls the tool per entry, collects success/fail counts. Used as Stage 5 of the /gaai:bootstrap pipeline (Cloud path only).
browser-journey-testValidate user stories by simulating real user journeys in a live browser against deployed application. Activate after implementation to verify actual user experience against acceptance criteria, not just code logic.
build-agents-indexScan all agent and sub-agent definition files in .gaai/core/agents/, extract YAML frontmatter, merge with specialists.registry.yaml, and generate a derived agents-index.yaml at .gaai/core/agents/agents-index.yaml. Activate after adding, modifying, or removing any agent, sub-agent, or specialist entry.
build-skills-indexScan SKILL.md files in .gaai/core/skills/ and .gaai/project/skills/, extract YAML frontmatter, and regenerate separate skills indices for each layer. Core index ships with the OSS framework; project index is project-specific.
ci-watch-and-fixWatch GitHub Actions CI after PR creation, detect failures, extract logs, apply minimal fixes, and re-push — keeping the delivery session alive until CI resolves or escalating after 3 cycles. Activate immediately after gh pr create and before marking the story done.