EMR/EHR development patterns for healthcare applications. Clinical safety, encounter workflows, prescription generation, clinical decision support integration, and accessibility-first UI for medical data entry.

Healthcare EMR Development Patterns
How It Works
UI Patterns for Clinical Data

UI Patterns for Clinical Data

**Vitals Display:** Current values with normal range highlighting (green/yellow/red), trend arrows vs previous, clinical scoring auto-calculated (NEWS2, qSOFA), escalation guidance inline.

**Lab Results Display:** Normal range highlighting, previous value comparison, critical values with non-dismissable alert, collection/analysis timestamps, pending orders with expected turnaround.

**Prescription PDF:** One-click generation with patient demographics, allergies, diagnosis, drug details (generic + brand, dose, route, frequency, duration), clinician signature block.


Apple FoundationModels framework for on-device LLM — text generation, guided generation with @Generable, tool calling, and snapshot streaming in iOS 26+.

FoundationModels: On-Device LLM (iOS 26)

When to Activate

Building AI-powered features using Apple Intelligence on-device

Generating or summarizing text without cloud dependency

Extracting structured data from natural language input

Implementing custom tool calling for domain-specific AI actions

Streaming structured responses for real-time UI updates

Need privacy-preserving AI (no data leaves the device)


C++ coding standards based on the C++ Core Guidelines (isocpp.github.io). Use when writing, reviewing, or refactoring C++ code to enforce modern, safe, and idiomatic practices.

C++ Coding Standards (C++ Core Guidelines)

Standard Library (SL.*)

Key Rules

| Rule | Summary |
|------|---------|
| **SL.1** | Use libraries wherever possible |
| **SL.2** | Prefer the standard library to other libraries |
| **SL.con.1** | Prefer `std::array` or `std::vector` over C arrays |
| **SL.con.2** | Prefer `std::vector` by default |
| **SL.str.1** | Use `std::string` to own character sequences |
| **SL.str.2** | Use `std::string_view` to refer to character sequences |
| **SL.io.50** | Avoid `endl` (use `'\n'` -- `endl` forces a flush) |


Use this skill to monitor a deployed URL for regressions after deploys, merges, or dependency upgrades.

Canary Watch — Post-Deploy Monitoring
Integration

Output

Integration

Pair with:

`/browser-qa` for pre-deploy verification

Hooks: add as a PostToolUse hook on `git push` to auto-check after deploys

CI: run in GitHub Actions after deploy step


Add x402 payment execution to AI agents — per-task budgets, spending controls, and non-custodial wallets via MCP tools. Use when agents need to pay for APIs, services, or other agents.

Agent Payment Execution (x402)
How It Works
Spending Controls

Spending Controls

Every payment tool call enforces a `SpendingPolicy`:

**Per-task budget** — max spend for a single agent action

**Per-session budget** — cumulative limit across an entire session

**Allowlisted recipients** — restrict which addresses/services the agent can pay

**Rate limits** — max transactions per minute/hour


Spring Boot architecture patterns, REST API design, layered services, data access, caching, async processing, and logging. Use for Java Spring Boot backend work.

Spring Boot Development Patterns
Observability

Observability

Structured logging (JSON) via Logback encoder

Metrics: Micrometer + Prometheus/OTel

Tracing: Micrometer Tracing with OpenTelemetry or Brave backend


HIPAA-specific entrypoint for healthcare privacy and security work. Use when a task is explicitly framed around HIPAA, PHI handling, covered entities, BAAs, breach posture, or US healthcare compliance requirements.

How It Works

Treat HIPAA as an overlay on top of the broader healthcare privacy skill:

Start with `healthcare-phi-compliance` for the concrete implementation rules.

Apply HIPAA-specific decision gates:

Is this data PHI?

Is this actor a covered entity or business associate?

Does a vendor or model provider require a BAA before touching the data?

Is access limited to the minimum necessary scope?

Are read/write/export events auditable?

Escalate to `healthcare-reviewer` if the task affects patient safety, clinical workflows, or regulated production architecture.


Record polished UI demo videos using Playwright. Use when the user asks to create a demo, walkthrough, screen recording, or tutorial video of a web application. Produces WebM videos with visible cursor, natural pacing, and professional feel.

Phase 3: Record

Only after discovery and rehearsal pass should you create the recording.


iOS 26 Liquid Glass design system — dynamic glass material with blur, reflection, and interactive morphing for SwiftUI, UIKit, and WidgetKit.

Extending Horizontal Scrolling Under Sidebar

To allow horizontal scroll content to extend under a sidebar or inspector, ensure the `ScrollView` content reaches the leading/trailing edges of the container. The system automatically handles the under-sidebar scrolling behavior when the layout extends to the edges — no additional modifier is needed.


Playwright E2E testing patterns, Page Object Model, configuration, CI/CD integration, artifact management, and flaky test strategies.

E2E Testing Patterns
Playwright Configuration

Test File Organization

Page Object Model (POM)

Test Structure

Playwright Configuration


Codified expertise for electricity and gas procurement, tariff optimization, demand charge management, renewable PPA evaluation, and multi-facility energy cost management. Informed by energy procurement managers with 15+ years experience at large commercial and industrial consumers. Includes market structure analysis, hedging strategies, load profiling, and sustainability reporting frameworks. Use when procuring energy, optimizing tariffs, managing demand charges, evaluating PPAs, or developing energy strategies.

Energy Procurement
Communication Patterns
Internal Stakeholders

Internal Stakeholders

