I like including sources.json in the @ in my claude.md, because it means the model implicitly knows which projects are available already, and it also gives it a boost in using opensrc proactively without me asking.
My only issue is the file is pretty context inefficient atm. Could be significantly improved with either a "derived" or just more compacted format. Example:
612 tokens in Claude Opus 4.6:
{
"updatedAt": "2026-02-17T02:49:53.178Z",
"packages": [
{
"name": "zod",
"version": "4.3.5",
"registry": "npm",
"path": "repos/github.com/colinhacks/zod",
"fetchedAt": "2026-01-12T01:38:55.980Z"
},
{
"name": "release-it",
"version": "19.2.4",
"registry": "npm",
"path": "repos/github.com/release-it/release-it",
"fetchedAt": "2026-02-05T22:15:56.222Z"
},
{
"name": "@release-it/bumper",
"version": "7.0.5",
"registry": "npm",
"path": "repos/github.com/release-it/bumper",
"fetchedAt": "2026-02-05T22:15:58.211Z"
},
{
"name": "tsdown",
"version": "0.20.3",
"registry": "npm",
"path": "repos/github.com/rolldown/tsdown",
"fetchedAt": "2026-02-10T17:55:23.209Z"
},
{
"name": "@opentelemetry/exporter-trace-otlp-http",
"version": "0.211.0",
"registry": "npm",
"path": "repos/github.com/open-telemetry/opentelemetry-js",
"fetchedAt": "2026-02-12T17:25:06.685Z"
},
{
"name": "kysely",
"version": "0.28.11",
"registry": "npm",
"path": "repos/github.com/kysely-org/kysely",
"fetchedAt": "2026-02-13T20:40:59.992Z"
},
{
"name": "tsx",
"version": "4.21.0",
"registry": "npm",
"path": "repos/github.com/privatenumber/tsx",
"fetchedAt": "2026-02-17T02:49:53.178Z"
}
]
}
233 tokens sources.yaml, using yaml + purls:
updated: 2026-02-17
packages:
pkg:npm/zod@4.3.5: repos/github.com/colinhacks/zod
pkg:npm/release-it@19.2.4: repos/github.com/release-it/release-it
"pkg:npm/@release-it/bumper@7.0.5": repos/github.com/release-it/bumper
pkg:npm/tsdown@0.20.3: repos/github.com/rolldown/tsdown
"pkg:npm/@opentelemetry/exporter-trace-otlp-http@0.211.0": repos/github.com/open-telemetry/opentelemetry-js
pkg:npm/kysely@0.28.11: repos/github.com/kysely-org/kysely
pkg:npm/tsx@4.21.0: repos/github.com/privatenumber/tsx
could even be a derived txt which is more loose in favor of conciseness (without losing info the agent cares about).
197 tokens, loose "purl-like" sources.txt:
npm/zod@4.3.5: repos/github.com/colinhacks/zod
npm/release-it@19.2.4: repos/github.com/release-it/release-it
npm/@release-it/bumper@7.0.5: repos/github.com/release-it/bumper
npm/tsdown@0.20.3: repos/github.com/rolldown/tsdown
npm/@opentelemetry/exporter-trace-otlp-http@0.211.0: repos/github.com/open-telemetry/opentelemetry-js
npm/kysely@0.28.11: repos/github.com/kysely-org/kysely
npm/tsx@4.21.0: repos/github.com/privatenumber/tsx
a bit inspired by the vercel blog https://vercel.com/blog/agents-md-outperforms-skills-in-our-agent-evals#addressing-the-context-bloat-concern :)
I like including
sources.jsonin the @ in my claude.md, because it means the model implicitly knows which projects are available already, and it also gives it a boost in using opensrc proactively without me asking.My only issue is the file is pretty context inefficient atm. Could be significantly improved with either a "derived" or just more compacted format. Example:
612 tokens in Claude Opus 4.6:
{ "updatedAt": "2026-02-17T02:49:53.178Z", "packages": [ { "name": "zod", "version": "4.3.5", "registry": "npm", "path": "repos/github.com/colinhacks/zod", "fetchedAt": "2026-01-12T01:38:55.980Z" }, { "name": "release-it", "version": "19.2.4", "registry": "npm", "path": "repos/github.com/release-it/release-it", "fetchedAt": "2026-02-05T22:15:56.222Z" }, { "name": "@release-it/bumper", "version": "7.0.5", "registry": "npm", "path": "repos/github.com/release-it/bumper", "fetchedAt": "2026-02-05T22:15:58.211Z" }, { "name": "tsdown", "version": "0.20.3", "registry": "npm", "path": "repos/github.com/rolldown/tsdown", "fetchedAt": "2026-02-10T17:55:23.209Z" }, { "name": "@opentelemetry/exporter-trace-otlp-http", "version": "0.211.0", "registry": "npm", "path": "repos/github.com/open-telemetry/opentelemetry-js", "fetchedAt": "2026-02-12T17:25:06.685Z" }, { "name": "kysely", "version": "0.28.11", "registry": "npm", "path": "repos/github.com/kysely-org/kysely", "fetchedAt": "2026-02-13T20:40:59.992Z" }, { "name": "tsx", "version": "4.21.0", "registry": "npm", "path": "repos/github.com/privatenumber/tsx", "fetchedAt": "2026-02-17T02:49:53.178Z" } ] }233 tokens
sources.yaml, using yaml +purls:could even be a derived txt which is more loose in favor of conciseness (without losing info the agent cares about).
197 tokens, loose "purl-like"
sources.txt:a bit inspired by the vercel blog https://vercel.com/blog/agents-md-outperforms-skills-in-our-agent-evals#addressing-the-context-bloat-concern :)