More screenshots

    Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+22 more

    ai coding collaboration

    1

    Enforce senior-level engineering guardrails, task-level discipline, and evidence-based verification for AI coding.

    Free

    Security scanned
    ai coding collaboration

    ai coding collaboration

    Example session with this skill installed

    Use $ai-coding-collaboration to fix a duplicate submission bug in my React + TypeScript application.
    Users can click the Save button multiple times, causing duplicate API requests.

    Here is the existing code

    const [saving, setSaving] = useState(false);
    
    async function handleSave() {
      setSaving(true);
      await api.updateProfile(form);
      setSaving(false);
    }
    
    <button onClick={handleSave}>Save</button>
    

    Requirements

    • Prevent duplicate API calls, including rapid double-clicks.
    • Restore the button state if the request fails.
    • Keep the smallest possible code change.
    • Do not modify backend APIs, routes, or database schemas.
    • Do not install new dependencies.
    • Do not refactor unrelated components.
    • Classify the task and identify affected areas.
    • Provide P0 validation steps and actual verification status.
    • Finish with a concise executive summary.

    Do not claim the fix is merge-ready unless core validation has been completed.

    • Read your context and instructions
    • Compiled the ai coding collaboration

    AI Coding Guardrails — Bug Fix

    1. Task Classification

    Level: L1 — Small Feature / Bug Fix

    Goal: Prevent duplicate Save requests without introducing unnecessary abstractions or unrelated changes.

    Strategy: Minimal Diff + Impact Analysis + P0 Validation.

    2. Impact Analysis

    AreaImpactAction
    Backend APINoKeep existing endpoint
    Service logicNoNo changes
    DTO / TypesNoPreserve existing contracts
    Database / ConfigNoNo changes
    FrontendYesUpdate the Save handler
    RoutingNoNo changes
    TestsYesVerify success and failure paths

    Risk: Rapid clicks can reach the handler before React has rendered the disabled state. An immediate synchronous guard is required.

    3. Root Cause

    The original implementation has two problems:

    1. There is no synchronous in-flight guard, so multiple Save requests can start before the UI updates.
    2. If api.updateProfile() rejects, setSaving(false) is skipped, potentially leaving the button stuck in a loading state.

    No backend changes are needed.

    4. Minimal Fix

    Add one useRef guard and use try/finally to guarantee state restoration.

    const [saving, setSaving] = useState(false);
    const saveInFlight = useRef(false);
    
    async function handleSave() {
      if (saveInFlight.current) return;
    
      saveInFlight.current = true;
      setSaving(true);
    
      try {
        await api.updateProfile(form);
      } finally {
        saveInFlight.current = false;
        setSaving(false);
      }
    }
    

    Update the existing button

    <button
      type="button"
      disabled={saving}
      onClick={handleSave}
    >
      {saving ? "Saving..." : "Save"}
    </button>
    

    Why this approach?

    • useRef blocks duplicate requests synchronously.
    • disabled prevents additional user interaction.
    • try/finally restores the button after success or failure.
    • No new packages, APIs, services, or architectural layers.
    • Existing error-handling behavior remains outside this scoped fix.

    5. Before vs. After

    BehaviorBeforeAfter
    Rapid double-clickDuplicate requests possibleGuard blocks duplicates
    Request pendingButton remains clickableButton disabled
    Request failureLoading state may remain stuckState restored
    New dependenciesNoneNone
    Backend changesNoneNone
    Unrelated refactoringNot requiredNone

    6. P0 Validation Checklist

    CheckExpected ResultStatus
    Single clickOne API requestNot executed
    Rapid double-clickStill one requestNot executed
    Request succeedsButton becomes enabledNot executed
    Request failsButton becomes enabledNot executed
    Build / TypeScript checkNo errorsNot executed

    Verification evidence: The provided snippet supports a static code review and proposed fix. A runnable repository and test environment were not provided, so no tests or builds have been claimed as passed.

    P0 status: Pending execution.

    7. Executive Summary

    【目标】 Prevent duplicate Save submissions.

    【改动文件】 Existing React component only; no backend or API changes.

    【自测结果】 Static analysis completed. Runtime tests and typecheck remain pending.

    【风险】 Existing rejected-request error feedback may need separate review.

    【必须验收】 Double-click prevention, successful save, failed save, and TypeScript build.

    【结论】 Needs validation before merge.


    Value Delivered

    One targeted fix. No unnecessary architecture. No fabricated test results.

    AI Coding Guardrails keeps AI-generated changes small, traceable, and evidence-based—helping developers review and ship with greater confidence.

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

    About this skill

    AI coding agents often fail by overengineering simple fixes, introducing scope creep, or claiming success without verification. This skill forces agents to act like senior engineers by applying pragmatic guardrails to every task. It classifies work into four distinct levels to ensure the process matches the complexity, preventing unnecessary ceremony for micro-tasks while enforcing strict planning for architecture changes.

    What it does

    • Task classification categorizes work from L0 micro-fixes to L3 project-scale architecture to select the right workflow.
    • Risk assessment triggers high-level planning and explicit scope confirmation for changes to auth, payments, or database schemas.
    • Minimal diff enforcement prevents unrelated refactors, renames, or dependency additions to keep PRs clean and reviewable.
    • Tiered validation mandates P0/P1/P2 testing protocols to ensure core flows work before claiming completion.
    • Evidence-based reporting requires actual command output or manual paths instead of vague "tests passed" statements.

    How it works

    1. Trigger the skill by asking for a bug fix, feature, or code review.
    2. The agent performs a pre-implementation check to assess impact across APIs, services, and databases.
    3. Implementation follows the chosen task level, adhering to strict rules on minimal diffs and pattern reuse.
    4. The agent runs a self-check and provides a standardized executive summary with evidence of verification.

    Frameworks & tools

    This skill is framework-agnostic and works with any repository structure. It provides specific support for OpenSpec workflows but can operate independently in any standard development environment.

    Why this beats prompting it yourself

    Writing prompts to stop an LLM from over-refactoring is notoriously difficult. This skill provides a structured decision matrix and standardized reporting format that forces the agent to prove its work through specific evidence categories.

    Use cases

    • Preventing a simple CSS fix from turning into a full component refactor.
    • Enforcing strict safety checks for tasks involving database migrations or API contract changes.
    • Standardizing the way agents report test results and validation evidence.
    • Managing handoffs between different agents or between an agent and a human reviewer.

    Known limitations

    Does not automatically create testing environments or mock data. Requires the underlying agent to have access to terminal commands for P0 validation evidence.

    How to use

    Skills on Agensi run inside your AI agent. Copy the prompt, paste it into your agent, and it connects to Agensi and installs this skill for you. If a payment is needed, your agent shows it to you first.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill passes our trust checks below.

    Security scanned

    Passed our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Free forever

    No account required to browse

    Trust & safety

    Security scanned

    Verified clean 1 day ago

    • Free to download with an account

    Requires

    Git (recommended)
    Git

    Listed1 day ago

    What's inside

    Frequently Asked Questions