Skip to content
Skills Library
Programming · Building & coding

performance-optimization

/performance-optimization

Optimize systems for speed and scale (Caching, Sharding, Async). Use when: performance, optimization, scaling, caching, sharding, profiling, latency, slow.

Repository
gabbe ↗
Licence
CC-BY-4.0
Last repository change
24.10.2026

Assessment and security

90/ 100Class: good
Format25 / 25
Frontmatter with name and description, valid name, description up to 1,024 characters, name matching the folder.
Discoverability25 / 25
Description explains when to use the skill, has a reasonable length and uses third person.
Content25 / 35
At least 150 words and at most 500 lines, headings, step lists, examples or code.
Hygiene15 / 15
No placeholders such as TODO, no Windows paths, with a licence.
Riskno signals detected in the scan
Files in this package
1
Scripts
0
HTML comments
0
URLs in SKILL.md
0
Deprecation

No signals detected. Repository changed on 24.10.2026, without references to retired models or APIs.

Licence

CC-BY-4.0, otwarta.

What it does and when to use it

Optimize systems for speed and scale (Caching, Sharding, Async). Use when: performance, optimization, scaling, caching, sharding, profiling, latency, slow.

Original author description

Optimize systems for speed and scale (Caching, Sharding, Async). Use when: performance, optimization, scaling, caching, sharding, profiling, latency, slow.

How it works

  1. Goal
  2. Capabilities
  3. Steps
  4. Deliverables
  5. Security & Guardrails
Original SKILL.md headings · 45 lines, 414 words
SKILL.md preview
---
name: performance-optimization
description: "Optimize systems for speed and scale (Caching, Sharding, Async). Use when: performance, optimization, scaling, caching, sharding, profiling, latency, slow."
license: CC-BY-SA-4.0
metadata:
  source: "agents/skills/ops/performance-optimization.skill.md"
  tags: "ops"
  core: "false"
  context_cost: "medium"
---
# Performance Optimization Skill

## Goal
To ensure systems behave predictably under load and utilize resources efficiently.

## Capabilities

### 1. Caching Strategy
-   **Cache-Aside**: App reads DB, populates cache. (Best for read-heavy).
-   **Write-Through**: App writes to Cache + DB. (Data consistency).
-   **Edge Caching**: CDN for static assets (Images, JS).

### 2. Database Scaling
-   **Read Replicas**: Offload `SELECT` queries to secondary nodes.
-   **Sharding**: Horizontal partitioning by Key (User ID, Region).
-   **Indexing**: The #1 fix for slow queries.

### 3. Async Architectures
-   **Message Queues**: Decouple heavy work (Sending Emails) from request loop.
-   **Event-Driven**: Services react to changes instead of polling.

## Steps
1.  **Stop Guessing**: Use a profiler (pprof, Flamegraphs) before optimizing.
2.  **N+1 Problem**: Watch for loops triggering DB queries.
3.  **Database First**: 99% of bottlenecks are in the data layer.

## Deliverables
-   `profiling-report.md`: Analysis of hotspots.
-   `caching-strategy.md`: Redis/Memcached plan.
-   `load-test-plan.md`: k6/JMeter script design.

## Security & Guardrails

### 1. Skill Security (Performance Optimization)
- **Safe Profiler Execution**: Profiling tools executed by the agent must be strictly isolated to the target container or process. The agent must not have root access on the host node, preventing an attacker from using a profiling tool to dump the memory of adjacent applications.
- **Optimization Artifact Integrity**: The generated `profiling-report.md` must be cryptographically signed by the auditing agent to prevent unauthorized parties from tampering with the reported hotspots to mislead the engineering team.

### 2. System Integration Security
- **Stale Auth Data Prevention**: When implementing Cache-Aside or Write-Through caching strategies, the agent must guarantee that authentication and authorization lookups (e.g., permission checks, session validation) are either NOT cached, or use incredibly short, verifiable TTLs to prevent privilege escalation.
- **Queue Poisoning Defense**: When decoupling heavy work using Message Queues (e.g., Kafka, RabbitMQ), the optimizing agent must design the queue consumers to gracefully handle "Poison Pills" (malformed or excessively large messages) without crashing, avoiding a Denial of Service attack vector.

### 3. LLM & Agent Guardrails
- **Premature Optimization Trap**: The LLM must be equipped with a generic threshold (e.g., "p99 latency < 100ms is acceptable"). It must actively refuse user prompts to over-engineer caching or sharding for low-traffic endpoints, avoiding unnecessary architectural complexity and security surface area.
- **Index Hijacking Warning**: If asked to "just index everything to make it fast," the agent must warn that excessive indexing drastically slows down `INSERT`/`UPDATE` operations and consumes massive disk space, which can be weaponized in a disk-exhaustion DoS attack.

Versions

RepositoryScoreLicence
This page · andreibesleaga/gabbe90CC-BY-4.0
zeative/satgas100AGPL-3.0
TheAstroByte/astrobyte-agent-skills100MIT
FrancoStino/opencode-skills-collection100MIT
sanity-io/sanity100MIT
magnus919/agent-skills100MIT
drvoss/everything-copilot-cli100MIT
atc-net/atc-agentic-toolkit100MIT
DnsQueen/orcinus-skills100MIT

Database snapshot: 13.11.2026 · package version b657dc4e9a1e (SHA-256 digest of the entire package)

Downloads in the last 30 days: 0 · ranking

Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.

Similar skills

  • 100application-performance-performance-optimization
    Optimize end-to-end application performance with profiling, observability, and backend/frontend tuning. Use when coordinating performance optimization across the stack.
  • 100application-performance-performance-optimization
    Optimize end-to-end application performance with profiling, observability, and backend/frontend tuning. Use when coordinating performance optimization across the stack.
  • 90application-performance-performance-optimization
    Optimize end-to-end application performance with profiling, observability, and backend/frontend tuning. Use when coordinating performance optimization across the stack.
  • 90application-performance-performance-optimization
    Optimize end-to-end application performance with profiling, observability, and backend/frontend tuning. Use when coordinating performance optimization across the stack.
  • 90application-performance-performance-optimization
    Optimize end-to-end application performance with profiling, observability, and backend/frontend tuning. Use when coordinating performance optimization across the stack.
  • 100linear-performance-tuning
    Optimize Linear API queries and caching for better performance. Use when improving response times, reducing API calls, or implementing caching strategies. Trigger with phrases like "linear performance", "optimize linear", "linear caching", "linear slow queries", "speed up linear".

Feedback and reports

Your message goes to Bartosz Sokoliński. An email address is needed only for a reply. See the privacy policy.