agentleFS
yanzyuyuyanzyuyu/min-tok/skills/perf-benchmark/SKILL.md

perf-benchmark

Skill1 starsChanged 47 days agoApache-2.0View on GitHub

Build zero-dependency, high-throughput benchmark and simulation scripts without AI slop. Use this skill whenever designing performance tests, stress-testing data pipelines, measuring rows/sec or request throughput, simulating edge-case data drift, or generating benchmark proof cards for documentation.

The file

We split this skill into the rules it gives an agent

3 rules. About 0 are common, 1 is distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Every benchmark script should follow a standalone 4-phase lifecycle (exemplified by demo.py):

    line 16
  2. Very specific:

    Cleanup: Always clean up temporary files in a finally: block.

    line 30
  3. Distinctive:

    Always report concrete, human-readable numbers:

    line 36

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 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

Zero-Dependency Benchmark & Stress Testing (perf-benchmark)

This skill guides the agent to design fast, self-contained benchmark scripts that prove performance with real numbers—without pulling in heavy benchmark frameworks or producing fabricated metrics.


1. The Core Simulation Architecture

Every benchmark script should follow a standalone 4-phase lifecycle (exemplified by demo.py):

  1. Setup Phase: Generate synthetic data in memory or fast temporary storage (e.g. SQLite / in-memory structures) in clean batches of 10,000 to avoid memory spikes.
  2. Drift/Fault Injection: Inject realistic real-world discrepancies:
    • 1 dropped record (simulating network timeout during ETL sync)
    • 1 phantom/duplicate record (simulating at-least-once delivery duplicates)
    • 1 mutated field (simulating floating-point or rounding precision mismatch)
  3. Execution & Measurement: Measure the core operation using time.perf_counter():
    t0 = time.perf_counter()
    result = engine.run(...)
    elapsed = time.perf_counter() - t0
    throughput = int(total_items / elapsed) if elapsed > 0 else 0
  4. Cleanup: Always clean up temporary files in a finally: block.

2. Standard Benchmark Metrics to Report

Always report concrete, human-readable numbers:

  • Total Volume: e.g. 50,000 items
  • Execution Time: e.g. 0.23 seconds
  • Throughput: e.g. ~215,000 rows/sec
  • Discrepancy Precision: 100% detection rate with zero false positives.

3. Markdown Benchmark Summary Card

Output results in a compact format ready for instant copy-pasting into README.md:

### Benchmark Performa

| Metrik | Hasil Pengujian |
|---|---|
| **Volume Data** | 50.000 transaksi |
| **Waktu Eksekusi** | 0.23 detik |
| **Throughput** | ~215.000 baris/detik |
| **Akurasi Deteksi** | 3/3 selisih terdeteksi (100%) |

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.