agentleFS
roedyrustamroedyrustam/vibes-plug/.cursor/skills/agentic-coding-workflow-expert/SKILL.md

agentic-coding-workflow-expert

Skill129 starsChanged 11 days agoMITView on GitHub

AI coding workflows, multi-agent code swarms, and CI/CD self-healing / Workflow koding AI, swarm multi-agen, dan self-healing CI/CD.

  • Deletes or force-pushes
  • Commits and pushes

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 6 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈6

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  • could be automatic: a setting could enforce it
  1. Distinctive:

    Plan → Implement → Verify → Refine: Always loop through planning, writing, testing, and iterating.

    line 45
  2. Distinctive:

    Implementation: Write code to satisfy generated tests.

    line 217
  3. Distinctive:

    Validation: Run tests, enforce coverage thresholds.

    line 218
  4. Distinctive:

    Rollback Safety: Always create a fix branch.

    line 255
  5. Distinctive:

    Incremental Updates: Update graph only on changed files.

    line 320
  6. Distinctive:

    Ensure safety with human oversight.

    line 368

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Agentic Coding Workflow Expert (2026 Edition)

English | Bahasa Indonesia


<a name="english"></a>

English

Orchestration & Integration

  • Upstream Orchestrators: Works under brainstorming and zero-to-prod-orchestrator (Phase 5 - Core Feature Development & Swarm Execution) to automate agentic coding pipelines.
  • Downstream Cooperating Skills:
    • multi-agent-orchestration — Coordinate multi-agent code swarms and task fan-out/fan-in topologies.
    • autonomous-tdd-debugger — Self-healing test runner and automated error resolution.
    • coderabbit — AI-powered PR review, automated diff summarization, and interactive feedback.
    • living-codebase-ast-graph — AST semantic analysis and cross-module impact radius calculation.
    • scalability-clean-code — Architectural compliance, DRY/SOLID enforcement, and code hygiene.
    • session-memory-manager — Persist agent learning history, architectural choices, and session memory.
  • Cross-Domain Synergy & Subagent Swarm Integration: ai-llm-integration-expert, speculative-multi-draft-synthesizer

Description

Production-grade framework for AI-assisted coding workflows and agent swarms. Covers autonomous code generation, multi-agent code swarms, self-healing CI/CD pipelines, automated PR reviews, codebase knowledge graphs, and human-in-the-loop approval gates.


1. Agentic Code Generation Patterns / Pola Generasi Kode Agentic

Implement autonomous code generation workflows. Implementasikan workflow pembuatan kode otonom.

Core Patterns / Pola Inti:

  1. Single-file vs Multi-file Generation:
    • Single-file: Isolate scope, update specific modules.
    • Multi-file: Coordinate state across files, ensure API contract consistency.
  2. Context-Aware Completion: Query codebase knowledge graph for semantic context before generating.
  3. Ghost Text / Inline Suggestion: Provide real-time snippet integration paths.
  4. Plan → Implement → Verify → Refine: Always loop through planning, writing, testing, and iterating.

Code Example: Multi-file Generation Workflow

// workflow-generator.ts
interface GenerationTask {
  plan: string;
  files: string[];
}

class AgenticGenerator {
  async execute(task: GenerationTask) {
    console.log(`[PLAN] Executing: ${task.plan}`);
    const generatedFiles = await this.generateFiles(task.files);
    
    for (const file of generatedFiles) {
      const isValid = await this.verify(file);
      if (!isValid) {
        await this.refine(file);
      }
    }
  }

  private async generateFiles(files: string[]) {
    // Generate code with multi-file context awareness
    return files.map(f => ({ name: f, content: "// generated code" }));
  }

  private async verify(file: any) {
    // Run linter and tests
    return true; 
  }

  private async refine(file: any) {
    // Apply fixes based on verification failures
  }
}

2. Multi-Agent Code Swarms / Swarm Kode Multi-Agen

Coordinate multiple specialized agents for complex engineering tasks. Koordinasikan beberapa agen khusus untuk tugas rekayasa yang kompleks.

Swarm Architecture:

  • Fan-out: Dispatch tasks to Frontend Agent, Backend Agent, Test Agent, and Review Agent.
  • Shared Workspace: Utilize branched git worktrees for isolated, parallel development.
  • Director Agent: Resolve conflicts, validate coherence across boundaries, merge branches.

Code Example: TypeScript Swarm Orchestration

// swarm-orchestrator.ts
enum AgentRole {
  FRONTEND, BACKEND, TEST, REVIEW, DIRECTOR
}

