pi-skill-search 0.1.0
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/CHANGELOG.md +20 -0
- package/LICENSE +21 -0
- package/README.md +97 -0
- package/index.ts +163 -0
- package/package.json +48 -0
- package/skills/adaptyv/SKILL.md +92 -0
- package/skills/add-community-extension/SKILL.md +85 -0
- package/skills/aeon/SKILL.md +111 -0
- package/skills/ai-slop-cleaner/SKILL.md +118 -0
- package/skills/anndata/SKILL.md +83 -0
- package/skills/arboreto/SKILL.md +107 -0
- package/skills/ask/SKILL.md +55 -0
- package/skills/astropy/SKILL.md +30 -0
- package/skills/async-worker-recovery/SKILL.md +44 -0
- package/skills/autopilot/SKILL.md +63 -0
- package/skills/autoresearch/SKILL.md +64 -0
- package/skills/autoskill/SKILL.md +116 -0
- package/skills/babysit/SKILL.md +43 -0
- package/skills/benchling-integration/SKILL.md +106 -0
- package/skills/bgpt-paper-search/SKILL.md +67 -0
- package/skills/biopython/SKILL.md +29 -0
- package/skills/bioservices/SKILL.md +96 -0
- package/skills/brainstorming/SKILL.md +104 -0
- package/skills/cancel/SKILL.md +85 -0
- package/skills/ccg/SKILL.md +87 -0
- package/skills/celery-pipeline/SKILL.md +30 -0
- package/skills/cellxgene-census/SKILL.md +104 -0
- package/skills/child-pi-spawning/SKILL.md +85 -0
- package/skills/cirq/SKILL.md +113 -0
- package/skills/citation-management/SKILL.md +91 -0
- package/skills/clinical-decision-support/SKILL.md +117 -0
- package/skills/clinical-reports/SKILL.md +118 -0
- package/skills/clinical-trial/SKILL.md +28 -0
- package/skills/cobrapy/SKILL.md +116 -0
- package/skills/configure-notifications/SKILL.md +85 -0
- package/skills/consciousness-council/SKILL.md +120 -0
- package/skills/context-artifact-hygiene/SKILL.md +85 -0
- package/skills/context-mode-ops/SKILL.md +87 -0
- package/skills/dask/SKILL.md +85 -0
- package/skills/database-lookup/SKILL.md +118 -0
- package/skills/datamol/SKILL.md +108 -0
- package/skills/debug/SKILL.md +32 -0
- package/skills/deep-dive/SKILL.md +114 -0
- package/skills/deep-interview/SKILL.md +90 -0
- package/skills/deepchem/SKILL.md +117 -0
- package/skills/deepinit/SKILL.md +100 -0
- package/skills/deeptools/SKILL.md +118 -0
- package/skills/delegation-patterns/SKILL.md +56 -0
- package/skills/depmap/SKILL.md +94 -0
- package/skills/dhdna-profiler/SKILL.md +86 -0
- package/skills/diffdock/SKILL.md +101 -0
- package/skills/dispatching-parallel-agents/SKILL.md +119 -0
- package/skills/dnanexus-integration/SKILL.md +118 -0
- package/skills/do/SKILL.md +48 -0
- package/skills/docker-sandbox/SKILL.md +29 -0
- package/skills/docx/SKILL.md +119 -0
- package/skills/esm/SKILL.md +116 -0
- package/skills/etetoolkit/SKILL.md +103 -0
- package/skills/event-log-tracing/SKILL.md +85 -0
- package/skills/exa-search/SKILL.md +72 -0
- package/skills/executing-plans/SKILL.md +69 -0
- package/skills/exploratory-data-analysis/SKILL.md +118 -0
- package/skills/external-context/SKILL.md +80 -0
- package/skills/fastapi/SKILL.md +30 -0
- package/skills/finishing-a-development-branch/SKILL.md +106 -0
- package/skills/flowio/SKILL.md +114 -0
- package/skills/fluidsim/SKILL.md +108 -0
- package/skills/generate-image/SKILL.md +108 -0
- package/skills/geniml/SKILL.md +117 -0
- package/skills/geomaster/SKILL.md +109 -0
- package/skills/geopandas/SKILL.md +114 -0
- package/skills/get-available-resources/SKILL.md +100 -0
- package/skills/gget/SKILL.md +111 -0
- package/skills/ginkgo-cloud-lab/SKILL.md +52 -0
- package/skills/git-master/SKILL.md +85 -0
- package/skills/glycoengineering/SKILL.md +104 -0
- package/skills/gtars/SKILL.md +104 -0
- package/skills/hackernews-frontpage/SKILL.md +46 -0
- package/skills/histolab/SKILL.md +98 -0
- package/skills/how-it-works/SKILL.md +25 -0
- package/skills/hud/SKILL.md +86 -0
- package/skills/hugging-science/SKILL.md +93 -0
- package/skills/huggingface/SKILL.md +30 -0
- package/skills/hypogenic/SKILL.md +107 -0
- package/skills/hypothesis-generation/SKILL.md +118 -0
- package/skills/imaging-data-commons/SKILL.md +119 -0
- package/skills/infographics/SKILL.md +102 -0
- package/skills/iso-13485-certification/SKILL.md +114 -0
- package/skills/knowledge-agent/SKILL.md +83 -0
- package/skills/labarchive-integration/SKILL.md +98 -0
- package/skills/lamindb/SKILL.md +119 -0
- package/skills/landsat/SKILL.md +29 -0
- package/skills/latchbio-integration/SKILL.md +118 -0
- package/skills/latex-posters/SKILL.md +112 -0
- package/skills/learn-codebase/SKILL.md +24 -0
- package/skills/learner/SKILL.md +118 -0
- package/skills/literature-review/SKILL.md +118 -0
- package/skills/live-agent-lifecycle/SKILL.md +85 -0
- package/skills/mailbox-interactive/SKILL.md +85 -0
- package/skills/make-plan/SKILL.md +59 -0
- package/skills/markdown-mermaid-writing/SKILL.md +118 -0
- package/skills/market-research-reports/SKILL.md +119 -0
- package/skills/markitdown/SKILL.md +111 -0
- package/skills/markitdown-docs/SKILL.md +28 -0
- package/skills/matchms/SKILL.md +91 -0
- package/skills/matlab/SKILL.md +118 -0
- package/skills/matplotlib/SKILL.md +30 -0
- package/skills/mcp-setup/SKILL.md +84 -0
- package/skills/medchem/SKILL.md +109 -0
- package/skills/mem-search/SKILL.md +96 -0
- package/skills/modal/SKILL.md +104 -0
- package/skills/model-routing-context/SKILL.md +85 -0
- package/skills/molecular-dynamics/SKILL.md +116 -0
- package/skills/molfeat/SKILL.md +110 -0
- package/skills/multi-perspective-review/SKILL.md +85 -0
- package/skills/networkx/SKILL.md +111 -0
- package/skills/neurokit2/SKILL.md +114 -0
- package/skills/neuropixels-analysis/SKILL.md +112 -0
- package/skills/nilearn/SKILL.md +29 -0
- package/skills/observability-reliability/SKILL.md +43 -0
- package/skills/omc-doctor/SKILL.md +86 -0
- package/skills/omc-reference/SKILL.md +119 -0
- package/skills/omc-setup/SKILL.md +82 -0
- package/skills/omc-teams/SKILL.md +81 -0
- package/skills/omero-integration/SKILL.md +111 -0
- package/skills/open-notebook/SKILL.md +100 -0
- package/skills/openephys/SKILL.md +28 -0
- package/skills/opentrons-integration/SKILL.md +110 -0
- package/skills/optimize-for-gpu/SKILL.md +119 -0
- package/skills/orchestration/SKILL.md +85 -0
- package/skills/ownership-session-security/SKILL.md +43 -0
- package/skills/paper-lookup/SKILL.md +119 -0
- package/skills/paperzilla/SKILL.md +114 -0
- package/skills/parallel-web/SKILL.md +64 -0
- package/skills/pathfinder/SKILL.md +114 -0
- package/skills/pathml/SKILL.md +98 -0
- package/skills/pdf/SKILL.md +113 -0
- package/skills/peer-review/SKILL.md +119 -0
- package/skills/pennylane/SKILL.md +119 -0
- package/skills/phylogenetics/SKILL.md +102 -0
- package/skills/pi-extension-lifecycle/SKILL.md +41 -0
- package/skills/plan/SKILL.md +66 -0
- package/skills/polars/SKILL.md +114 -0
- package/skills/polars-bio/SKILL.md +84 -0
- package/skills/pptx/SKILL.md +118 -0
- package/skills/pptx-posters/SKILL.md +112 -0
- package/skills/primekg/SKILL.md +97 -0
- package/skills/project-session-manager/SKILL.md +85 -0
- package/skills/protocolsio-integration/SKILL.md +119 -0
- package/skills/pubmed-search/SKILL.md +29 -0
- package/skills/pufferlib/SKILL.md +103 -0
- package/skills/pydeseq2/SKILL.md +106 -0
- package/skills/pydicom/SKILL.md +115 -0
- package/skills/pyhealth/SKILL.md +117 -0
- package/skills/pylabrobot/SKILL.md +100 -0
- package/skills/pymatgen/SKILL.md +28 -0
- package/skills/pymc/SKILL.md +108 -0
- package/skills/pymoo/SKILL.md +90 -0
- package/skills/pyopenms/SKILL.md +119 -0
- package/skills/pysam/SKILL.md +118 -0
- package/skills/pyspark/SKILL.md +30 -0
- package/skills/pytdc/SKILL.md +102 -0
- package/skills/pytorch/SKILL.md +31 -0
- package/skills/pytorch-lightning/SKILL.md +119 -0
- package/skills/pyzotero/SKILL.md +104 -0
- package/skills/qiskit/SKILL.md +119 -0
- package/skills/qutip/SKILL.md +111 -0
- package/skills/ralph/SKILL.md +23 -0
- package/skills/ralplan/SKILL.md +105 -0
- package/skills/rdflib/SKILL.md +29 -0
- package/skills/rdkit/SKILL.md +30 -0
- package/skills/read-only-explorer/SKILL.md +85 -0
- package/skills/receiving-code-review/SKILL.md +103 -0
- package/skills/release/SKILL.md +117 -0
- package/skills/remember/SKILL.md +39 -0
- package/skills/requesting-code-review/SKILL.md +85 -0
- package/skills/requirements-to-task-packet/SKILL.md +65 -0
- package/skills/research-grants/SKILL.md +118 -0
- package/skills/research-lookup/SKILL.md +117 -0
- package/skills/research-reproducibility/SKILL.md +28 -0
- package/skills/resource-discovery-config/SKILL.md +43 -0
- package/skills/rowan/SKILL.md +100 -0
- package/skills/runtime-state-reader/SKILL.md +46 -0
- package/skills/safe-bash/SKILL.md +85 -0
- package/skills/scanpy/SKILL.md +32 -0
- package/skills/scholar-evaluation/SKILL.md +115 -0
- package/skills/scientific-brainstorming/SKILL.md +118 -0
- package/skills/scientific-critical-thinking/SKILL.md +119 -0
- package/skills/scientific-schematics/SKILL.md +116 -0
- package/skills/scientific-slides/SKILL.md +117 -0
- package/skills/scientific-visualization/SKILL.md +109 -0
- package/skills/scientific-writing/SKILL.md +119 -0
- package/skills/scikit-bio/SKILL.md +92 -0
- package/skills/scikit-learn/SKILL.md +99 -0
- package/skills/scikit-survival/SKILL.md +110 -0
- package/skills/sciomc/SKILL.md +86 -0
- package/skills/scvelo/SKILL.md +106 -0
- package/skills/scvi-tools/SKILL.md +114 -0
- package/skills/seaborn/SKILL.md +97 -0
- package/skills/secure-agent-orchestration-review/SKILL.md +47 -0
- package/skills/self-improve/SKILL.md +119 -0
- package/skills/semantic-compression/SKILL.md +62 -0
- package/skills/setup/SKILL.md +42 -0
- package/skills/shap/SKILL.md +103 -0
- package/skills/simpy/SKILL.md +116 -0
- package/skills/skill/SKILL.md +117 -0
- package/skills/skill-search/SKILL.md +67 -0
- package/skills/skillify/SKILL.md +46 -0
- package/skills/smart-explore/SKILL.md +94 -0
- package/skills/sqlite-pandas/SKILL.md +30 -0
- package/skills/stable-baselines3/SKILL.md +86 -0
- package/skills/state-mutation-locking/SKILL.md +44 -0
- package/skills/statistical-analysis/SKILL.md +108 -0
- package/skills/statsmodels/SKILL.md +29 -0
- package/skills/subagent-driven-development/SKILL.md +89 -0
- package/skills/sympy/SKILL.md +115 -0
- package/skills/system-prompts/SKILL.md +116 -0
- package/skills/systematic-debugging/SKILL.md +119 -0
- package/skills/team/SKILL.md +85 -0
- package/skills/test-driven-development/SKILL.md +84 -0
- package/skills/tiledbvcf/SKILL.md +119 -0
- package/skills/timeline-report/SKILL.md +85 -0
- package/skills/timesfm-forecasting/SKILL.md +112 -0
- package/skills/torch-geometric/SKILL.md +118 -0
- package/skills/torchdrug/SKILL.md +118 -0
- package/skills/trace/SKILL.md +118 -0
- package/skills/transformers/SKILL.md +110 -0
- package/skills/treatment-plans/SKILL.md +119 -0
- package/skills/ui-render-performance/SKILL.md +41 -0
- package/skills/ultragoal/SKILL.md +63 -0
- package/skills/ultraqa/SKILL.md +85 -0
- package/skills/ultrawork/SKILL.md +20 -0
- package/skills/umap-learn/SKILL.md +119 -0
- package/skills/usfiscaldata/SKILL.md +118 -0
- package/skills/using-git-worktrees/SKILL.md +112 -0
- package/skills/using-superpowers/SKILL.md +85 -0
- package/skills/using-vetc/SKILL.md +92 -0
- package/skills/vaex/SKILL.md +111 -0
- package/skills/venue-templates/SKILL.md +113 -0
- package/skills/verification-before-completion/SKILL.md +88 -0
- package/skills/verification-before-done/SKILL.md +68 -0
- package/skills/verify/SKILL.md +33 -0
- package/skills/version-bump/SKILL.md +54 -0
- package/skills/vetc-analyze-ba/SKILL.md +117 -0
- package/skills/vetc-analyze-codebase/SKILL.md +118 -0
- package/skills/vetc-api-design/SKILL.md +103 -0
- package/skills/vetc-brainstorming/SKILL.md +116 -0
- package/skills/vetc-change-proposal/SKILL.md +111 -0
- package/skills/vetc-cicd/SKILL.md +113 -0
- package/skills/vetc-continuous-learning/SKILL.md +115 -0
- package/skills/vetc-deep-interview/SKILL.md +103 -0
- package/skills/vetc-docgen/SKILL.md +108 -0
- package/skills/vetc-frontend-patterns/SKILL.md +99 -0
- package/skills/vetc-iterative-retrieval/SKILL.md +110 -0
- package/skills/vetc-java-patterns/SKILL.md +113 -0
- package/skills/vetc-meta-skill-creator/SKILL.md +99 -0
- package/skills/vetc-oracle-patterns/SKILL.md +109 -0
- package/skills/vetc-performance-testing/SKILL.md +104 -0
- package/skills/vetc-pr-response/SKILL.md +106 -0
- package/skills/vetc-ralph/SKILL.md +108 -0
- package/skills/vetc-ralplan/SKILL.md +116 -0
- package/skills/vetc-receiving-review/SKILL.md +106 -0
- package/skills/vetc-reconcile-patterns/SKILL.md +117 -0
- package/skills/vetc-refactoring/SKILL.md +96 -0
- package/skills/vetc-runbook/SKILL.md +118 -0
- package/skills/vetc-sast/SKILL.md +118 -0
- package/skills/vetc-sdlc/SKILL.md +97 -0
- package/skills/vetc-security/SKILL.md +117 -0
- package/skills/vetc-spec-driven/SKILL.md +111 -0
- package/skills/vetc-spec-quality/SKILL.md +117 -0
- package/skills/vetc-systematic-debugging/SKILL.md +74 -0
- package/skills/vetc-tdd/SKILL.md +96 -0
- package/skills/vetc-thinking-pm/SKILL.md +110 -0
- package/skills/vetc-ui-visual-qa/SKILL.md +117 -0
- package/skills/vetc-verify/SKILL.md +101 -0
- package/skills/visual-verdict/SKILL.md +59 -0
- package/skills/what-if-oracle/SKILL.md +87 -0
- package/skills/widget-rendering/SKILL.md +85 -0
- package/skills/wiki/SKILL.md +69 -0
- package/skills/workspace-isolation/SKILL.md +85 -0
- package/skills/worktree-isolation/SKILL.md +85 -0
- package/skills/wowerpoint/SKILL.md +101 -0
- package/skills/writer-memory/SKILL.md +82 -0
- package/skills/writing-plans/SKILL.md +115 -0
- package/skills/writing-skills/SKILL.md +115 -0
- package/skills/xgboost/SKILL.md +29 -0
- package/skills/xgboost-ts/SKILL.md +28 -0
- package/skills/xlsx/SKILL.md +111 -0
- package/skills/zarr-python/SKILL.md +101 -0
- package/src/categories.ts +383 -0
- package/src/format.ts +104 -0
- package/src/indexer.ts +101 -0
- package/src/proactive.ts +51 -0
- package/src/scanner.ts +85 -0
- package/src/search.ts +89 -0
- package/src/strip.ts +29 -0
- package/src/synonyms.ts +83 -0
- package/src/text.ts +118 -0
- package/src/types.ts +64 -0
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: systematic-debugging
|
|
3
|
+
description: Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Systematic Debugging
|
|
7
|
+
|
|
8
|
+
## Overview
|
|
9
|
+
|
|
10
|
+
Random fixes waste time and create new bugs. Quick patches mask underlying issues.
|
|
11
|
+
|
|
12
|
+
**Core principle:** ALWAYS find root cause before attempting fixes. Symptom fixes are failure.
|
|
13
|
+
|
|
14
|
+
**Violating the letter of this process is violating the spirit of debugging.**
|
|
15
|
+
|
|
16
|
+
## The Iron Law
|
|
17
|
+
|
|
18
|
+
```
|
|
19
|
+
NO FIXES WITHOUT ROOT CAUSE INVESTIGATION FIRST
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
If you haven't completed Phase 1, you cannot propose fixes.
|
|
23
|
+
|
|
24
|
+
## When to Use
|
|
25
|
+
|
|
26
|
+
Use for ANY technical issue:
|
|
27
|
+
- Test failures
|
|
28
|
+
- Bugs in production
|
|
29
|
+
- Unexpected behavior
|
|
30
|
+
- Performance problems
|
|
31
|
+
- Build failures
|
|
32
|
+
- Integration issues
|
|
33
|
+
|
|
34
|
+
**Use this ESPECIALLY when:**
|
|
35
|
+
- Under time pressure (emergencies make guessing tempting)
|
|
36
|
+
- "Just one quick fix" seems obvious
|
|
37
|
+
- You've already tried multiple fixes
|
|
38
|
+
- Previous fix didn't work
|
|
39
|
+
|
|
40
|
+
## The Four Phases
|
|
41
|
+
|
|
42
|
+
You MUST complete each phase before proceeding to the next.
|
|
43
|
+
|
|
44
|
+
### Phase 1: Root Cause Investigation
|
|
45
|
+
|
|
46
|
+
**BEFORE attempting ANY fix:**
|
|
47
|
+
|
|
48
|
+
1. **Read Error Messages Carefully**
|
|
49
|
+
- Don't skip past errors or warnings
|
|
50
|
+
- They often contain the exact solution
|
|
51
|
+
- Read stack traces completely
|
|
52
|
+
- Note line numbers, file paths, error codes
|
|
53
|
+
|
|
54
|
+
2. **Reproduce Consistently**
|
|
55
|
+
- Can you trigger it reliably?
|
|
56
|
+
- What are the exact steps?
|
|
57
|
+
- Does it happen every time?
|
|
58
|
+
- If not reproducible → gather more data, don't guess
|
|
59
|
+
|
|
60
|
+
### Phase 2: Pattern Analysis
|
|
61
|
+
|
|
62
|
+
**Find the pattern before fixing:**
|
|
63
|
+
|
|
64
|
+
1. **Find Working Examples**
|
|
65
|
+
- Locate similar working code in same codebase
|
|
66
|
+
- What works that's similar to what's broken?
|
|
67
|
+
|
|
68
|
+
2. **Compare Against References**
|
|
69
|
+
- If implementing pattern, read reference implementation COMPLETELY
|
|
70
|
+
- Don't skim - read every line
|
|
71
|
+
- Understand the pattern fully before applying
|
|
72
|
+
|
|
73
|
+
3. **Identify Differences**
|
|
74
|
+
- What's different between working and broken?
|
|
75
|
+
|
|
76
|
+
### Phase 3: Hypothesis and Testing
|
|
77
|
+
|
|
78
|
+
**Scientific method:**
|
|
79
|
+
|
|
80
|
+
1. **Form Single Hypothesis**
|
|
81
|
+
- State clearly: "I think X is the root cause because Y"
|
|
82
|
+
- Write it down
|
|
83
|
+
- Be specific, not vague
|
|
84
|
+
|
|
85
|
+
2. **Test Minimally**
|
|
86
|
+
- Make the SMALLEST possible change to test hypothesis
|
|
87
|
+
- One variable at a time
|
|
88
|
+
- Don't fix multiple things at once
|
|
89
|
+
|
|
90
|
+
3. **Verify Before Continuing**
|
|
91
|
+
|
|
92
|
+
### Phase 4: Implementation
|
|
93
|
+
|
|
94
|
+
**Fix the root cause, not the symptom:**
|
|
95
|
+
|
|
96
|
+
1. **Create Failing Test Case**
|
|
97
|
+
- Simplest possible reproduction
|
|
98
|
+
- Automated test if possible
|
|
99
|
+
- One-off test script if no framework
|
|
100
|
+
- MUST have before fixing
|
|
101
|
+
- Use the `superpowers:test-driven-development` skill for writing proper failing tests
|
|
102
|
+
|
|
103
|
+
2. **Implement Single Fix**
|
|
104
|
+
- Address the root cause identified
|
|
105
|
+
- ONE change at a time
|
|
106
|
+
- No "while I'm here" improvements
|
|
107
|
+
|
|
108
|
+
## Red Flags - STOP and Follow Process
|
|
109
|
+
|
|
110
|
+
If you catch yourself thinking:
|
|
111
|
+
- "Quick fix for now, investigate later"
|
|
112
|
+
- "Just try changing X and see if it works"
|
|
113
|
+
- "Add multiple changes, run tests"
|
|
114
|
+
- "Skip the test, I'll manually verify"
|
|
115
|
+
- "It's probably X, let me fix that"
|
|
116
|
+
- "I don't fully understand but this might work"
|
|
117
|
+
- "Pattern says X but I'll adapt it differently"
|
|
118
|
+
|
|
119
|
+
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: team
|
|
3
|
+
description: N coordinated agents on shared task list using Claude Code native teams
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Team Skill
|
|
7
|
+
|
|
8
|
+
Spawn N coordinated agents working on a shared task list using Claude Code's native team tools. Replaces the legacy `/swarm` skill (SQLite-based) with built-in team management, inter-agent messaging, and task dependencies -- no external dependencies required.
|
|
9
|
+
|
|
10
|
+
The `swarm` compatibility alias was removed in #1131.
|
|
11
|
+
|
|
12
|
+
## Usage
|
|
13
|
+
|
|
14
|
+
```
|
|
15
|
+
team N:agent-type "task description"
|
|
16
|
+
team "task description"
|
|
17
|
+
team ralph "task description"
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
### Parameters
|
|
21
|
+
|
|
22
|
+
- **N** - Number of teammate agents (1-20). Optional; defaults to auto-sizing based on task decomposition.
|
|
23
|
+
- **agent-type** - OMC agent to spawn for the `team-exec` stage (e.g., executor, debugger, designer, codex, gemini). Optional; defaults to stage-aware routing. Use `codex` to spawn Codex CLI workers or `gemini` for Gemini CLI workers (requires respective CLIs installed). See Stage Agent Routing below.
|
|
24
|
+
- **task** - High-level task to decompose and distribute among teammates
|
|
25
|
+
- **ralph** - Optional modifier. When present, wraps the team pipeline in Ralph's persistence loop (retry on failure, architect verification before completion). See Team + Ralph Composition below.
|
|
26
|
+
|
|
27
|
+
### Examples
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
/team 5:executor "fix all TypeScript errors across the project"
|
|
31
|
+
/team 3:debugger "fix build errors in src/"
|
|
32
|
+
/team 4:designer "implement responsive layouts for all page components"
|
|
33
|
+
/team "refactor the auth module with security review"
|
|
34
|
+
/team ralph "build a complete REST API for user management"
|
|
35
|
+
# With Codex CLI workers (requires: npm install -g @openai/codex)
|
|
36
|
+
/team 2:codex "review architecture and suggest improvements"
|
|
37
|
+
# With Gemini CLI workers (requires: npm install -g @google/gemini-cli)
|
|
38
|
+
/team 2:gemini "redesign the UI components"
|
|
39
|
+
# Mixed: Codex for backend analysis, Gemini for frontend (use /ccg instead for this)
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## Architecture
|
|
43
|
+
|
|
44
|
+
```
|
|
45
|
+
User: "/team 3:executor fix all TypeScript errors"
|
|
46
|
+
|
|
|
47
|
+
v
|
|
48
|
+
[TEAM ORCHESTRATOR (Lead)]
|
|
49
|
+
|
|
|
50
|
+
+-- TeamCreate("fix-ts-errors")
|
|
51
|
+
| -> lead becomes team-lead@fix-ts-errors
|
|
52
|
+
|
|
|
53
|
+
+-- Analyze & decompose task into subtasks
|
|
54
|
+
| -> explore/architect produces subtask list
|
|
55
|
+
|
|
|
56
|
+
+-- TaskCreate x N (one per subtask)
|
|
57
|
+
| -> tasks #1, #2, #3 with dependencies
|
|
58
|
+
|
|
|
59
|
+
+-- TaskUpdate x N (pre-assign owners)
|
|
60
|
+
| -> task #1 owner=worker-1, etc.
|
|
61
|
+
|
|
|
62
|
+
+-- Task(team_name="fix-ts-errors", name="worker-1") x 3
|
|
63
|
+
| -> spawns teammates into the team
|
|
64
|
+
|
|
|
65
|
+
+-- Monitor loop
|
|
66
|
+
| <- SendMessage from teammates (auto-delivered)
|
|
67
|
+
| -> TaskList polling for progress
|
|
68
|
+
| -> SendMessage to unblock/coordinate
|
|
69
|
+
|
|
|
70
|
+
+-- Completion
|
|
71
|
+
-> SendMessage(shutdown_request) to each teammate
|
|
72
|
+
<- SendMessage(shutdown_response, approve: true)
|
|
73
|
+
-> TeamDelete("fix-ts-errors")
|
|
74
|
+
-> rm .omc/state/team-state.json
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
**Storage layout (managed by Claude Code):**
|
|
78
|
+
```
|
|
79
|
+
~/.claude/
|
|
80
|
+
teams/fix-ts-errors/
|
|
81
|
+
config.json # Team metadata + members array
|
|
82
|
+
tasks/fix-ts-errors/
|
|
83
|
+
.lock # File lock for concurrent access
|
|
84
|
+
1.json # Subtask #1
|
|
85
|
+
```
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: test-driven-development
|
|
3
|
+
description: Use when implementing any feature or bugfix, before writing implementation code
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Test-Driven Development (TDD)
|
|
7
|
+
|
|
8
|
+
## Overview
|
|
9
|
+
|
|
10
|
+
Write the test first. Watch it fail. Write minimal code to pass.
|
|
11
|
+
|
|
12
|
+
**Core principle:** If you didn't watch the test fail, you don't know if it tests the right thing.
|
|
13
|
+
|
|
14
|
+
**Violating the letter of the rules is violating the spirit of the rules.**
|
|
15
|
+
|
|
16
|
+
## When to Use
|
|
17
|
+
|
|
18
|
+
**Always:**
|
|
19
|
+
- New features
|
|
20
|
+
- Bug fixes
|
|
21
|
+
- Refactoring
|
|
22
|
+
- Behavior changes
|
|
23
|
+
|
|
24
|
+
**Exceptions (ask your human partner):**
|
|
25
|
+
- Throwaway prototypes
|
|
26
|
+
- Generated code
|
|
27
|
+
- Configuration files
|
|
28
|
+
|
|
29
|
+
Thinking "skip TDD just this once"? Stop. That's rationalization.
|
|
30
|
+
|
|
31
|
+
## The Iron Law
|
|
32
|
+
|
|
33
|
+
```
|
|
34
|
+
NO PRODUCTION CODE WITHOUT A FAILING TEST FIRST
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
Write code before the test? Delete it. Start over.
|
|
38
|
+
|
|
39
|
+
**No exceptions:**
|
|
40
|
+
- Don't keep it as "reference"
|
|
41
|
+
- Don't "adapt" it while writing tests
|
|
42
|
+
- Don't look at it
|
|
43
|
+
- Delete means delete
|
|
44
|
+
|
|
45
|
+
Implement fresh from tests. Period.
|
|
46
|
+
|
|
47
|
+
## Red-Green-Refactor
|
|
48
|
+
|
|
49
|
+
```dot
|
|
50
|
+
digraph tdd_cycle {
|
|
51
|
+
rankdir=LR;
|
|
52
|
+
red [label="RED\nWrite failing test", shape=box, style=filled, fillcolor="#ffcccc"];
|
|
53
|
+
verify_red [label="Verify fails\ncorrectly", shape=diamond];
|
|
54
|
+
green [label="GREEN\nMinimal code", shape=box, style=filled, fillcolor="#ccffcc"];
|
|
55
|
+
verify_green [label="Verify passes\nAll green", shape=diamond];
|
|
56
|
+
refactor [label="REFACTOR\nClean up", shape=box, style=filled, fillcolor="#ccccff"];
|
|
57
|
+
next [label="Next", shape=ellipse];
|
|
58
|
+
|
|
59
|
+
red -> verify_red;
|
|
60
|
+
verify_red -> green [label="yes"];
|
|
61
|
+
verify_red -> red [label="wrong\nfailure"];
|
|
62
|
+
|
|
63
|
+
### RED - Write Failing Test
|
|
64
|
+
|
|
65
|
+
Write one minimal test showing what should happen.
|
|
66
|
+
|
|
67
|
+
```typescript
|
|
68
|
+
test('retries failed operations 3 times', async () => {
|
|
69
|
+
let attempts = 0;
|
|
70
|
+
const operation = () => {
|
|
71
|
+
attempts++;
|
|
72
|
+
if (attempts < 3) throw new Error('fail');
|
|
73
|
+
return 'success';
|
|
74
|
+
};
|
|
75
|
+
|
|
76
|
+
const result = await retryOperation(operation);
|
|
77
|
+
|
|
78
|
+
### Verify RED - Watch It Fail
|
|
79
|
+
|
|
80
|
+
**MANDATORY. Never skip.**
|
|
81
|
+
|
|
82
|
+
```bash
|
|
83
|
+
npm test path/to/test.test.ts
|
|
84
|
+
```
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: tiledbvcf
|
|
3
|
+
description: Efficient storage and retrieval of genomic variant data using TileDB. Scalable VCF/BCF ingestion, incremental sample addition, compressed storage, parallel queries, and export capabilities for population genomics.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# TileDB-VCF
|
|
7
|
+
|
|
8
|
+
## Overview
|
|
9
|
+
|
|
10
|
+
TileDB-VCF is a high-performance C++ library with Python and CLI interfaces for efficient storage and retrieval of genomic variant-call data. Built on TileDB's sparse array technology, it enables scalable ingestion of VCF/BCF files, incremental sample addition without expensive merging operations, and efficient parallel queries of variant data stored locally or in the cloud.
|
|
11
|
+
|
|
12
|
+
## When to Use This Skill
|
|
13
|
+
|
|
14
|
+
This skill should be used when:
|
|
15
|
+
- Learning TileDB-VCF concepts and workflows
|
|
16
|
+
- Prototyping genomics analyses and pipelines
|
|
17
|
+
- Working with small-to-medium datasets (< 1000 samples)
|
|
18
|
+
- Need incremental addition of new samples to existing datasets
|
|
19
|
+
- Require efficient querying of specific genomic regions across many samples
|
|
20
|
+
- Working with cloud-stored variant data (S3, Azure, GCS)
|
|
21
|
+
- Need to export subsets of large VCF datasets
|
|
22
|
+
- Building variant databases for cohort studies
|
|
23
|
+
- Educational projects and method development
|
|
24
|
+
- Performance is critical for variant data operations
|
|
25
|
+
|
|
26
|
+
## Quick Start
|
|
27
|
+
|
|
28
|
+
# Enter the following two lines if you are on a M1 Mac
|
|
29
|
+
CONDA_SUBDIR=osx-64
|
|
30
|
+
conda config --env --set subdir osx-64
|
|
31
|
+
|
|
32
|
+
# Create the conda environment
|
|
33
|
+
conda create -n tiledb-vcf "python<3.10"
|
|
34
|
+
conda activate tiledb-vcf
|
|
35
|
+
|
|
36
|
+
# Mamba is a faster and more reliable alternative to conda
|
|
37
|
+
conda install -c conda-forge mamba
|
|
38
|
+
|
|
39
|
+
### Basic Examples
|
|
40
|
+
|
|
41
|
+
**Create and populate a dataset:**
|
|
42
|
+
```python
|
|
43
|
+
import tiledbvcf
|
|
44
|
+
|
|
45
|
+
# Create a new dataset
|
|
46
|
+
ds = tiledbvcf.Dataset(uri="my_dataset", mode="w",
|
|
47
|
+
cfg=tiledbvcf.ReadConfig(memory_budget=1024))
|
|
48
|
+
|
|
49
|
+
# Ingest VCF files (must be single-sample with indexes)
|
|
50
|
+
# Requirements:
|
|
51
|
+
# - VCFs must be single-sample (not multi-sample)
|
|
52
|
+
# - Must have indexes: .csi (bcftools) or .tbi (tabix)
|
|
53
|
+
ds.ingest_samples(["sample1.vcf.gz", "sample2.vcf.gz"])
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
**Query variant data:**
|
|
57
|
+
```python
|
|
58
|
+
# Open existing dataset for reading
|
|
59
|
+
ds = tiledbvcf.Dataset(uri="my_dataset", mode="r")
|
|
60
|
+
|
|
61
|
+
# Query specific regions and samples
|
|
62
|
+
df = ds.read(
|
|
63
|
+
attrs=["sample_name", "pos_start", "pos_end", "alleles", "fmt_GT"],
|
|
64
|
+
regions=["chr1:1000000-2000000", "chr2:500000-1500000"],
|
|
65
|
+
samples=["sample1", "sample2", "sample3"]
|
|
66
|
+
)
|
|
67
|
+
print(df.head())
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
**Export to VCF:**
|
|
71
|
+
```python
|
|
72
|
+
import os
|
|
73
|
+
|
|
74
|
+
# Export two VCF samples
|
|
75
|
+
ds.export(
|
|
76
|
+
regions=["chr21:8220186-8405573"],
|
|
77
|
+
samples=["HG00101", "HG00097"],
|
|
78
|
+
output_format="v",
|
|
79
|
+
output_dir=os.path.expanduser("~"),
|
|
80
|
+
)
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
## Core Capabilities
|
|
84
|
+
|
|
85
|
+
### 1. Dataset Creation and Ingestion
|
|
86
|
+
|
|
87
|
+
Create TileDB-VCF datasets and incrementally ingest variant data from multiple VCF/BCF files. This is appropriate for building population genomics databases and cohort studies.
|
|
88
|
+
|
|
89
|
+
**Requirements:**
|
|
90
|
+
- **Single-sample VCFs only**: Multi-sample VCFs are not supported
|
|
91
|
+
- **Index files required**: VCF/BCF files must have indexes (.csi or .tbi)
|
|
92
|
+
|
|
93
|
+
**Common operations:**
|
|
94
|
+
- Create new datasets with optimized array schemas
|
|
95
|
+
- Ingest single or multiple VCF/BCF files in parallel
|
|
96
|
+
- Add new samples incrementally without re-processing existing data
|
|
97
|
+
- Configure memory usage and compression settings
|
|
98
|
+
- Handle various VCF formats and INFO/FORMAT fields
|
|
99
|
+
- Resume interrupted ingestion processes
|
|
100
|
+
- Validate data integrity during ingestion
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
### 2. Efficient Querying and Filtering
|
|
104
|
+
|
|
105
|
+
Query variant data with high performance across genomic regions, samples, and variant attributes. This is appropriate for association studies, variant discovery, and population analysis.
|
|
106
|
+
|
|
107
|
+
**Common operations:**
|
|
108
|
+
- Query specific genomic regions (single or multiple)
|
|
109
|
+
- Filter by sample names or sample groups
|
|
110
|
+
- Extract specific variant attributes (position, alleles, genotypes, quality)
|
|
111
|
+
- Access INFO and FORMAT fields efficiently
|
|
112
|
+
- Combine spatial and attribute-based filtering
|
|
113
|
+
- Stream large query results
|
|
114
|
+
- Perform aggregations across samples or regions
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
### 3. Data Export and Interoperability
|
|
118
|
+
|
|
119
|
+
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: timeline-report
|
|
3
|
+
description: Generate a "Journey Into [Project]" narrative report analyzing a project's entire development history from claude-mem's timeline. Use when asked for a timeline report, project history analysis, development journey, or full project report.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Timeline Report
|
|
7
|
+
|
|
8
|
+
Generate a comprehensive narrative analysis of a project's entire development history using claude-mem's persistent memory timeline.
|
|
9
|
+
|
|
10
|
+
## When to Use
|
|
11
|
+
|
|
12
|
+
Use when users ask for:
|
|
13
|
+
|
|
14
|
+
- "Write a timeline report"
|
|
15
|
+
- "Journey into [project]"
|
|
16
|
+
- "Analyze my project history"
|
|
17
|
+
- "Full project report"
|
|
18
|
+
- "Summarize the entire development history"
|
|
19
|
+
- "What's the story of this project?"
|
|
20
|
+
|
|
21
|
+
## Prerequisites
|
|
22
|
+
|
|
23
|
+
The claude-mem worker must be running. The project must have claude-mem observations recorded.
|
|
24
|
+
|
|
25
|
+
**Resolve the worker port** (do this once at the start and reuse `$WORKER_PORT` in every curl call below):
|
|
26
|
+
|
|
27
|
+
```bash
|
|
28
|
+
WORKER_PORT="${CLAUDE_MEM_WORKER_PORT:-$(node -e "const fs=require('fs'),p=require('path'),os=require('os');const uid=(typeof process.getuid==='function'?process.getuid():77);const fallback=String(37700+(uid%100));try{const s=JSON.parse(fs.readFileSync(p.join(os.homedir(),'.claude-mem','settings.json'),'utf-8'));process.stdout.write(String(s.CLAUDE_MEM_WORKER_PORT||fallback));}catch{process.stdout.write(fallback);}" 2>/dev/null)}"
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
This honors `CLAUDE_MEM_WORKER_PORT` env, then `~/.claude-mem/settings.json`, then falls back to the per-UID default `37700 + (uid % 100)` — matching how the worker itself picks its port. Required for multi-account setups (#2101) and any user who has overridden the default port (#2103).
|
|
32
|
+
|
|
33
|
+
## Workflow
|
|
34
|
+
|
|
35
|
+
### Step 1: Determine the Project Name
|
|
36
|
+
|
|
37
|
+
Ask the user which project to analyze if not obvious from context. The project name is typically the directory name of the project (e.g., "tokyo", "my-app"). If the user says "this project", use the current working directory's basename.
|
|
38
|
+
|
|
39
|
+
**Worktree Detection:** Before using the directory basename, check if the current directory is a git worktree. In a worktree, the data source is the **parent project**, not the worktree directory itself. Run:
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
git_dir=$(git rev-parse --git-dir 2>/dev/null)
|
|
43
|
+
git_common_dir=$(git rev-parse --git-common-dir 2>/dev/null)
|
|
44
|
+
if [ "$git_dir" != "$git_common_dir" ]; then
|
|
45
|
+
# We're in a worktree — resolve the parent project name
|
|
46
|
+
parent_project=$(basename "$(dirname "$git_common_dir")")
|
|
47
|
+
echo "Worktree detected. Parent project: $parent_project"
|
|
48
|
+
else
|
|
49
|
+
parent_project=$(basename "$PWD")
|
|
50
|
+
|
|
51
|
+
### Step 2: Fetch the Full Timeline
|
|
52
|
+
|
|
53
|
+
Use Bash to fetch the complete timeline from the claude-mem worker API:
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
curl -s "http://localhost:${WORKER_PORT}/api/context/inject?project=PROJECT_NAME&full=true"
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
This returns the entire compressed timeline -- every observation, session boundary, and summary across the project's full history. The response is pre-formatted markdown optimized for LLM consumption.
|
|
60
|
+
|
|
61
|
+
**Token estimates:** The full timeline size depends on the project's history:
|
|
62
|
+
- Small project (< 1,000 observations): ~20-50K tokens
|
|
63
|
+
- Medium project (1,000-10,000 observations): ~50-300K tokens
|
|
64
|
+
- Large project (10,000-35,000 observations): ~300-750K tokens
|
|
65
|
+
|
|
66
|
+
If the response is empty or returns an error, the worker may not be running or the project name may be wrong. Try `curl -s "http://localhost:${WORKER_PORT}/api/search?query=*&limit=1"` to verify the worker is healthy.
|
|
67
|
+
|
|
68
|
+
### Step 3: Estimate Token Count
|
|
69
|
+
|
|
70
|
+
Before proceeding, estimate the token count of the fetched timeline (roughly 1 token per 4 characters). Report this to the user:
|
|
71
|
+
|
|
72
|
+
```
|
|
73
|
+
Timeline fetched: ~X observations, estimated ~Yk tokens.
|
|
74
|
+
This analysis will consume approximately Yk input tokens + ~5-10k output tokens.
|
|
75
|
+
Proceed? (y/n)
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
Wait for user confirmation before continuing if the timeline exceeds 100K tokens.
|
|
79
|
+
|
|
80
|
+
### Step 4: Analyze with a Subagent
|
|
81
|
+
|
|
82
|
+
Deploy an Agent (using the Task tool) with the full timeline and the following analysis prompt. Pass the ENTIRE timeline as context to the agent. The agent should also be instructed to query the SQLite database at `~/.claude-mem/claude-mem.db` for the Token Economics section.
|
|
83
|
+
|
|
84
|
+
**Agent prompt:**
|
|
85
|
+
```
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: timesfm-forecasting
|
|
3
|
+
description: Zero-shot time series forecasting with Google's TimesFM foundation model. Use for any univariate time series (sales, sensors, energy, vitals, weather) without training a custom model. Supports CSV/DataFrame/array inputs with point forecasts and prediction intervals. Includes a preflight system checker script to verify RAM/GPU before first use.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# TimesFM Forecasting
|
|
7
|
+
|
|
8
|
+
## Overview
|
|
9
|
+
|
|
10
|
+
TimesFM (Time Series Foundation Model) is a pretrained decoder-only foundation model
|
|
11
|
+
developed by Google Research for time-series forecasting. It works **zero-shot** — feed it
|
|
12
|
+
any univariate time series and it returns point forecasts with calibrated quantile
|
|
13
|
+
prediction intervals, no training required.
|
|
14
|
+
|
|
15
|
+
This skill wraps TimesFM for safe, agent-friendly local inference. It includes a
|
|
16
|
+
**mandatory preflight system checker** that verifies RAM, GPU memory, and disk space
|
|
17
|
+
before the model is ever loaded so the agent never crashes a user's machine.
|
|
18
|
+
|
|
19
|
+
> **Key numbers**: TimesFM 2.5 uses 200M parameters (~800 MB on disk, ~1.5 GB in RAM on
|
|
20
|
+
> CPU, ~1 GB VRAM on GPU). The archived v1/v2 500M-parameter model needs ~32 GB RAM.
|
|
21
|
+
> Always run the system checker first.
|
|
22
|
+
|
|
23
|
+
## When to Use This Skill
|
|
24
|
+
|
|
25
|
+
Use this skill when:
|
|
26
|
+
|
|
27
|
+
- Forecasting **any univariate time series** (sales, demand, sensor, vitals, price, weather)
|
|
28
|
+
- You need **zero-shot forecasting** without training a custom model
|
|
29
|
+
- You want **probabilistic forecasts** with calibrated prediction intervals (quantiles)
|
|
30
|
+
- You have time series of **any length** (the model handles 1–16,384 context points)
|
|
31
|
+
- You need to **batch-forecast** hundreds or thousands of series efficiently
|
|
32
|
+
- You want a **foundation model** approach instead of hand-tuning ARIMA/ETS parameters
|
|
33
|
+
|
|
34
|
+
Do **not** use this skill when:
|
|
35
|
+
|
|
36
|
+
- You need classical statistical models with coefficient interpretation → use `statsmodels`
|
|
37
|
+
- You need time series classification or clustering → use `aeon`
|
|
38
|
+
|
|
39
|
+
## ⚠️ Mandatory Preflight: System Requirements Check
|
|
40
|
+
|
|
41
|
+
**CRITICAL — ALWAYS run the system checker before loading the model for the first time.**
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
python scripts/check_system.py
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
This script checks:
|
|
48
|
+
|
|
49
|
+
1. **Available RAM** — warns if below 4 GB, blocks if below 2 GB
|
|
50
|
+
2. **GPU availability** — detects CUDA/MPS devices and VRAM
|
|
51
|
+
3. **Disk space** — verifies room for the ~800 MB model download
|
|
52
|
+
4. **Python version** — requires 3.10+
|
|
53
|
+
5. **Existing installation** — checks if `timesfm` and `torch` are installed
|
|
54
|
+
|
|
55
|
+
### Hardware Requirements by Model Version
|
|
56
|
+
|
|
57
|
+
| Model | Parameters | RAM (CPU) | VRAM (GPU) | Disk | Context |
|
|
58
|
+
| ----- | ---------- | --------- | ---------- | ---- | ------- |
|
|
59
|
+
| **TimesFM 2.5** (recommended) | 200M | ≥ 4 GB | ≥ 2 GB | ~800 MB | up to 16,384 |
|
|
60
|
+
| TimesFM 2.0 (archived) | 500M | ≥ 16 GB | ≥ 8 GB | ~2 GB | up to 2,048 |
|
|
61
|
+
| TimesFM 1.0 (archived) | 200M | ≥ 8 GB | ≥ 4 GB | ~800 MB | up to 2,048 |
|
|
62
|
+
|
|
63
|
+
> **Recommendation**: Always use TimesFM 2.5 unless you have a specific reason to use an
|
|
64
|
+
> older checkpoint. It is smaller, faster, and supports 8× longer context.
|
|
65
|
+
|
|
66
|
+
### Step 1: Verify System (always first)
|
|
67
|
+
|
|
68
|
+
```bash
|
|
69
|
+
python scripts/check_system.py
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
# Using uv (recommended by this repo)
|
|
73
|
+
uv pip install timesfm[torch]
|
|
74
|
+
|
|
75
|
+
# Or using pip
|
|
76
|
+
pip install timesfm[torch]
|
|
77
|
+
|
|
78
|
+
# For JAX/Flax backend (faster on TPU/GPU)
|
|
79
|
+
uv pip install timesfm[flax]
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
# CUDA 12.1 (NVIDIA GPU)
|
|
83
|
+
pip install torch>=2.0.0 --index-url https://download.pytorch.org/whl/cu121
|
|
84
|
+
|
|
85
|
+
# CPU only
|
|
86
|
+
pip install torch>=2.0.0 --index-url https://download.pytorch.org/whl/cpu
|
|
87
|
+
|
|
88
|
+
# Apple Silicon (MPS)
|
|
89
|
+
pip install torch>=2.0.0 # MPS support is built-in
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
## 🎯 Quick Start
|
|
93
|
+
|
|
94
|
+
### Minimal Example (5 Lines)
|
|
95
|
+
|
|
96
|
+
```python
|
|
97
|
+
import torch, numpy as np, timesfm
|
|
98
|
+
|
|
99
|
+
torch.set_float32_matmul_precision("high")
|
|
100
|
+
|
|
101
|
+
model = timesfm.TimesFM_2p5_200M_torch.from_pretrained(
|
|
102
|
+
"google/timesfm-2.5-200m-pytorch"
|
|
103
|
+
)
|
|
104
|
+
model.compile(timesfm.ForecastConfig(
|
|
105
|
+
max_context=1024, max_horizon=256, normalize_inputs=True,
|
|
106
|
+
use_continuous_quantile_head=True, force_flip_invariance=True,
|
|
107
|
+
infer_is_positive=True, fix_quantile_crossing=True,
|
|
108
|
+
))
|
|
109
|
+
|
|
110
|
+
# point.shape == (1, 24) — median forecast
|
|
111
|
+
# quantiles.shape == (1, 24, 10) — 10th–90th percentile bands
|
|
112
|
+
```
|