LLM Coding Rules

    1

    Enforce surgical edits and prevent LLM over-engineering with a strict behavioral coding contract.

    $5

    Secure checkout via Stripe

    Money-back guarantee

    Converts to your local currency at checkout

    Security scanned

    Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIDeepSeekDeepSeekMuseMuse+22 more

    LLM Coding Rules

    Example session with this skill installed

    Follow the LLM Coding Rules: Add a 'status' field to the User struct in models.go, default to 'pending'.

    • Read your context and instructions
    • Compiled the llm coding rules

    I will add a 'status' field to the User struct.

    Assumptions:

    1. The 'status' field should be a string to allow for future states (active, suspended).
    2. Existing JSON tags should be followed for consistency.

    Success Criteria:

    • models.go compiles successfully.
    • The User struct contains Status string json:"status"``.
    • New User instances default to "pending" in the constructor/factory function if one exists.

    Code Update

    // internal/models/user.go
    
    package models
    
    type User struct {
    	ID        int64     `json:"id"`
    	Email     string    `json:"email"`
    	Password  string    `json:"-"`
    +	Status    string    `json:"status"`
    	CreatedAt time.Time `json:"created_at"`
    }
    
    func NewUser(email, password string) *User {
    	return &User{
    		Email:    email,
    		Password: password,
    +		Status:   "pending",
    	}
    }
    

    Changes:

    • Modified internal/models/user.go: Added Status field to User struct and initialized it in NewUser.

    Trade-off:
    Using a string instead of an iota/enum increases memory slightly but avoids manual string mapping for JSON responses.

    Next steps:

    1. Run go build ./internal/models/... to verify compilation.
    2. Update the database schema migration to include the new column.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    The problem

    LLMs often over-engineer simple fixes, rewriting entire files and introducing breaking changes or unnecessary boilerplate just to update a single line of logic.

    What it does

    • Enforces surgical edits to minimize code churn and accidental side effects.
    • Forces the model to state assumptions and trade-offs before modifying files.
    • Requires the definition of verifiable success criteria (tests or diffs) prior to execution.
    • Prevents speculative generality by blocking unrequested abstractions and helpers.

    Why this beats prompting it yourself

    Standard prompts fail to prevent the "helpful" LLM from refactoring working code or adding unasked-for features. These rules act as a strict behavioral contract that keeps the model focused on the specific task, reducing review time and preventing architectural drift.

    Use cases

    • Quick bug fixes where you need to preserve existing file formatting.
    • Feature additions in large, sensitive codebases where side effects are costly.
    • Collaborative coding sessions where you need predictable, verifiable model outputs.
    • Refactoring tasks that require explicit trade-off analysis before implementation.

    Known limitations

    Requires an agent with file-reading capabilities. Not suitable for tasks where a complete architectural overhaul is the primary goal.

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Code Quality & Review.

    Requires an LLM with file-system access (e.g., Claude Code, Cursor). Not suitable for requests where a total system rewrite is intended.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before buying a skill.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Money-back guarantee

    Doesn't do what its page promises? You get your money back.

    Trust & safety

    Security scan

    Security scan passed 2 months ago

    Permissions

    No special permissions declared or detected

    Listed2 months ago

    What's inside

    Frequently Asked Questions

    This skill provides a set of rigorous behavioral instructions that prevent LLMs from refactoring entire files when only minor changes are needed, reducing code churn and preventing the introduction of bugs during simple updates.

    This skill is compatible with any AI coding agent or IDE extension that supports custom instructions or system prompts, such as Cursor, Windsurf, or GitHub Copilot Custom Instructions.

    Setup is straightforward: you will receive a structured configuration file that can be copied directly into your agent's system prompt or global rules settings, immediately enforcing the coding contract.

    Yes, the rules are language-agnostic and work effectively across Go, TypeScript, Python, and other major frameworks, focusing on logical precision rather than language-specific syntax.

    Upon purchase, you receive the full set of optimized behavioral rules, an implementation guide for various agents, and a checklist for defining success criteria to ensure the model follows the contract.

    While these rules excel at surgical edits and bug fixes, they are not recommended for total project migrations or architectural overhauls where wide-scale refactoring is the intended goal.

    New in Code Quality & Review