vimalinx/bio-agent / .claude/skills/esl-selectn
esl-selectn
VerifiedUse when reservoir-sampling a fixed number of random lines from a large text file or stream without loading the whole file.
esl-selectn
Quick Start
- Command:
esl-selectn [-options] <n> <file> - Local executable:
/home/vimalinx/miniforge3/envs/bio/bin/esl-selectn - Extended help: See
references/help.md
When To Use This Tool
- Use
esl-selectnwhen the thing you want to sample is one physical line per record. - It is useful for downsampling huge ID lists, score tables, one-record-per-line exports, or stdin streams in a single pass.
- Reach for
--seedwhen you need the same sampled subset on repeated runs.
Common Patterns
# Sample 100 random lines from a text file
esl-selectn 100 all-records.txt > sample.txt
# Reproducible sampling with a fixed seed
esl-selectn --seed 42 500 ids.txt > ids.sample.txt
# Sample directly from a stream
cat metrics.tsv | esl-selectn 1000 - > metrics.sample.tsv
Recommended Workflow
- Make sure each logical record you care about is represented by exactly one line.
- Choose the sample size
nand whether you need reproducibility. - Run
esl-selectnon the file or stream, redirecting stdout to the sampled output. - Validate the sampled line count and spot-check that the input format survived intact.
Guardrails
- This tool samples lines, not FASTA, FASTQ, or Stockholm records. Multi-line biological records must be flattened or sampled by another method first.
- The implementation is single-pass reservoir sampling, so memory scales with
n, not with full file size. -hworks;--helpand--versionare rejected by the local executable.filemay be-to read from stdin.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack." | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |
| ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read. | Stars: 192k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report. | Stars: 192k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt. | Stars: 192k | Updated | Claude CodeCodex | Verified | Install |