**Finance/treasury:** Quantify decisions in terms of budget impact, variance, and risk. "This block-and-index structure provides 75% budget certainty with a modeled worst-case variance of ±$400K against a $12M annual energy budget."

**Sustainability:** Map procurement decisions to Scope 2 targets. "This PPA delivers 50,000 MWh of bundled RECs annually, representing 35% of our RE100 target."

**Operations:** Focus on operational requirements and constraints. "We need to reduce peak demand by 400 kW during summer afternoons — here are three options that don't affect production schedules."

Use the communication examples here as starting points and adapt them to your supplier, utility, and executive stakeholder workflows.


Write articles, guides, blog posts, tutorials, newsletter issues, and other long-form content in a distinctive voice derived from supplied examples or brand guidance. Use when the user wants polished written content longer than a paragraph, especially when voice consistency, structure, and credibility matter.

Article Writing

Write long-form content that sounds like an actual person with a point of view, not an LLM smoothing itself into paste.


Capture architectural decisions made during Claude Code sessions as structured ADRs. Auto-detects decision moments, records context, alternatives considered, and rationale. Maintains an ADR log so future developers understand why the codebase is shaped the way it is.

Architecture Decision Records
Integration with Other Skills

Integration with Other Skills

**Planner agent**: when the planner proposes architecture changes, suggest creating an ADR

**Code reviewer agent**: flag PRs that introduce architectural changes without a corresponding ADR


Audit, plan, and implement SEO improvements across technical SEO, on-page optimization, structured data, Core Web Vitals, and content strategy. Use when the user wants better search visibility, SEO remediation, schema markup, sitemap/robots work, or keyword mapping.

Related Skills

`seo-specialist`

`frontend-patterns`

`brand-voice`

`market-research`


Operate notifications as one ECC-native workflow across GitHub, Linear, desktop alerts, hooks, and connected communication surfaces. Use when the real problem is alert routing, deduplication, escalation, or inbox collapse.

Unified Notifications Ops
Default Severity Model

Default Severity Model

| Class | Examples | Default handling |
| --- | --- | --- |
| Critical | broken default-branch CI, security issue, blocked release, failed deploy | interrupt now |
| High | review requested, failing PR, owner-blocking handoff | same-day alert |
| Medium | issue state changes, notable comments, backlog movement | digest or queue |
| Low | repeat successes, routine churn, redundant lifecycle markers | suppress or fold |

If the workspace has no severity model, build one before proposing automation.


Operate as an agentic engineer using eval-first execution, decomposition, and cost-aware model routing.

Cost Discipline

Track per task:

model

token estimate

retries

wall-clock time

success/failure

Escalate model tier only when lower tier fails with a clear reasoning gap.


Pythonic idioms, PEP 8 standards, type hints, and best practices for building robust, efficient, and maintainable Python applications.

Python Development Patterns
Decorators
Parameterized Decorators

Data Classes with Validation

Named Tuples

Decorators

Function Decorators

Parameterized Decorators


Discover and evaluate Laravel packages via LaraPlugins.io MCP. Use when the user wants to find plugins, check package health, or assess Laravel/PHP compatibility.

Laravel Plugin Discovery
MCP Tools
SearchPluginTool

MCP Tools

The LaraPlugins MCP provides two primary tools:

SearchPluginTool

Search packages by keyword, health score, vendor, and version compatibility.

**Parameters:**

`text_search` (string, optional): Keyword to search (e.g. "permission", "admin", "api")

`health_score` (string, optional): Filter by health band — `Healthy`, `Medium`, `Unhealthy`, or `Unrated`

`laravel_compatibility` (string, optional): Filter by Laravel version — `"5"`, `"6"`, `"7"`, `"8"`, `"9"`, `"10"`, `"11"`, `"12"`, `"13"`

`php_compatibility` (string, optional): Filter by PHP version — `"7.4"`, `"8.0"`, `"8.1"`, `"8.2"`, `"8.3"`, `"8.4"`, `"8.5"`

`vendor_filter` (string, optional): Filter by vendor name (e.g. "spatie", "laravel")

`page` (number, optional): Page number for pagination


Swift 6.2 Approachable Concurrency — single-threaded by default, @concurrent for explicit background offloading, isolated conformances for main actor types.

Swift 6.2 Approachable Concurrency
Best Practices

Best Practices

**Start on MainActor** — write single-threaded code first, optimize later

**Use `@concurrent` only for CPU-intensive work** — image processing, compression, complex computation

**Enable MainActor inference mode** for app targets that are mostly single-threaded

**Profile before offloading** — use Instruments to find actual bottlenecks

**Protect globals with MainActor** — global/static mutable state needs actor isolation

**Use isolated conformances** instead of `nonisolated` workarounds or `@Sendable` wrappers

**Migrate incrementally** — enable features one at a time in build settings


Build a fully automated AI-powered data collection agent for any public source — job boards, prices, news, GitHub, sports, anything. Scrapes on a schedule, enriches data with a free LLM (Gemini Flash), stores results in Notion/Sheets/Supabase, and learns from user feedback. Runs 100% free on GitHub Actions. Use when the user wants to monitor, collect, or track any public data automatically.

Data Scraper Agent

Build a production-ready, AI-powered data collection agent for any public data source.
Runs on a schedule, enriches results with a free LLM, stores to a database, and improves over time.

**Stack: Python · Gemini Flash (free) · GitHub Actions (free) · Notion / Sheets / Supabase**


