add-trainer-model
БесплатноБез исполняемых скриптовНе проверенAdd a new trainable base model to BOTH trainers end-to-end — the in-app trainer (main Next.js app, src/) and the Training Studio (apps/training-studio)…
от civitai★ 7 333 звезды на GitHubОб этом скилле
Add a Trainer Model
There are two trainers, and a new trainable model has to land in both or it will only appear in one:
- In-app trainer — the "Train a LoRA" flow in the main Next.js app (
src/components/Training/**,src/utils/training.ts,src/server/...). Kohya + AI-Toolkit. New models are gated behind a per-model Flipt flag (mod-only until launch). - Training Studio — the SvelteKit replacement at
apps/training-studio; see its engine support. Its model catalog is a vendored mirror of the in-app trainer's list, and it has its own per-model gate: aModelCard.flagKey(Flipt, fail-closed) hides a new model from everyone but the segmented cohort until launch — the mirror of the main app's<name>Trainingflag. Whichever host mounts the Studio resolves it: the standalone shell's server, or the main app for the/training-studioembed (throughstudioModelFlagFeatures). A card with noflagKeyis visible to every signed-in user immediately.
This skill is the umbrella that keeps the two in step. It owns the decision layer (the three facts below), delegates the pieces that already have skills, and owns the Training Studio mirror step, which no other skill covers.
AI-Toolkit by default for new model families. Preserve Studio's Kohya support as described in
apps/training-studio/CLAUDE.md. A Flux.2-style model that has no AI-Toolkit ecosystem usesimageResourceTrainingwith an explicit base AIR and its ownengine(flux2-dev,flux-dev-fast,musubi). It takes no AI-Toolkit hyperparameters. Confirm the engine contract before wiring it.
The three facts to establish first (Step 0)
Ask the user or infer from the model card / an orchestrator sample. Do not touch any file until all three are answered — each one changes what you do:
Does the base model / ecosystem already exist?
grep -niE "<name>" packages/civitai-shared/src/basemodel.constants.tsThe definitions live in the
@civitai/sharedpackage —src/shared/constants/basemodel.constants.tsis a 4-line re-export shim (grepping it finds nothing, for every model). Look forECO.<Name>, anEcosystemRecord, and aBaseModelRecord. If any are missing → run theadd-ecosystemskill first (it creates the ECO/BM constants, ecosystem, family, license and base model). This skill assumes they exist.Is it the same ecosystem as a model that is already trainable, or a genuinely new one?
- New version of an existing trainable ecosystem (e.g. another Wan version, another SDXL
fine-tune) → you are adding a
trainingModelInfokey to an ecosystem already wired up. Most of the main-app plumbing (schema enum aggregate, orchestrator union branch, feature flag,baseTypeToEcosystem,isAiToolkitSupported) is already in place; you mainly add the new key + its UI defaults, and a new version to the existing Training Studio card. - New ecosystem → the full
add-training-supportfile list applies, and the Training Studio gets a new card. Confirm the exact orchestratorecosystemliteral and whether the SDK type carries amodelVariant(Flux.1dev|schnell, Wan2.1|2.2, Flux.2 Klein4b|9b) — this disambiguates "new version" from "new ecosystem".
- New version of an existing trainable ecosystem (e.g. another Wan version, another SDXL
fine-tune) → you are adding a
Does
@civitai/orchestration-clientship the ecosystem's training input type? The orchestrator API depends on the SDK, so submission validation and the typed dispatch need it.grep -niE "<Name>AiToolkitTrainingInput|ecosystem: '<name>'" \ node_modules/@civitai/orchestration-client/dist/generated/types.gen.d.ts- Present → note the exact
ecosystemliteral, whethermodelVariantis required, any fixed fields (e.g. BoogubatchSizefixed at 1), and the server-computedreadonlyoutputs (never send those). - Absent → check
npm view @civitai/orchestration-client versionand bump to it in everypackage.jsonthat lists the client (git grep -l '"@civitai/orchestration-client"' -- '*package.json'), thenpnpm install;src/__tests__/orchestration-client-single-version.test.tsfails on a partial bump. If the type is still absent after bumping, the AI-Toolkit dispatch castsecosystem as anyso it works untyped — but say so to the user and prefer a typed SDK. The@civitai/orchestration-clientbump, when needed, is the answer to the brief's "does the client need updating?" — surface it explicitly.
- Present → note the exact
Step 1 — Confirm the plan with the user
State the whole plan back before editing, across both trainers:
Add trainer model: <Name>
Base model exists in basemodel.constants.ts: yes | NO → run add-ecosystem first
Relationship: new ecosystem | new version of <existing ecosystem>
@civitai/orchestration-client: ships <Name>AiToolki
Установить add-trainer-model в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл add-trainer-model?
Add a new trainable base model to BOTH trainers end-to-end — the in-app trainer (main Next.js app, src/) and the Training Studio (apps/training-studio). Orchestrates add-ecosystem (if the base model is missing) and add-training-support (main-app wiring), then mirrors the model into the Training Studio catalog, which nothing else covers. New model families default to AI-Toolkit; preserve the Studio engines documented in apps/training-studio/CLAUDE.md. Use when onboarding a new model family for training, or a new version of one — e.g. ZImage, MiniMax H3, a new Flux/Wan variant. Always checks whether @civitai/orchestration-client ships the ecosystem's training input type first.
Как установить скилл add-trainer-model?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл add-trainer-model запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic