Agent skill · Code Review & Quality

pufferlib

Version-aware guidance for PufferLib reinforcement-learning environments, vectorization, policies, PuffeRL training, evaluation, and safe checkpoint review. Use when adapting Gymnasium/PettingZoo environments to published PufferLib 3.0.0 or working with the redesigned native 4.0 source line.

K-Dense-AIgithub.com/K-Dense-AIGitHub ↗
claude-codecan modify filesships scriptsMIT
Install
npx skills add K-Dense-AI/scientific-agent-skills --skill pufferlib --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 15
SKILL.md size: 11 KB
Bundled scripts: yes
Version: 1.1
Allowed tools: ReadBashGrepPython
Requires: Bundled CLIs require Python 3.10+ and use only the standard library. Published pufferlib 3.0.0 supports Python >=3.9…
Path: skills/pufferlib/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 32,619
Language: Python
Read our review of the source →

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# PufferLib Use PufferLib with an explicit version profile. Upstream currently has two incompatible surfaces: | Profile | Status on 2026-07-23 | Main use | |---|---|---| | `pufferlib==3.0.0` | Latest stable PyPI release, published 2025-06-23 | Python/Gymnasium/PettingZoo emulation, `pufferlib.vector`, Torch PuffeRL | | source `4.0` | Upstream default branch; not the latest stable PyPI artifact | Native C Ocean environments, native CUDA trainer, optional Torch fallback | Do not combine 3.0 imports with 4.0 config/CLI examples. The 4.0 redesign removed the 3.0 `emulation`, `vector`, and `pytorch` modules from the current package tree. ## Safe defaults 1. Start with bundled synthetic, CPU-only, network-free tools. 2. Do not import an arbitrary environment by dotted path. Bundled tools accept only allowlisted built-ins and slug identifiers. 3. Do not install or execute an unreviewed environment package, native extension, ROM, map, checkpoint, or pickle file. 4. Verify official source, immutable revision, licenses, checksums or attestations, and build hooks. Sandbox native builds and first execution. 5. Cap steps, environments, agents, workers, threads, buffers, memory, disk, render siz

What's inside
Steps it walks through
  1. Safe defaults
  2. First local checks
  3. Installation and provenance
  4. Published 3.0.0
  5. Current 4.0 source
  6. Environment workflow
  7. 1. Validate the contract
  8. 2. Adapt only after review
  9. 3. Native environments
  10. Vectorization workflow
  11. Policy workflow
  12. Training and evaluation
  13. Logging
  14. Checkpoint workflow
Ships with 14 files
  • references/environments.md
  • references/integration.md
  • references/policies.md
  • references/training.md
  • references/vectorization.md
  • scripts/__init__.py
  • scripts/_common.py
  • scripts/benchmark_vectorization.py
  • scripts/env_contract_validator.py
  • scripts/env_template.py
  • scripts/inspect_checkpoint.py
  • scripts/repro_plan.py
  • scripts/train_template.py
  • scripts/validate_plan.py
Commands it runs
python3 scripts/env_template.py --help
python3 scripts/env_contract_validator.py
python3 scripts/benchmark_vectorization.py --backend serial
python3 scripts/train_template.py
python3 scripts/validate_plan.py
python3 scripts/repro_plan.py
uv venv --python 3.11
uv add --exact --no-sync "pufferlib==3.0.0"
uv lock
uv sync --frozen
More from scientific-agent-skills
All skills →
About this skill
What does the pufferlib skill do?

Version-aware guidance for PufferLib reinforcement-learning environments, vectorization, policies, PuffeRL training, evaluation, and safe checkpoint review. Use when adapting Gymnasium/PettingZoo environments to published PufferLib 3.0.0 or working with the redesigned native 4.0 source line.

How do I install it?

Run `npx skills add K-Dense-AI/scientific-agent-skills --skill pufferlib --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From K-Dense-AI/scientific-agent-skills, a repository with 32,619 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going