Data type
Code datasets for AI training
Code datasets range from open corpora built from public repositories to private codebases that AI labs now buy from shut-down startups.
Published
What is a code dataset?
A code dataset is a collection of source code, often with its history, tests, issues and documentation, gathered so a model can learn to read, write and fix software.
Public code datasets and private codebases
There are two kinds of code dataset, and they sell for very different reasons. Public corpora collect code that is already on the open web, mostly from public repositories, and release it for anyone to train on under the original files' licences.
Private codebases are the source code a company wrote for its own product and never published. Most large coding models have already trained on the public material, which is why AI labs and the firms that build data for them have started paying for private code.
What the first sales fetched
- A crypto startup's code base (MIT Technology Review, Oct 2026)
- About $25,000
- Dollars per codebase Turing was reported paying
- Tens of thousands
The buying is recent. In October 2026 MIT Technology Review reported a crypto startup selling its code base for about $25,000, with a sale of its workspace data from Google, Notion, Figma and Slack still pending. Earlier coverage reported that Turing, which builds coding data for labs, was paying tens of thousands of dollars per codebase from failed startups.
Public and private code datasets compared
| Dataset or route | What it contains | Terms | Reported price |
|---|---|---|---|
| The Stack v2 (BigCode) | Over 3 billion files in 600+ languages from the Software Heritage archive; 67.5 TB in full, 32.1 TB deduplicated | Gated; each file keeps its original licence; bulk download needs an agreement with Software Heritage and INRIA; owners can opt out | Free to access under its terms |
| Turing SWE-bench Trajectory dataset | 1,441 human-in-the-loop solution paths for hard SWE-bench tasks, with human corrections | Sold as part of Turing's coding data service | Not published |
| Private codebase via a wind-down marketplace | Repositories, documentation and tests, sometimes with tickets and designs | Licensed or sold to vetted buyers after PII and credentials are scrubbed (SimpleClosure AssetHub) | About $25,000 for one crypto startup's code (MIT Technology Review, October 2026) |
| Private codebase sold to a data firm | Production code from failed startups, cleaned and relicensed for training | Bought outright by firms such as Turing | Tens of thousands of dollars per codebase, per company reports (Let's Data Science, December 2025) |
Why labs pay for private repositories
- It is new to the model. Public repositories have been scraped many times; a private product codebase has not.
- It is real production code, written for paying users, with the tests, migrations and fixes that come with that.
- Context raises the value. SimpleClosure's CEO told Upstarts Media that tickets and designs from tools such as Jira, Linear or Figma add value to code, and that rarer languages such as Ruby or C++ fetch more.
- Scarcity beats size. The same interview says a smaller codebase can be worth twice as much as a larger one when what it contains is rare.
- Buyers price on a research thesis: how many useful training tasks they can cut from the code, which MIT Technology Review says they estimate from measures like lines of code.
- What a smaller codebase can be worth against a larger one, when what it holds is rare
- 2×
- Rarer languages that fetch more
- Ruby, C++
To get a first estimate for your own repository, our codebase value calculator turns size, language and history into a range you can test against buyers. Our guide to selling software after a shutdown covers the process end to end, and workspace archives sold alongside code are covered on our conversational data page.
Rights to check before a codebase is sold
- 1
Prove the company owns the code
Check that every employee and contractor signed an IP assignment. Code a freelancer wrote without one may not be the company's to sell.
- 2
List the open-source parts
Vendored libraries keep their own licences. Buyers will want them identified, and some licences carry conditions that travel with the code.
- 3
Strip secrets and personal data
Remove API keys, credentials, customer records in fixtures and database dumps. A PII scanner catches the obvious cases before a human review.
- 4
Get the right approvals
In a wind-down or bankruptcy, the board, creditors or a court may need to approve the sale. Proceeds usually go to creditors and investors first.
- 5
Decide what else is in the bundle
Workspace archives sell too, but they hold staff messages. An attorney quoted by MIT Technology Review called such data legally radioactive; buyers say they scrub PII and exclude HR records.
What DataBroker is, and isn't
DataBroker doesn't buy or hold codebases. We run a paid academy and a set of tools for people who broker data deals, including finding companies with code or data to sell, valuing it, checking the rights and introducing it to buyers. We can't promise a sale or a price; the figures above are what others have reported.
Sources
6 sources · checked Nov 9, 2026
The DataBroker team checked the facts on this page against 6 public sources, last on .
- AI labs are buying data from dead startups to train their models, MIT Technology Review, 13 October 2026Checked
- Turing Buys Failed-Startup Codebases for Training, Let's Data Science, 18 December 2025Checked
- What Fetches Top Dollar On The Dead Startup Data Marketplace?, Upstarts Media, 3 September 2026Checked
- AssetHub, SimpleClosureChecked
- The Stack v2 dataset card, BigCode on Hugging FaceChecked
- Expert coding data built for frontier standards, TuringChecked
Code datasets for AI training FAQ
Where can I find free code datasets?
Open corpora such as BigCode's The Stack v2 are free to access under their terms, which require you to respect each file's original licence. Benchmarks and smaller task sets are listed on Hugging Face and GitHub.
How much do AI labs pay for a codebase?
Public reports are thin. MIT Technology Review reported one startup codebase selling for about $25,000, and other coverage reported tens of thousands of dollars per codebase. Price depends on rarity, context and what the buyer can train on.
Can I sell code that uses open-source libraries?
Usually you can sell your own code, but the open-source parts keep their own licences. List them so the buyer can decide how to handle them, and have a lawyer check any copyleft components.
Does selling a codebase include the Git history?
Only if the agreement says so. Buyers often value commit history, tests and linked tickets, so decide what is in scope and scrub personal data from commit metadata and messages first.
Related
- AI training data
AI training data licensing explained: which datasets labs want, publicly reported deal values, and the copyright and transparency rules that now apply.
Codebase value calculatorA codebase value calculator that reads a public GitHub repository in your browser and estimates rebuild effort and cost with basic COCOMO.
- How to sell software you have built
How to sell software you have built, whether that means the whole product, the IP, or licensing the codebase as training data.
- Can a bankrupt company sell customer data?
Can a bankrupt company sell customer data? Often, but its old privacy promises follow the data into court, as RadioShack and 23andMe showed.
- Conversational data for AI training
Conversational data means real dialogue, from call recordings to chat and ticket logs; AI buyers want it consented, de-identified and labelled.
- Dataset overlap
Dataset overlap is the part of your data a lab already has; here is how labs measure it and how to measure it first.
Free tool
Try the codebase value calculator
A codebase value calculator estimates what it would cost to write a piece of software again, from its size in lines of code, an effort model such as COCOMO, and an hourly engineering cost.
- Free
- No sign-up
- Runs in your browser






