Skills

Verify Artifact

Prove that the file you are about to send, publish, or hand off IS the thing you mean, ...

Install

npx skills add pedrohcgs/claude-code-my-workflow --skill verify-artifact -g -a claude-code -y
Category
Documents
Updated
1mo ago
License
MIT
Context cost
Lightabout 1,064 tokens
Runs scripts
No, instructions only

What it does

Prove that the file you are about to send, publish, or hand off IS the thing you mean, before it leaves your hands. Rebuild from source, check integrity, diff the derived artifact against its source, and require the recipient to echo what they received. Use before sending a paper/PDF for review, shipping a release or replication package, handing files to a coauthor or collaborator, uploading anything to an external reviewer or model, or publishing. Prevents an entire review/QA cycle from being spent on defects that exist only in the artifact, not in the work.

Verify the artifact before it leaves

A review is only as good as the thing reviewed. If the artifact is corrupt, truncated, stale, or silently renumbered, a competent reviewer will return confident findings about defects that do not exist in your work, and you will spend a cycle chasing them. This is cheap to prevent and expensive to miss.

Rule: never send a derived artifact you have not diffed against its source.

1. Rebuild from source, in one shell invocation

Never send yesterday's build. Rebuild, then copy to the send location in the same command, so nothing can change underneath you.

Cloud-synced folders (Dropbox/iCloud/OneDrive) dehydrate files: a PDF can become 0 bytes or a partial copy between building and reading it. Symptoms: Syntax Error: Couldn't find trailer dictionary, a 70 KB file that should be 700 KB. Build-tool "up to date" messages are not evidence the file is intact, the tool checks timestamps, not content. Always stage to a local (non-synced) directory and verify there.

2. Integrity checks (mechanical, fast, non-negotiable)

  • Size and structure: byte size in the expected range; page/record/row count as expected.
  • It parses: open it with a real reader (pdfinfo, pdftotext, a JSON/CSV parser, unzip -t). A file that exists is not a file that works.
  • Sample the content: first and last page/record actually contain what you expect, truncation shows up at the end.
  • Unresolved markers: for documents, count ??, [cite], TODO, XXX, \ref{ leftovers, "Chapter ??"; for code/data, NaNs, empty cells, placeholder values.

3. Diff the derived artifact against its source

This is the step people skip and the one that pays. If you produced the artifact by transforming, excerpting, compressing, or subsetting, then enumerate what could have been lost and check it:

Read the whole SKILL.md on GitHub

More in Documents