class SwarmDirector {
  async orchestrate(featureSpec: string) {
    // Fan-out
    const feTask = this.dispatch(AgentRole.FRONTEND, featureSpec);
    const beTask = this.dispatch(AgentRole.BACKEND, featureSpec);
    
    await Promise.all([feTask, beTask]);
    
    // Testing and Review
    const testResults = await this.dispatch(AgentRole.TEST, "Run integration tests");
    const reviewStatus = await this.dispatch(AgentRole.REVIEW, "Review cross-boundary changes");
    
    if (reviewStatus.approved) {
      await this.mergeWorktrees();
    } else {
      await this.resolveConflicts();
    }
  }

  private async dispatch(role: AgentRole, context: string) {
    // Send task to specific agent queue
    return { approved: true };
  }

  private async mergeWorktrees() {}
  private async resolveConflicts() {}
}

Code Example: Python CrewAI Engineering Swarm / Contoh Kode: Tim Rekayasa CrewAI

# crewai_engineering_swarm.py
from crewai import Agent, Crew, Process, Task
from crewai.tools import tool
from pydantic import BaseModel, Field

class CodeReviewResult(BaseModel):
    approved: bool
    lint_score: float = Field(ge=0.0, le=10.0)
    critical_findings: list[str] = Field(default_factory=list)
    suggested_refactors: list[str] = Field(default_factory=list)

@tool("run_linter_and_tests")
def run_linter_and_tests(target_module: str) -> str:
    """Runs automated AST linter, security scan, and test suite on target module."""
    return f"Evaluation of {target_module}: 18 unit tests passed, 0 security vulnerabilities, lint score 9.8/10."

def create_engineering_swarm(feature_spec: str) -> CodeReviewResult:
    # 1. Specialized Agents: Architect, Implementer, QA Guardian
    architect = Agent(
        role="Software Architect",
        goal="Decompose feature specifications into typed contracts and domain models",
        backstory="Principal Systems Architect focused on Domain-Driven Design and modularity.",
        verbose=True,
        memory=True
    )

    implementer = Agent(
        role="Senior Fullstack Craftsman",
        goal="Produce production-grade, typed implementations with zero technical debt",
        backstory="Senior polyglot engineer executing clean code patterns with complete test coverage.",
        verbose=True,
        memory=True
    )

    qa_guardian = Agent(
        role="Quality Guardian",
        goal="Audit code changes, verify test suites, and enforce static verification",
        backstory="DevSecOps & QA lead specialized in automated verification, AST analysis, and fuzzing.",
        tools=[run_linter_and_tests],
        verbose=True,
        memory=True
    )

    # 2. Sequential Engineering Tasks
    architecture_task = Task(
        description=f"Analyze specification: '{feature_spec}'. Design the data contracts and component interfaces.",
        expected_output="Modular architecture blueprint with typed function signatures.",
        agent=architect
    )

    coding_task = Task(
        description="Implement the architecture blueprint into production code adhering to Clean Code standards.",
        expected_output="Complete source code files without placeholders or stubs.",
        agent=implementer
    )

    review_task = Task(
        description="Run linting and test suite on the implemented code, verify security, and output formal review.",
        expected_output="A structured JSON evaluation matching the CodeReviewResult schema.",
        agent=qa_guardian,
        output_pydantic=CodeReviewResult
    )

    # 3. Assemble Sequential Swarm
    engineering_crew = Crew(
        agents=[architect, implementer, qa_guardian],
        tasks=[architecture_task, coding_task, review_task],
        process=Process.sequential,
        verbose=True
    )

    result = engineering_crew.kickoff()
    return result.pydantic

3. Spec-to-Code Pipeline / Pipeline Spec-to-Code

Transform natural language specifications into tested implementation. Ubah spesifikasi bahasa alami menjadi implementasi yang teruji.

Pipeline Steps:

  1. PRD to Test Cases (TDD): Extract acceptance criteria, generate unit/integration tests first.
  2. Implementation: Write code to satisfy generated tests.
  3. Validation: Run tests, enforce coverage thresholds.

Code Example: Spec-to-Test-to-Code

# spec_pipeline.py
def run_spec_to_code(prd_text: str):
    # 1. Extract and Generate Tests
    criteria = extract_acceptance_criteria(prd_text)
    tests = generate_tests_from_criteria(criteria)
    
    # 2. Implement
    implementation = generate_code_to_pass(tests)
    
    # 3. Validate
    result = run_tests(implementation, tests)
    if not result.passed:
        implementation = refine_code(implementation, result.errors)
        
    return implementation

def extract_acceptance_criteria(text): return []
def generate_tests_from_criteria(criteria): return []
def generate_code_to_pass(tests): return ""
def run_tests(code, tests): return type('Result', (), {'passed': True, 'errors': []})
def refine_code(code, errors): return code

4. Self-Healing CI/CD Pipelines / Pipeline CI/CD Self-Healing

Automate failure recovery in integration pipelines. Otomatisasi pemulihan kegagalan dalam pipeline integrasi.

