rag-and-acceleration
Operate CoRAG chain-of-retrieval augmented generation and LLMA reference-based lossless decoding workflows.
- License 许可
- MIT
- 最近更新
- 2026-09-03
- Stars
- ★ 351
- Forks
- 27
01 前言 Front Matter
- name
- rag-and-acceleration
- license
- MIT
- metadata
- { "disco-role": "operating" }
- description
- Operate CoRAG chain-of-retrieval augmented generation and LLMA reference-based lossless decoding workflows.
- disable-model-invocation
- true
02 资源文件 5
- 参考文档references/corag-workflows.md6.3 KB
- 参考文档references/llma-reference-decoding.md4.8 KB
- 参考文档references/troubleshooting.md4.9 KB
- 脚本scripts/corag_service_plan.py15.2 KB
- 脚本scripts/llma_overlap_demo.py8.1 KB
03 SKILL.md 正文
rag-and-acceleration
Use this sub-skill when the user asks about either of these LMOps workflow families:
- CoRAG: chain-of-retrieval augmented generation for multihop QA using an E5 search server, a vLLM OpenAI-compatible server, a CoRAG-tuned Llama model, and evaluation metrics.
- LLMA: reference-based lossless decoding acceleration when generated text overlaps retrieved documents, multi-turn context, or other reference passages.
Do not use this sub-skill for generic LLM serving, unrelated vLLM deployments, or in-context-example retriever training. Route retriever training, prompt pools, UPRISE, SE2, CED-ICL, and LLM Retriever work to ../example-retrieval/SKILL.md.
Operating route
- Classify the request:
- CoRAG service/evaluation orchestration: use
references/corag-workflows.md, then run the bundled plannerscripts/corag_service_plan.pyto produce a safe checklist before any external command is attempted. - LLMA acceleration fit, algorithm explanation, or small sanity check: use
references/llma-reference-decoding.md, then runscripts/llma_overlap_demo.pyon a tiny reference/target sample if the user needs an overlap demonstration. - Failures or ambiguous runtime symptoms: use
references/troubleshooting.mdfirst, then return to the relevant workflow reference.
- CoRAG service/evaluation orchestration: use
- Keep heavy operations explicit. CoRAG end-to-end inference expects model/data downloads, long-running servers, CUDA GPUs, and two occupied local ports. LLMA experiments expect converted LLaMA-family weights and a GPU for real model timing.
- Treat the bundled scripts as planning and demonstration utilities only. They do not download data, start servers, import repository code, load models, or run evaluation.
- For CoRAG, verify service order before evaluation: embeddings staged -> E5 server ready -> vLLM server ready with the intended model -> multihop QA inference.
- For LLMA, verify the lossless assumption: copied spans are only accepted after model verification. If references do not overlap likely generations, LLMA may add overhead rather than speed.
Bundled reference map
references/corag-workflows.md: CoRAG datasets/models, server order, ports/logs, inference flags, outputs, and metrics.references/llma-reference-decoding.md: LLMA algorithm, CLI parameters, data expectations, and fit criteria for RAG or multi-turn settings.references/troubleshooting.md: missing data/model/embeddings, E5/vLLM ordering, port/log issues, hardware notes, decode path length, metrics JSON, and reference-overlap assumptions.
Bundled scripts
scripts/corag_service_plan.py: prints a safe service/evaluation checklist and command concepts for CoRAG without executing anything.scripts/llma_overlap_demo.py: CPU-only toy demonstration of reference-overlap proposal and verification behavior without importing repository code.
Verification status
Creation-time verification for this sub-skill is static and CPU-only. End-to-end CoRAG server startup, model downloads, vLLM serving, E5 retrieval over full embeddings, and LLMA GPU timing are documented but not claimed as executed by this skill.
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).