opencode-skills-collection 4.1.15 → 4.1.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +0 -1
- package/bundled-skills/.antigravity-install-manifest.json +1 -214
- package/bundled-skills/advanced-evaluation/SKILL.md +44 -21
- package/bundled-skills/ai-sre-incident-response/SKILL.md +4 -5
- package/bundled-skills/antigravity-maintainer-batch-release/SKILL.md +13 -77
- package/bundled-skills/api-integration/SKILL.md +22 -6
- package/bundled-skills/api-rate-limit-handler/SKILL.md +27 -34
- package/bundled-skills/awareness-stage-mapper/SKILL.md +1 -1
- package/bundled-skills/brand-perception-psychologist/SKILL.md +1 -1
- package/bundled-skills/content-strategy/SKILL.md +1 -1
- package/bundled-skills/content-strategy/references/headless-cms.md +3 -5
- package/bundled-skills/copywriting-psychologist/SKILL.md +1 -1
- package/bundled-skills/customer-psychographic-profiler/SKILL.md +1 -1
- package/bundled-skills/data-storytelling/SKILL.md +2 -4
- package/bundled-skills/deprecation-and-migration/SKILL.md +1 -3
- package/bundled-skills/emotional-arc-designer/SKILL.md +1 -1
- package/bundled-skills/glasser/SKILL.md +1 -1
- package/bundled-skills/headline-psychologist/SKILL.md +1 -1
- package/bundled-skills/identity-mirror/SKILL.md +1 -1
- package/bundled-skills/jobs-to-be-done-analyst/SKILL.md +1 -1
- package/bundled-skills/liuguang-banlan-ui/SKILL.md +18 -22
- package/bundled-skills/liuguang-banlan-ui/assets/starter/launcher.css +2 -2
- package/bundled-skills/liuguang-banlan-ui/assets/starter/obsidian/index.html +4 -5
- package/bundled-skills/liuguang-banlan-ui/assets/starter/obsidian/theme-config.js +10 -3
- package/bundled-skills/liuguang-banlan-ui/assets/starter/obsidian/theme.css +62 -48
- package/bundled-skills/liuguang-banlan-ui/assets/starter/opal/index.html +4 -5
- package/bundled-skills/liuguang-banlan-ui/assets/starter/opal/theme-config.js +35 -27
- package/bundled-skills/liuguang-banlan-ui/assets/starter/opal/theme.css +62 -48
- package/bundled-skills/liuguang-banlan-ui/assets/starter/shared/spectral-field.js +148 -135
- package/bundled-skills/liuguang-banlan-ui/references/style-contract.md +7 -26
- package/bundled-skills/liuguang-banlan-ui/references/verification.md +7 -19
- package/bundled-skills/liuguang-banlan-ui/scripts/measure_preview.py +47 -78
- package/bundled-skills/liuguang-banlan-ui/scripts/validate_manifest.py +3 -34
- package/bundled-skills/loki-mode/examples/todo-app-generated/backend/package-lock.json +12 -16
- package/bundled-skills/loki-mode/examples/todo-app-generated/backend/package.json +2 -4
- package/bundled-skills/loki-mode/examples/todo-app-generated/frontend/package-lock.json +15 -15
- package/bundled-skills/loki-mode/examples/todo-app-generated/frontend/package.json +2 -3
- package/bundled-skills/loss-aversion-designer/SKILL.md +1 -1
- package/bundled-skills/objection-preemptor/SKILL.md +1 -1
- package/bundled-skills/on-call-handoff-patterns/SKILL.md +4 -6
- package/bundled-skills/onboarding-cro/SKILL.md +2 -6
- package/bundled-skills/onboarding-psychologist/SKILL.md +1 -1
- package/bundled-skills/parallel-search-mcp/SKILL.md +0 -12
- package/bundled-skills/pitch-psychologist/SKILL.md +1 -1
- package/bundled-skills/price-psychology-strategist/SKILL.md +1 -1
- package/bundled-skills/python-testing-patterns/resources/implementation-playbook.md +2 -6
- package/bundled-skills/riffkit/SKILL.md +13 -22
- package/bundled-skills/scarcity-urgency-psychologist/SKILL.md +1 -1
- package/bundled-skills/seo-content-refresher/SKILL.md +4 -8
- package/bundled-skills/sequence-psychologist/SKILL.md +1 -1
- package/bundled-skills/social-proof-architect/SKILL.md +1 -1
- package/bundled-skills/subject-line-psychologist/SKILL.md +1 -1
- package/bundled-skills/system-prompt-lookup/SKILL.md +1 -1
- package/bundled-skills/telegram/assets/boilerplate/nodejs/package-lock.json +12 -16
- package/bundled-skills/telegram/assets/boilerplate/nodejs/package.json +2 -4
- package/bundled-skills/testing-patterns/SKILL.md +3 -2
- package/bundled-skills/trust-calibrator/SKILL.md +1 -1
- package/bundled-skills/typescript-expert/scripts/ts_diagnostic.py +19 -40
- package/bundled-skills/usage-based-pricing/SKILL.md +1 -3
- package/bundled-skills/usage-based-pricing/references/detailed-guide.md +9 -11
- package/bundled-skills/ux-persuasion-engineer/SKILL.md +1 -1
- package/bundled-skills/visual-emotion-engineer/SKILL.md +1 -1
- package/bundled-skills/waf-setup/SKILL.md +1 -1
- package/bundled-skills/wcag-audit-patterns/resources/implementation-playbook.md +8 -12
- package/bundled-skills/whatsapp-cloud-api/assets/boilerplate/nodejs/package-lock.json +12 -16
- package/bundled-skills/whatsapp-cloud-api/assets/boilerplate/nodejs/package.json +2 -4
- package/bundled-skills/youtube-summarizer/SKILL.md +3 -3
- package/package.json +1 -1
- package/skills_index.json +8846 -883
- package/bundled-skills/360-feedback-system/SKILL.md +0 -481
- package/bundled-skills/aas-compose-stack/SKILL.md +0 -39
- package/bundled-skills/aas-discover/SKILL.md +0 -35
- package/bundled-skills/aas-review-stack/SKILL.md +0 -37
- package/bundled-skills/access-matrix/SKILL.md +0 -338
- package/bundled-skills/accounting-audit-system-builder/SKILL.md +0 -302
- package/bundled-skills/accounting-audit-system-builder/references/catalog.md +0 -114
- package/bundled-skills/accounting-software-selection/SKILL.md +0 -427
- package/bundled-skills/accounting-software-selection/references/build-artifacts.md +0 -362
- package/bundled-skills/accounting-software-selection/references/common-pitfalls.md +0 -44
- package/bundled-skills/accounting-software-selection/references/field-reference.md +0 -93
- package/bundled-skills/accounting-software-selection/references/select-options.md +0 -202
- package/bundled-skills/admin-access-register/SKILL.md +0 -381
- package/bundled-skills/advanced-analytics-dashboard/SKILL.md +0 -318
- package/bundled-skills/agent-reels/SKILL.md +0 -107
- package/bundled-skills/ai-agent-evaluation-benchmarking/SKILL.md +0 -124
- package/bundled-skills/ai-agent-tool-routing/SKILL.md +0 -136
- package/bundled-skills/ai-code-generation-guardrails/SKILL.md +0 -142
- package/bundled-skills/ai-headshot-studio/SKILL.md +0 -267
- package/bundled-skills/ai-image-generation-studio/SKILL.md +0 -259
- package/bundled-skills/ai-logo-maker/SKILL.md +0 -259
- package/bundled-skills/ai-multilingual-dubbing/SKILL.md +0 -259
- package/bundled-skills/ai-photo-restyler/SKILL.md +0 -259
- package/bundled-skills/ai-podcast-voiceover/SKILL.md +0 -259
- package/bundled-skills/ai-prompt-regression-testing/SKILL.md +0 -130
- package/bundled-skills/alumni-re-hire-tracker/SKILL.md +0 -314
- package/bundled-skills/announcement-board/SKILL.md +0 -336
- package/bundled-skills/api-contract-testing/SKILL.md +0 -116
- package/bundled-skills/arcmira-find-quotes/SKILL.md +0 -89
- package/bundled-skills/arcmira-find-quotes/references/LICENSE.md +0 -202
- package/bundled-skills/ask-human-expert/SKILL.md +0 -141
- package/bundled-skills/assay/SKILL.md +0 -162
- package/bundled-skills/asset-it-management/SKILL.md +0 -407
- package/bundled-skills/attendance/SKILL.md +0 -331
- package/bundled-skills/audit-log/SKILL.md +0 -314
- package/bundled-skills/audit-preparation/SKILL.md +0 -416
- package/bundled-skills/axonx/SKILL.md +0 -374
- package/bundled-skills/axonx/references/LICENSE.md +0 -201
- package/bundled-skills/beatra/SKILL.md +0 -260
- package/bundled-skills/board-governance/SKILL.md +0 -360
- package/bundled-skills/brand-growth-system-builder/SKILL.md +0 -360
- package/bundled-skills/brand-kit-print-collateral/SKILL.md +0 -498
- package/bundled-skills/browser-extension-launch/SKILL.md +0 -102
- package/bundled-skills/browser-extension-launch/references/acceptance.md +0 -103
- package/bundled-skills/browser-extension-launch/references/complex-workflow.md +0 -46
- package/bundled-skills/browser-extension-launch/references/dependencies.md +0 -62
- package/bundled-skills/browser-extension-launch/references/development.md +0 -42
- package/bundled-skills/browser-extension-launch/references/efficient-delivery.md +0 -52
- package/bundled-skills/browser-extension-launch/references/host-compatibility.md +0 -58
- package/bundled-skills/browser-extension-launch/references/playwright-mcp.md +0 -102
- package/bundled-skills/browser-extension-launch/references/product-loop.md +0 -35
- package/bundled-skills/browser-extension-launch/references/publishing.md +0 -103
- package/bundled-skills/browser-extension-launch/references/required-skills.json +0 -153
- package/bundled-skills/browser-extension-launch/references/workflow.md +0 -71
- package/bundled-skills/buddy-program-manager/SKILL.md +0 -329
- package/bundled-skills/budget-cash-flow/SKILL.md +0 -352
- package/bundled-skills/build-ui/SKILL.md +0 -181
- package/bundled-skills/busabase/SKILL.md +0 -118
- package/bundled-skills/business-email-template/SKILL.md +0 -480
- package/bundled-skills/business-email-template/references/common-pitfalls.md +0 -30
- package/bundled-skills/business-website-setup/SKILL.md +0 -489
- package/bundled-skills/business-website-setup/references/common-pitfalls.md +0 -32
- package/bundled-skills/byagent/SKILL.md +0 -125
- package/bundled-skills/candidate-talent-pool/SKILL.md +0 -359
- package/bundled-skills/capacity-workload-planner/SKILL.md +0 -354
- package/bundled-skills/changelog-entry/SKILL.md +0 -141
- package/bundled-skills/clients-accounts/SKILL.md +0 -398
- package/bundled-skills/cline-pilot/README.md +0 -138
- package/bundled-skills/cline-pilot/SKILL.md +0 -301
- package/bundled-skills/cline-pilot/assets/global-memory-bank-prompt.en.md +0 -66
- package/bundled-skills/cline-pilot/assets/global-memory-bank-prompt.md +0 -56
- package/bundled-skills/cline-pilot/references/cold-start.md +0 -58
- package/bundled-skills/cline-pilot/references/decision-log.example.md +0 -9
- package/bundled-skills/cline-pilot/references/local-config.example.md +0 -26
- package/bundled-skills/cline-pilot/references/project-profiles.example.md +0 -10
- package/bundled-skills/cline-pilot/scripts/session_report.py +0 -151
- package/bundled-skills/cloudish/SKILL.md +0 -188
- package/bundled-skills/cockney/SKILL.md +0 -104
- package/bundled-skills/code-of-conduct/SKILL.md +0 -488
- package/bundled-skills/code-of-conduct/references/common-pitfalls.md +0 -31
- package/bundled-skills/company-email-accounts/SKILL.md +0 -404
- package/bundled-skills/competency-matrix/SKILL.md +0 -335
- package/bundled-skills/contract-document-renewal/SKILL.md +0 -396
- package/bundled-skills/course-upskilling-requests/SKILL.md +0 -354
- package/bundled-skills/court/SKILL.md +0 -141
- package/bundled-skills/court/references/jurors.json +0 -14
- package/bundled-skills/court/scripts/court.py +0 -348
- package/bundled-skills/credit-cycle-analysis/SKILL.md +0 -303
- package/bundled-skills/credit-cycle-analysis/references/best-practices.md +0 -35
- package/bundled-skills/credit-cycle-analysis/references/common-pitfalls.md +0 -5
- package/bundled-skills/credit-cycle-analysis/references/examples.md +0 -34
- package/bundled-skills/credit-cycle-analysis/references/field-reference.md +0 -47
- package/bundled-skills/credit-cycle-analysis/references/how-it-works.md +0 -494
- package/bundled-skills/credit-cycle-analysis/references/security-notes.md +0 -16
- package/bundled-skills/credit-cycle-analysis/references/select-options.md +0 -32
- package/bundled-skills/cross-chain-relayer-audit/SKILL.md +0 -136
- package/bundled-skills/csv-manual-export/SKILL.md +0 -499
- package/bundled-skills/csv-manual-export/references/common-pitfalls.md +0 -19
- package/bundled-skills/culture-retention/SKILL.md +0 -346
- package/bundled-skills/darkmoon-pentest/SKILL.md +0 -123
- package/bundled-skills/data-export-engine/SKILL.md +0 -308
- package/bundled-skills/data-privacy-controls/SKILL.md +0 -309
- package/bundled-skills/datacircle/SKILL.md +0 -141
- package/bundled-skills/day-book/SKILL.md +0 -499
- package/bundled-skills/day-book/references/best-practices.md +0 -32
- package/bundled-skills/day-book/references/common-pitfalls.md +0 -58
- package/bundled-skills/day-book/references/field-reference.md +0 -45
- package/bundled-skills/day-book/references/how-it-works.md +0 -7
- package/bundled-skills/day-book/references/related-skills.md +0 -18
- package/bundled-skills/day-book/references/relations.md +0 -14
- package/bundled-skills/day-book/references/reusable-prompt.md +0 -50
- package/bundled-skills/day-book/references/security-safety-notes.md +0 -19
- package/bundled-skills/day-book/references/select-options.md +0 -38
- package/bundled-skills/deep-research-framework/SKILL.md +0 -81
- package/bundled-skills/defi-yield-strategy-allocator/SKILL.md +0 -124
- package/bundled-skills/define-my-content-pillars/SKILL.md +0 -127
- package/bundled-skills/dei-dashboard/SKILL.md +0 -307
- package/bundled-skills/design-theme-guide/SKILL.md +0 -472
- package/bundled-skills/disciplinary-pip-tracker/SKILL.md +0 -345
- package/bundled-skills/document-management-system/SKILL.md +0 -328
- package/bundled-skills/draft-my-comments/SKILL.md +0 -132
- package/bundled-skills/dropthehassle-publish/SKILL.md +0 -151
- package/bundled-skills/ecommerce-listing-image-set/SKILL.md +0 -259
- package/bundled-skills/email-marketing-bible/SKILL.md +0 -413
- package/bundled-skills/employee-suggestion-hub/SKILL.md +0 -322
- package/bundled-skills/equibles/SKILL.md +0 -185
- package/bundled-skills/esop-equity-tracker/SKILL.md +0 -331
- package/bundled-skills/etsy-search-listings/SKILL.md +0 -122
- package/bundled-skills/etsy-shop-sales-history/SKILL.md +0 -119
- package/bundled-skills/events-activities/SKILL.md +0 -355
- package/bundled-skills/expense-accounting/SKILL.md +0 -496
- package/bundled-skills/expense-accounting/references/common-pitfalls.md +0 -41
- package/bundled-skills/expense-accounting/references/related-skills.md +0 -11
- package/bundled-skills/expense-accounting/references/reusable-prompt.md +0 -36
- package/bundled-skills/expense-management/SKILL.md +0 -351
- package/bundled-skills/five-axis-code-review/SKILL.md +0 -78
- package/bundled-skills/free-design-resources/SKILL.md +0 -480
- package/bundled-skills/free-design-resources/references/common-pitfalls.md +0 -44
- package/bundled-skills/free-design-resources/references/related-skills.md +0 -24
- package/bundled-skills/free-design-resources/references/reusable-prompt.md +0 -12
- package/bundled-skills/fxmacrodata/SKILL.md +0 -224
- package/bundled-skills/gamification-engine/SKILL.md +0 -307
- package/bundled-skills/gbp-local-seo-intent/SKILL.md +0 -466
- package/bundled-skills/gbp-local-seo-intent/references/best-practices.md +0 -41
- package/bundled-skills/gbp-local-seo-intent/references/common-pitfalls.md +0 -40
- package/bundled-skills/gbp-local-seo-intent/references/related-skills.md +0 -17
- package/bundled-skills/gbp-local-seo-intent/references/reusable-prompt.md +0 -11
- package/bundled-skills/gbp-local-seo-intent/references/security-safety-notes.md +0 -27
- package/bundled-skills/get-seen-in-replies/SKILL.md +0 -134
- package/bundled-skills/git-commit-message/SKILL.md +0 -76
- package/bundled-skills/health-wellness/SKILL.md +0 -334
- package/bundled-skills/idea-to-blueprint/LICENSE +0 -21
- package/bundled-skills/idea-to-blueprint/SKILL.md +0 -260
- package/bundled-skills/idea-to-blueprint/assets/AGENTS.md.template +0 -38
- package/bundled-skills/idea-to-blueprint/assets/CLAUDE.md.template +0 -38
- package/bundled-skills/idea-to-blueprint/assets/DECISIONS.md.template +0 -14
- package/bundled-skills/idea-to-blueprint/assets/PROGRESS.md.template +0 -47
- package/bundled-skills/idea-to-blueprint/assets/session-prompt.md +0 -23
- package/bundled-skills/idea-to-blueprint/references/architecture-decisions.md +0 -202
- package/bundled-skills/idea-to-blueprint/references/blueprint-template.md +0 -259
- package/bundled-skills/idea-to-blueprint/references/code-quality-and-review.md +0 -216
- package/bundled-skills/idea-to-blueprint/references/design-minimal.md +0 -96
- package/bundled-skills/idea-to-blueprint/references/edge-case-catalog.md +0 -239
- package/bundled-skills/idea-to-blueprint/references/intake-questions.md +0 -105
- package/bundled-skills/idea-to-blueprint/references/research-protocol.md +0 -196
- package/bundled-skills/idea-to-blueprint/references/session-protocol.md +0 -133
- package/bundled-skills/idea-to-blueprint/references/stories-ac-tests.md +0 -194
- package/bundled-skills/idea-to-blueprint/references/ux-writing-guide.md +0 -128
- package/bundled-skills/idea-to-blueprint/scripts/lint_blueprint.py +0 -460
- package/bundled-skills/intern-program/SKILL.md +0 -354
- package/bundled-skills/internal-communication/SKILL.md +0 -318
- package/bundled-skills/inventory-stock-reconciliation/SKILL.md +0 -470
- package/bundled-skills/inventory-stock-reconciliation/references/best-practices.md +0 -18
- package/bundled-skills/inventory-stock-reconciliation/references/common-pitfalls.md +0 -42
- package/bundled-skills/inventory-stock-reconciliation/references/related-skills.md +0 -13
- package/bundled-skills/inventory-stock-reconciliation/references/relations.md +0 -8
- package/bundled-skills/inventory-stock-reconciliation/references/reusable-prompt.md +0 -31
- package/bundled-skills/inventory-stock-reconciliation/references/security-safety-notes.md +0 -17
- package/bundled-skills/inventory-stock-reconciliation/references/select-options.md +0 -45
- package/bundled-skills/invoices-billing/SKILL.md +0 -385
- package/bundled-skills/invokely-statistics/SKILL.md +0 -124
- package/bundled-skills/invokely-statistics/references/LICENSE.md +0 -21
- package/bundled-skills/ios-screens/SKILL.md +0 -172
- package/bundled-skills/issue-grievance-tracker/SKILL.md +0 -400
- package/bundled-skills/jet-browser/SKILL.md +0 -155
- package/bundled-skills/json-schema-manual/SKILL.md +0 -309
- package/bundled-skills/json-schema-manual/references/best-practices.md +0 -9
- package/bundled-skills/json-schema-manual/references/common-pitfalls.md +0 -25
- package/bundled-skills/json-schema-manual/references/input-modules.md +0 -203
- package/bundled-skills/json-schema-manual/references/related-skills.md +0 -8
- package/bundled-skills/json-schema-manual/references/reusable-prompt.md +0 -10
- package/bundled-skills/json-schema-manual/references/security-safety-notes.md +0 -13
- package/bundled-skills/kernel-prompt/SKILL.md +0 -64
- package/bundled-skills/knowledge-base/SKILL.md +0 -318
- package/bundled-skills/kpi-tracker/SKILL.md +0 -345
- package/bundled-skills/learning-career-development/SKILL.md +0 -349
- package/bundled-skills/leave-management/SKILL.md +0 -341
- package/bundled-skills/legal-compliance-vault/SKILL.md +0 -324
- package/bundled-skills/linkdigest-social-link-reader/SKILL.md +0 -232
- package/bundled-skills/linktree-link-hub/SKILL.md +0 -453
- package/bundled-skills/liuguang-banlan-ui/scripts/serve_preview.py +0 -35
- package/bundled-skills/liuguang-banlan-ui/tests/test_measure_preview.py +0 -119
- package/bundled-skills/liuguang-banlan-ui/tests/test_serve_preview.py +0 -38
- package/bundled-skills/liuguang-banlan-ui/tests/test_validate_manifest.py +0 -73
- package/bundled-skills/lognorm/SKILL.md +0 -86
- package/bundled-skills/lognorm/references/playbooks.md +0 -76
- package/bundled-skills/logo-image-design/SKILL.md +0 -459
- package/bundled-skills/looot/SKILL.md +0 -188
- package/bundled-skills/mcd-secret-menu-lab/SKILL.md +0 -110
- package/bundled-skills/meeting-notes/SKILL.md +0 -80
- package/bundled-skills/mentorship-program/SKILL.md +0 -332
- package/bundled-skills/mirrord/SKILL.md +0 -90
- package/bundled-skills/monthly-closing-statements/SKILL.md +0 -488
- package/bundled-skills/monthly-closing-statements/references/related-skills.md +0 -17
- package/bundled-skills/monthly-closing-statements/references/reusable-prompt.md +0 -8
- package/bundled-skills/music-generation-studio/SKILL.md +0 -259
- package/bundled-skills/notification-reminder-hub/SKILL.md +0 -324
- package/bundled-skills/notion-manual-import/SKILL.md +0 -376
- package/bundled-skills/notion-manual-import/references/best-practices.md +0 -10
- package/bundled-skills/notion-manual-import/references/common-pitfalls.md +0 -26
- package/bundled-skills/notion-manual-import/references/input-modules.md +0 -203
- package/bundled-skills/notion-manual-import/references/related-skills.md +0 -7
- package/bundled-skills/notion-manual-import/references/reusable-prompt.md +0 -8
- package/bundled-skills/notion-manual-import/references/security-safety-notes.md +0 -15
- package/bundled-skills/observability-cloud-planning/SKILL.md +0 -487
- package/bundled-skills/observability-cloud-planning/references/common-pitfalls.md +0 -39
- package/bundled-skills/observability-cloud-planning/references/related-skills.md +0 -20
- package/bundled-skills/observability-cloud-planning/references/reusable-prompt.md +0 -12
- package/bundled-skills/observability-cloud-planning/references/security-safety-notes.md +0 -30
- package/bundled-skills/offboarding-exit/SKILL.md +0 -343
- package/bundled-skills/offer-appointment/SKILL.md +0 -351
- package/bundled-skills/okr-system/SKILL.md +0 -355
- package/bundled-skills/omentir-linkedin-outreach/SKILL.md +0 -96
- package/bundled-skills/onboarding-playbook/SKILL.md +0 -292
- package/bundled-skills/organization-design/SKILL.md +0 -324
- package/bundled-skills/party-ledger-reconciliation/SKILL.md +0 -411
- package/bundled-skills/payment-accounting/SKILL.md +0 -421
- package/bundled-skills/payments-received/SKILL.md +0 -315
- package/bundled-skills/payroll-finance/SKILL.md +0 -351
- package/bundled-skills/people-directory/SKILL.md +0 -459
- package/bundled-skills/performance-management/SKILL.md +0 -367
- package/bundled-skills/petty-cash-management/SKILL.md +0 -448
- package/bundled-skills/placecall/SKILL.md +0 -237
- package/bundled-skills/policy-acknowledgement/SKILL.md +0 -314
- package/bundled-skills/policy-library/SKILL.md +0 -327
- package/bundled-skills/poster-design-studio/SKILL.md +0 -259
- package/bundled-skills/pre-boarding/SKILL.md +0 -326
- package/bundled-skills/presentation-deck/SKILL.md +0 -491
- package/bundled-skills/presentation-deck/references/related-skills.md +0 -19
- package/bundled-skills/presentation-deck/references/reusable-prompt.md +0 -11
- package/bundled-skills/probation-tracker/SKILL.md +0 -347
- package/bundled-skills/product-photo-studio/SKILL.md +0 -259
- package/bundled-skills/project-based-performance/SKILL.md +0 -323
- package/bundled-skills/projects-work-management/SKILL.md +0 -368
- package/bundled-skills/promotion-upgrade-requests/SKILL.md +0 -377
- package/bundled-skills/purchase-accounting/SKILL.md +0 -414
- package/bundled-skills/qrx/SKILL.md +0 -131
- package/bundled-skills/qrx/references/prompt-guide.md +0 -30
- package/bundled-skills/qrx/references/rest-api.md +0 -40
- package/bundled-skills/receipt-accounting/SKILL.md +0 -424
- package/bundled-skills/recognition-rewards/SKILL.md +0 -324
- package/bundled-skills/recruitment-pipeline/SKILL.md +0 -399
- package/bundled-skills/remote-work-tracker/SKILL.md +0 -306
- package/bundled-skills/repo-foundation/SKILL.md +0 -166
- package/bundled-skills/repo-foundation/references/LICENSE.md +0 -21
- package/bundled-skills/repo-foundation/references/bootstrap.md +0 -63
- package/bundled-skills/repo-foundation/references/companion.md +0 -9
- package/bundled-skills/repo-foundation/references/continuity.md +0 -50
- package/bundled-skills/repo-foundation/references/evolution.md +0 -60
- package/bundled-skills/repo-foundation/references/migration-examples.md +0 -53
- package/bundled-skills/repo-foundation/references/shared-contracts.md +0 -48
- package/bundled-skills/repo-foundation/references/verification.md +0 -50
- package/bundled-skills/repo-native-refactor/SKILL.md +0 -225
- package/bundled-skills/repo-native-refactor/references/LICENSE.md +0 -21
- package/bundled-skills/repo-native-refactor/references/deterministic-tooling.md +0 -101
- package/bundled-skills/repo-native-refactor/references/error-reliability.md +0 -117
- package/bundled-skills/repo-native-refactor/references/finding-taxonomy.md +0 -181
- package/bundled-skills/repo-native-refactor/references/refactor-examples.md +0 -77
- package/bundled-skills/repo-native-refactor/references/repository-prose.md +0 -157
- package/bundled-skills/repo-native-refactor/references/repository-rehabilitation.md +0 -94
- package/bundled-skills/repo-native-refactor/references/semantic-risk.md +0 -187
- package/bundled-skills/repo-native-refactor/references/shared-contracts.md +0 -48
- package/bundled-skills/repo-native-refactor/references/testing-integrity.md +0 -103
- package/bundled-skills/reports-analytics/SKILL.md +0 -320
- package/bundled-skills/repurpose-into-a-post/SKILL.md +0 -134
- package/bundled-skills/reverse-engineer-anything/SKILL.md +0 -243
- package/bundled-skills/reverse-engineer-anything/references/android-applications.md +0 -34
- package/bundled-skills/reverse-engineer-anything/references/evidence-workflows.md +0 -40
- package/bundled-skills/reverse-engineer-anything/references/javascript-applications.md +0 -70
- package/bundled-skills/reverse-engineer-anything/references/native-and-artifacts.md +0 -146
- package/bundled-skills/reverse-engineer-anything/references/runtime-observation.md +0 -28
- package/bundled-skills/salary-benchmarking/SKILL.md +0 -318
- package/bundled-skills/salary-wage-accounting/SKILL.md +0 -412
- package/bundled-skills/sales-accounting/SKILL.md +0 -494
- package/bundled-skills/sales-accounting/references/common-pitfalls.md +0 -28
- package/bundled-skills/sales-accounting/references/related-skills.md +0 -13
- package/bundled-skills/sales-accounting/references/reusable-prompt.md +0 -8
- package/bundled-skills/same-idea-both-platforms/SKILL.md +0 -111
- package/bundled-skills/scarf-single-cell/SKILL.md +0 -326
- package/bundled-skills/scarf-single-cell/references/LICENSE.md +0 -29
- package/bundled-skills/scarf-single-cell/references/clustering-and-embedding.md +0 -270
- package/bundled-skills/scarf-single-cell/references/data-access.md +0 -269
- package/bundled-skills/scarf-single-cell/references/features-and-graphs.md +0 -279
- package/bundled-skills/scarf-single-cell/references/gene-blacklists.md +0 -182
- package/bundled-skills/scarf-single-cell/references/integration-and-comparisons.md +0 -295
- package/bundled-skills/scarf-single-cell/references/markers-and-annotation.md +0 -280
- package/bundled-skills/scarf-single-cell/references/performance-and-export.md +0 -291
- package/bundled-skills/scarf-single-cell/references/pipeline-runs-and-artifacts.md +0 -273
- package/bundled-skills/scarf-single-cell/references/plotting.md +0 -260
- package/bundled-skills/scarf-single-cell/references/quality-control.md +0 -290
- package/bundled-skills/seo-directory-backlinks/SKILL.md +0 -484
- package/bundled-skills/seo-directory-backlinks/references/common-pitfalls.md +0 -36
- package/bundled-skills/seo-directory-backlinks/references/related-skills.md +0 -15
- package/bundled-skills/seo-directory-backlinks/references/reusable-prompt.md +0 -11
- package/bundled-skills/session-handoff/SKILL.md +0 -112
- package/bundled-skills/shark/SKILL.md +0 -134
- package/bundled-skills/shark/references/investors.json +0 -12
- package/bundled-skills/shark/scripts/shark.py +0 -302
- package/bundled-skills/shipvela-publish/SKILL.md +0 -80
- package/bundled-skills/shipvela-publish/references/LICENSE.md +0 -21
- package/bundled-skills/since-cutoff/SKILL.md +0 -68
- package/bundled-skills/skeleton-first/SKILL.md +0 -163
- package/bundled-skills/skill-gap-analysis/SKILL.md +0 -338
- package/bundled-skills/smart-contract-formal-verification/SKILL.md +0 -136
- package/bundled-skills/smart-contract-upgrade-governance/SKILL.md +0 -130
- package/bundled-skills/social-media-setup/SKILL.md +0 -477
- package/bundled-skills/social-media-setup/references/common-pitfalls.md +0 -34
- package/bundled-skills/social-media-setup/references/related-skills.md +0 -19
- package/bundled-skills/social-media-setup/references/reusable-prompt.md +0 -11
- package/bundled-skills/social-media-setup/references/security-safety-notes.md +0 -27
- package/bundled-skills/sop-company-wiki/SKILL.md +0 -324
- package/bundled-skills/soroban-contract-audit/SKILL.md +0 -136
- package/bundled-skills/soroban-liquidity-pool/SKILL.md +0 -118
- package/bundled-skills/soroban-oracle-data-feed-audit/SKILL.md +0 -118
- package/bundled-skills/soroban-storage-ttl-lifecycle/SKILL.md +0 -118
- package/bundled-skills/soroban-token-minter/SKILL.md +0 -124
- package/bundled-skills/source-document-filing/SKILL.md +0 -368
- package/bundled-skills/spreadsheet-manual-build/SKILL.md +0 -493
- package/bundled-skills/spreadsheet-manual-build/references/best-practices.md +0 -9
- package/bundled-skills/spreadsheet-manual-build/references/common-pitfalls.md +0 -22
- package/bundled-skills/spreadsheet-manual-build/references/related-skills.md +0 -8
- package/bundled-skills/spreadsheet-manual-build/references/reusable-prompt.md +0 -9
- package/bundled-skills/spreadsheet-manual-build/references/security-safety-notes.md +0 -16
- package/bundled-skills/stakeholder-investor-reports/SKILL.md +0 -303
- package/bundled-skills/stellar-anchor-integration/SKILL.md +0 -136
- package/bundled-skills/stellar-asset-clawback-compliance/SKILL.md +0 -118
- package/bundled-skills/stellar-escrow-timelock/SKILL.md +0 -118
- package/bundled-skills/stellar-multisig-threshold-coordinator/SKILL.md +0 -112
- package/bundled-skills/suno-lyrics-to-song/SKILL.md +0 -259
- package/bundled-skills/supercov/SKILL.md +0 -119
- package/bundled-skills/talking-avatar-video/SKILL.md +0 -260
- package/bundled-skills/tastegate/SKILL.md +0 -129
- package/bundled-skills/tastegate/references/THIRD_PARTY_NOTICES.md +0 -25
- package/bundled-skills/tastegate/references/craft-floor.md +0 -53
- package/bundled-skills/tastegate/references/direction.md +0 -59
- package/bundled-skills/tastegate/references/impeccable-LICENSE-Apache-2.0.txt +0 -191
- package/bundled-skills/tastegate/references/taste-skill-LICENSE-MIT.txt +0 -21
- package/bundled-skills/tastegate/scripts/gate.py +0 -401
- package/bundled-skills/tax-register/SKILL.md +0 -363
- package/bundled-skills/tds-booking-payment/SKILL.md +0 -405
- package/bundled-skills/team-calendar/SKILL.md +0 -312
- package/bundled-skills/tech-writing-proofread/SKILL.md +0 -78
- package/bundled-skills/telegram-channel-ads/SKILL.md +0 -139
- package/bundled-skills/template-library/SKILL.md +0 -304
- package/bundled-skills/time-tracking/SKILL.md +0 -353
- package/bundled-skills/tokenleak/SKILL.md +0 -79
- package/bundled-skills/turn-this-into-a-thread/SKILL.md +0 -130
- package/bundled-skills/ui-from-screenshot/SKILL.md +0 -147
- package/bundled-skills/ui-states/SKILL.md +0 -149
- package/bundled-skills/url-to-markdown/SKILL.md +0 -74
- package/bundled-skills/uxkin-research/SKILL.md +0 -127
- package/bundled-skills/vendor-contractor-management/SKILL.md +0 -327
- package/bundled-skills/viral-video-teardown-remake/SKILL.md +0 -260
- package/bundled-skills/voice-cloning-studio/SKILL.md +0 -260
- package/bundled-skills/voiceover-narration-studio/SKILL.md +0 -259
- package/bundled-skills/web3-rate-limiting-circuit-breaker/SKILL.md +0 -130
- package/bundled-skills/web3-transaction-relayer-pool/SKILL.md +0 -124
- package/bundled-skills/what-could-break/SKILL.md +0 -128
- package/bundled-skills/what-could-break/references/LICENSE-pstack.txt +0 -21
- package/bundled-skills/why-did-this-post-flop/SKILL.md +0 -130
- package/bundled-skills/write-design-md/SKILL.md +0 -158
- package/bundled-skills/write-in-my-voice/SKILL.md +0 -140
- package/bundled-skills/zk-proof-verification-pipeline/SKILL.md +0 -124
|
@@ -1,273 +0,0 @@
|
|
|
1
|
-
# Pipeline runs and artifacts
|
|
2
|
-
|
|
3
|
-
Run the standard RNA recipe, reopen and audit runs, inspect and trace immutable artifacts, branch
|
|
4
|
-
from a run with exact refs, and record the analysis for handoff. Docs:
|
|
5
|
-
<https://scarf.readthedocs.io/en/latest/reference/api/pipeline.html>, <https://scarf.readthedocs.io/en/latest/reference/api/artifacts.html>,
|
|
6
|
-
<https://scarf.readthedocs.io/en/latest/concepts/provenance.html>, <https://scarf.readthedocs.io/en/latest/tutorials/reuse_and_tracing.html>,
|
|
7
|
-
<https://scarf.readthedocs.io/en/latest/analysis_with_agents.html>.
|
|
8
|
-
|
|
9
|
-
## When to use
|
|
10
|
-
|
|
11
|
-
- First pass on any RNA store: one `ds.pipeline.run(label=...)` gives QC filtering, HVGs, PCA,
|
|
12
|
-
graph, UMAP, Leiden candidates, Paris, doublet scores and markers as one durable record.
|
|
13
|
-
- Resuming work: open a run by label or id; inspect any result before consuming it.
|
|
14
|
-
- Alternatives outside the fixed recipe: take refs from a completed run and pass them on.
|
|
15
|
-
|
|
16
|
-
## Key concepts
|
|
17
|
-
|
|
18
|
-
- Every result is an immutable artifact addressed by an `ArtifactRef` (frozen dataclass):
|
|
19
|
-
`scope` (`"assay"` or `"datastore"`), `kind`, `artifact_id` (64 hex chars; there is no `.id`),
|
|
20
|
-
`assay` (`None` for datastore scope). Cell selections and metadata snapshots are datastore-scoped.
|
|
21
|
-
- Reuse is content-addressed: same operation, parameters and exact input refs returns the existing
|
|
22
|
-
complete artifact. Changing anything creates a new artifact; upstream ones are reused.
|
|
23
|
-
`invalidate_cache=True` on a granular method forces a fresh one.
|
|
24
|
-
- `ds.pipeline.run` writes artifacts plus a run record only. It never edits live `I` or adds
|
|
25
|
-
metadata columns, and needs `zarr_mode="r+"` (the default); a read-only store raises
|
|
26
|
-
`PermissionError`, though `open`, reports and plots still work.
|
|
27
|
-
- `PipelineRun` is a read-only `Mapping[str, ArtifactRef]` (`keys`, `items`, `values`, `get`,
|
|
28
|
-
`run["pca"]`) plus `run_id`, `label`, `status`, `recipe` (`"basic_rna_analysis"`), `assay`,
|
|
29
|
-
`started_at_ns`, `finished_at_ns`, `report()`, `cells`, `features`. Outputs and views work only
|
|
30
|
-
on `status == "completed"`; otherwise they raise `RuntimeError`.
|
|
31
|
-
- Labels are immutable. Only a completed run acquires its label. A completed label cannot be
|
|
32
|
-
reused (`ValueError` before any work). Failed and interrupted runs reserve nothing.
|
|
33
|
-
- There is no resume. A new run reuses every complete artifact from earlier attempts.
|
|
34
|
-
- `run.cells` and `run.features` are frozen views of captured fields only. Live columns such as
|
|
35
|
-
author labels are absent unless listed in `snapshot_columns` on the run.
|
|
36
|
-
|
|
37
|
-
## Recipes
|
|
38
|
-
|
|
39
|
-
### Run the baseline
|
|
40
|
-
|
|
41
|
-
Default outputs and their kinds: `input_cell_selection`, `analysis_cell_selection`
|
|
42
|
-
(`cell_selection`), `feature_universe`, `highly_variable_features` (`feature_selection`),
|
|
43
|
-
`cell_cycle`, `normalized`, `pca` (`reduction`), `ann_index`, `neighbors`, `connectivity_map`,
|
|
44
|
-
`embedding_initialization`, `umap` (`embedding`), `leiden_0.5` ... `leiden_1.25`
|
|
45
|
-
(`cluster_labels`), `paris` (`cluster_cut`), `cluster_selection`, `clusters` (the selected Leiden
|
|
46
|
-
ref itself, not a copy), `doublets` (`doublet_score`), `markers` (`marker_table`). Harmony adds
|
|
47
|
-
`harmony` after `pca`; disabled stages omit their keys. A fresh baseline took 22 s on local
|
|
48
|
-
counts, 10 s of it one-time compilation in the graph stage; a second run in the same process took
|
|
49
|
-
11 s (10x 5K PBMC docs dataset). On remote counts expect about a minute for a few thousand cells.
|
|
50
|
-
|
|
51
|
-
```python
|
|
52
|
-
import scarf
|
|
53
|
-
|
|
54
|
-
scarf.configure_output(level="WARNING", progress=False)
|
|
55
|
-
ds = scarf.DataStore("analysis.zarr", nthreads=4, min_features_per_cell=-1)
|
|
56
|
-
run = ds.pipeline.run(label="baseline")
|
|
57
|
-
list(run.keys())
|
|
58
|
-
run["clusters"] == run["leiden_0.5"] # True on the 10x 5K PBMC docs dataset
|
|
59
|
-
```
|
|
60
|
-
|
|
61
|
-
### Reopen, list and report runs
|
|
62
|
-
|
|
63
|
-
`open` needs exactly one of `label` or `run_id`; an unknown label raises `KeyError`. `list_runs`
|
|
64
|
-
is newest first, all statuses unless filtered, `limit=20` by default.
|
|
65
|
-
|
|
66
|
-
```python
|
|
67
|
-
run = ds.pipeline.open(label="baseline")
|
|
68
|
-
same = ds.pipeline.open(run_id=run.run_id)
|
|
69
|
-
ds.pipeline.list_runs(status="completed", limit=5)
|
|
70
|
-
report = run.report(format="dict") # keys: run, stages, summary
|
|
71
|
-
[(s["stage"], s["status"], s["metrics"]["wallSeconds"]) for s in report["stages"]]
|
|
72
|
-
report["run"]["config"] # resolved settings, including filtering method and params
|
|
73
|
-
len(report["summary"]["createdArtifacts"]), len(report["summary"]["reusedArtifacts"])
|
|
74
|
-
print(run.report(format="markdown")) # config, stage table, outputs, failure or interruption
|
|
75
|
-
```
|
|
76
|
-
|
|
77
|
-
### Read frozen fields
|
|
78
|
-
|
|
79
|
-
`run.cells.columns` here: `I, ids, names, s_score, g2m_score, cell_cycle_phase, umap_1, umap_2,
|
|
80
|
-
leiden_*, paris, clusters, doublet_score`, then any `snapshot_columns`; filter and Harmony columns
|
|
81
|
-
are not exposed. `run.features.columns`: `I, ids, names, highly_variable_features`. `fetch` returns
|
|
82
|
-
analysed rows; `fetch_all` aligns to every stored cell (3,847 and 5,025 on the 10x 5K PBMC docs
|
|
83
|
-
dataset, whose live `I` holds 3,948).
|
|
84
|
-
|
|
85
|
-
```python
|
|
86
|
-
df = run.cells.to_pandas_dataframe(["umap_1", "umap_2", "clusters"])
|
|
87
|
-
clusters = run.cells.fetch("clusters") # int labels starting at 1
|
|
88
|
-
analysed = run.cells.fetch_all("I") # boolean mask over every stored cell
|
|
89
|
-
n_hvgs = int(run.features.fetch_all("highly_variable_features").sum())
|
|
90
|
-
mito = ds.cells.fetch_all("RNA_percentMito")[analysed] # a filter column, aligned to run cells
|
|
91
|
-
```
|
|
92
|
-
|
|
93
|
-
### Configure a run
|
|
94
|
-
|
|
95
|
-
Shortcuts and `params` sections are mutually exclusive for the same setting. Validation errors
|
|
96
|
-
(unknown section, column collision, reused label, `leiden={}`) raise before any run record exists.
|
|
97
|
-
`leiden.selected` replaces the silhouette choice and skips `cluster_selection`.
|
|
98
|
-
|
|
99
|
-
```python
|
|
100
|
-
custom = ds.pipeline.run(label="leiden_custom", leiden={"partitions": [0.4, 0.8]})
|
|
101
|
-
pinned = ds.pipeline.run(
|
|
102
|
-
label="leiden_pinned",
|
|
103
|
-
params={"leiden": {"partitions": [0.5, 1.0], "selected": 1.0}},
|
|
104
|
-
umap=False, doublets=False, markers=False, cell_cycle=False, paris=False,
|
|
105
|
-
)
|
|
106
|
-
pinned["clusters"] == pinned["leiden_1.0"] # True; no cluster_selection key
|
|
107
|
-
labelled = ds.pipeline.run(label="with_labels", snapshot_columns=["cell_type"]) # full recompute
|
|
108
|
-
"cell_type" in labelled.cells.columns # True
|
|
109
|
-
```
|
|
110
|
-
|
|
111
|
-
`cell_type` stands for a label column you own; never snapshot held-out author labels.
|
|
112
|
-
|
|
113
|
-
### Handle failures and interruptions
|
|
114
|
-
|
|
115
|
-
A stage error raises `PipelineExecutionError` (`run_id`, `stage`, cause in `__cause__`). SIGTERM,
|
|
116
|
-
SIGINT, SIGHUP or `KeyboardInterrupt` stop at the next safe checkpoint (in testing, the running
|
|
117
|
-
stage finished and kept its artifact) and record `status="interrupted"`. Rerun with the same
|
|
118
|
-
label; completed artifacts are reused (interrupted during UMAP: rerun 10 s, 16 reused; 10x 5K
|
|
119
|
-
PBMC docs dataset). Run it as `timeout 1800 python job.py`; behind a wrapper such as `uv run`, put
|
|
120
|
-
`timeout` inside it (`uv run timeout 1800 python job.py`), because `timeout 1800 uv run ...` killed the run without the handler (performance-and-export.md).
|
|
121
|
-
|
|
122
|
-
```python
|
|
123
|
-
from scarf import PipelineExecutionError
|
|
124
|
-
|
|
125
|
-
try:
|
|
126
|
-
ds.pipeline.run(label="bad", params={"paris": {"min_cluster_size": -5}})
|
|
127
|
-
except PipelineExecutionError as error:
|
|
128
|
-
failed = ds.pipeline.open(run_id=error.run_id)
|
|
129
|
-
error.stage, failed.status, failed.report(format="dict")["run"]["error"]
|
|
130
|
-
interrupted = ds.pipeline.list_runs(status="interrupted")
|
|
131
|
-
```
|
|
132
|
-
|
|
133
|
-
A process killed mid-stage (SIGKILL, OOM, or a `timeout` outside a `uv run` wrapper) leaves a record
|
|
134
|
-
stuck at `status="running"` with `summary["uncleanIncomplete"]` true; it claimed no label, so a
|
|
135
|
-
rerun with the label works. Check the process, not the status. Not executed (needs a hard-killed
|
|
136
|
-
finalizer): if a process died after claiming its label, the label stays blocked. After confirming
|
|
137
|
-
the process is gone, call `ds.pipeline.abandon_label_claim(label=..., run_id=..., reason=...)`,
|
|
138
|
-
then rerun. It refuses completed owners and has no timeout heuristic.
|
|
139
|
-
|
|
140
|
-
### Inspect, load and find artifacts
|
|
141
|
-
|
|
142
|
-
```python
|
|
143
|
-
status = ds.inspect_artifact(run["pca"])
|
|
144
|
-
status.exists, status.complete, status.path, status.operation # ..., "run_pca"
|
|
145
|
-
status.parameters # {'dims': 21, 'feat_scaling': True}
|
|
146
|
-
status.inputs # serialized refs: normalized, feature_scaling, pca_cell_selection
|
|
147
|
-
status.input_ref("normalized") == run["normalized"] # True
|
|
148
|
-
status.execution_options, status.created_at_ns, status.scarf_version
|
|
149
|
-
group = ds.load_artifact(run["pca"]) # zarr group: data, loadings, center
|
|
150
|
-
group["data"].shape # (analysed cells, 21)
|
|
151
|
-
|
|
152
|
-
ds.list_artifacts(complete_only=True) # assay scope, default assay
|
|
153
|
-
ds.list_artifacts(kind="cell_selection", scope="datastore")
|
|
154
|
-
on_graph = ds.list_artifacts(
|
|
155
|
-
kind="cluster_labels",
|
|
156
|
-
operation="run_leiden_clustering",
|
|
157
|
-
inputs={"graph": run["connectivity_map"]},
|
|
158
|
-
)
|
|
159
|
-
[ds.inspect_artifact(ref).parameters["resolution"] for ref in on_graph]
|
|
160
|
-
|
|
161
|
-
decision = ds.load_artifact(run["cluster_selection"])
|
|
162
|
-
decision.attrs["selectedKey"], decision.attrs["candidateKeys"], decision["scores"][:]
|
|
163
|
-
```
|
|
164
|
-
|
|
165
|
-
### Branch from a completed run and trace lineage
|
|
166
|
-
|
|
167
|
-
Pass exact run refs to granular methods. Same inputs return the run's own artifacts; new
|
|
168
|
-
parameters create a branch. Explicit normalization/PCA/graph chains: features-and-graphs.md.
|
|
169
|
-
Clustering choices: clustering-and-embedding.md.
|
|
170
|
-
|
|
171
|
-
```python
|
|
172
|
-
graph = run["connectivity_map"]
|
|
173
|
-
ds.run_leiden_clustering(graph, resolution=0.5) == run["leiden_0.5"] # reused, no recompute
|
|
174
|
-
fine_clusters = ds.run_leiden_clustering(graph, resolution=2.0) # new cluster_labels ref
|
|
175
|
-
fine_markers = ds.run_marker_search(fine_clusters, features=run["feature_universe"])
|
|
176
|
-
|
|
177
|
-
cells = run["analysis_cell_selection"]
|
|
178
|
-
hvgs = run["highly_variable_features"]
|
|
179
|
-
ds.run_normalization(cells, hvgs) == run["normalized"] # True: reused
|
|
180
|
-
ds.plots.embedding(layout=run["umap"], color_by=fine_clusters, show=False).close()
|
|
181
|
-
|
|
182
|
-
lineage = ds.lineage({"selected": run["clusters"], "fine": fine_clusters})
|
|
183
|
-
markdown = lineage.to_markdown() # Mermaid graph (shared upstream once) plus details
|
|
184
|
-
mermaid = lineage.to_mermaid()
|
|
185
|
-
snapshot = ds.summary().to_dict() # columns, artifact inventory, run counts, labels
|
|
186
|
-
```
|
|
187
|
-
|
|
188
|
-
### Record the analysis for handoff
|
|
189
|
-
|
|
190
|
-
Write the prospective record (question, unit of inference, input refs, planned writes,
|
|
191
|
-
alternatives, decision criteria) before the first mutating call, then extend it into the handoff:
|
|
192
|
-
add metadata roles and confounding, evidence per alternative, unsupported claims, required
|
|
193
|
-
validation and exported files. Refs round-trip with `to_dict()` and `ArtifactRef.from_dict()`.
|
|
194
|
-
|
|
195
|
-
```python
|
|
196
|
-
import json
|
|
197
|
-
from pathlib import Path
|
|
198
|
-
|
|
199
|
-
out = Path("handoff")
|
|
200
|
-
out.mkdir(exist_ok=True)
|
|
201
|
-
refs = {"cellSelection": "analysis_cell_selection", "featureSelection": "highly_variable_features",
|
|
202
|
-
"graph": "connectivity_map", "selectedClusters": "clusters"}
|
|
203
|
-
record = {
|
|
204
|
-
"question": "Which broad populations are present?",
|
|
205
|
-
"unitOfInference": "cells from one sample; no replicate-level claims",
|
|
206
|
-
"pipelineRun": {"runId": run.run_id, "label": run.label, "status": run.status},
|
|
207
|
-
"refs": {name: run[key].to_dict() for name, key in refs.items()}
|
|
208
|
-
| {"fineClusters": fine_clusters.to_dict()},
|
|
209
|
-
"alternatives": "Leiden 0.5 (pipeline choice) vs 2.0",
|
|
210
|
-
"decision": "provisional", "openQuestions": ["Does MAD filtering remove a real population?"],
|
|
211
|
-
}
|
|
212
|
-
(out / "handoff.json").write_text(json.dumps(record, indent=2))
|
|
213
|
-
(out / "run_report.md").write_text(run.report(format="markdown"))
|
|
214
|
-
(out / "lineage.md").write_text(lineage.to_markdown())
|
|
215
|
-
saved = json.loads((out / "handoff.json").read_text())
|
|
216
|
-
scarf.ArtifactRef.from_dict(saved["refs"]["fineClusters"]) == fine_clusters # True
|
|
217
|
-
```
|
|
218
|
-
|
|
219
|
-
## Parameters that matter
|
|
220
|
-
|
|
221
|
-
| Parameter | Default | Change when |
|
|
222
|
-
| --- | --- | --- |
|
|
223
|
-
| `label` | `None` | Always name runs you will reopen; pick a new name per variant. |
|
|
224
|
-
| `cell_key` | `"I"` | A boolean column already defines the cohort. |
|
|
225
|
-
| `filtering` | `True` (pooled MAD, 3 MADs, over `RNA_nCounts/nFeatures/percentMito/percentRibo`) | Data already filtered (`False`) or per-sample or manual bounds needed (mapping; see quality-control.md). |
|
|
226
|
-
| `harmony_batch_columns` | `None` | Real batch columns exist; see integration-and-comparisons.md. |
|
|
227
|
-
| `hvg_count` / `pca_dims` / `neighbors_k` | `1000` / `21` / `11` | A representation choice is under test. `pca_dims=0` skips PCA (output key `reduction`). |
|
|
228
|
-
| `umap` | `True` | `False` skips `embedding_initialization` and `umap`. |
|
|
229
|
-
| `leiden` | `True` = `[0.5, 0.75, 1.0, 1.25]` | Other candidates: `{"partitions": [...]}`; pin with `params["leiden"]["selected"]`. |
|
|
230
|
-
| `cell_cycle`, `paris` | `True` | Skip to save time (cell cycle is the slowest stage on remote counts). |
|
|
231
|
-
| `doublets`, `markers` | `True` | `False` to skip; both are required off when `leiden=False`. |
|
|
232
|
-
| `snapshot_columns` | `()` | Run-mode plots or `run.cells` need live columns. Choose on the first run (see Pitfalls). |
|
|
233
|
-
| `params` | `None` | Stage settings (`hvg`, `pca`, `umap`, `leiden`, `tsne`, `membership_strength`, ...). |
|
|
234
|
-
| `callback` | `None` | Progress events: `event.kind`, `event.stage`, `event.error`. |
|
|
235
|
-
|
|
236
|
-
## Check before moving on
|
|
237
|
-
|
|
238
|
-
- `run.status == "completed"` and the expected keys are present.
|
|
239
|
-
- `run.report(format="markdown")`: stage statuses, wall seconds, created versus reused counts,
|
|
240
|
-
resolved `filtering` config, and any failure or interruption section.
|
|
241
|
-
- Kept cells: `run.cells.fetch_all("I").sum()` versus the store total. Audit removed cells (by
|
|
242
|
-
your own clusters or a marker panel, not held-out labels) before trusting clusters.
|
|
243
|
-
- `decision["scores"]` from `cluster_selection`: silhouette is a provisional baseline, not ground
|
|
244
|
-
truth.
|
|
245
|
-
- For any ref you consume: `ds.inspect_artifact(ref).complete` is `True`, and `operation`,
|
|
246
|
-
`parameters` and `inputs` match what you intend.
|
|
247
|
-
|
|
248
|
-
## Pitfalls
|
|
249
|
-
|
|
250
|
-
- `snapshot_columns` (and Harmony columns) enter the cell snapshot that feeds filtering, so adding
|
|
251
|
-
one changes `analysis_cell_selection` and recomputes everything downstream. Same parameters under
|
|
252
|
-
a new label reused all 26 artifacts in 2 s; adding `["cell_type"]` created 24 of 27 again
|
|
253
|
-
(10x 5K PBMC docs dataset).
|
|
254
|
-
- `ds.list_artifacts(kind="cell_selection")` silently returns `[]`; pass `scope="datastore"`.
|
|
255
|
-
- Compare cell selections from different routes by mask, not by ref: equal values can have
|
|
256
|
-
different ids.
|
|
257
|
-
- A `PipelineRun` is bound to the `DataStore` object that opened it. After reopening the store,
|
|
258
|
-
reopen the run, or plotting raises `ValueError`.
|
|
259
|
-
- `run.get(key)` returns `None` for a disabled stage, but raises `RuntimeError` on a run that did
|
|
260
|
-
not complete.
|
|
261
|
-
- `run.cells.fetch("clusters")` is integer, while `get_markers(...)["group_id"]` is a string.
|
|
262
|
-
- In a backgrounded non-interactive shell, SIGINT is ignored; use SIGTERM to stop a run cleanly.
|
|
263
|
-
`SIGKILL` or OOM leaves an incomplete run with no cleanup.
|
|
264
|
-
- Never read private Zarr paths or mutate `ds.z`, `ds.zw` or run records; use the methods above.
|
|
265
|
-
|
|
266
|
-
## See also
|
|
267
|
-
|
|
268
|
-
- quality-control.md: filtering policies behind `analysis_cell_selection`.
|
|
269
|
-
- features-and-graphs.md: explicit normalization, PCA, ANN, neighbours and graph chains.
|
|
270
|
-
- clustering-and-embedding.md: re-clustering, UMAP/t-SNE branches, partition comparison.
|
|
271
|
-
- markers-and-annotation.md: `get_markers`, marker tables and labels.
|
|
272
|
-
- plotting.md: `ds.plots.*(run=run, ...)` versus explicit refs.
|
|
273
|
-
- performance-and-export.md: `ds.to_anndata(run=run)` and resource settings.
|
|
@@ -1,260 +0,0 @@
|
|
|
1
|
-
# Plotting
|
|
2
|
-
|
|
3
|
-
Draw, inspect and save Scarf figures headlessly, from a completed pipeline run or from explicit
|
|
4
|
-
artifact refs. Docs: <https://scarf.readthedocs.io/en/latest/tutorials/plotting.html>,
|
|
5
|
-
<https://scarf.readthedocs.io/en/latest/reference/api/plotting.html>, <https://scarf.readthedocs.io/en/latest/reference/api/datastore.html>.
|
|
6
|
-
|
|
7
|
-
## When to use
|
|
8
|
-
|
|
9
|
-
- Visual checks after QC, graph, clustering, doublet and marker steps.
|
|
10
|
-
- Figures for a report or handoff. Agents run headless: always save to files and close.
|
|
11
|
-
|
|
12
|
-
## Key concepts
|
|
13
|
-
|
|
14
|
-
- `ds.plots.<name>(...)` is `scarf.plotting.<name>(ds, ...)` with the store bound. Accessor methods:
|
|
15
|
-
`embedding`, `embedding_raster`, `distribution`, `dotplot`, `matrixplot`, `composition`,
|
|
16
|
-
`marker_heatmap`, `cluster_connectivity`, `cluster_tree`, `modality_weights`,
|
|
17
|
-
`pseudotime_heatmap`, `mapping_score`, `mapping_evidence`, `mapping_confusion`,
|
|
18
|
-
`mapping_calibration`, `run_recipe`. Standalone only in `scarf.plotting`: `graph_qc` (sparse
|
|
19
|
-
graph), `elbow` and `highly_variable_features` (arrays), `qc` (DataFrame), plus
|
|
20
|
-
`compose_results`, `label_panels`, `theme_context`.
|
|
21
|
-
- Every plot returns a `PlotResult`: `figure`, `axes` (dict keyed by panel), `tables` (dict of
|
|
22
|
-
DataFrames with the plotted values), `legends`, `scales`, `provenance`, `owns_figure`, and
|
|
23
|
-
`save()`, `save_provenance()`, `show()`, `close()`. Plots never add metadata columns; on a
|
|
24
|
-
writable store `cluster_tree` caches `dendrogram` and `coalesced_tree` artifacts.
|
|
25
|
-
- `show=True` is the default. In a script it draws nothing on Agg and closes a Scarf-owned figure.
|
|
26
|
-
Pass `show=False`, save, then `close()`.
|
|
27
|
-
- Run mode, embedding and embedding_raster only: `run=run`, `layout="umap"` (default), and
|
|
28
|
-
`color_by` set to one string from `run.cells.columns`. No genes, live columns, lists, `CellField`,
|
|
29
|
-
`facet_by`, `subset_by`, `normalization` or `Highlight(by=...)`.
|
|
30
|
-
- Ref mode, everything else: `layout=run["umap"]`, `color_by=` an `ArtifactRef`, a live metadata
|
|
31
|
-
column, a gene name, `FeatureRef`, `CellField`, or a list of these (one panel each). Cells come
|
|
32
|
-
from the layout artifact's selection; live columns are aligned to it.
|
|
33
|
-
- Helpers in `scarf.plotting`: `CellField(key, kind="auto"|"categorical"|"continuous", label=)`,
|
|
34
|
-
`FeatureRef(value, assay=None, by="name"|"id"|"index", label=, reduction=)`,
|
|
35
|
-
`NormalizationSpec(source="assay"|"raw", transform="none"|"log1p")`,
|
|
36
|
-
`ColorScale(cmap, vmin, vmax, vcenter, quantiles, missing_color, scope, scale)`,
|
|
37
|
-
`CategoricalScale(order, palette, labels, missing_color, missing_label, palette_name)`,
|
|
38
|
-
`Highlight(by, groups, indices, color, dim_alpha, ...)`, `DensityOverlay`, `SizeScale`,
|
|
39
|
-
`StudyDesign`.
|
|
40
|
-
- Plots are display. `max_points` thins only the overlaid points in `distribution`; violins use
|
|
41
|
-
every cell and `provenance.notes` gains `"subsampled_display"`. Take numbers from
|
|
42
|
-
`result.tables` or artifacts, never from pixels or UMAP distances.
|
|
43
|
-
|
|
44
|
-
## Recipes
|
|
45
|
-
|
|
46
|
-
`cell_type`, `sample_id` and `B cell` below are placeholders for your own annotation and design
|
|
47
|
-
columns. When author labels are held out, plot only labels you assigned.
|
|
48
|
-
|
|
49
|
-
### Save headlessly
|
|
50
|
-
|
|
51
|
-
Run scripts as `MPLBACKEND=Agg python script.py`, or call `matplotlib.use("Agg")` before
|
|
52
|
-
importing pyplot. `save` infers the format (png, pdf, svg, tif) from the suffix, keeps the exact
|
|
53
|
-
inch size, and uses a white background. The exact size can clip a legend outside the axes
|
|
54
|
-
(`legend_loc="right"`, many categories): save those with `exact_size=False`, a tight crop.
|
|
55
|
-
|
|
56
|
-
```python
|
|
57
|
-
import matplotlib.pyplot as plt
|
|
58
|
-
import scarf
|
|
59
|
-
import scarf.plotting as splt
|
|
60
|
-
|
|
61
|
-
scarf.configure_output(level="WARNING", progress=False)
|
|
62
|
-
ds = scarf.DataStore("analysis.zarr", nthreads=4, min_features_per_cell=-1)
|
|
63
|
-
run = ds.pipeline.open(label="baseline")
|
|
64
|
-
|
|
65
|
-
result = ds.plots.embedding(run=run, layout="umap", color_by="clusters", show=False)
|
|
66
|
-
result.save("figures/umap_clusters.png", dpi=150, provenance_sidecar=True) # + .png.json
|
|
67
|
-
result.figure.savefig("figures/umap_clusters_tight.png", dpi=150, bbox_inches="tight")
|
|
68
|
-
result.close()
|
|
69
|
-
assert plt.get_fignums() == [] # nothing left open
|
|
70
|
-
```
|
|
71
|
-
|
|
72
|
-
### Plot frozen run fields
|
|
73
|
-
|
|
74
|
-
```python
|
|
75
|
-
for field in ("clusters", "leiden_1.0", "doublet_score", "cell_cycle_phase"):
|
|
76
|
-
r = ds.plots.embedding(run=run, color_by=field, show=False)
|
|
77
|
-
r.save(f"figures/run_{field}.png", dpi=120)
|
|
78
|
-
r.close()
|
|
79
|
-
r = ds.plots.embedding_raster(run=run, color_by="doublet_score", show=False)
|
|
80
|
-
r.close()
|
|
81
|
-
```
|
|
82
|
-
|
|
83
|
-
### Color by cluster artifacts, metadata and genes
|
|
84
|
-
|
|
85
|
-
Gene panels read counts and normalize on the fly; several genes in one call share one matrix
|
|
86
|
-
read (seconds on remote counts).
|
|
87
|
-
|
|
88
|
-
```python
|
|
89
|
-
umap = run["umap"]
|
|
90
|
-
r = ds.plots.embedding(
|
|
91
|
-
layout=umap,
|
|
92
|
-
color_by=[run["clusters"], "CD3D", "MS4A1", "LYZ"],
|
|
93
|
-
normalization=splt.NormalizationSpec(transform="log1p"),
|
|
94
|
-
color_scale=splt.ColorScale(cmap="viridis", quantiles=(0.0, 0.99)),
|
|
95
|
-
sort_values=True,
|
|
96
|
-
show=False,
|
|
97
|
-
)
|
|
98
|
-
r.axes["cluster_labels"].set_title("Leiden (selected)") # ref panels are keyed by kind
|
|
99
|
-
r.save("figures/umap_genes.png", dpi=150)
|
|
100
|
-
r.close()
|
|
101
|
-
|
|
102
|
-
r = ds.plots.embedding(
|
|
103
|
-
layout=umap,
|
|
104
|
-
color_by=splt.CellField("cell_type", kind="categorical", label="Cell type"),
|
|
105
|
-
categorical_scale=splt.CategoricalScale(palette_name="colorblind"), # or "default" only
|
|
106
|
-
legend_loc="right",
|
|
107
|
-
show=False,
|
|
108
|
-
)
|
|
109
|
-
r.save("figures/umap_cell_type.png", dpi=150, exact_size=False) # keeps the outside legend
|
|
110
|
-
r.close()
|
|
111
|
-
ds.plots.embedding(layout=umap, color_by=run["leiden_1.0"], show=False).close()
|
|
112
|
-
ds.plots.embedding(
|
|
113
|
-
layout=umap,
|
|
114
|
-
color_by=None,
|
|
115
|
-
default_color="#bdbdbd",
|
|
116
|
-
highlight=splt.Highlight(by="cell_type", groups=("B cell",)),
|
|
117
|
-
show=False,
|
|
118
|
-
).close()
|
|
119
|
-
ds.plots.embedding(
|
|
120
|
-
layout=umap, color_by=splt.FeatureRef("NKG7", label="NKG7"), show=False
|
|
121
|
-
).close()
|
|
122
|
-
```
|
|
123
|
-
|
|
124
|
-
### Distributions
|
|
125
|
-
|
|
126
|
-
`grouping` must be an `ArtifactRef` or a `CellField`; a plain string raises `TypeError`. `keys`
|
|
127
|
-
are metadata columns, genes, or a `cell_cycle` artifact: every other `ArtifactRef` (doublets,
|
|
128
|
-
membership strength, enrichment) raises `ValueError`. Insert a frozen field as a live column first.
|
|
129
|
-
|
|
130
|
-
```python
|
|
131
|
-
r = ds.plots.distribution(
|
|
132
|
-
["RNA_nCounts", "RNA_percentMito"],
|
|
133
|
-
grouping=run["clusters"],
|
|
134
|
-
kind="violin",
|
|
135
|
-
max_points=2000,
|
|
136
|
-
show=False,
|
|
137
|
-
)
|
|
138
|
-
r.tables["RNA_nCounts"].head() # value, group, display_value; one row per analysed cell
|
|
139
|
-
r.provenance.notes # ('distribution', 'violin', 'subsampled_display')
|
|
140
|
-
r.close()
|
|
141
|
-
ds.plots.distribution(
|
|
142
|
-
"RNA_nCounts",
|
|
143
|
-
grouping=splt.CellField("cell_type", kind="categorical"),
|
|
144
|
-
cell_selection=run["analysis_cell_selection"],
|
|
145
|
-
max_points=0,
|
|
146
|
-
show=False,
|
|
147
|
-
).close()
|
|
148
|
-
ds.plots.distribution(run["cell_cycle"], grouping=run["clusters"], show=False).close()
|
|
149
|
-
ds.cells.insert("baseline_doublet_score", run.cells.fetch_all("doublet_score"), overwrite=True)
|
|
150
|
-
ds.plots.distribution("baseline_doublet_score", grouping=run["clusters"], show=False).close()
|
|
151
|
-
```
|
|
152
|
-
|
|
153
|
-
### Dot plots, matrix plots and marker heatmaps
|
|
154
|
-
|
|
155
|
-
Here `groups=` is the cluster `ArtifactRef`; `group_by=` names a live column instead and groups
|
|
156
|
-
the cells of `cell_key` (default `"I"`, not the run's cells). The aggregate table's group column is
|
|
157
|
-
`groups` for `groups=`, and the column's own name for `group_by=` (one column per name in a tuple).
|
|
158
|
-
|
|
159
|
-
```python
|
|
160
|
-
panel = {"T": ["CD3D", "IL7R"], "B": ["MS4A1", "CD79A"], "NK": ["NKG7", "GNLY"]}
|
|
161
|
-
r = ds.plots.dotplot(features=panel, groups=run["clusters"], standardize="feature", show=False)
|
|
162
|
-
r.tables["aggregate"].head() # groups, feature, feature_group, mean, fraction, n_cells, variance
|
|
163
|
-
r.save("figures/dotplot.png", dpi=150)
|
|
164
|
-
r.close()
|
|
165
|
-
r = ds.plots.dotplot(features=panel, group_by="cell_type", show=False)
|
|
166
|
-
agg = r.tables["aggregate"] # cell_type, feature, feature_group, mean, fraction, n_cells, variance
|
|
167
|
-
fraction = agg.pivot(index="cell_type", columns="feature", values="fraction") # not "groups"
|
|
168
|
-
r.close()
|
|
169
|
-
ds.plots.matrixplot(
|
|
170
|
-
features=["CD3D", "MS4A1", "LYZ"], groups=run["clusters"], cluster_groups=True, show=False
|
|
171
|
-
).close()
|
|
172
|
-
r = ds.plots.marker_heatmap(marker=run["markers"], topn=3, show=False)
|
|
173
|
-
r.tables["markers"].head() # group, rank, feature_index, score, feature
|
|
174
|
-
r.close()
|
|
175
|
-
```
|
|
176
|
-
|
|
177
|
-
### Graph and cluster structure
|
|
178
|
-
|
|
179
|
-
```python
|
|
180
|
-
graph = run["connectivity_map"]
|
|
181
|
-
r = ds.plots.cluster_connectivity(
|
|
182
|
-
graph=graph, groups=run["clusters"], layout=run["umap"], show_cells=True, show=False
|
|
183
|
-
)
|
|
184
|
-
r.tables["edges"] # source, target, rawWeight, normalizedWeight
|
|
185
|
-
r.close()
|
|
186
|
-
ds.plots.cluster_tree(graph=graph, clusters=run["paris"], show=False).close()
|
|
187
|
-
splt.graph_qc(ds.load_graph(graph=graph), show=False).close()
|
|
188
|
-
ds.plots.composition(categories=run["clusters"], show=False).close() # one stacked bar
|
|
189
|
-
r = ds.plots.composition(category_by="cell_type", sample_by="sample_id", kind="stacked", show=False)
|
|
190
|
-
r.tables["per_sample"].head() # one stacked bar per sample
|
|
191
|
-
r.close()
|
|
192
|
-
```
|
|
193
|
-
|
|
194
|
-
`kind="per_sample"` with a `StudyDesign` draws a strip of per-sample proportions per category
|
|
195
|
-
instead; see integration-and-comparisons.md.
|
|
196
|
-
|
|
197
|
-
### Compose panels in a figure you own
|
|
198
|
-
|
|
199
|
-
With `target=` the caller owns the figure: child `close()` does nothing, so close the figure. A
|
|
200
|
-
ref-mode embedding with many long category labels and `legend_loc="right"` shrinks its axes to a
|
|
201
|
-
thumbnail; draw it on a wide figure you own instead.
|
|
202
|
-
|
|
203
|
-
```python
|
|
204
|
-
fig, axes = plt.subplots(1, 2, figsize=(9, 4), layout="constrained")
|
|
205
|
-
ds.plots.embedding(run=run, color_by="clusters", target=axes[0], show=False)
|
|
206
|
-
ds.plots.embedding(run=run, color_by="doublet_score", target=axes[1], show=False)
|
|
207
|
-
fig.savefig("figures/panels.png", dpi=150, bbox_inches="tight")
|
|
208
|
-
plt.close(fig)
|
|
209
|
-
|
|
210
|
-
fig, ax = plt.subplots(figsize=(11, 6), layout="constrained") # room for long labels
|
|
211
|
-
ds.plots.embedding(layout=run["umap"], color_by=splt.CellField("cell_type"), legend_loc="right",
|
|
212
|
-
target=ax, show=False)
|
|
213
|
-
fig.savefig("figures/umap_cell_type_wide.png", dpi=150, bbox_inches="tight")
|
|
214
|
-
plt.close(fig)
|
|
215
|
-
```
|
|
216
|
-
|
|
217
|
-
## Parameters that matter
|
|
218
|
-
|
|
219
|
-
| Parameter | Default | Change when |
|
|
220
|
-
| --- | --- | --- |
|
|
221
|
-
| `show` | `True` | Always `False` in scripts; then `save` and `close`. |
|
|
222
|
-
| `layout` / `layout_key` | none; exactly one required (run mode: `"umap"`) | `layout_key` only for coordinates you inserted as metadata columns. |
|
|
223
|
-
| `normalization` | `NormalizationSpec()` (assay normalization, no transform) | `transform="log1p"` for gene panels. |
|
|
224
|
-
| `color_scale` | auto per feature | `quantiles=(0.0, 0.99)` to stop outliers washing out a gene. |
|
|
225
|
-
| `categorical_scale` | default palette | Fix `order` or `palette` (dict) to keep colors identical; `palette_name` is only `"default"` or `"colorblind"`. |
|
|
226
|
-
| `sort_values` | `False` | `True` draws high values last for expression panels. |
|
|
227
|
-
| `legend_loc` | `"auto"` | `"right"`, `"on_data"` or `"none"` to force placement. |
|
|
228
|
-
| `max_points` (distribution) | `10000` | `0` for no points; `None` gives no points for stacked violins. |
|
|
229
|
-
| `rasterize_threshold` | `50000` | Lower for smaller vector files. |
|
|
230
|
-
| `save(dpi=, exact_size=)` | figure dpi (300 for TIFF), `True` | `exact_size=False` for a tight crop and for legends outside the axes. |
|
|
231
|
-
|
|
232
|
-
## Check before moving on
|
|
233
|
-
|
|
234
|
-
- Open one or two saved PNGs and confirm panels, legends and colorbars rendered.
|
|
235
|
-
- Legend categories equal the cluster count; `tables` row counts equal analysed cells.
|
|
236
|
-
- `plt.get_fignums()` is empty after a batch of figures.
|
|
237
|
-
- `result.provenance.n_cells` and `notes` match the intended selection and subsampling.
|
|
238
|
-
|
|
239
|
-
## Pitfalls
|
|
240
|
-
|
|
241
|
-
- Run mode rejects anything but one frozen field: a gene or live column raises `KeyError`, a list
|
|
242
|
-
or `CellField` raises `TypeError`, `facet_by`/`subset_by`/`normalization` raise `ValueError`.
|
|
243
|
-
Switch to `layout=run["umap"]`.
|
|
244
|
-
- `layout="umap"` without `run=` raises `TypeError`. The pipeline writes no `RNA_UMAP*` columns,
|
|
245
|
-
so `layout_key="RNA_UMAP"` fails on pipeline-only stores.
|
|
246
|
-
- `groups` filters categories in `embedding` and `distribution` but is the cluster ref in
|
|
247
|
-
`dotplot`, `matrixplot` and `cluster_connectivity`. Pivoting a `group_by=` aggregate on
|
|
248
|
-
`"groups"` raises `KeyError: 'groups'`.
|
|
249
|
-
- `CategoricalScale(palette_name="tab20")` raises `ValueError`; pass `palette={label: color}`.
|
|
250
|
-
- The same clusters get different colors in run mode and ref mode; pass a `CategoricalScale`
|
|
251
|
-
when figures must match.
|
|
252
|
-
- A run opened from another `DataStore` object raises `ValueError` in plots.
|
|
253
|
-
- Unclosed `show=False` figures accumulate in long loops.
|
|
254
|
-
|
|
255
|
-
## See also
|
|
256
|
-
|
|
257
|
-
- pipeline-runs-and-artifacts.md: which run keys and frozen fields exist.
|
|
258
|
-
- quality-control.md, features-and-graphs.md, clustering-and-embedding.md,
|
|
259
|
-
markers-and-annotation.md: the diagnostic plot for each step.
|
|
260
|
-
- integration-and-comparisons.md: `modality_weights`, mapping plots, `StudyDesign` composition.
|