trainer

trainer is a skill for Claude Code, Codex from OpenDCAI/Dataflow-LoopAI. It costs 64 tokens per session (4,800 once invoked), scanned A, original, Apache-2.0.

A workflow for preparing and running machine-learning model training with LLaMA-Factory or Verl. It checks training data and settings, starts or reconnects to training workers, and handles results.

In plain words
What is it for?
Use it to validate SFT data or GRPO data, configure rewards, create training settings, run training, monitor workers, compare checkpoints, export models, and inspect failures.
Why use it?
It reduces errors caused by invalid data, mismatched training settings, or lost worker connections. It also keeps checkpoint comparison and model export in one workflow.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions Codex.

Good fit Use it to validate SFT data or GRPO data, configure rewards, create training settings, run training, monitor workers, compare checkpoints, export models, and inspect failures.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/opendcai/dataflow-loopai/trainer
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add OpenDCAI/Dataflow-LoopAI --skill trainer
Clone the repo
git clone --depth 1 https://github.com/OpenDCAI/Dataflow-LoopAI

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for trainer

README.md
[![agentmods](https://agentmods.dev/badge/skills/opendcai/dataflow-loopai/trainer/github.svg)](https://agentmods.dev/skills/opendcai/dataflow-loopai/trainer)
Your own site
<a href="https://agentmods.dev/skills/opendcai/dataflow-loopai/trainer"><img src="https://agentmods.dev/badge/skills/opendcai/dataflow-loopai/trainer/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for trainer

Your own site · 80×15
<a href="https://agentmods.dev/skills/opendcai/dataflow-loopai/trainer"><img src="https://agentmods.dev/badge/skills/opendcai/dataflow-loopai/trainer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 64 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,800 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 1 finding, up to medium

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • medium Agent Snooping · line 42
    Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.
    Fix: Remove all code or instructions that list or read other skills' files or directories. Skills should operate independently; cross-skill access is a privilege escalation.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00064 $0.04800
Opus 5.5 $0.00026 $0.01920
Sonnet 5.5 $0.00013 $0.00960
Haiku 4.5 $0.00006 $0.00480

Measured 1mo ago against content hash 2d4abca6bc4d, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

trainer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/Trainer/SKILL.md · 514 lines

How it starts

The opening of the file, as written. The whole thing — 514 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Trainer Skill

Purpose

Trainer Skill is the Codex-facing entry point and the canonical Python implementation for LoopAI model training.

Use this skill for:

  • Running sft + llamafactory or grpo + verl; do not mix backend/stage pairs
  • Validating SFT JSON/JSONL or GRPO Parquet data and reward configuration
  • Generating and approving backend-specific training YAML
  • Running or reconnecting to the persistent Trainer worker
  • Reading local metrics, selecting checkpoints, and exporting Verl FSDP actors
  • Returning structured Trainer errors without relying on SwanLab or Trainer MCP

Do not use this skill for Judger, Analyzer, data crawling, or broad project refactors.

Python Implementation

loopai/skills/Trainer/
├── __init__.py        # prepare() / run_prepared() / run() / result helpers
├── trainer_agent.py   # LangGraph subgraph used by Starter and the skill runner
├── nodes/             # data validation, config generation, training execution
├── rewards/           # stable LoopAI routing to Verl reward implementations
├── utils/             # persistent worker, Verl/SFT launchers, events, parsers
├── templates/         # bundled training templates
├── results.py         # parses metrics and selects the best checkpoint
├── runner.py          # skill entry that runs the Trainer subgraph
├── runtime_config.py  # resolves kwargs/env/state/starter.yaml
└── worker_entry.py    # independent process that owns training and finalization

The root skill description lives at:

skills/Trainer/SKILL.md

Mandatory YAML Approval

For every user-initiated training round, use this two-stage workflow:

  1. Call prepare() to validate the data and generate the final training YAML. This stage must not start training.
  2. Read result["trainer"]["trainer_result"]["data"] and show the user:
    • config_path
    • the complete config_yaml in a YAML code block
    • the selected train_framework and train_stage
    • for SFT: dataset/model paths, learning rate, epochs, batch size, LoRA fields, devices, output directory, and save_total_limit
    • for GRPO: train/validation Parquet paths, model, reward mode/preset or custom function, rollout backend, GPUs, batch/token limits, save/test frequency, checkpoint directory, selection metric, and checkpoint retention
  3. Stop and wait for explicit user approval. Do not treat a previous round's approval as approval for a new round.
  4. If the user requests edits, update the generated YAML, call inspect_prepared_config(), show the complete updated YAML, and wait for approval again.
  5. Only after approval, call run_prepared() with the displayed config_path, its displayed config_sha256, and the trainer_version_id returned by prepare().
  6. Keep run_prepared() in the foreground until training reaches completed, failed, or cancelled.

Read the full file on GitHub · 514 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 514 lines · 64 tokens per session scan A 2d4abca6bc4d

Subscribe to this mod's changes

trainer is a skill published in the GitHub repository OpenDCAI/Dataflow-LoopAI (29 stars, last pushed 16d ago), licensed Apache-2.0. It adds 64 tokens to every session and 4,800 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

install-openviking-memory

Install and configure the OpenViking long-term memory plugin for OpenClaw via natural conversation. Once installed, the plugin automatically captures facts from chats and recalls relevant context before each reply (auto-capture + auto-recall, cross-session). Covers prerequisites, install through OpenClaw's plugin…

volcengine/OpenViking · 191 tokens

knowledge-distillation

Compile one or more OpenViking knowledge bases or document collections into topic-organized, evidence-grounded high-level knowledge, including cross-source findings, trends, changes, drivers, comparisons, implications, and uncertainties. Use with ov compile when the user asks to distill or synthesize a knowledge base…

volcengine/OpenViking · 89 tokens

knowledge-graph

Compile documents, notes, web content, transcripts, research materials, or code repositories into an evidence-grounded, visualization-ready knowledge graph with semantically typed entity nodes, statement-level provenance, and typed relationship edges. Use with ov compile to create or incrementally refresh entities/.md…

volcengine/OpenViking · 107 tokens

seo-llm

Use when optimizing content for LLM-powered search engines (ChatGPT, Perplexity, Gemini, Claude, Bing AI, Qwen), implementing RAG optimization, prompt engineering for search visibility, semantic SEO, and ensuring content ranks highly in AI-driven search results. Includes techniques for ChatGPT SEO, Perplexity…

Omar-Obando/qwen-orchestrator · 79 tokens

llm-integrations

Use when integrating LLM providers (OpenAI, DeepSeek, OpenRouter, Anthropic, Google), configuring API keys, optimizing costs, implementing rate limiting, and managing LLM usage across projects. Includes best practices for cost optimization and API management. Based on OpenAI, Anthropic, Google, and other LLM provider…

Omar-Obando/qwen-orchestrator · 73 tokens

qwen-agent

Use when developing Qwen-specific agents, implementing Qwen model integrations, optimizing Qwen performance, and building agent workflows with Qwen models. Includes Qwen API, Qwen-Plus, Qwen-Turbo, and best practices. Based on Qwen official documentation and agent development best practices.

Omar-Obando/qwen-orchestrator · 63 tokens