JetBrains Exposed ORM patterns including DSL queries, DAO pattern, transactions, HikariCP connection pooling, Flyway migrations, and repository pattern.

When to Use

Setting up database access with Exposed

Writing SQL queries using Exposed DSL or DAO

Configuring connection pooling with HikariCP

Creating database migrations with Flyway

Implementing the repository pattern with Exposed

Handling JSON columns and complex queries


SwiftUI architecture patterns, state management with @Observable, view composition, navigation, performance optimization, and modern iOS/macOS UI best practices.

SwiftUI Patterns
State Management
Environment Injection

View Consuming the ViewModel

Environment Injection

Replace `@EnvironmentObject` with `@Environment`:


Codified expertise for customs documentation, tariff classification, duty optimization, restricted party screening, and regulatory compliance across multiple jurisdictions. Informed by trade compliance specialists with 15+ years experience. Includes HS classification logic, Incoterms application, FTA utilization, and penalty mitigation. Use when handling customs clearance, tariff classification, trade compliance, import/export documentation, or duty optimization.

Customs & Trade Compliance
Decision Frameworks
Classification Decision Logic

Decision Frameworks

Classification Decision Logic

When classifying a product, follow this sequence without shortcuts. Convert it into an internal decision tree before automating any tariff-classification workflow.

**Identify the good precisely.** Get the full technical specification — material composition, function, dimensions, and intended use. Never classify from a product name alone.

**Determine the Section and Chapter.** Use the Section and Chapter notes to confirm or exclude. Chapter notes override heading text.

**Apply GRI 1.** Read the heading terms literally. If only one heading covers the good, classification is decided.

**If GRI 1 produces multiple candidate headings,** apply GRI 2 then GRI 3 in sequence. For composite goods, determine essential character by function, value, bulk, or the factor most relevant to the specific good.

**Validate at the subheading level.** Apply GRI 6. Check subheading notes. Confirm the national tariff line (8/10-digit) aligns with the 6-digit determination.

**Check for binding rulings.** Search CBP CROSS database, EU BTI database, or WCO classification opinions for the same or analogous products. Existing rulings are persuasive even if not directly binding.

**Document the rationale.** Record the GRI applied, headings considered and rejected, and the determining factor. This documentation is your defence in an audit.


Offers the user an informed choice about how much response depth to consume before answering. Use this skill when the user explicitly wants to control response length, depth, or token budget. TRIGGER when: "token budget", "token count", "token usage", "token limit", "response length", "answer depth", "short version", "brief answer", "detailed answer", "exhaustive answer", "respuesta corta vs larga", "cuántos tokens", "ahorrar tokens", "responde al 50%", "dame la versión corta", "quiero controlar cuánto usas", or clear variants where the user is explicitly asking to control answer size or depth. DO NOT TRIGGER when: user has already specified a level in the current session (maintain it), the request is clearly a one-word answer, or "token" refers to auth/session/payment tokens rather than response size.

Step 2 — Estimate response size by complexity

Classify the prompt, then apply the multiplier range to get the full response window:

| Complexity   | Multiplier range | Example prompts                                      |
|--------------|------------------|------------------------------------------------------|
| Simple       | 3× – 8×          | "What is X?", yes/no, single fact                   |
| Medium       | 8× – 20×         | "How does X work?"                                  |
| Medium-High  | 10× – 25×        | Code request with context                           |
| Complex      | 15× – 40×        | Multi-part analysis, comparisons, architecture      |
| Creative     | 10× – 30×        | Stories, essays, narrative writing                  |

Response window = `input_tokens × mult_min` to `input_tokens × mult_max` (but don’t exceed your model’s configured output-token limit).


Knowledge base management, ingestion, sync, and retrieval across multiple storage layers (local files, MCP memory, vector stores, Git repos). Use when the user wants to save, organize, sync, deduplicate, or search across their knowledge systems.

Knowledge Operations
Sync Operations
Workspace State Sync

Workspace State Sync

Mirror important workspace configuration and scripts to the knowledge base:

Generate directory maps

Redact sensitive config before committing

Track changes over time

Do not treat the knowledge base or archive folder as the live code workspace


Customs & Trade Compliance
Core Knowledge
Incoterms 2020

Incoterms 2020

Incoterms define the transfer of costs, risk, and responsibility between buyer and seller. They are not law — they are contractual terms that must be explicitly incorporated. Critical compliance implications:

**EXW (Ex Works):** Seller's minimum obligation. Buyer arranges everything. Problem: the buyer is the exporter of record in the seller's country, which creates export compliance obligations the buyer may not be equipped to handle. Rarely appropriate for international trade.

**FCA (Free Carrier):** Seller delivers to carrier at named place. Seller handles export clearance. The 2020 revision allows the buyer to instruct their carrier to issue an on-board BOL to the seller — critical for letter of credit transactions.

**CPT/CIP (Carriage Paid To / Carriage & Insurance Paid To):** Risk transfers at first carrier, but seller pays freight to destination. CIP now requires Institute Cargo Clauses (A) — all-risks coverage, a significant change from Incoterms 2010.

**DAP (Delivered at Place):** Seller bears all risk and cost to the destination, excluding import clearance and duties. The seller does not clear customs in the destination country.

**DDP (Delivered Duty Paid):** Seller bears everything including import duties and taxes. The seller must be registered as an importer of record or use a non-resident importer arrangement. Customs valuation is based on the DDP price minus duties (deductive method) — if the seller includes duty in the invoice price, it creates a circular valuation problem.

