onescience-trainer

onescience-trainer is a skill for Claude Code from onescience-ai/OneSkills. It costs 147 tokens per session (2,941 once invoked), scanned A, original, MIT.

A workflow for planning, creating, running, and checking machine-learning model training. It covers data splits, loss functions, optimizers, learning-rate schedules, evaluation, checkpoints, logs, and runtime needs.

In plain words
What is it for?
Use it to generate training scripts, continue training from a checkpoint, fine-tune a model, organize training outputs, submit runs, and verify results.
Why use it?
It turns an informal training request or existing checkpoint into a traceable plan and execution process with defined validation steps.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the oneskills plugin — 27 skills shipped together

Good fit Use it to generate training scripts, continue training from a checkpoint, fine-tune a model, organize training outputs, submit runs, and verify results.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/onescience-ai/oneskills/onescience-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 onescience-ai/OneSkills --skill onescience-trainer
Clone the repo
git clone --depth 1 https://github.com/onescience-ai/OneSkills

Made for: Claude Code.

Or install oneskills, the plugin that ships this one along with the rest of its 27 skills.

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 onescience-trainer

README.md
[![agentmods](https://agentmods.dev/badge/skills/onescience-ai/oneskills/onescience-trainer/github.svg)](https://agentmods.dev/skills/onescience-ai/oneskills/onescience-trainer)
Your own site
<a href="https://agentmods.dev/skills/onescience-ai/oneskills/onescience-trainer"><img src="https://agentmods.dev/badge/skills/onescience-ai/oneskills/onescience-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 onescience-trainer

Your own site · 80×15
<a href="https://agentmods.dev/skills/onescience-ai/oneskills/onescience-trainer"><img src="https://agentmods.dev/badge/skills/onescience-ai/oneskills/onescience-trainer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 147 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,941 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 pass 7 Sept 2026
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.00147 $0.02941
Opus 5.5 $0.00059 $0.01176
Sonnet 5.5 $0.00029 $0.00588
Haiku 4.5 $0.00015 $0.00294

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

Security

Grade A, and why

onescience-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/onescience-trainer/SKILL.md · 139 lines

How it starts

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

输入获取方式

本技能支持两种输入方式:

  1. 上下文 handoff(默认):从调用方传入的 step_handoff 获取任务信息。
  2. 文件 handoff(autonomous_mode):从 .onescience/handoff/step_{step_id}.yaml 读取任务信息。执行后,将结果写入 .onescience/handoff/step_{step_id}_result.yaml。

启动时优先检查 .onescience/handoff/ 目录是否存在对应的交接文件;若存在则使用文件模式,否则使用上下文模式。

文件交接格式参见 skills/onescience-orchestrator/references/file_handoff_contract.md。

OneScience Trainer

职责

将本技能作为科学模型训练任务的执行工作流。把 orchestrator 交给本技能的当前步骤,例如“根据网页说明生成训练脚本”“基于已有 checkpoint 继续训练”“按文本给定的数据与优化器约束生成微调入口”“整理训练计划并提交训练”,转化为从训练信息获取到结果验证的可追踪闭环。

本技能只消费当前执行步骤,不重新规划完整用户目标。本技能负责训练工作流契约和阶段顺序,负责明确训练策略、数据配置、split 假设、loss、optimizer、scheduler、评测频率、checkpoint 策略、日志与验证要求等完整训练脚本内容;这些内容由 trainer 直接定义并保留在 trainer_workdir 中。训练执行阶段的外层控制、入口确定、预检要求和结果归因也由 trainer 负责。只有当这些已定义内容需要写入仓库、修改现有项目文件或对接项目原生目录结构时,才把当前步骤中的文件落盘子动作交接给 onescience-coder。依赖包、硬件和运行环境需求不单独成阶段,而是在训练执行阶段通过 onescience-runtime 统一处理。

工作流

创建或更新工作目录;当 step_handoff.inputs.runtime.code_save_dir、上游交接物或用户明确指定了代码保存目录时,trainer_workdir 必须使用 <code_save_dir>/.trainer_work/<run_id>/。其中 code_save_dir 用于保存最终训练脚本、配置、日志引用和用户要求的结果输出,trainer_workdir 用于保存训练知识、计划、manifest、runtime 请求/结果、验证报告等 trainer 中间知识产物。若上游已显式提供 step_handoff.inputs.runtime.trainer_workdir,则应直接使用该目录,并要求其与 code_save_dir 语义保持一致;若未提供代码保存目录,但 step_handoff.inputs.runtime.workdir、task_context.relevant_artifacts 或用户明确指定了工作目录,则沿用该目录;否则兼容性回退到 .onescience/trainer/<run_id>/。进入具体代码生成或执行阶段时,必须从 trainer_workdir 中已保存的知识文件读取并交接,不依赖未落盘的会话上下文。

本技能不依赖 scripts/ 目录下的预置脚本;训练入口、配置、数据适配器、损失函数、评估逻辑和测试要求等完整训练脚本内容都由 trainer 先行定义,不再把这些内容重新交给 onescience-coder 决定。若需要将这些已定义内容写入仓库、修改现有项目文件或对接项目原生目录结构,再交接给 onescience-coder 落盘为明确文件。

在消费上游交接或生成产物前,先读取 references/workflow_contract.md。随后必须先根据 step_handoff.step_goal、task_context.user_goal、inputs、resource_bindings 和用户直接请求,从 type=resource 技能中召回与训练目标相关的资源,获取训练规格知识、模型/数据使用知识和训练规划决策知识;无论上游是否提供了 resource_bindings,都不能跳过初始资源召回。资源 path 仅用于标识和追踪,允许作为训练依据的只有用户明确提供内容、上游已展开的资源内容和资源技能返回的 matched_resources[*].content。

Read the full file on GitHub · 139 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 · 139 lines · 147 tokens per session scan A 9b179b2bb634

Subscribe to this mod's changes

onescience-trainer is a skill published in the GitHub repository onescience-ai/OneSkills (24 stars, last pushed 2d ago), licensed MIT. It adds 147 tokens to every session and 2,941 once invoked, about $0.0006 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

graph-retrieval

Exposes graph-based retrieval as a tool capability via querygraph. Reads normalized graph store files, builds a query-relevant subgraph, and returns LLM-friendly semantic triples with replayable evidence metadata.

study8677/repobrain · 46 tokens

admet_genetic

ADMET-guided genetic molecule optimization workflow from seed SMILES; use when the agent needs to build or run an RDKit/SA-Score/ADMET-AI GA pipeline for molecule optimization, enforce molecule lineage logs, render optimization-history HTML dashboards, and write candidate triage reports.

PKU-YuanGroup/OpenAI4S · 63 tokens

bioprobench

Score an LLM's biological-protocol reasoning on the BioProBench benchmark: protocol QA, step ordering, error detection, protocol generation, and LLM-judged error reasoning; or generate the responses.

PKU-YuanGroup/OpenAI4S · 46 tokens

knowledge-layer

High-level deployment wrapper over RepoBrain core with graph-first knowledge injection and all-file support. Exposes refreshfilesystem and askfilesystem for building and querying the knowledge graph.

study8677/repobrain · 42 tokens

cqlib-kernel

A controlled workflow for running a cqlib quantum-style angle kernel and quantum support vector machine (QSVM), a classifier that separates labelled data. It compares the result with independent mathematical and RBF baselines and states the method's scientific limits.

xi-zhao/OpenQuantum · 42 tokens

qiskit-machine-learning

A Qiskit Machine Learning coding skill for quantum kernels, quantum support-vector models, quantum neural networks, gradients, training, and prediction. It uses quantum circuits as part of machine-learning models.

xi-zhao/OpenQuantum · 51 tokens