baleen-multihop
Optional ColBERT Baleen multi-hop retrieval extension: HopSearcher context search, Baleen engine loops, Condenser fact selection, collectionX format, and artifact caveats. Use when tasks mention Baleen, multi-hop retrieval, condensed retrieval, HopSearcher, Condenser, collectionX, or L1/L2 condenser checkpoints.
- License 许可
- MIT
- 最近更新
- 2026-09-03
- Stars
- ★ 351
- Forks
- 27
01 前言 Front Matter
- name
- baleen-multihop
- license
- MIT
- metadata
- { "disco-role": "operating" }
- description
- Optional ColBERT Baleen multi-hop retrieval extension: HopSearcher context search, Baleen engine loops, Condenser fact selection, collectionX format, and artifact caveats. Use when tasks mention Baleen, multi-hop retrieval, condensed retrieval, HopSearcher, Condenser, collectionX, or L1/L2 condenser checkpoints.
- disable-model-invocation
- true
02 资源文件 4
- 参考文档references/api-reference.md6.7 KB
- 参考文档references/baleen-workflows.md5.5 KB
- 参考文档references/troubleshooting.md5.7 KB
- 脚本scripts/inspect_baleen_imports.py7.8 KB
03 SKILL.md 正文
Baleen Multi-hop
Use this sub-skill for ColBERT's optional Baleen multi-hop retrieval components, not for ordinary one-hop ColBERT indexing or search. Baleen composes a ColBERT Searcher variant with an Electra-based Condenser to retrieve passages, select sentence-level facts, and feed those facts as context into later hops.
Route here when
- The user asks about Baleen, multi-hop retrieval, condensed retrieval, hop-aware search,
HopSearcher,Condenser,collectionX, or L1/L2 condenser checkpoints. - The code path involves
baleen.engine.Baleen,baleen.hop_searcher.HopSearcher,baleen.condenser.condense.Condenser,baleen.condenser.model.ElectraReader, orbaleen.condenser.tokenization.AnswerAwareTokenizer. - The user has, or needs to reason about, a built ColBERT index plus Baleen-specific sentence JSONL and condenser checkpoint artifacts.
- The safe answer is to inspect imports/signatures, explain prerequisites, plan an adaptation, or diagnose why a full Baleen run cannot be validated locally.
Route elsewhere when
- Use
indexing-and-searchfor normalIndexer,Searcher, collection TSVs, one-hop search, or ranking files. - Use
training-and-distillationfor training or fine-tuning ColBERT retriever checkpoints. - Use data/evaluation guidance for non-Baleen data conversion and metrics; keep only
collectionXsentence-format notes here. - Use modeling/tokenization guidance for ColBERT checkpoint internals unless the tokenizer issue is specifically Baleen's answer-aware condenser tokenizer.
Safe operating stance
Baleen is bundled as a research-style extension. Imports and source signatures can be inspected on CPU, but end-to-end multi-hop retrieval usually needs local ColBERT index artifacts, a retrieval checkpoint, two Baleen Electra reader checkpoints, a compatible sentence-level collectionX file, and often CUDA-capable devices. Do not promise full execution from package import success alone.
Start by confirming artifacts and device constraints. If the user is CPU-only or lacks checkpoints/data, run the import inspector, explain what is available, and provide a static adaptation plan rather than attempting retrieval.
Common actions
- Use
references/api-reference.mdwhen you need source-backed class/function behavior, signatures, and composition notes. - Use
references/baleen-workflows.mdwhen planning a safe multi-hop flow, validating artifact shape, or explaining how facts become context. - Use
references/troubleshooting.mdfor install/import, optional dependency, CUDA/device, checkpoint,collectionX, API misuse, and depth/hop failures. - Use
scripts/inspect_baleen_imports.pywhen you need deterministic import/signature diagnostics without loading checkpoints, building indexes, downloading datasets, or running retrieval.
Minimal diagnostic
From an environment where colbert-ai is installed and colbert is importable:
python scripts/inspect_baleen_imports.py --tiny-fixture
Add --json for machine-readable output. Treat a passing report as evidence that Baleen import surfaces and loader behavior are available, not as evidence that the user's checkpoints, GPU, index, or full multi-hop workflow will run.
04 同仓库更多 Skills
passnet-triton-opt
Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.
passnet-solve
END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.
passnet-skill
PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.
passnet-pattern-fusion
Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.
passnet-orchestrate
Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.
passnet-feedback
Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).