**Valuation impact:** Incoterms affect the invoice structure, but customs valuation still follows the importing regime's rules. In the U.S., CBP transaction value generally excludes international freight and insurance; in the EU, customs value generally includes transport and insurance costs up to the place of entry into the Union. Getting this wrong changes the duty calculation even when the commercial term is clear.

**Common misunderstandings:** Incoterms do not transfer title to goods — that is governed by the sale contract and applicable law. Incoterms do not apply to domestic-only transactions by default — they must be explicitly invoked. Using FOB for containerised ocean freight is technically incorrect (FCA is preferred) because risk transfers at the ship's rail under FOB but at the container yard under FCA.


Cache expensive file processing results using SHA-256 content hashes — path-independent, auto-invalidating, with service layer separation.

Content-Hash File Cache Pattern
Core Pattern
3. File-Based Cache Storage

2. Frozen Dataclass for Cache Entry

3. File-Based Cache Storage

Each cache entry is stored as `{hash}.json` — O(1) lookup by hash, no index file required.


Use this skill to measure performance baselines, detect regressions before/after PRs, and compare stack alternatives.

Benchmark — Performance Baseline & Regression Detection

When to Use

Before and after a PR to measure performance impact

Setting up performance baselines for a project

When users report "it feels slow"

Before a launch — ensure you meet performance targets

Comparing your stack against alternatives


Weighted social-graph ranking for warm intro discovery, bridge scoring, and network gap analysis across X and LinkedIn. Use when the user wants the reusable graph-ranking engine itself, not the broader outreach or network-maintenance workflow layered on top of it.

Inputs

Collect or infer:

target people, companies, or ICP definition

the user's current graph on X, LinkedIn, or both

weighting priorities such as role, industry, geography, and responsiveness

traversal depth and decay tolerance


Interactive installer for Everything Claude Code — guides users through selecting and installing skills and rules to user-level or project-level directories, verifies paths, and optionally optimizes installed files.

Configure Everything Claude Code (ECC)
Step 2: Select & Install Skills
2c: Confirm Individual Skills

2c: Confirm Individual Skills

For each selected category, print the full list of skills below and ask the user to confirm or deselect specific ones. If the list exceeds 4 items, print the list as text and use `AskUserQuestion` with an "Install all listed" option plus "Other" for the user to paste specific names.

**Category: Framework & Language (21 skills)**

| Skill | Description |
|-------|-------------|
| `backend-patterns` | Backend architecture, API design, server-side best practices for Node.js/Express/Next.js |
| `coding-standards` | Universal coding standards for TypeScript, JavaScript, React, Node.js |
| `django-patterns` | Django architecture, REST API with DRF, ORM, caching, signals, middleware |
| `django-security` | Django security: auth, CSRF, SQL injection, XSS prevention |
| `django-tdd` | Django testing with pytest-django, factory_boy, mocking, coverage |
| `django-verification` | Django verification loop: migrations, linting, tests, security scans |
| `laravel-patterns` | Laravel architecture patterns: routing, controllers, Eloquent, queues, caching |
| `laravel-security` | Laravel security: auth, policies, CSRF, mass assignment, rate limiting |
| `laravel-tdd` | Laravel testing with PHPUnit and Pest, factories, fakes, coverage |
| `laravel-verification` | Laravel verification: linting, static analysis, tests, security scans |
| `frontend-patterns` | React, Next.js, state management, performance, UI patterns |
| `frontend-slides` | Zero-dependency HTML presentations, style previews, and PPTX-to-web conversion |
| `golang-patterns` | Idiomatic Go patterns, conventions for robust Go applications |
| `golang-testing` | Go testing: table-driven tests, subtests, benchmarks, fuzzing |
| `java-coding-standards` | Java coding standards for Spring Boot: naming, immutability, Optional, streams |
| `python-patterns` | Pythonic idioms, PEP 8, type hints, best practices |
| `python-testing` | Python testing with pytest, TDD, fixtures, mocking, parametrization |
| `springboot-patterns` | Spring Boot architecture, REST API, layered services, caching, async |
| `springboot-security` | Spring Security: authn/authz, validation, CSRF, secrets, rate limiting |
| `springboot-tdd` | Spring Boot TDD with JUnit 5, Mockito, MockMvc, Testcontainers |
| `springboot-verification` | Spring Boot verification: build, static analysis, tests, security scans |

**Category: Database (3 skills)**

| Skill | Description |
|-------|-------------|
| `clickhouse-io` | ClickHouse patterns, query optimization, analytics, data engineering |
| `jpa-patterns` | JPA/Hibernate entity design, relationships, query optimization, transactions |
| `postgres-patterns` | PostgreSQL query optimization, schema design, indexing, security |

**Category: Workflow & Quality (8 skills)**

| Skill | Description |
|-------|-------------|
| `continuous-learning` | Legacy v1 Stop-hook session pattern extraction; prefer `continuous-learning-v2` for new installs |
| `continuous-learning-v2` | Instinct-based learning with confidence scoring, evolves into skills, agents, and optional legacy command shims |
| `eval-harness` | Formal evaluation framework for eval-driven development (EDD) |
| `iterative-retrieval` | Progressive context refinement for subagent context problem |
| `security-review` | Security checklist: auth, input, secrets, API, payment features |
| `strategic-compact` | Suggests manual context compaction at logical intervals |
| `tdd-workflow` | Enforces TDD with 80%+ coverage: unit, integration, E2E |
| `verification-loop` | Verification and quality loop patterns |

