← AI Terminology
Fork
A fork is an independent copy of a codebase or model repository, created so that a developer or team can experiment, customise, or extend the original without affecting it.
In AI, "forking" most commonly refers to copying a model repository on GitHub or HuggingFace to fine-tune or adapt it under a new name.
In AI, "forking" most commonly refers to copying a model repository on GitHub or HuggingFace to fine-tune or adapt it under a new name.
Why It Matters in AI
The open-source AI ecosystem runs on forks: Meta releases Llama, and within days hundreds of forks appear fine-tuned on medical, legal, or multilingual data. Forking lets the community build on frontier research without waiting for permission or publishing new weights from scratch. In decision trees, "fork" also refers to each branch point — the split where the tree divides data into two child nodes.
Key Points
| Aspect | Description |
|---|---|
| Merge | The reverse: integrating changes from a fork back into the upstream via a pull request |
| Hard fork | In blockchain/open source: a fork that is intentionally incompatible with the original |
| Model fork | Copy of model weights + config on HuggingFace Hub — fine-tuned and re-uploaded under a new ID |
| Licence risk | Forking a model with a restrictive licence (e.g. Llama 2's non-commercial terms) can create legal exposure |
| Software fork | Copy of a Git repository — diverges independently from the original (git fork on GitHub) |
| Decision tree fork | Each internal node where the tree splits data on a feature threshold (also called a split) |
Simple Analogy
Forking a recipe: you take someone's published lasagne recipe, write your own name on top, and substitute ricotta for béchamel. The original recipe is unchanged; yours diverges from that moment forward. Pull requests are how you send your improvements back to the original chef.
Common Usage Examples
gh repo fork meta-llama/llama— fork the Llama repo to your GitHub account- HuggingFace: click "Duplicate this Space" or use
huggingface_hub.Repositoryto fork a model - Mistral 7B has thousands of forks on HuggingFace (instruction-tuned, quantised, domain-adapted variants)
- In a CART decision tree, each fork is computed by finding the feature threshold that minimises Gini impurity
git checkout -b my-featurecreates a local branch — a lightweight form of forking within one repo
Summary
In short: A fork is how open-source AI compounds — one strong base model becomes hundreds of specialised variants, each starting from the same checkpoint.