ln-811-performance-profiler
БесплатноБез исполняемых скриптовНе проверенRuntime profiling with multi-metric measurement, instrumentation, and performance map generation
от tensology★ 17 звёзд на GitHubОб этом скилле
Paths: File paths (
shared/,references/,../ln-*) are relative to skills repo root. If not found at CWD, locate this SKILL.md directory and go up one level for repo root.
ln-811-performance-profiler
Type: L3 Worker Category: 8XX Optimization
Runtime profiler that executes the optimization target, measures multiple metrics (CPU, memory, I/O, time), instruments code for per-function breakdown, and produces a standardized performance map from real data.
Overview
| Aspect | Details |
|---|---|
| Input | Problem statement: target (file/endpoint/pipeline) + observed metric |
| Output | Performance map (multi-metric, per-function), suspicion stack, bottleneck classification |
| Pattern | Discover test → Baseline run → Static analysis → Deep profile → Performance map → Report |
Workflow
Phases: Test Discovery → Baseline Run → Static Analysis → Deep Profile → Performance Map → Report
Phase 0: Test Discovery/Creation
MANDATORY READ: Load shared/references/ci_tool_detection.md for test framework detection.
MANDATORY READ: Load shared/references/benchmark_generation.md for auto-generating benchmarks when none exist.
Find or create commands that exercise the optimization target. Two outputs: test_command (profiling/measurement) and e2e_test_command (functional safety gate).
Step 1: Discover test_command
| Priority | Method | Action |
|---|---|---|
| 1 | User-provided | User specifies test command or API endpoint |
| 2 | Discover existing E2E test | Grep test files for target entry point (stop at first match) |
| 3 | Create test script | Generate per shared/references/benchmark_generation.md to .optimization/{slug}/profile_test.sh |
E2E discovery protocol (stop at first match):
| Priority | Method | How |
|---|---|---|
| 1 | Route-based search | Grep e2e/integration test files for entry point route |
| 2 | Function-based search | Grep for entry point function name |
| 3 | Module-based search | Grep for import of entry point module |
Test creation (if no existing test found):
| Target Type | Generated Script |
|---|---|
| API endpoint | curl -w "%{time_total}" -o /dev/null -s {endpoint} |
| Function | Stack-specific benchmark per shared/references/benchmark_generation.md |
| Pipeline | Full pipeline invocation with test input |
Step 2: Discover e2e_test_command
If test_command came from E2E discovery (Step 1 priority 2): e2e_test_command = test_command.
Otherwise, run E2E discovery protocol again (same 3-priority table) to find a separate functional safety test.
If not found: e2e_test_command = null, log: WARNING: No e2e test covers {entry_point}. Full test suite serves as functional gate.
Output
| Field | Description |
|---|---|
test_command |
Command for profiling/measurement |
e2e_test_command |
Command for functional safety gate (may equal test_command, or null) |
e2e_test_source |
Discovery method: user / route / function / module / none |
Phase 1: Baseline Run (Multi-Metric)
Run test_command with system-level profiling. Capture simultaneously:
| Metric | How to Capture | When |
|---|---|---|
| Wall time | time wrapper or test harness |
Always |
| CPU time (user+sys) | /usr/bin/time -v or language profiler |
Always |
| Memory peak (RSS) | /usr/bin/time -v (Max RSS) or tracemalloc / process.memoryUsage() |
Always |
| I/O bytes | /usr/bin/time -v or structured logs |
If I/O suspected |
| HTTP round-trips | Count from structured logs or application metrics | If network I/O in call graph |
| GPU utilization | nvidia-smi --query-gpu |
Only if CUDA/GPU detected in stack |
Baseline Protocol
| Parameter | Value |
|---|---|
| Runs | 3 |
| Metric | Median |
| Warm-up | 1 discarded run |
| Output | baseline — multi-metric snapshot |
Phase 2: Static Analysis → Instrumentation Points
MANDATORY READ: Load bottleneck_classification.md
Trace call chain from code + build suspicion stack. Purpose: guide WHERE to instrument in Phase 3.
Step 1: Trace Call Chain
Starting from entry point, trace depth-first (max depth 5). At each step, READ the full function body.
Cross-service tracing: If service_topology is available from coordinator and a step makes an HTTP/gRPC call to another service whose code is accessible:
| Situation | Action |
|---|---|
| HTTP call to service with code in submodule/monorepo | Follow into that service's handler: resolve route → trace handler code (depth resets to 0 for the new service) |
| HTTP call to service without accessible code | Classify as External, record latency estimate |
| gRPC/message queue to known service | Same as HTTP — follow into handler if code accessible |
Record service: "{service_name}" on each step to track wh
Установить ln-811-performance-profiler в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл ln-811-performance-profiler?
Runtime profiling with multi-metric measurement, instrumentation, and performance map generation
Как установить скилл ln-811-performance-profiler?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл ln-811-performance-profiler запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic