본문으로 건너뛰기
cccskills
무료GitHub에 공개

change-grug

Try model or training changes in a copied Grug or Grugformer experiment, document the differences, and bring successful changes back into the base template while removing superseded experiment code and checking behavior.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

원문원문 설명 보기

Modify or upstream behavior in a named Grug/Grugformer experiment variant.

설치 방법 보기

이럴 때 유용합니다

  • Try changes to attention or masking
  • Experiment with optimizers or training loops
  • Bring successful changes into the base template
  • Archive experiment history and remove stale code

포함된 파일(1)

  • SKILL.md3.2 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Skill: Changing Grug (Template-First)

Grug is intentionally template-first: the canonical edit surface lives in experiments/grug/base/, not in a shared levanter.grug trainer stack.

This skill covers two steps: trying a change in an experiment copy, and upstreaming it into the base template when it proves out.

Do not use this skill to run an existing variant, change launch-only configuration, or add a bounded operational diagnostic. Use the variant README and launcher controls for those tasks.

Source Of Truth

  • Canonical template: experiments/grug/base/ — model.py, train.py, launch.py.
  • Variants: experiments/grug/<variant>/ — copy from base and modify locally (e.g. MoE).
  • One-off speedruns: experiments/speedrun/... — useful for exploration, not canonical.
  • Reference branch for array-stacked grug variant wiring: https://github.com/marin-community/marin/tree/codex/array-stacked-grug-variant-pointer — useful for perf-focused experiments, especially improving compile times and reducing peak HBM.

Workflow

1) Pick one change bucket

Keep each pass scoped to one bucket:

  • attention/masking
  • block wiring/norm ordering
  • MLP/activation
  • loss kernel behavior
  • optimizer/training loop behavior

2) Experiment in a copy

  • Copy experiments/grug/base to a new variant directory.
  • Keep edits local and explicit (copy/paste over abstraction).
  • Avoid introducing reusable framework surface unless there's clear repeated use.

3) Record the experiment

Update docs/reports/grug-archive.md with: path, origin (base, moe, or another source variant), commit SHA (when known), purpose, status (active, superseded, deleted), and diff link (prefer the CI-posted PR comment link; fallback to local report path).

For PRs that add a new experiments/grug/<variant>/, CI posts a visual diff comment automatically — copy that link into the archive entry.

For a local fallback, generate the diff report manually and link the report in the archive entry:

uv run python scripts/ci/grug_dir_diff.py \
  experiments/grug/base \
  experiments/grug/<variant> \
  --out /tmp/grug-diff

4) Upstream to base if it wins

Port the successful change back into experiments/grug/base/model.py, train.py, and launch.py. Keep it grug-style:

  • plain JAX arrays and explicit sharding
  • Equinox modules with init + __call__
  • minimal config knobs
  • legibility first; if a block gets hard to read, introduce a small local helper instead of framework indirection
  • when HBM is tight, use docs/references/hbm-optimization.md before bespoke memory hacks
  • when compile time or peak HBM is the bottleneck, evaluate an array-stacked variant first (see reference branch above)

5) Delete stale paths

After upstreaming, delete superseded experiment code; keep only the archive trail in docs/reports/grug-archive.md.

6) Validate

./infra/pre-commit.py --all-files
uv run pytest tests/test_grug_variant_contracts.py

Add focused tests for any behavior changes.

This workflow is inspired by modded-nanogpt: iterate quickly in copy-paste experiments, then upstream only what stays simple and useful.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Compare Zephyr changes using the same prepared dataset and matching execution settings. Analyze Finelog metrics for each processing stage to distinguish CPU efficiency, elapsed time, and peak memory changes, then report improvements, regressions, or tradeoffs.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Compare Zephyr performance before and after a PR
  • Assess speed gains against additional CPU usage
  • Check peak memory and out-of-memory regressions
marin-community/marin4천2026년 10월 23일 업데이트

Register Hugging Face datasets for Marin by inspecting their structure without downloading the full dataset. Identify text fields, configurations, and data splits, then add a dataset module and validate the mapping with a sample.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Registering a Hugging Face dataset for Marin
  • Inspecting text fields without a full dataset download
  • Checking configurations and data splits
marin-community/marin4천2026년 10월 23일 업데이트

add-grant

무료

Turn a specified GCP access request into a reviewable Pulumi change and pull request. Select the narrowest suitable role and encrypt personal email identities, covering resource permissions and Cloud Run viewer access through IAP, an access gateway.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Prepare a request for GCS bucket read access
  • Add a viewer to a Cloud Run service protected by IAP
  • Prepare service account impersonation permissions
marin-community/marin4천2026년 10월 23일 업데이트

Add or update Pallas/Mosaic kernels, specialized computation routines for JAX. The skill covers reference implementations, output and gradient checks, public wrappers, fallback behavior, performance benchmarks, and hardware-specific tuning when requested.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Adding a Pallas kernel for a JAX computation
  • Checking outputs and gradients against a reference
  • Maintaining backend selection and fallback behavior
marin-community/marin4천2026년 10월 23일 업데이트

Organize Marin experiment reports into a maintained index, or archive explicitly named older experiments using lasting tags and issue references. Existing conclusions and canonical links are preserved so experiment records remain traceable.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Organizing an index of experiment reports
  • Consolidating canonical report entries
  • Archiving named legacy experiments
marin-community/marin4천2026년 10월 23일 업데이트

Turn a bug report, improvement request, or experiment into a structured GitHub issue. Check for duplicates, write reproduction steps or testable completion criteria, apply suitable labels, and verify the published title and body.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • File a bug with clear reproduction steps
  • Create an improvement task with testable completion criteria
  • Track an experiment's hypothesis, status, and conclusions
marin-community/marin4천2026년 10월 23일 업데이트

marin-community의 스킬 모두 보기

이 스킬의 문제 신고