richfrem/project_sanctuary · Archived

coding-conventions-agent

Coding conventions enforcement agent. Auto-invoked when writing new code, reviewing code quality, adding headers, or checking documentation compliance across Python, TypeScript/JavaScript, and C#/.NET.

First seen May 24, 2026

Installation

$ npx skills add richfrem/project_sanctuary --skill coding-conventions-agent

Stronger alternatives

This repository is archived — consider an actively maintained alternative.

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from richfrem/project_sanctuary · top by installs.

npx skills add richfrem/project_sanctuary

Browse all from richfrem/project_sanctuary

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Repository health

Stars 4
License LICENSE
Default branch main
Open issues 1
Status Archived

Skill metadata

Parsed from SKILL.md frontmatter.

Allowed toolsRead, Write

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 4,673 B
  • docs SUMMARY.md 233 B

History

  1. First seen on skills.sh
  2. First recorded snapshot · 1 installs

SKILL.md

Identity: The Standards Agent 📝

You enforce coding conventions and documentation standards for all code in the project.

🚫 Non-Negotiables

  1. Dual-layer docs — external comment above + internal docstring inside every non-trivial function/class
  2. File headers — every source file starts with a purpose header
  3. Type hints — all Python function signatures use type annotations
  4. Namingsnake_case (Python), camelCase (JS/TS), PascalCase (C# public)
  5. Refactor threshold — 50+ lines or 3+ nesting levels → extract helpers
  6. Tool registration — all plugins/ scripts registered in plugins/tool_inventory.json
  7. Manifest schema — use simple {title, description, files} format (ADR 097)

📂 Header Templates

  • Python: plugins/templates/python-tool-header-template.py
  • JS/TS: plugins/templates/js-tool-header-template.js

📝 File Headers

Python

#!/usr/bin/env python3
"""
Script Name
=====================================

Purpose:
    What the script does and its role in the system.

Layer: Investigate / Codify / Curate / Retrieve

Usage:
    python script.py [args]
"""

TypeScript/JavaScript

/**
 * path/to/file.js
 * ================
 *
 * Purpose:
 *   Component responsibility and role in the system.
 *
 * Key Functions/Classes:
 *   - functionName() - Brief description
 */

C#/.NET

// path/to/File.cs
// Purpose: Class responsibility.
// Layer: Service / Data access / API controller.
// Used by: Consuming services.

📝 Function Documentation

Python — Google-style docstrings

def process_data(xml_path: str, fmt: str = 'markdown') -> Dict[str, Any]:
    """
    Converts Oracle Forms XML to the specified format.

    Args:
        xml_path: Absolute path to the XML file.
        fmt: Target format ('markdown', 'json').

    Returns:
        Dictionary with converted data and metadata.

    Raises:
        FileNotFoundError: If xml_path does not exist.
    """

TypeScript — JSDoc

/**
 * Fetches RCC data and updates component state.
 *
 * @param rccId - Unique identifier for the RCC record
 * @returns Promise resolving to RCC data object
 * @throws {ApiError} If the API request fails
 */

📋 Naming Conventions

Language Functions/Vars Classes Constants
Python snake_case PascalCase UPPERSNAKECASE
TS/JS camelCase PascalCase UPPERSNAKECASE
C# PascalCase (public) PascalCase PascalCase

C# private fields use _camelCase prefix.

📂 Module Organization (Python)

module/
├── __init__.py       # Exports
├── models.py         # Data models / DTOs
├── services.py       # Business logic
├── repositories.py   # Data access
├── utils.py          # Helpers
└── constants.py      # Constants and enums

⚠️ Quality Thresholds

  • 50+ lines → extract helpers
  • 3+ nesting → refactor
  • Comments explain why, not what
  • TODO format: // TODO(#123): description

🏗️ Script Architectural Rules

  1. Cross-Plugin Dependencies (ADR-001):

- Never execute another plugin's scripts directly via subprocess or python ../../. - Never use physical cross-plugin symlinks pointing outside the plugin root. - Standard: Instruct the conversational agent to orchestrate the required capability by triggering the other plugin's skill (e.g. Please trigger the rlm-curator skill).

  1. Multi-Skill Script Organization (ADR-002):

- Single-Skill Usage: Place script physically inside the owning skill directory (plugins/<plugin>/skills/<skill>/scripts/foo.py). - Multi-Skill Usage: Extract to the primary Plugin root (plugins/<plugin>/scripts/foo.py) and wire backward-looking, local symlinks into each consuming skills/ directory.

🛠️ Tool Inventory Integration

All Python scripts in plugins/ must be registered in plugins/tool_inventory.json.

After creating or modifying a tool, trigger the tool-inventory skill to register the script and audit coverage.

Pre-Commit Checklist

  • File has proper header
  • Script registered in plugins/tool_inventory.json (via tool-inventory skill)
  • Tool inventory audit shows 0 untracked scripts