**Category: Business & Content (5 skills)**

| Skill | Description |
|-------|-------------|
| `article-writing` | Long-form writing in a supplied voice using notes, examples, or source docs |
| `content-engine` | Multi-platform social content, scripts, and repurposing workflows |
| `market-research` | Source-attributed market, competitor, fund, and technology research |
| `investor-materials` | Pitch decks, one-pagers, investor memos, and financial models |
| `investor-outreach` | Personalized investor cold emails, warm intros, and follow-ups |

**Category: Research & APIs (3 skills)**

| Skill | Description |
|-------|-------------|
| `deep-research` | Multi-source deep research using firecrawl and exa MCPs with cited reports |
| `exa-search` | Neural search via Exa MCP for web, code, company, and people research |
| `claude-api` | Anthropic Claude API patterns: Messages, streaming, tool use, vision, batches, Agent SDK |

**Category: Social & Content Distribution (2 skills)**

| Skill | Description |
|-------|-------------|
| `x-api` | X/Twitter API integration for posting, threads, search, and analytics |
| `crosspost` | Multi-platform content distribution with platform-native adaptation |

**Category: Media Generation (2 skills)**

| Skill | Description |
|-------|-------------|
| `fal-ai-media` | Unified AI media generation (image, video, audio) via fal.ai MCP |
| `video-editing` | AI-assisted video editing for cutting, structuring, and augmenting real footage |

**Category: Orchestration (1 skill)**

| Skill | Description |
|-------|-------------|
| `dmux-workflows` | Multi-agent orchestration using dmux for parallel agent sessions |

**Standalone**

| Skill | Description |
|-------|-------------|
| `docs/examples/project-guidelines-template.md` | Template for creating project-specific skills |


Process, convert, OCR, extract, redact, sign, and fill documents using the Nutrient DWS API. Works with PDFs, DOCX, XLSX, PPTX, HTML, and images.

Nutrient Document Processing
When to Use

When to Use

Converting documents between formats (PDF, DOCX, XLSX, PPTX, HTML, images)

Extracting text, tables, or key-value pairs from PDFs

OCR on scanned documents or images

Redacting PII before sharing documents

Adding watermarks to drafts or confidential documents

Digitally signing contracts or agreements

Filling PDF forms programmatically


Modern Perl 5.36+ idioms, best practices, and conventions for building robust, maintainable Perl applications.

Modern Perl Development Patterns
Quick Reference: Modern Perl Idioms

Dependency Management (cpanfile + carton)

Quick Reference: Modern Perl Idioms

| Legacy Pattern | Modern Replacement |
|---|---|
| `use strict; use warnings;` | `use v5.36;` |
| `my ($x, $y) = @_;` | `sub foo($x, $y) { ... }` |
| `@{ $ref }` | `$ref->@*` |
| `%{ $ref }` | `$ref->%*` |
| `open FH, "< $file"` | `open my $fh, '<:encoding(UTF-8)', $file` |
| `blessed hashref` | `Moo` class with types |
| `$1, $2, $3` | `$+{name}` (named captures) |
| `eval { }; if ($@)` | `Try::Tiny` or native `try/catch` (5.40+) |
| `BEGIN { require Exporter; }` | `use Exporter 'import';` |
| Manual file ops | `Path::Tiny` |
| `blessed($o) && $o->isa('X')` | `$o isa 'X'` (5.32+) |
| `builtin::true / false` | `use builtin 'true', 'false';` (5.36+, experimental) |


GAN-inspired Generator-Evaluator agent harness for building high-quality applications autonomously. Based on Anthropic's March 2026 harness design paper.

References

