Docs
Core
vrk tok
corevrk tok counts the tokens in text (o200k_base by default). Use --check N to stop a pipeline when the input is over your context budget.
vrk prompt
corevrk prompt sends text to Claude or GPT and prints the reply. It can check the reply against a --schema and retry on a mismatch.
vrk chunk
corevrk chunk splits text into chunks that fit a token budget and writes each one as a JSONL record. It never splits inside a character.
Pipeline
vrk grab
pipelinevrk grab fetches a URL and returns clean markdown. Use --text for plain text or --raw for HTML. No HTML parsing script needed.
vrk pdf
pipelinevrk pdf extracts the text layer of a PDF as Markdown or plain text, or as one JSONL record per page. It does no OCR and needs no Python.
vrk sql
pipelinevrk sql runs SQL over CSV or JSONL files in an in-memory SQLite database. It supports joins, GROUP BY, and type inference. Output is CSV or JSONL.
vrk sse
pipelinevrk sse parses Server-Sent Events (text/event-stream) into JSONL records. Use --field to pull out one value, such as streamed LLM text.
vrk validate
pipelinevrk validate checks JSONL records against a flat key-to-type schema. With --strict it exits 1 on the first bad record, so bad data stops early.
vrk coax
pipelinevrk coax retries a command with fixed or exponential backoff and replays the same stdin on every attempt. Use it for flaky API calls.
vrk kv
pipelinevrk kv is a persistent key-value store for shell pipelines. It uses SQLite and supports namespaces, TTL, and atomic counters.
vrk mask
pipelinevrk mask redacts secrets such as API keys, Bearer tokens, and high-entropy strings from text. It reads line by line.
vrk throttle
pipelinevrk throttle paces the lines in a pipe to a fixed rate, so LLM batch jobs stay inside API rate limits. Set the rate with --rate N/s or N/m.
Utilities
vrk jwtvrk jwt decodes a JWT on your machine, prints its claims, and checks expiry with --expired. It does not verify the signature.
vrk epochvrk epoch converts between Unix timestamps and ISO 8601 dates. It also accepts relative times such as +3d or -1h, on macOS and Linux.
vrk uuidvrk uuid generates v4 (random) or v7 (time-ordered) UUIDs from the command line, with the same output on macOS and Linux. Use --count for a batch.
vrk basevrk base encodes and decodes base64, base64url, hex, and base32 from the command line. It gives the same output on macOS and Linux.
vrk digestvrk digest hashes text or files with SHA-256, MD5, or SHA-512. Use --hmac to sign, --verify to check, and --compare to match files.
vrk plainvrk plain removes markdown syntax and keeps the prose. Use it to cut tokens before you send text to an LLM or count it with vrk tok.
vrk linksvrk links extracts every hyperlink from markdown, HTML, or plain text. It writes one JSONL record per link with text, URL, and line number.
vrk recasevrk recase converts text between naming conventions: snake_case, camelCase, kebab-case, PascalCase, and Title Case. Pick one with --to.
vrk slugvrk slug turns any text into a URL-safe, filename-safe slug. It folds Latin text to ASCII, accepts custom separators, and limits length.
vrk monikervrk moniker generates memorable adjective-noun names for run IDs, job labels, and temp dirs. Use --seed for repeatable output.
vrk pctvrk pct percent-encodes and decodes text per RFC 3986. Use --form for HTML form encoding, where spaces become +, and --decode to reverse it.
vrk jsonlvrk jsonl converts a JSON array to JSONL (one object per line) and back with --collect. It streams, so large files do not fill memory.
vrk sipvrk sip samples lines from stdin. Take the first N, a reservoir sample, every Nth line, or a random percentage, on input of any size.
vrk urlinfovrk urlinfo parses a URL into scheme, host, port, path, query, and fragment as JSON. Use --field to print one component.
vrk emitvrk emit turns plain text lines into JSONL log records with timestamps, levels, and tags. Pipe the output of any command through it.
vrk assertvrk assert checks a condition on pipeline data and exits 1 if it fails. Use a jq expression, --contains, or --matches to stop bad data early.