Capabilities:

  • Detection: Parse terminal output and stack traces from CI runners.
  • Root-Cause Analysis: Pattern match common failure modes (e.g., missing dependencies, type errors).
  • Auto-Fix Generation: Propose fixes with confidence scoring.
  • Rollback Safety: Always create a fix branch; never push directly to main.

Code Example: CI Failure Analyzer

#!/bin/bash
# ci-self-heal.sh

LOG_FILE="ci-output.log"
FAIL_PATTERN="ERR!"

if grep -q "$FAIL_PATTERN" "$LOG_FILE"; then
  echo "[CI] Failure detected. Triggering self-healing agent..."
  
  # Analyze logs and generate patch
  PATCH_FILE=$(agent-analyze-ci --log "$LOG_FILE")
  
  if [ -n "$PATCH_FILE" ]; then
    git checkout -b auto-fix-$(date +%s)
    git apply "$PATCH_FILE"
    git commit -m "chore(ci): auto-fix CI failure"
    git push origin HEAD
    echo "[CI] Fix pushed for review."
  else
    echo "[CI] Could not auto-fix. Escalating."
    exit 1
  fi
fi

5. Agentic Code Review / Review Kode Agentic

Perform deep, context-aware automated code reviews. Lakukan review kode otomatis yang mendalam dan peka konteks.

Review Dimensions:

  • Impact Analysis: Summarize PRs and map cross-module impact.
  • Security: Scan for CVEs, audit dependencies, flag unsafe patterns.
  • Performance: Detect regressions in bundle size or runtime complexity (Big-O).
  • Style: Enforce project-specific conventions.

Code Example: Automated Review Checklist

# review-rules.yml
rules:
  security:
    - detect_sql_injection
    - audit_package_json
  performance:
    - max_bundle_size_kb: 500
    - flag_nested_loops: true
  style:
    - enforce_strict_types

6. Codebase Knowledge Graph / Knowledge Graph Codebase

Build semantic graphs for contextual intelligence. Bangun grafik semantik untuk kecerdasan kontekstual.

Graph Components:

  • AST Parsing: Extract nodes and relationships using tree-sitter.
  • Graph Topology: Function call graphs, import trees, type hierarchies.
  • Semantic Search: Embed codebase snippets for retrieval-augmented generation (RAG).
  • Incremental Updates: Update graph only on changed files.

Code Example: Building Graph with Tree-Sitter

// graph-builder.js
const Parser = require('tree-sitter');
const JavaScript = require('tree-sitter-javascript');

const parser = new Parser();
parser.setLanguage(JavaScript);

function buildASTGraph(sourceCode) {
  const tree = parser.parse(sourceCode);
  const graph = { nodes: [], edges: [] };
  
  // Traverse tree to extract function declarations and calls
  traverse(tree.rootNode, (node) => {
    if (node.type === 'function_declaration') {
      graph.nodes.push({ id: node.text, type: 'function' });
    }
    // Extract edges based on call expressions
  });
  
  return graph;
}

function traverse(node, callback) {
  callback(node);
  for (let i = 0; i < node.childCount; i++) {
    traverse(node.child(i), callback);
  }
}

7. Code Agent Memory & Learning / Memori & Pembelajaran Agen Kode

Persist context and learn from interactions. Pertahankan konteks dan belajar dari interaksi.

Memory Mechanics:

  • Per-Project Context: Store conventions, architectural decisions, and patterns.
  • Correction Learning: Log past mistakes and explicitly avoid them in future generation.
  • Session Persistence: Utilize session-memory-manager to maintain state across agent runs.
  • Convention Extraction: Automatically derive team style guidelines from existing codebase.

8. Human-in-the-Loop Code Gates / Gate Kode Human-in-the-Loop

Ensure safety with human oversight. Pastikan keamanan dengan pengawasan manusia.

Gate Mechanisms:

  • Confidence Threshold: High confidence -> auto-apply. Low confidence -> request approval.
  • Diff Preview: Present clear, annotated diffs with risk assessments.
  • Destructive Approvals: Mandate human sign-off for DB migrations or breaking API changes.
  • Escalation: Alert human developers when agent loop is stuck or oscillating.

Hard Guardrails (Declarative Invariants)

  1. Isolated Branch & Git Worktree Execution:
    • Coding agents and multi-agent swarms MUST execute modifications within dedicated feature branches or isolated git worktrees. Unchecked direct mutations or direct pushes to production/main branches are strictly prohibited.
  2. Mandatory Pre-Commit Anti-Slop & Syntax Gates:
    • Autonomous code generation pipelines MUST verify syntactic validity and run anti-slop checks (node scripts/check-anti-slop.js --strict) before committing or proposing diffs. Committing placeholder tokens (TODO, ...rest of code) is strictly prohibited.
  3. Bounded Self-Healing Loop Limits:
    • CI/CD self-healing and test-fix loops MUST enforce a strict maximum ceiling of 2 iterative repair attempts (maxRetries <= 2). Unbounded recursive retry loops that consume unlimited reasoning tokens are forbidden.
  4. Mandatory Human-in-the-Loop Escalation on High-Impact Operations:
    • Any agentic workflow involving schema drop operations (DROP TABLE, DROP COLUMN), credential changes, or breaking API contract mutations MUST halt and require explicit human confirmation.

