Read committed source and answer with Workers AI.
const release = await imprint.imprint('HEAD');
const repo = await imprint.open(release.commit);
await repo.ask('Where is authentication implemented?');Repository intelligence / 0.0.1
Turn a Git commit into repository context an LLM can use—and prove exactly which source it learned.
import { Imprint, WorkersAiProvider } from 'imprint';
const imprint = new Imprint({
directory: './repo',
provider: new WorkersAiProvider({ accountId, apiToken }),
});
const repo = await imprint.open('abc123');
await repo.ask('How do sessions work?');IMP–001
COMMIT → CONTEXT → INFERENCE
01 / What ships
The included check changes an API, imprints both commits, promotes the new release, then rolls back. Each release remains bound to its own source.
$ bun run prove
old a9c49d7 ✓ knows createSession
next 591f70d ✓ knows openSession
diff session.ts changed
rollback ✓ exact old release active 02 / Use it
Each example adds one operation. The release remains tied to the commit selected in the first line.
Read committed source and answer with Workers AI.
const release = await imprint.imprint('HEAD');
const repo = await imprint.open(release.commit);
await repo.ask('Where is authentication implemented?');See which committed files changed between releases.
await imprint.imprint('HEAD~1');
await imprint.imprint('HEAD');
const diff = await imprint.diff('HEAD~1', 'HEAD');Move the local active pointer between verified releases.
await imprint.promote('HEAD');
await imprint.rollback('HEAD~1');
const active = await imprint.open();bun add github:acoyfellow/imprint03 / System
The current release stores selected source from one commit and sends it to Workers AI. The release records which files and digests produced the answer.
Resolve immutable source and parents.
Select committed source and build bounded context.
Record source and context digests.
Run inference against that exact release.