forge-synth
Skill1 starsChanged 6 months agoMITView on GitHub
Generates Q/A pairs from cleaned passages via Claude Haiku. Converts a pretrain corpus (raw text chunks) into proper SFT chat-format training data (3 Q/A pairs per passage — factual + mechanism + clinical). Critical phase — without this, lora-sft regimes degenerate into raw-text continuation pretending to be SFT.
- Reads credentials
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 1 is distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 11
Skipped: when input is already chat-jsonl format.
- Very specific: line 46
If qa.jsonl exists, resumes from where it left off (uses passage_id as the dedup key).
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
forge-synth
When this fires
Phase position: SYNTH — after AUDIT, before SHAPE. Skipped when input is already chat-jsonl format.
What it does
- Reads the audited pretrain corpus from
data/audited/cleaned.jsonl(orprepped.jsonlif no audit phase ran) - For each passage, calls Claude Haiku to generate exactly 3 Q/A pairs:
- factual recall
- mechanism / "why does this work"
- clinical / practical
- Strict grounding (answers must come from passage)
- Filter rule-based junk (short answers, "according to the passage" framing, generic AI questions)
- Emit chat-format JSONL:
{id, format:"chat", messages:[{role:user,content:Q},{role:assistant,content:A}], metadata}
Inputs
run_id- Reads
audited/cleaned.jsonlorprepped.jsonlfrom run dir or S3 ANTHROPIC_API_KEY(from /tmp/forge-creds.env)
Outputs
slm-forge/.runs/<run_id>/qa.jsonl— raw synthesis output (one record per Q/A pair)slm-forge/.runs/<run_id>/qa-filtered.jsonl— after rule-based filterslm-forge/.runs/<run_id>/synth-stats.json— token usage + cost- Updates manifest:
artifacts.synth_corpus_s3
Concurrency
12 parallel requests via asyncio.Semaphore. ~50 sec per 100 passages.
Cost
Haiku 4.5 at $1/M input + $5/M output. Average ~$0.0026 per passage. 1500 passages → ~$4.
Idempotent
If qa.jsonl exists, resumes from where it left off (uses passage_id as the dedup key).
In this repository29 other files it gives its agents.
- slm-forgeSkill
- forge-analyzeSkill
- forge-architectSkill
- forge-auditSkill
- forge-bootstrapSkill
- forge-card-validatorSkill
- forge-curateSkill
- forge-estimateSkill
- forge-evalSkill
- forge-ingest-dbSkill
- forge-ingestSkill
- forge-intakeSkill
- forge-monitorSkill
- forge-plan-fitSkill
- forge-planSkill
- forge-preflightSkill
- forge-prepSkill
- forge-provisionSkill
- forge-publishSkill
- forge-quantizeSkill
- forge-registerSkill
- forge-reportSkill
- forge-resumeSkill
- forge-shapeSkill
- forge-smoketestSkill
- forge-sourceSkill
- forge-statusSkill
- forge-teardownSkill
- forge-trainSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