Sovereign Execution, Token Efficiency & Invariants

DimensionSovereign Mandate & Deterministic Contract
Frontier Model CascadeHigh Fast / Medium / High (Gemini 4 Carbon/Hydrogen/Neon/Argon/Pro, Grok 4.7 High Fast, Claude Sonnet/Opus 5.5, GPT-5.6 Sol)
Availability FallbackGemini 4 (Carbon/Hydrogen/Neon/Argon/Pro) -> Gemini 3.8 Flash; Claude Opus 5.5 -> Claude Opus 4.6 (Zero unhandled missing-model errors)
KV-Cache & Token ProtocolPin static instructions & schemas at prompt prefix (kv-cache-prefix-optimizer); pass surgical CONTEXT_MAP.md slices (<250 tokens/call) during Swarm Fan-Out
SaaT CLI & MCP DispatchCLI: vibes skill exec agentic-coding-workflow-expert <audit|eval|verify|generate|blueprint> / MCP: vibes_skill_dispatch, vibes_ast_query, vibes_compile_cache, vibes_optimize_budget, vibes_verify_gate
NFR & Anti-Slop InvariantsAST mutation blast radius <= 1 module, git worktree cleanup 100%, automated self-heal pass rate >= 90%; 100% complete zero-placeholder output verified via node scripts/check-anti-slop.js --strict


<a name="bahasa-indonesia"></a>

Bahasa Indonesia

Integrasi Orkestrasi

  • Orkestrator Hulu: Beroperasi di bawah arahan brainstorming dan zero-to-prod-orchestrator (Fase 5 - Pengembangan Fitur Utama & Eksekusi Swarm) untuk mengotomasi alur pembuatan kode agentic.
  • Skill Hilir & Kerja Sama:
    • multi-agent-orchestration — Mengoordinasikan swarm multi-agen dan topologi fan-out/fan-in tugas.
    • autonomous-tdd-debugger — Runner tes self-healing dan remediasi error otomatis.
    • coderabbit — Review PR berbasis AI, ringkasan diff otomatis, dan feedback interaktif.
    • living-codebase-ast-graph — Analisis semantik AST dan kalkulasi radius dampak lintas modul.
    • scalability-clean-code — Kepatuhan arsitektur, penegakan prinsip DRY/SOLID, dan kebersihan kode.
    • session-memory-manager — Menyimpan histori pembelajaran agen, pilihan arsitektur, dan memori sesi.
  • Sinergi Lintas Domain & Integrasi Swarm Subagent: ai-llm-integration-expert, speculative-multi-draft-synthesizer

Deskripsi

Panduan produksi untuk alur kerja pembuatan kode berbasis AI dan swarm agen. Mencakup pembuatan kode otonom, koordinasi swarm multi-agen, pipeline CI/CD self-healing, review PR otomatis, graph pengetahuan codebase AST, dan gerbang persetujuan human-in-the-loop.

Matriks Eksekusi Berdaulat, Efisiensi Token & Invarian

DimensiMandat Berdaulat & Kontrak Deterministik
Kaskade Model FrontierHigh Fast / Medium / High (Gemini 4 Carbon/Hydrogen/Neon/Argon/Pro, Grok 4.7 High Fast, Claude Sonnet/Opus 5.5, GPT-5.6 Sol)
Invarian Fallback KetersediaanGemini 4 (Carbon/Hydrogen/Neon/Argon/Pro) -> Gemini 3.8 Flash; Claude Opus 5.5 -> Claude Opus 4.6 (Bebas gagal saat model belum tersedia/kuota penuh)
Protokol Hemat Token & KV-CacheKunci instruksi & skema statis di prefix awal (kv-cache-prefix-optimizer); kirim potongan CONTEXT_MAP.md (<250 token/panggilan) saat Fan-Out
Eksekusi SaaT CLI & MCPCLI: vibes skill exec agentic-coding-workflow-expert <audit|eval|verify|generate|blueprint> / MCP: vibes_skill_dispatch, vibes_ast_query, vibes_compile_cache, vibes_optimize_budget, vibes_verify_gate
Invarian NFR & Anti-SlopRadius dampak mutasi AST <= 1 modul, pembersihan git worktree 100%, tingkat kelulusan self-heal otomatis >= 90%; kode 100% tuntas tanpa placeholder diverifikasi melalui node scripts/check-anti-slop.js --strict

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.