[Anthropic: Harness Design for Long-Running Apps](https://www.anthropic.com/engineering/harness-design-long-running-apps) — Original paper by Prithvi Rajasekaran

[Epsilla: The GAN-Style Agent Loop](https://www.epsilla.com/blogs/anthropic-harness-engineering-multi-agent-gan-architecture) — Architecture deconstruction

[Martin Fowler: Harness Engineering](https://martinfowler.com/articles/exploring-gen-ai/harness-engineering.html) — Broader industry context

[OpenAI: Harness Engineering](https://openai.com/index/harness-engineering/) — OpenAI's parallel work


Backend architecture patterns, API design, database optimization, and server-side best practices for Node.js, Express, and Next.js API routes.

Backend Development Patterns
Logging & Monitoring
Structured Logging

Background Jobs & Queues

Simple Queue Pattern

Logging & Monitoring

Structured Logging

**Remember**: Backend patterns enable scalable, maintainable server-side applications. Choose patterns that fit your complexity level.


Create platform-native content systems for X, LinkedIn, TikTok, YouTube, newsletters, and repurposed multi-platform campaigns. Use when the user wants social posts, threads, scripts, content calendars, or one source asset adapted cleanly across platforms.

Content Engine
Platform Adaptation Rules
Newsletter

Newsletter

open with the point, conflict, or artifact

do not spend the first paragraph warming up

every section needs to add something new


Record polished UI demo videos using Playwright. Use when the user asks to create a demo, walkthrough, screen recording, or tutorial video of a web application. Produces WebM videos with visible cursor, natural pacing, and professional feel.

When to Use

User asks for a "demo video", "screen recording", "walkthrough", or "tutorial"

User wants to showcase a feature or workflow visually

User needs a video for documentation, onboarding, or stakeholder presentation


Python testing strategies using pytest, TDD methodology, fixtures, mocking, parametrization, and coverage requirements.

Python Testing Patterns
When to Activate

When to Activate

Writing new Python code (follow TDD: red, green, refactor)

Designing test suites for Python projects

Reviewing Python test coverage

Setting up testing infrastructure


Rust testing patterns including unit tests, integration tests, async testing, property-based testing, mocking, and coverage. Follows TDD methodology.

Rust Testing Patterns

Comprehensive Rust testing patterns for writing reliable, maintainable tests following TDD methodology.


Evidence-first live messaging workflow for ECC. Use when the user wants to read texts or DMs, recover a recent one-time code, inspect a thread before replying, or prove which message source was actually checked.

Skill Stack

Pull these ECC-native skills into the workflow when relevant:

`email-ops` when the message task is really mailbox work

`connections-optimizer` when the DM thread belongs to outbound network work

`lead-intelligence` when the live thread should inform targeting or warm-path outreach

`knowledge-ops` when the thread contents need to be captured into durable context


Cost optimization patterns for LLM API usage — model routing by task complexity, budget tracking, retry logic, and prompt caching.

Cost-Aware LLM Pipeline
Core Concepts
4. Prompt Caching

4. Prompt Caching

Cache long system prompts to avoid resending them on every request.


Codified expertise for handling freight exceptions, shipment delays, damages, losses, and carrier disputes. Informed by logistics professionals with 15+ years operational experience. Includes escalation protocols, carrier-specific behaviors, claims procedures, and judgment frameworks. Use when handling shipping exceptions, freight claims, delivery issues, or carrier disputes.

Logistics Exception Management
Communication Patterns
Tone Calibration

Communication Patterns

Tone Calibration

Match communication tone to situation severity and relationship:

**Routine exception, good carrier relationship:** Collaborative. "We've got a delay on PRO# X — can you get me an updated ETA? Customer is asking."

**Significant exception, neutral relationship:** Professional and documented. State facts, reference BOL/PRO, specify what you need and by when.

**Major exception or pattern, strained relationship:** Formal. CC management. Reference contract terms. Set response deadlines. "Per Section 4.2 of our transportation agreement dated..."

**Customer-facing (delay):** Proactive, honest, solution-oriented. Never blame the carrier by name. "Your shipment has experienced a transit delay. Here's what we're doing and your updated timeline."

**Customer-facing (damage/loss):** Empathetic, action-oriented. Lead with the resolution, not the problem. "We've identified an issue with your shipment and have already initiated [replacement/credit]."


Laravel architecture patterns, routing/controllers, Eloquent ORM, service layers, queues, events, caching, and API resources for production apps.

Laravel Development Patterns
How It Works

How It Works

Structure the app around clear boundaries (controllers -> services/actions -> models).

Use explicit bindings and scoped bindings to keep routing predictable; still enforce authorization for access control.

Favor typed models, casts, and scopes to keep domain logic consistent.

Keep IO-heavy work in queues and cache expensive reads.

Centralize config in `config/*` and keep environments explicit.


This skill should be used when the user asks to create a hookify rule, write a hook rule, configure hookify, add a hookify rule, or needs guidance on hookify rule syntax and patterns.

Writing Hookify Rules
Pattern Writing Tips
Common Pitfalls

Common Pitfalls

**Too broad**: `log` matches "login", "dialog" — use `console\.log\(`

**Too specific**: `rm -rf /tmp` — use `rm\s+-rf`

**YAML escaping**: Use unquoted patterns; quoted strings need `\\s`


Unified media generation via fal.ai MCP — image, video, and audio. Covers text-to-image (Nano Banana), text/image-to-video (Seedance, Kling, Veo 3), text-to-speech (CSM-1B), and video-to-audio (ThinkSound). Use when the user wants to generate images, videos, or audio with AI.

fal.ai Media Generation
Image Generation
Image Editing

Image Editing

Use Nano Banana 2 with an input image for inpainting, outpainting, or style transfer:


为 OpenClaw AI Agent 锻造完整的龙虾灵魂方案。根据用户偏好或随机抽卡，
输出身份定位、灵魂描述(SOUL.md)、角色化底线规则、名字和头像生图提示词。
如当前环境提供已审核的生图 skill，可自动生成统一风格头像图片。
当用户需要创建、设计或定制 OpenClaw 龙虾灵魂时使用。
不适用于：微调已有 SOUL.md、非 OpenClaw 平台的角色设计、纯工具型无性格 Agent。
触发词：龙虾灵魂、虾魂、OpenClaw 灵魂、养虾灵魂、龙虾角色、龙虾定位、
龙虾剧本杀角色、龙虾游戏角色、龙虾 NPC、龙虾性格、龙虾背景故事、
lobster soul、lobster character、抽卡、随机龙虾、龙虾 SOUL、gacha。

龙虾灵魂锻造炉
How It Works
触发判断

触发判断

| 用户说 | 执行模式 |
|--------|---------|
| "帮我设计龙虾灵魂" / "我想给龙虾定个性格" | → **引导模式**（Step 1） |
| "抽卡" / "随机" / "来一发" / "盲盒" / "gacha" | → **抽卡模式**（Step 1-B） |
| "帮我优化这个灵魂" / 附带已有 SOUL.md | → **打磨模式**（跳到 Step 4） |


Create stunning, animation-rich HTML presentations from scratch or by converting PowerPoint files. Use when the user wants to build a presentation, convert a PPT/PPTX to web, or create slides for a talk/pitch. Helps non-designers discover their aesthetic through visual exploration rather than abstract choices.

Content Density Limits

Use these maxima unless the user explicitly asks for denser slides and readability still holds:

| Slide type | Limit |
|------------|-------|
| Title | 1 heading + 1 subtitle + optional tagline |
| Content | 1 heading + 4-6 bullets or 2 short paragraphs |
| Feature grid | 6 cards max |
| Code | 8-10 lines max |
| Quote | 1 quote + attribution |
| Image | 1 image constrained by viewport |


Use this skill when adding authentication, handling user input, working with secrets, creating API endpoints, or implementing payment/sensitive features. Provides comprehensive security checklist and patterns.

Security Review Skill

This skill ensures all code follows security best practices and identifies potential vulnerabilities.


Structured self-debugging workflow for AI agent failures using capture, diagnosis, contained recovery, and introspection reports.

Agent Introspection Debugging
Recovery Heuristics

Recovery Heuristics

Prefer these interventions in order:

Restate the real objective in one sentence.

Verify the world state instead of trusting memory.

Shrink the failing scope.

Run one discriminating check.

Only then retry.

Bad pattern:

retrying the same action three times with slightly different wording

Good pattern:

capture failure

classify the pattern

run one direct check

change the plan only if the check supports it


Workflow

1. Detect Mode

Choose one path:

**New presentation**: user has a topic, notes, or full draft

**PPT conversion**: user has `.ppt` or `.pptx`

**Enhancement**: user already has HTML slides and wants improvements


Use this skill to measure performance baselines, detect regressions before/after PRs, and compare stack alternatives.

Output

Stores baselines in `.ecc/benchmarks/` as JSON. Git-tracked so the team shares baselines.


Database migration best practices for schema changes, data migrations, rollbacks, and zero-downtime deployments across PostgreSQL, MySQL, and common ORMs (Prisma, Drizzle, Kysely, Django, TypeORM, golang-migrate).

Database Migration Patterns
Migration Safety Checklist

Migration Safety Checklist

Before applying any migration:

[ ] Migration has both UP and DOWN (or is explicitly marked irreversible)

[ ] No full table locks on large tables (use concurrent operations)

[ ] New columns have defaults or are nullable (never add NOT NULL without default)

[ ] Indexes created concurrently (not inline with CREATE TABLE for existing tables)

[ ] Data backfill is a separate migration from schema change

[ ] Tested against a copy of production data

[ ] Rollback plan documented


iOS 26 Liquid Glass design system — dynamic glass material with blur, reflection, and interactive morphing for SwiftUI, UIKit, and WidgetKit.

Glass Button Styles

GlassEffectContainer for Multiple Elements

Always wrap multiple glass views in a container for performance and morphing:

The `spacing` parameter controls merge distance — closer elements blend their glass shapes together.


Create platform-native content systems for X, LinkedIn, TikTok, YouTube, newsletters, and repurposed multi-platform campaigns. Use when the user wants social posts, threads, scripts, content calendars, or one source asset adapted cleanly across platforms.

When to Activate

writing X posts or threads

drafting LinkedIn posts or launch updates

scripting short-form video or YouTube explainers

repurposing articles, podcasts, demos, docs, or internal notes into public content

building a launch sequence or ongoing content system around a product, insight, or narrative


Convene a four-voice council for ambiguous decisions, tradeoffs, and go/no-go calls. Use when multiple valid paths exist and you need structured disagreement before choosing.

Multi-Round Follow-up

Default is one round.

If the user wants another round:

keep the new question focused

include the previous verdict only if it is necessary

keep the Skeptic as clean as possible to preserve anti-anchoring value


See, Understand, Act on video and audio. See- ingest from local files, URLs, RTSP/live feeds, or live record desktop; return realtime context and playable stream links. Understand- extract frames, build visual/semantic/temporal indexes, and search moments with timestamps and auto-clips. Act- transcode and normalize (codec, fps, resolution, aspect ratio), perform timeline edits (subtitles, text/image overlays, branding, audio overlays, dubbing, translation), generate media assets (image, audio, video), and create real time alerts for events from live streams or desktop capture.

Additional docs

Reference documentation is in the `reference/` directory adjacent to this SKILL.md file. Use the Glob tool to locate it if needed.

[reference/api-reference.md](reference/api-reference.md) - Complete VideoDB Python SDK API reference

[reference/search.md](reference/search.md) - In-depth guide to video search (spoken word and scene-based)

[reference/editor.md](reference/editor.md) - Timeline editing, assets, and composition

[reference/streaming.md](reference/streaming.md) - HLS streaming and instant playback

[reference/generative.md](reference/generative.md) - AI-powered media generation (images, video, audio)

[reference/rtstream.md](reference/rtstream.md) - Live stream ingestion workflow (RTSP/RTMP)

[reference/rtstream-reference.md](reference/rtstream-reference.md) - RTStream SDK methods and AI pipelines

[reference/capture.md](reference/capture.md) - Desktop capture workflow

[reference/capture-reference.md](reference/capture-reference.md) - Capture SDK and WebSocket events

[reference/use-cases.md](reference/use-cases.md) - Common video processing patterns and examples

**Do not use ffmpeg, moviepy, or local encoding tools** when VideoDB supports the operation. The following are all handled server-side by VideoDB — trimming, combining clips, overlaying audio or music, adding subtitles, text/image overlays, transcoding, resolution changes, aspect-ratio conversion, resizing for platform requirements, transcription, and media generation. Only fall back to local tools for operations listed under Limitations in reference/editor.md (transitions, speed changes, crop/zoom, colour grading, volume mixing).


Use only when writing/updating/fixing C++ tests, configuring GoogleTest/CTest, diagnosing failing or flaky tests, or adding coverage/sanitizers.

C++ Testing (Agent Skill)
Best Practices
DO

Best Practices

DO

Keep tests deterministic and isolated

Prefer dependency injection over globals

Use `ASSERT_*` for preconditions, `EXPECT_*` for multiple checks

Separate unit vs integration tests in CTest labels or directories

Run sanitizers in CI for memory and race detection


Build MCP servers with Node/TypeScript SDK — tools, resources, prompts, Zod validation, stdio vs Streamable HTTP. Use Context7 or official MCP docs for latest API.

MCP Server Patterns
How It Works
Core concepts

How It Works

Core concepts

**Tools**: Actions the model can invoke (e.g. search, run a command). Register with `registerTool()` or `tool()` depending on SDK version.

**Resources**: Read-only data the model can fetch (e.g. file contents, API responses). Register with `registerResource()` or `resource()`. Handlers typically receive a `uri` argument.

**Prompts**: Reusable, parameterised prompt templates the client can surface (e.g. in Claude Desktop). Register with `registerPrompt()` or equivalent.

**Transport**: stdio for local clients (e.g. Claude Desktop); Streamable HTTP is preferred for remote (Cursor, cloud). Legacy HTTP/SSE is for backward compatibility.

The Node/TypeScript SDK may expose `tool()` / `resource()` or `registerTool()` / `registerResource()`; the official SDK has changed over time. Always verify against the current [MCP docs](https://modelcontextprotocol.io) or Context7.


龙虾灵魂锻造炉
Step 2：锻造身份张力

Step 2：锻造身份张力

Step 1-B：抽卡模式

**必须执行脚本**，不要自己随机编：

展示结果后，用创世神的语气点评这个组合的亮点，然后引导用户决定。

Step 2：锻造身份张力

**详细模板和示例**：见 [references/identity-tension.md](references/identity-tension.md)

构建：前世身份 × 当下处境 × 内在矛盾 → 一句话灵魂。

展示后，以创世神的眼光点评这个身份张力中最有趣的点，然后引导用户。


Laravel Development Patterns
Examples
Events, Jobs, and Queues

API Resources

Keep API responses consistent with resources and pagination.

Events, Jobs, and Queues

Emit domain events for side effects (emails, analytics)

Use queued jobs for slow work (reports, exports, webhooks)

Prefer idempotent handlers with retries and backoff


Weighted social-graph ranking for warm intro discovery, bridge scoring, and network gap analysis across X and LinkedIn. Use when the user wants the reusable graph-ranking engine itself, not the broader outreach or network-maintenance workflow layered on top of it.

Scoring Signals

Weight targets before graph traversal with whatever matters for the current priority set:

role or title alignment

company or industry fit

current activity and recency

geographic relevance

influence or reach

likelihood of response

Weight mutuals after traversal with:

number of weighted paths into the target set

directness of those paths

responsiveness or prior interaction history

contextual fit for making the intro


Build reusable Manim explainers for technical concepts, graphs, system diagrams, and product walkthroughs, then hand off to the wider ECC video stack if needed. Use when the user wants a clean animated explainer rather than a generic talking-head script.

Scene Planning Rules

each scene should prove one thing

avoid overstuffed diagrams

prefer progressive reveal over full-screen clutter

use motion to explain state change, not just to keep the screen busy

title cards should be short and loaded with meaning


Comprehensive Perl security covering taint mode, input validation, safe process execution, DBI parameterized queries, web security (XSS/SQLi/CSRF), and perlcritic security policies.

Perl Security Patterns
Safe Process Execution
List-Form system and exec

Safe Process Execution

List-Form system and exec

Also use `Capture::Tiny` for capturing stdout/stderr from external commands safely.


Database Migration Patterns
Zero-Downtime Migration Strategy

golang-migrate (Go)

Workflow

Migration Files

Zero-Downtime Migration Strategy

For critical production changes, follow the expand-contract pattern:


Cache expensive file processing results using SHA-256 content hashes — path-independent, auto-invalidating, with service layer separation.

Content-Hash File Cache Pattern
Best Practices

Best Practices

**Hash content, not paths** — paths change, content identity doesn't

**Chunk large files** when hashing — avoid loading entire files into memory

**Keep processing functions pure** — they should know nothing about caching

**Log cache hit/miss** with truncated hashes for debugging

**Handle corruption gracefully** — treat invalid cache entries as misses, never crash


Knowledge base management, ingestion, sync, and retrieval across multiple storage layers (local files, MCP memory, vector stores, Git repos). Use when the user wants to save, organize, sync, deduplicate, or search across their knowledge systems.

Knowledge Operations
Sync Operations
Conversation Sync

4. Index

Update any relevant indexes or summary files.

Sync Operations

Conversation Sync

Periodically sync conversation history into the knowledge base:

Sources: Claude session files, Codex sessions, other agent sessions

Destination: knowledge base repo

Generate a session index for quick browsing

Commit and push


Compose Multiplatform and Jetpack Compose patterns for KMP projects — state management, navigation, theming, performance, and platform-specific UI.

Compose Multiplatform Patterns

Patterns for building shared UI across Android, iOS, Desktop, and Web using Compose Multiplatform and Jetpack Compose. Covers state management, navigation, theming, and performance.