model-factory
Skill2.2k starsChanged 3 days agoApache-2.0View on GitHub
Launch and monitor prime-rl runs on Model Factory with prime train, and retrieve their traces. Use for requests such as "run this on model factory", including custom code revisions, private datasets, credentials, and team setup. Explicit local or SLURM jobs use start-run.
- Reads credentials
We split this skill into the rules it gives an agent
14 rules. About 0 are common, 4 are distinctive, and 10 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
10
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 8
Use prime train run CONFIG.toml for managed training.
- Very specific: line 15
All local paths below are relative to the selected prime-rl checkout.
- Distinctive: line 73
Start from an existing example in that revision, copying it to a task-specific TOML if edits are needed.
- Distinctive: line 88
Use the exact model ID and GPU type available for the selected account/team.
- Very specific: line 96
Remove SLURM configuration and machine-local output_dir / run.dir paths.
- Distinctive: line 97
Put prompts and other required assets in the launched source or a supported volume.
- Very specific: line 100
Check TP/DP/EP/CP and context length against the model, hardware, and schema.
- Very specific: line 102
Use the revision's [run] and [monitors.wandb] schema for names and logging.
- Very specific: line 105
Keep RL train/eval sources separate under orchestrator.train.source and orchestrator.eval.source.
- Very specific: line 111
Keep [ckpt] and attach a named volume when checkpoints must persist.
- Very specific: line 117
If prime train validate --help is available, use that command with the same --ref / --image-tag and --sft selection as the intended launch.
- Very specific: line 138
Keep dispatch metadata (--ref, image, GPU, volume) in CLI flags so this fallback receives only native prime-rl fields.
- Distinctive: line 189
When asked to stop, or when an already agreed stop condition is reached:
- Very specific: line 196
Verify terminal state, wait for volume sync, and retrieve requested checkpoints with prime volumes get.
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Model Factory
Use prime train run CONFIG.toml for managed training. prime train CONFIG.toml
is the same command. The platform provisions and launches the components. Pass a
single TOML filename directly; @, local uv run rl / uv run sft, and arbitrary
dotted training flags belong to the local entrypoints. Put training overrides in
the TOML. An explicit request to submit a SLURM job on a Model Factory cluster
still uses the start-run skill.
All local paths below are relative to the selected prime-rl checkout. Discover the user's checkout, credentials, team, and available CLI; do not assume a home directory, secret-file location, organization, GPU type, or previous run.
CLI, authentication, and team
command -v prime
prime --version
prime train run --helpInstall a missing CLI with uv tool install prime; update an existing tool with
uv tool upgrade prime when a required feature needs it. Check which executable
the shell resolves: a project environment can shadow the tool installation.
Authenticate with prime login, an existing exported PRIME_API_KEY, or the
secure prompt from prime config set-api-key. For automation, load the key from
the user's chosen secret store into the process environment. Do not put its value
in command arguments, TOML, Git, or chat. A file on disk is not automatically
exported. The CLI config implementation
gives PRIME_API_KEY and nonempty PRIME_TEAM_ID precedence over saved settings.
For an API-key workflow, after loading the key securely:
: "${PRIME_API_KEY:?Load a Prime API key for the launching account}"
export PRIME_API_KEYInspect the effective account configuration and available teams:
prime config view --plain
prime teams list --plain -o jsonconfig view masks the API key. Reuse the account/team the user selected; if the
intended owner is ambiguous, resolve it before launching billable work. Set the
chosen team ID from that list with prime config set-team-id "$TEAM_ID", or use
export PRIME_TEAM_ID="$TEAM_ID" for the current process. An exported team ID
overrides set-team-id. To intentionally use a personal account, unset
PRIME_TEAM_ID and use prime config remove-team-id. Team choice also scopes
volumes and run access. See CLI configuration
and teams.
The launching credential and the remote run credential have different roles:
the platform supplies a run-scoped PRIME_API_KEY to the Model Factory job. Do not
include the launching key in -e or --env-file. Read
data and secrets before forwarding credentials
or using private Hugging Face data.
Choose the source and a checked-in example
For custom training code, branches, commits, dependencies, or environments, read custom code first. Select the runtime revision before adapting or validating its config.
Start from an existing example in that revision, copying it to a task-specific TOML if edits are needed. Do not use personal debug configs or prior experiment artifacts as the default recipe.
| Task | Starting point |
| Small RL run | examples/basic/reverse-text/rl.toml |
| SFT | examples/basic/reverse-text/sft.toml |
| Larger model or environment | Select a matching checked-in TOML under examples/advanced |
prime train models --plain -o json
prime train gpus --plain -o jsonUse the exact model ID and GPU type available for the selected account/team.
The Model Factory RL docs
describe uncached HF downloads on on-demand capacity, while reserved clusters
require cached weights or weights on a volume. Check the actual dispatch path; an
HF_TOKEN grants repository access, not cluster capacity or model-cache access.
Adapt the example to the requested experiment:
- Remove SLURM configuration and machine-local
output_dir/run.dirpaths. Put prompts and other required assets in the launched source or a supported volume. A path in TOML does not upload the file. - Set
[deployment]explicitly, including trainer and inference GPU counts. Check TP/DP/EP/CP and context length against the model, hardware, and schema. Preserveoptimization_dtypeandreduce_dtypeunless explicitly requested. - Use the revision's
[run]and[monitors.wandb]schema for names and logging; consult the configs skill for config structure. The selected revision's schema takes precedence over snippets from another build. - Keep RL train/eval sources separate under
orchestrator.train.sourceandorchestrator.eval.source. Dataset arguments belong to the selected taskset's config underenv.taskset; inspect its supported fields before setting them. - SFT uses
[data]and needs real data staged on a volume. The checked-in SFT example also enables online eval; check CLI and cluster support before using it. See data and secrets for both paths. - Keep
[ckpt]and attach a named volume when checkpoints must persist. Choose its size for the dataset, model, and retained checkpoints; see volume sizing.
Validate and dispatch
If prime train validate --help is available, use that command with the same
--ref / --image-tag and --sft selection as the intended launch. It is a
validation command, not a GPU run. Otherwise, validate from the matching checkout
and its installed environment (CONFIG_PATH names the prepared TOML):
uv run --no-sync python - "$CONFIG_PATH" <<'PY'
import sys
import tomllib
from pathlib import Path
from prime_rl.configs.rl import RLConfig
from prime_rl.configs.sft import SFTConfig
data = tomllib.loads(Path(sys.argv[1]).read_text())
schema = SFTConfig if "data" in data and not {"trainer", "orchestrator"} & data.keys() else RLConfig
schema.model_validate(data)
print("Config valid")
PYKeep dispatch metadata (--ref, image, GPU, volume) in CLI flags so this fallback
receives only native prime-rl fields. Validation checks the config, not remote
imports, private dataset access, capacity, or feature entitlements. For custom
code, verify that the validator actually imports the selected revision's schema.
Summarize the prepared config, source/image, owner, GPU allocation, and expected run length before dispatch. Carry out an already authorized launch; ask only for unresolved choices or credentials that affect it. For an initial smoke run, use a small step budget unless the user specified otherwise.
prime train run "$CONFIG_PATH" \
--gpu-type "$GPU_TYPE" --volume "$VOLUME_NAME" \
-e WANDB_API_KEY -e HF_TOKEN --yes --plain -o jsonInclude only the flags and exported secrets that the run needs. Add
--ref "$CODE_REF" for authorized custom source access, and --sft for SFT.
--yes skips the CLI prompt for the launch the user requested. Save the returned
.run.runId, config, source SHA, image selection, team, volume, and reported
placement/rate. Share the dashboard URL returned by the CLI.
Monitor and finish
prime train get "$RUN_ID" --plain -o json
prime train components "$RUN_ID" --plain
prime train logs "$RUN_ID" --plain --tail 100
prime train logs "$RUN_ID" -c trainer --plain --since 5m --tail 500
prime train logs "$RUN_ID" -c inference --plain --since 5m --tail 500
prime train metrics "$RUN_ID" --plain --limit 10
prime train progress "$RUN_ID" --plainFor environment logs, use --env with a name returned by components. Follow
with -f or filter with --search / --level ERROR when needed. Confirm completed
training steps and inspect rollout/eval infrastructure errors; RUNNING alone
does not establish progress. Export needed component logs while pods still exist.
Uploaded traces persist separately from pods and can be retrieved after the run
ends. For rollout inspection or trace downloads, read
retrieving traces: list by run ID with prime traces list,
then save raw documents with prime traces get --raw --dest. Listing summaries
alone does not download the traces. The reference covers whole-run pagination,
per-step episodes, separate eval run IDs, and missing-upload checks.
Queued and image-pull states can be normal. After an ambiguous dispatch timeout,
check prime train list for the submitted run before retrying; do not create
duplicates. Deterministic config, import, credential, or sandbox setup errors
need a fix before another launch. Respect the user's run budget and stop conditions.
When asked to stop, or when an already agreed stop condition is reached:
prime train stop "$RUN_ID" --force --plain
prime train get "$RUN_ID" --plain -o jsonVerify terminal state, wait for volume sync, and retrieve requested checkpoints
with prime volumes get. Report the run ID/link, actual completed steps, outcome,
and checkpoint/trace artifact locations. Follow-up runs need to remain within the
user's request.
Trending
Less talk lately.about the whole repository
Who's talking about PrimeIntellect-ai/prime-rl
- ai-dynamo/dynamo“feat(RL): support external RL control planes”GitHub · Sep 2, 2026 · 1 reactions
- PrimeIntellect-ai/verifiers“chore: remove legacy environments”GitHub · Jul 17, 2026 · 1 reactions
- PrimeIntellect-ai/verifiers“fix(v1): structure env server worker failures”GitHub · Jul 12, 2026 · 1 reactions
- vllm-project/vime“docs: acknowledge SkyRL/verl and list SkyRL/prime-rl as users in README”GitHub · Jun 10, 2026 · 1 reactions
- huggingface/trl“AsyncGRPO: make NCCL weight sync robust on PCIe-only GPUs (auto fallback from P2P/SHM)”GitHub · May 27, 2026 · 1 reactions
The biggest 5 of 50 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 50
Talked about on GitHub (50 times).
On GitHub · 50
- Sep 2, 2026feat(RL): support external RL control planes — ai-dynamo/dynamo1 reaction · 7 comments
- Jul 17, 2026chore: remove legacy environments — PrimeIntellect-ai/verifiers1 reaction · 1 comment
- Jul 12, 2026fix(v1): structure env server worker failures — PrimeIntellect-ai/verifiers1 reaction · 1 comment
- Jun 10, 2026docs: acknowledge SkyRL/verl and list SkyRL/prime-rl as users in README — vllm-project/vime1 reaction
- May 27, 2026AsyncGRPO: make NCCL weight sync robust on PCIe-only GPUs (auto fallback from P2P/SHM) — huggingface/trl1 reaction · 3 comments
45 more on GitHub
- Nov 25, 2025[ROCm][CI] Skip NVIDIA-Only Prime-RL Test in AMD CI — vllm-project/vllm1 reaction · 8 comments
- Oct 24, 2026feat(loss): add ipo probability-gap token mask — NVIDIA-NeMo/RL0 reactions · 4 comments
- Oct 6, 2026perf(v1): accept packed CSR sampling masks from prime-rl's /generate — PrimeIntellect-ai/verifiers0 reactions · 1 comment
- Oct 6, 2026perf(client): read prime-rl's packed completion_logprobs — PrimeIntellect-ai/renderers0 reactions · 1 comment
- Sep 24, 2026Preserve unclosed implicit Qwen3.5 thinking — PrimeIntellect-ai/renderers0 reactions · 1 comment
- Sep 9, 2026Prevent untrainable-batch stalls in RL training — pytorch/torchtitan0 reactions · 1 comment
- Sep 2, 2026docs(rfd): propose model request relationships — agentclientprotocol/agent-client-protocol0 reactions · 1 comment
- Sep 1, 2026[Feature Request] Add text-only GRPO support for Qwen3.8-Flash-Next (qwen4_exp) — verl-project/verl0 reactions
- Aug 27, 2026test(rl): validate the Dynamo integration with Prime-RL — ai-dynamo/dynamo0 reactions
- Aug 27, 2026feat(mx_refit): rebase and consolidate the ModelExpress transport — tanushriya910/prime-rl0 reactions
- Aug 24, 2026feat(v1): add Trace.reward_shaping for trainer reward-shaping terms — PrimeIntellect-ai/verifiers0 reactions
- Aug 20, 2026Add raw multimodal content parts support — PrimeIntellect-ai/renderers0 reactions · 1 comment
- Aug 20, 2026Keep multimodal content inline in v1 rollouts — PrimeIntellect-ai/verifiers0 reactions · 1 comment
- Aug 12, 2026GRPO example: reverse text (single p150, Qwen3-0.6B) — tenstorrent/tt-metal0 reactions · 2 comments
- Aug 11, 2026Github trending [PrimeIntellect-ai/prime-agent] 开源长期任务编码代理 — web1992/github-trending0 reactions
- Aug 10, 2026Github trending [PrimeIntellect-ai/prime-agent] 开源持久化编码智能体 — web1992/github-trending0 reactions
- Aug 9, 2026Github trending [PrimeIntellect-ai/prime-agent] 递归语言模型自动优化 — web1992/github-trending0 reactions
- Aug 8, 2026Github trending [PrimeIntellect-ai/prime-agent] 开源长期任务编码智能体 — web1992/github-trending0 reactions
- Jul 23, 2026feat: gate Kubernetes workers until weight update — PrimeIntellect-ai/router0 reactions
- Jul 16, 2026feat: add MMMU V1 taskset — PrimeIntellect-ai/prime-envs0 reactions · 1 comment
- Jul 14, 2026Token-level trace emission for PrimeIntellect renderers compatibility — gents-ai/gents0 reactions · 1 comment
- Jul 8, 2026feat: VF_* env-var config overrides for the v1 CLIs — PrimeIntellect-ai/verifiers0 reactions
- Jul 8, 2026feat: environment-variable overrides via env_prefix — PrimeIntellect-ai/pydantic-config0 reactions
- Jun 20, 2026feat(v1): add trace algorithm classes — PrimeIntellect-ai/verifiers0 reactions
- Jun 18, 2026[codex] Support raw image offload in v1 train client — PrimeIntellect-ai/verifiers0 reactions · 1 comment
- Jun 18, 2026[codex] Support raw image refs for multimodal rendering — PrimeIntellect-ai/renderers0 reactions · 1 comment
- Jun 10, 2026[ENG-4030] config updates to support orch v2 — PrimeIntellect-ai/prime0 reactions · 1 comment
- Jun 5, 2026[Add] PRIME-RL (PrimeIntellect-ai/prime-rl) — PyTorchKR/landscape0 reactions
- Jun 2, 2026ENG-3847: deprecate repetition_penalty, min_tokens, and seed from sampling config — PrimeIntellect-ai/prime0 reactions
- Jun 1, 2026ENG-3693: deprecate max_async_level user configuration — PrimeIntellect-ai/prime0 reactions
- May 23, 2026Typed renderer configs — PrimeIntellect-ai/renderers0 reactions · 1 comment
- May 23, 2026Pass renderer chat template kwargs from sampling — PrimeIntellect-ai/verifiers0 reactions · 2 comments
- May 18, 2026ENG-3683: Add max inflight rollout config — PrimeIntellect-ai/prime0 reactions
- May 16, 2026[PD]: Bidirectional KV transfer — PrimeIntellect-ai/router0 reactions · 1 comment
- Apr 3, 2026[Feature] Support real CP for Qwen 3.5 — radixark/miles0 reactions · 1 comment
- Mar 11, 2026make httpx connect timout configurable — PrimeIntellect-ai/verifiers0 reactions
- Feb 24, 2026add `RolloutGatewayMixin` for server-side rollout execution — PrimeIntellect-ai/verifiers0 reactions · 2 comments
- Feb 17, 2026experiment: LoRA RL tune for injection robustness via Prime Hosted Training — misty-step/laboratory0 reactions
- Feb 16, 2026Feat: router replay — PrimeIntellect-ai/verifiers0 reactions · 1 comment
- Feb 10, 2026`opencode_swe`: deprecate `InterceptionServer` — PrimeIntellect-ai/prime-envs0 reactions
- Jan 15, 2026use custom logger in mini swe sandbox — PrimeIntellect-ai/prime-envs0 reactions
- Jan 7, 2026mini_swe_agent_plus `0.2.0`: integrate vf.SandboxError — PrimeIntellect-ai/prime-envs0 reactions
- Jan 2, 2026docs: fix training examples link — PrimeIntellect-ai/verifiers0 reactions · 1 comment
- Nov 29, 2025Fix: Replace invalid `--weights` flag with `--ckpt` in example READMEs — zch42/prime-rl0 reactions
- Aug 26, 2025Concurrency issues with OAI client for large-scale evals — PrimeIntellect-ai/verifiers0 reactions · 4 comments
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

