Document Public APIs
pytorch/pytorch
Document undocumented public APIs in PyTorch by removing functions from coverageignorefunctions and coverageignoreclasses in docs/source/conf.py, running Sphinx coverage, and adding the appropriate…
Run Pyrefly benchmarks locally via Buck or Cargo, including PyTorch real-world LSP benchmarks.
$ npx skills add facebook/pyrefly --skill benchmark-pyrefly -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install facebook/pyrefly benchmark-pyrefly --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/facebook/pyrefly.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/benchmark-pyrefly .claude/skills/benchmark-pyrefly && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "benchmark-pyrefly" agent skill from https://github.com/facebook/pyrefly/tree/main/.agents/skills/benchmark-pyrefly into .claude/skills/benchmark-pyrefly/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "benchmark-pyrefly", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/facebook/pyrefly/tree/main/.agents/skills/benchmark-pyreflyType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add facebook/pyrefly --skill benchmark-pyrefly -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install facebook/pyrefly benchmark-pyrefly --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/facebook/pyrefly.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.agents/skills/benchmark-pyrefly .agents/skills/benchmark-pyrefly && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "benchmark-pyrefly" agent skill from https://github.com/facebook/pyrefly/tree/main/.agents/skills/benchmark-pyrefly into .agents/skills/benchmark-pyrefly/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "benchmark-pyrefly", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add facebook/pyrefly --skill benchmark-pyrefly -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install facebook/pyrefly benchmark-pyrefly --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/facebook/pyrefly.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.agents/skills/benchmark-pyrefly .cursor/skills/benchmark-pyrefly && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "benchmark-pyrefly" agent skill from https://github.com/facebook/pyrefly/tree/main/.agents/skills/benchmark-pyrefly into .cursor/skills/benchmark-pyrefly/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "benchmark-pyrefly", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/facebook/pyrefly.git --path .agents/skills/benchmark-pyrefly--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add facebook/pyrefly --skill benchmark-pyrefly -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install facebook/pyrefly benchmark-pyrefly --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/facebook/pyrefly.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.agents/skills/benchmark-pyrefly .gemini/skills/benchmark-pyrefly && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "benchmark-pyrefly" agent skill from https://github.com/facebook/pyrefly/tree/main/.agents/skills/benchmark-pyrefly into .gemini/skills/benchmark-pyrefly/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "benchmark-pyrefly", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install facebook/pyrefly benchmark-pyreflyInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add facebook/pyrefly --skill benchmark-pyrefly -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/facebook/pyrefly.git skills-src && mkdir -p .github/skills && cp -r skills-src/.agents/skills/benchmark-pyrefly .github/skills/benchmark-pyrefly && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "benchmark-pyrefly" agent skill from https://github.com/facebook/pyrefly/tree/main/.agents/skills/benchmark-pyrefly into .github/skills/benchmark-pyrefly/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "benchmark-pyrefly", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add facebook/pyrefly --skill benchmark-pyrefly -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install facebook/pyrefly benchmark-pyrefly --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/facebook/pyrefly.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.agents/skills/benchmark-pyrefly .opencode/skills/benchmark-pyrefly && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "benchmark-pyrefly" agent skill from https://github.com/facebook/pyrefly/tree/main/.agents/skills/benchmark-pyrefly into .opencode/skills/benchmark-pyrefly/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "benchmark-pyrefly", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
benchmark-pyreflyRun Pyrefly benchmarks locally via Buck or Cargo, including PyTorch real-world LSP benchmarks.
Benchmark Pyrefly is an agent skill from facebook/pyrefly, published by the product's own GitHub organization. Run Pyrefly benchmarks locally via Buck or Cargo, including PyTorch real-world LSP benchmarks. Use when user asks to benchmark pyrefly performance, run pyrefly bench, compare cold start vs error propagation, or update PyTorch benchmark pin.
Its SKILL.md is about 1.8k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
It sits in AI & LLM Engineering, covering Deep learning. It works with PyTorch and Python. The repository describes itself as: A fast type checker and language server for Python. The licence is MIT.
Read from SKILL.md and the folder at commit 6bc6ea9. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
cargoFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Benchmark Pyrefly loads about 1.8k tokens when it runs. Until then it costs about 65 tokens; SKILL.md has 772 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from facebook/pyrefly at commit 6bc6ea9, republished under its MIT licence (© facebook). 772 words, ~1,809 tokens.
.claude/skills/benchmark-pyrefly/SKILL.md (or your agent's skills folder).Use this skill when asked to benchmark pyrefly performance, run a pyrefly bench,
compare cold-start vs error-propagation latency, or update the PyTorch benchmark
pin. All benches live in pyrefly/pyrefly/benches/ and use Criterion.
Build mode matters: always build optimized, or the numbers are meaningless.
Buck uses @fbcode//mode/opt (or @fbcode//mode/opt-clang-thinlto for final
numbers). Cargo cargo bench already uses the optimized bench profile;
cargo run/cargo build would need --release. Debug builds run 3-10x slower
and are not comparable.
Never run two benchmarks in parallel — they compete for CPU and memory and the timings become unreliable.
Deterministic, single-threaded microbenchmarks of type-checker internals. Cheap to run, good for a quick signal.
buck2 run @fbcode//mode/opt fbcode//pyrefly/pyrefly:micro_bench -- --benchcargo bench --bench microSource: pyrefly/pyrefly/benches/micro.rs.
Three real-world benchmarks run over a pinned, multi-gigabyte PyTorch checkout
(15k+ Python files) across all cores. They are walltime benchmarks (threads,
I/O, a long cold start), not deterministic unit tests — distinct from the micro
benchmarks. Two drive the actual LSP server (cold_start, error_propagation);
one runs a cold batch check (full_check).
All three ship in one target — buck pytorch_bench, cargo bench
pytorch — and you select an individual one at runtime with a Criterion name
filter rather than picking a separate target. They live under
pyrefly/pyrefly/benches/pytorch/, one module file per bench:
pytorch/main.rs — crate root; declares the modules and calls
criterion_main! aggregating the benchmarks' Criterion groups.pytorch/common.rs — shared PyTorch-checkout acquisition harness and standard
LSP args.pytorch/cold_start.rs — the cold-start benchmark. Fresh server per iteration;
opens torch/distributed/pipelining/_backward.py and queries go-to-definition
of the Parameter import. Proxy for time-to-first-index. Criterion id
pytorch/cold_start_go_to_definition.pytorch/error_propagation.rs — the error-propagation benchmark. Warm server;
edits torch/nn/__init__.py to rebind Parameter to an int and waits for the
resulting type error to surface in the distant dependent _backward.py. Proxy
for incremental edit-propagation latency. Criterion id
pytorch/error_propagation.pytorch/full_check.rs — the full-check benchmark. Fresh State per iteration;
runs exactly what pyrefly check (project mode, no file args) does from inside
the checkout — discovers the project and checks every project file across all
cores. Proxy for whole-project batch throughput (not interactive latency).
Criterion id pytorch/full_check.These are slow. A cold-start iteration is ~3-5 s on a 64-thread devvm;
error-propagation is ~2-3 s and full-check ~1-1.5 s per iteration. Criterion's
sample floor is 10, so budget roughly 2-4 minutes per benchmark. Do not run
them in CI Sandcastle by default — they are manual/heavy (the PyTorch
http_archive dep is labeled manual).
Run all benchmarks:
# Buck (internal)
buck2 run @fbcode//mode/opt fbcode//pyrefly/pyrefly:pytorch_bench -- --bench
# Cargo (OSS)
cargo bench --bench pytorchRun just one, selecting it by Criterion name filter:
# Buck (internal) — cold start
buck2 run @fbcode//mode/opt fbcode//pyrefly/pyrefly:pytorch_bench -- --bench cold_start
# Buck (internal) — error propagation
buck2 run @fbcode//mode/opt fbcode//pyrefly/pyrefly:pytorch_bench -- --bench error_propagation
# Buck (internal) — full check
buck2 run @fbcode//mode/opt fbcode//pyrefly/pyrefly:pytorch_bench -- --bench full_check
# Cargo (OSS)
cargo bench --bench pytorch -- cold_start
cargo bench --bench pytorch -- error_propagation
cargo bench --bench pytorch -- full_checkUseful flags (append after -- for buck; pass directly for cargo):
--list — list the benches in the binary instead of running them, e.g.
buck2 run @fbcode//mode/opt fbcode//pyrefly/pyrefly:pytorch_bench -- --list.--quick — quicker, lower-confidence run.--noplot — skip Criterion report rendering. Required on a headless devserver
with no gnuplot and no usable font: the plotters backend otherwise panics
after a bench finishes with BackendError(FontError(FontUnavailable)).
Timings are unaffected. Example:
buck2 run @fbcode//mode/opt fbcode//pyrefly/pyrefly:pytorch_bench -- --bench --noplot.The PyTorch source (~550 MB unpacked, 68 MB tar.gz) is pinned by a single 40-hex
commit in pyrefly/pyrefly/benches/pytorch_pin.bzl — there is no git submodule. That
file is loaded by BUCK and parsed by the shared common module. Two providers:
http_archive and passes its path to the benches in
PYREFLY_PYTORCH_BENCH_PATH. No github egress; Buck CAS caches it.git + github.com egress), reused after.Set PYREFLY_PYTORCH_BENCH_PATH to an existing checkout to bypass both. If the
checkout can't be obtained, the bench prints a skip notice and exits cleanly.
Criterion writes to target/criterion/ (HTML plots, CSV samples,
estimates.json). Because buck run / cargo bench run from the cell root, it
lands at the fbsource repo root target/criterion/. It is ephemeral — do not
commit it, and do not add repo-root ignore entries (it is already gitignored
appropriately).
benches/tsp.rs -- buck tsp_bench, cargo bench tsp, Criterion id
tsp/get_computed_type_unopened_cached. Durable regression coverage for the
TSP unopened-file solve-reuse fix (D118537886): repeats an identical
getComputedType request, on a stable snapshot, against one never-opened,
unreferenced module deliberately expensive to solve, over the plain
in-process main connection. Server spawn, fixture generation, and the first
cold request are unmeasured; each measured iteration is one logical request.
Portable, no pinned checkout, no manual label.
buck2 run @fbcode//mode/opt fbcode//pyrefly/pyrefly:tsp_bench -- --bench
cargo bench --bench tspRun on a machine with github access (devvm/Sandcastle have no egress):
pyrefly/pyrefly/benches/update_revision.sh <40-hex-sha>It clones the rev, archives a tarball, rewrites pytorch_pin.bzl (rev +
sha256), and uploads the tarball to Manifold.
After a pin bump, re-check PARAM_LINE / PARAM_COL in
pytorch/cold_start.rs — they encode the position of Parameter in
_backward.py, and the cold-start bench asserts if they drift.
© facebook, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in .agents/skills/benchmark-pyrefly of facebook/pyrefly.
Open the folder on GitHubat commit 6bc6ea9
Benchmark Pyrefly next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Benchmark Pyrefly this skillfacebook/pyrefly | 7.1k | — | ~1.8k | Automated safety check: Pass | MIT | |
| Document Public APIspytorch/pytorch | 104k | — | ~4.2k | Automated safety check: Pass | Custom licence | |
| ExecuTorch Cortex-M Backendpytorch/executorch | 5.1k | — | ~872 | Automated safety check: Pass | Custom licence | |
| PyTorch Lightning TrainingOrchestra-Research/AI-Research-SKILLs | 13k | 7 repos | ~2.3k | Automated safety check: Pass | MIT | |
| Ako4allTongmingLAIC/AKO4ALL | 369 | — | ~4k | Automated safety check: Pass | MIT | |
| Homepage Generatorwanshuiyin/ARIS-in-AI-Offer | 580 | — | ~4.8k | Automated safety check: Notes | MIT |
pytorch/pytorch
Document undocumented public APIs in PyTorch by removing functions from coverageignorefunctions and coverageignoreclasses in docs/source/conf.py, running Sphinx coverage, and adding the appropriate…
pytorch/executorch
Developer guide for the Cortex-M (CMSIS-NN) backend in ExecuTorch: quantization pipeline, pass manager, tests and adding new ops.
Orchestra-Research/AI-Research-SKILLs
Shows how to organize PyTorch training with Lightning's LightningModule and Trainer, covering validation, DDP, callbacks and learning-rate scheduling.
TongmingLAIC/AKO4ALL
Drive an agentic loop that iteratively optimizes a GPU kernel for maximum speedup.
wanshuiyin/ARIS-in-AI-Offer
Generate a fact-checked academic personal homepage from a CV, optionally augmented by an existing manual homepage and an assets directory.
PaddlePaddle/Paddle
PaddlePaddle (飞桨) C++ 算子开发指南。提供从 YAML 配置、InferMeta 函数、Kernel 实现、Python API 封装、单元测试到编译验证的完整算子开发流程指导。在以下场景使用此 skill:(1) 为 Paddle 框架新增 C++ 算子 (2) 修改或调试已有 Paddle 算子 (3) 编写算子的 YAML…
facebook/pyrefly
A skill your agent uses when adding a new PyTorch model to Pyrefly's shape-tracking example corpus under tensor-shapes/pyrefly-torch-stubs/examples — i.e.
facebook/pyrefly
A skill your agent uses when Pyrefly computes a wrong tensor shape (or is missing one that can't be expressed in a stub signature) and you need to add or fix a shape-DSL rule.
facebook/pyrefly
Port a PyTorch model to use pyrefly's tensor shape type system (Tensor[[B, C, H, W]], Int[T]).
facebook/pyrefly
Produces a scorecard evaluating a pyrefly change on correctness and quality.
facebook/pyrefly
Reviews a comma separated pyrefly diff according to the pyrefly review best practices.
Categories
Run Pyrefly benchmarks locally via Buck or Cargo, including PyTorch real-world LSP benchmarks. Benchmark Pyrefly is an agent skill from facebook/pyrefly, published by the product's own GitHub organization. Run Pyrefly benchmarks locally via Buck or Cargo, including PyTorch real-world LSP benchmarks.
Benchmark Pyrefly fits situations like: user asks to benchmark pyrefly performance; run pyrefly bench; compare cold start vs error propagation; update PyTorch benchmark pin.
Run `npx skills add facebook/pyrefly --skill benchmark-pyrefly -a claude-code`. Or copy the skill folder (.agents/skills/benchmark-pyrefly in facebook/pyrefly) into .claude/skills/benchmark-pyrefly in your project. Claude Code loads it when a task matches its description.
Run `npx skills add facebook/pyrefly --skill benchmark-pyrefly -a codex`. Or copy the skill folder (.agents/skills/benchmark-pyrefly in facebook/pyrefly) into .agents/skills/benchmark-pyrefly in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add facebook/pyrefly --skill benchmark-pyrefly -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/benchmark-pyrefly, .gemini/skills/benchmark-pyrefly, .github/skills/benchmark-pyrefly and .opencode/skills/benchmark-pyrefly in your project.
Going by SKILL.md and its folder, Benchmark Pyrefly needs the command-line tools its instructions call (cargo). Our summary lists: Python 3.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Benchmark Pyrefly is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.8k tokens (SKILL.md is roughly 7.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Benchmark Pyrefly: Document Public APIs (pytorch/pytorch, 104k stars), ExecuTorch Cortex-M Backend (pytorch/executorch, 5.1k stars), PyTorch Lightning Training (Orchestra-Research/AI-Research-SKILLs, 13k stars) and Ako4all (TongmingLAIC/AKO4ALL, 369 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
facebook (a GitHub organization, an official publisher) maintains it in facebook/pyrefly, which has 7,054 GitHub stars. The repository holds 6 skills in this directory. The repository was last updated on October 8, 2026.
Source: facebook/pyrefly on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.