一键导入
perf-optimize
Iterative performance optimization workflow for the apply-load benchmark
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Iterative performance optimization workflow for the apply-load benchmark
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
One tick of a CI watchdog — check main-branch GHA status; spawn an agent to fix if failing and no investigation is in flight.
One tick of the henyey mainnet monitor — checks, metrics scan, deploy, status report
Continuous always-on orchestrator for the henyey project pipeline. Each pass queries the board, central-picks up to N actionable issues by priority, and fans out parallel foreground specialist sub-agents (triage/plan/do/review-pr) with the right Claude model per stage. Owns concurrency, conflict-avoidance, CI pipelining, sibling-nit consolidation, and a self-reflection pass that files pipeline-improvement issues. Replaces scripts/project-tick-loop.sh. Use when the operator asks to "run the loop", "process the board continuously", or "keep the pipeline going".
Single-pick dispatcher primitive for the henyey project pipeline. One tick = pick one actionable issue from the project board and dispatch the right specialist sub-agent for its current state. Used for manual single picks and `--issue=` recovery; the continuous orchestrator is `/project-loop`, which owns concurrency centrally. Use when the user asks to "run a tick", "pick up an issue", or "process one board item".
Run two parallel adversarial PR reviewers and combine their verdicts with external PR reviews (GH Copilot bot, humans, other bots) and CI state into a merge decision. Agent reviewers post structured comment verdicts (since the agent is the PR author and cannot self-approve via GH native review). External CHANGES_REQUESTED reviews block merge identically to agent CHANGES_REQUESTED. Operates on issues in `in-review`. Auto-merges with --admin on all-green (after filing follow-up issues for unaddressed inline review comments, so non-critical feedback is preserved as backlog instead of dropped); bounces to `ready-for-doing` on any request-changes or CI red; blocks after 3 bounce-backs on the same code state. At the lifetime cap (6 bounces since last `## Review: Reset`) the PR enters **force-converge mode**: if CI is green, the PR auto-merges and unresolved reviewer concerns become follow-up issues; only red/pending CI at the cap still blocks. Use when invoked by /project-tick with an issue in in-review, or manuall
Audit a Rust crate's adherence to its Stellar protocol spec (spec-driven, walks every normative claim)
| name | perf-optimize |
| description | Iterative performance optimization workflow for the apply-load benchmark |
| argument-hint | <target-tps> |
Parse $ARGUMENTS:
/perf-optimize 5000).$TARGET_TPS.Iteratively optimize henyey's apply-load single-shot benchmark to reach
$TARGET_TPS transactions per second.
Hard constraint: No protocol changes — observed behavior (transaction results, ledger hashes, meta) must stay identical. Only internal implementation performance is in scope.
Major refactorings are allowed and encouraged when they unlock performance
gains. Don't shy away from changing data structures (e.g. Vec → Arc),
reworking function signatures, or restructuring hot paths across crate
boundaries. Correctness is verified by the test suite, not by minimizing diff
size.
~/data/<session-id>/.CARGO_TARGET_DIR=~/data/<session-id>/cargo-target cargo build --release -p henyey
CARGO_TARGET_DIR=~/data/<session-id>/cargo-target cargo test --release -p henyey-ledger --test apply_load -- --nocapture
If apply_load doesn't exist yet, look for the closest benchmark test
(grep for apply_load, bench, or perf in crates/). If none exists,
tell the user and stop.$BASELINE_TPS.$BASELINE_TPS >= $TARGET_TPS, report success and stop — target already
met.Create or update docs/perf-hypotheses.md with this format:
# Performance Hypotheses
Baseline: <BASELINE_TPS> TPS | Target: <TARGET_TPS> TPS | Date: <today>
## Hypotheses
| # | Hypothesis | Status | Expected Gain | Measured Gain | TPS After |
|---|-----------|--------|---------------|---------------|-----------|
| 1 | <description> | pending | | | |
To generate initial hypotheses:
cargo instruments, samply, or perf). Identify the top 5 hotspots
by cumulative time.pending.For each hypothesis (in priority order — highest expected gain first):
measured_gain: percentage improvementtps_after: new median TPSstatus: accepted if gain > 1%, rejected if notOptimize <what>: +X% TPS (<old> -> <new>). Update the hypothesis status.rejected, note why.>= $TARGET_TPS: stop — target reached. Print a
summary and update the hypothesis doc with final results.pending.pending hypothesis and go to Step A.--release.purge on macOS).When the loop terminates (target reached or hypotheses exhausted), print:
## Performance Optimization Summary
Baseline: <BASELINE_TPS> TPS
Final: <FINAL_TPS> TPS
Target: <TARGET_TPS> TPS
Improvement: +<PERCENT>%
Status: <target reached | gap remaining>
Accepted optimizations:
- <hypothesis>: +X% (<old> -> <new> TPS)
- ...
Rejected hypotheses:
- <hypothesis>: <reason>
- ...
Update docs/perf-hypotheses.md with the final summary.