MoECat is an end-to-end reasoning distillation pipeline for Scratch 3.0 algorithm education. The project converts 3K+ raw .sb3 algorithm works into standard scratchblocks pseudocode, then distills them via a top-tier reasoning LLM into high-quality JSONL corpora with <think> tags and deep algorithmic breakdowns, and finally fine-tunes lightweight MoE/LLM models under Kaggle's free dual-T4 GPU constraints.
.sb3 Raw Files
|
v
[1] Node.js AST Converter (.sb3 --> scratchblocks pseudocode)
|
v
[2] LLM Distillation Skill (single-item / read-and-destroy --> JSONL with <think>)
|
v
[3] Kaggle Fine-tuning (Unsloth 4-bit QLoRA, dual T4)
|
v
MoECat Series Models
| Stage | Tool | Output |
|---|---|---|
| Scratch Parsing | Node.js + sb3 parser | scratchblocks text |
| CoT Distillation | DeepSeek-R1-Distill-Qwen-8B | JSONL with <think> reasoning |
| Fine-tuning | Unsloth + QLoRA 4-bit | LoRA adapter weights |
DeepSeek-R1-Distill-Qwen-8B
MoECat-LLM/
βββ dataset_pipeline/
β βββ scratch_scraper.py # Scratch project batch scraper (auto-converts to scratchblocks)
β βββ parse-sb3-blocks/ # Node.js sb3-to-scratchblocks converter
β β βββ cli.js # CLI entry point
β β βββ src/ # Parser, block mapping, sanitizer source
β β βββ rollup.config.js # Build config
β β βββ package.json
β βββ Compact-Reasoning-Distiller/ # Agent skill for CoT distillation
β βββ SKILL.md # Skill definition and workflow
β βββ get_unprocessed_id.py # Tool: get next unprocessed project ID
β βββ merge_dataset.py # Tool: merge all entries into final JSONL
βββ fine_tune/ # (planned) Unsloth QLoRA training scripts
βββ examples/ # (planned) Advanced Scratch algorithm examples
βββ LICENSE
βββ README.md