AGENT SKILL

evo-kit

Build, inspect, and safely use PARL EvoKit, the optional C++ evolution-strategy toolkit with Torch or PaddleLite prediction backends.

License 许可
Apache-2.0
最近更新
2026-09-03
Stars
★ 351
Forks
27

01 前言 Front Matter

name
evo-kit
license
Apache 2.0
metadata
{ "disco-role": "operating" }
description
Build, inspect, and safely use PARL EvoKit, the optional C++ evolution-strategy toolkit with Torch or PaddleLite prediction backends.
disable-model-invocation
true

02 资源文件 3

03 SKILL.md 正文

PARL EvoKit

Use this sub-skill when a task involves PARL's optional C++ EvoKit toolkit: ESAgent sampling/update loops, SamplingInfo records, C++ build prerequisites, Torch/libtorch versus PaddleLite backend selection, or safe interpretation of EvoKit build helpers.

Do not use this sub-skill for ordinary Python PARL Model / Algorithm / Agent code, xparl cluster orchestration, or selecting a full Python RL recipe. For high-level RL recipe structure, consult the sibling algorithm-recipes skill conceptually; EvoKit-specific work here is C++ ES toolkit work.

Operating workflow

  1. Confirm EvoKit is actually needed. EvoKit is a C++ evolution-strategy toolkit for parameter perturbation, evaluation, and parameter updates. If the task only asks for a Python PARL algorithm, stay with the Python PARL skills instead.

  2. Choose one prediction backend. Use Torch when the model is a C++ torch::nn::Module and a local libtorch/ tree is available. Use PaddleLite when the model is an exported Paddle inference model and a local inference_lite_lib/ tree is available. Do not enable both backends in one EvoKit build.

  3. Check local prerequisites before building. Run the bundled checker from a repository checkout or a copied EvoKit tree:

    python scripts/check_evokit_prereqs.py --project-root <evokit-root> --backend torch
    

    Replace torch with paddle when using PaddleLite, or use auto to accept either backend directory.

  4. Model the ESAgent loop explicitly. The original agent owns the current parameters, sampling method, and optimizer. Clone sampling agents, call add_noise only on clones, evaluate each noisy clone, keep each SamplingInfo paired with its reward, then call update on the original agent. The update reconstructs perturbations from SamplingInfo keys and applies the optimizer to the original parameters.

  5. Handle online/offline runs as data contracts. Online sampling should persist SamplingInfo plus reward records in the same order used for offline update. Offline update should reload the current model/solver state, parse the records, call update, and save the next model/solver state.

  6. Avoid unsafe build shortcuts by default. Treat upstream shell helpers as examples only: they may remove build directories, install into the source tree, unzip bundled data, download libtorch, and run demos. Prefer an explicit local prerequisite check and a controlled manual CMake build in a disposable checkout or dedicated build directory.

  7. Escalate by symptom. Use references/build-and-api.md for API/build planning and references/troubleshooting.md for protobuf, backend library, CMake, gflags/glog/OpenMP, and ESAgent misuse errors.

Verification status

This sub-skill is source-evidence backed. The bundled checker was written to inspect local prerequisites without downloads or builds. EvoKit itself was not fully compiled during skill construction because the optional C++ backend libraries are environment-specific.

Reference map

  • references/build-and-api.md — distilled EvoKit C++ API concepts, config schema, Torch/PaddleLite choices, and safe build outline.
  • references/troubleshooting.md — fixes and safety notes for protobuf/protoc, backend libraries, gflags/glog/OpenMP, build helper side effects, CMake cleanup, and ESAgent loop mistakes.
  • scripts/check_evokit_prereqs.py — deterministic local prerequisite checker; it prints missing items and never downloads, builds, deletes, or writes project files.

04 同仓库更多 Skills

VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-triton-opt

Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-solve

END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-skill

PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-pattern-fusion

Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-orchestrate

Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-feedback

Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).

★ 351