Dev.to AI 🤖 Ai 👁 0 📖 4 min read

What AI labs pay for private code in 2026 – and a 30-minute pre-flight before you submit a repo

Disclosure: this post contains my referral links for Pangea.ai. If you license code through them, Pangea pays me a referral fee on top – it is not deducted from your share. I wrote two earlier posts about licensing old

Disclosure: this post contains my referral links for Pangea.ai. If you license code through them, Pangea pays me a referral fee on top – it is not deducted from your share.

I wrote two earlier posts about licensing old private code to AI labs (how it works, and an honest eligibility checklist). The most common follow-up question was practical: "OK, I have a few old private repos – what do I actually check before I submit anything?"

This is that pre-flight checklist. It takes about 30 minutes per repo and it will tell you whether a repo is worth submitting at all.

1. Ownership: can you license this code?

This is the step that matters most, because the ownership warranty in these agreements is serious – if you submit code you don't have the rights to, you carry the risk.

Ask yourself, for each repo:

  • Did I (or my company) write it and do we own it? Side projects, a startup that wound down, internal tools, in-house R&D – good candidates.
  • Was it written for a client? Client deliverables are out unless you have the client's written permission.
  • Was it written while employed somewhere? Check your employment contract's IP clause. Many contracts assign everything written on company time or equipment to the employer.
  • Co-founders / ex-partners? If the code belongs to a company with several owners, get agreement in writing.
  • Third-party code inside? Vendored libraries and copied snippets don't belong to you and don't count toward value anyway.

If any answer is unclear, park the repo. Don't guess.

2. Has it ever been public?

Labs want code they have never seen. Pangea's rules exclude code that is public or was public at any point:

  • Was the repo ever public on GitHub/GitLab, even briefly?
  • Is there an Internet Archive capture of it?
  • Was any part of it published as an npm / PyPI package?
  • Is it a fork, or a renamed copy of somebody else's project?

A public starter template is fine as a base if most of the code and the commits are yours. A public repo you later made private is not.

3. When was it written?

Labs increasingly avoid AI-generated code, so code written before 2025 is the best fit. Repos started in 2025 or later are flagged as "low likelihood" unless you can explain how they were developed. They're not rejected automatically, but set expectations accordingly.

Quick check:

git log --reverse --format="%ad %an" --date=short | head -5   # first commits
git log --format="%ad" --date=short | cut -c1-4 | sort | uniq -c  # commits per year

4. Is the git history intact?

Full history is a big part of the value – the indicative rate for history is separate from source (see below). A repo with years of commits from several developers is much more useful than a single "initial commit" dump.

  • Don't squash, rebase-flatten or re-upload the repo as a zip.
  • Connect it directly from GitHub, GitLab or Bitbucket so history, PRs, reviews and issues stay attached.
  • If you have the history only locally, push it to a private remote first.
git rev-list --count HEAD          # number of commits
git shortlog -sn | head            # contributors

5. Is there enough real source code?

What does not count: generated files, vendored dependencies, build output, binaries, data dumps, minified bundles. What labs like: real products – SaaS backends, internal tools, full applications, games, legacy systems. Bigger and more complete is better. WordPress sites/themes/plugins are declined.

Pangea/pre.dev publish a token counter that runs locally (the code is downloaded to your machine and nothing is uploaded). Read the script before running it, as you would with anything you download:

curl -fsSLO https://api.pre.dev/api/code-licensing/estimate.mjs
node estimate.mjs /path/to/repo

6. Secrets and personal data

Pangea says secrets and personal data are stripped from the review copy (code and history) before any buyer sees it, and your original repo isn't touched. Still, do your own pass – it's good hygiene anyway:

# scan the whole history for secrets
gitleaks detect --source . --log-opts="--all"

If you find live keys: rotate them regardless of what you decide about licensing.

7. The money, honestly

  • Pangea's published indicative rates: $100 per million tokens of source code and $40 per million tokens of git history. Illustrative only – the real per-repo estimate appears after you connect Git, and the agreement sets the terms.
  • The licence is non-exclusive: you keep ownership and can keep using the code; the same repo can be licensed again if there's demand.
  • Income is not guaranteed. Labs choose what to license; timelines are typically weeks to a few months.
  • When a deal happens, owners are paid within 15 days after the buyer pays.
  • No fee to join; you can review the agreement (ideally with a lawyer) before signing, and nothing goes to labs until you sign.

8. The 30-minute pre-flight, as a table

Check Pass if…
Ownership You or your company own it; no client code without written OK; employment IP clause checked
Never public Never public on any host, no archive capture, no published package, not a fork
Age Mostly pre-2025, or you can explain how 2025+ code was written
History Full history on a private GitHub/GitLab/Bitbucket remote
Substance Real application code, not mostly vendored/generated/data
Hygiene Secrets scan done, live keys rotated

If a repo passes all six, it's worth getting an estimate.

Links

Disclosure (again): these are referral links – Pangea pays me a referral fee. It doesn't change what you're paid. I'm not a lawyer; check the agreement and your contracts yourself. Questions welcome in the comments.

📰 Read the original article on Dev.to AI

Originally published by Dev.to AI. Aggregated on AIWithGhost for educational purposes — full credit and traffic to the original publisher.