name: izkf-pack description: Use when working in the izkf_pack repository to inspect, render, run, collect, test, or modify Linkar genomics templates and their downstream analysis summary/export behavior. Covers pack structure, common template workflows, runtime/output conventions, and repo-specific gotchas.
izkf_pack
This skill is for agent work inside the izkf_pack repository.
Use it when the task involves:
- editing or reviewing templates in
templates/ - updating binding logic in
linkar_pack.yamlorfunctions/ - helping a user render, run, collect, or inspect Linkar template outputs
- debugging project history,
.linkar/runs,project.yaml, or exported reports - improving
summary,export, ornfcore_*template behavior
Do not load the whole repository into context. Read only the files needed for the current task.
Repository Map
templates/<template_id>/Template contract, runtime files, tests, and template-local docs.functions/Binding functions used bylinkar_pack.yaml.linkar_pack.yamlDefault parameter bindings for selected templates.README.mdHuman-facing pack usage.TEMPLATE_AUTHORING_FOR_AGENTS.mdTemplate authoring checklist and conventions. Read this before adding or restructuring templates.
Core Linkar Workflow
Default user workflow:
linkar render <template>to inspect or edit the rendered bundle.bash run.shinside the rendered directory when the template is render-first.linkar collect <outdir>to record outputs.linkar run <template>for one-shot execution when inspection is not needed.
Inside an active Linkar project:
project.yamlrecords template history..linkar/runs/stores per-run snapshots and runtime context.- repeated renders or runs can append history even when the visible outdir stays the same.
Follow the repository README usage patterns unless the user explicitly wants a different flow:
- start from a processed sequencing run or project directory
- render first when the user wants to inspect generated files
- run
bash run.shin the rendered directory for render-first templates - run
linkar collect <outdir>after manual execution or edits - use
linkar run <template>for one-shot execution when inspection is not needed
When the task involves a new project, prefer the README pattern:
- demultiplex first
linkar project init --adopt ...after processed outputs exist- run downstream templates from inside the project directory
Important Repo Conventions
- Always prefix shell commands with
rtk. - Use
rgfor searching. - Use
apply_patchfor file edits. - Do not overwrite unrelated user edits.
- Commit each logical fix separately when making repo changes.
- Keep README paths GitHub-friendly; do not write workstation-specific paths in docs.
- Prefer the examples and naming patterns from
README.mdwhen drafting commands for users.
Start With README Practice
Before suggesting commands, check whether the root README.md already defines the expected usage pattern.
Important README-backed practices:
- install the pack globally with
linkar config pack add ... - configure author defaults with
linkar config author set ... - adopt processed runs into a project before downstream analysis
- use
linkar project viewandlinkar project runsfor orientation - use
linkar inspect RUN_INSTANCE_IDwhen the user wants run details - use
linkar collect ./run_directoryafter manual execution of rendered bundles
Do not invent a different house style for commands when the README already shows the preferred flow.
Template Design Rules
Follow TEMPLATE_AUTHORING_FOR_AGENTS.md for new templates and major refactors.
Important local conventions:
- Prefer
run.pyonce logic becomes nontrivial. - Keep
run.shthin and human-friendly. - For command-wrapper templates, prefer:
run.pyresolves parameters -> writes exact editablerun.sh-> executes it. - Record stable outputs in
linkar_template.yamlso downstream templates can reuse them. - Add or update
test.pywhenever runtime behavior changes.
High-Value Templates
demultiplex
- Starts from raw sequencing run folders.
- Produces FASTQ, QC, and MultiQC outputs.
- Often seeds downstream project adoption.
- README-backed pattern:
render in a processed runs directory, execute
bash run.sh, thenlinkar collect.
nfcore_3mrnaseq
- Wraps
nf-core/rnaseqfor facility 3' mRNA-seq usage. - Current repo preference:
rendered
run.shshould show the exact multiline Nextflow command clearly. umiandspikeinsupport facility shorthands liketrue, but analysis summary text should reflect the actual rendered command.- Prefer relative paths in rendered commands where possible.
- Default bindings in
linkar_pack.yamlresolvesamplesheet,genome,umi,spikein,max_cpus, andmax_memory. - README-backed practice for split batches:
users may render multiple
nfcore_3mrnaseqoutdirs and manually adjust the generatedsamplesheet.csv.
nfcore_methylseq
- Similar class of template to
nfcore_3mrnaseq. - Good candidate for the same
run.py -> generated run.shpattern.
dgea
- Editable downstream analysis workspace.
- Uses quantified RNA-seq outputs and generates HTML reports.
- GO / GSEA references should match the actual package used by the template.
- If multiple upstream nf-core runs exist, prefer explicit
--salmon-dirand--samplesheetvalues.
ercc
- Spike-in QC report template.
- Exported reports should focus on user-facing QC outputs, not low-value runtime metadata links unless explicitly wanted.
summary
- Generates
summary_long.md,summary_short.md, citations, and prompt/response artifacts. - Treat it as a render-first visible workspace, typically
./summary. - LLM polishing is enabled by default.
- Publication-facing wording matters more than internal template trivia.
- For nf-core sections, UMI, genome, spike-in, and key parameters should come from the rendered or recorded command when available, not only from Agendo metadata.
summary_short.mdshould be a clean condensation of the long version, not an unrelated summary.- README-backed practice:
keep LLM secrets in the environment, not in
project.yaml, and uselinkar run summary --outdir ./summary --refreshfor reruns.
export
- Builds
export_job_spec.jsonand submits export jobs. - If
export_job_spec.jsonalready exists, current logic can reuse it instead of rebuilding. - When export output looks stale, inspect the existing spec before changing mappings.
report_linksin the spec come fromtemplates/export/export_mapping.table.yaml.- README-backed practice:
prefer
linkar render export, inspectresults/export_job_spec.json, then runbash run.shwhen the user wants review before submission.
Project History And .linkar/runs
Understand the distinction:
- visible rendered bundle: the current working directory such as
summary/ornfcore_bile_duct/ - history snapshot:
.linkar/runs/<instance_id>/ - project registry:
project.yaml
Useful implications:
- one visible outdir does not imply one history entry
--refreshrerenders the visible bundle before execution; it does not mean “collapse history”- templates may rely on
history_pathwhen reconstructing prior runs
Do not casually delete .linkar/runs or old project.yaml entries unless the user explicitly wants to drop provenance.
Methods And Publication Style
When editing analysis summary generation:
- prefer publication-ready scientific prose
- remove authoring chatter, internal implementation notes, and facility-internal wording unless scientifically relevant
- use lists for grouped settings instead of dense parameter sentences
- include references and citations only when they correspond to real tools or methods in use
- keep
summary_long.mddetailed but tidy - keep
summary_short.mdreadable in manuscript style, ideally with inline numbered citations
If the user asks for journal style, align with the requested journal's conventions, but stay grounded in recorded project provenance.
Export Debugging Checklist
When exported reports do not match the latest mapping:
- inspect
templates/export/export_mapping.table.yaml - inspect
export/results/export_job_spec.json - confirm whether the builder reused an existing spec
- regenerate the spec before assuming the mapping change failed
When the export summary looks noisy:
- prefer counted template summaries over raw repeated ids
- remember that export entries come from the mapping/spec, not directly from the number of project history entries
Useful Files To Inspect
Depending on the task, start with:
project.yaml.linkar/meta.json.linkar/runtime.json.linkar/runs/<instance_id>/results/runtime_command.jsonresults/software_versions.json- template
test.py - template
README.md
For analysis summary/export work, also inspect:
templates/summary/summary_catalog.yamltemplates/export/export_mapping.table.yaml
Validation
After template changes, run the smallest relevant verification:
- template-local
test.py - targeted render/run dry-run checks when safe
- YAML validation for
linkar_template.yamledits - CLI help checks when Linkar core behavior is uncertain
If a change affects docs and runtime behavior, update both.
Output Style For Agents
When helping users with izkf_pack:
- explain whether behavior comes from the visible rendered bundle, the recorded runtime command, or project history
- distinguish current files from stale cached/exported artifacts
- prefer concrete file references over abstract descriptions
- avoid guessing how Linkar core behaves when local evidence is missing; inspect help text or generated files first