builder
Use this RAGs sub-skill to build a Streamlit RAG agent from files, directories, URLs, optional web search, model settings, and RAG parameters.
- License 许可
- MIT
- 最近更新
- 2026-09-03
- Stars
- ★ 351
- Forks
- 27
01 前言 Front Matter
- name
- builder
- license
- MIT
- metadata
- { "disco-role": "operating" }
- description
- Use this RAGs sub-skill to build a Streamlit RAG agent from files, directories, URLs, optional web search, model settings, and RAG parameters.
- disable-model-invocation
- true
02 资源文件 4
- 参考文档references/api-reference.md4.2 KB
- 参考文档references/troubleshooting.md3.5 KB
- 参考文档references/workflows.md4.5 KB
- 脚本scripts/validate_source_selection.py3.7 KB
03 SKILL.md 正文
RAGs Builder
Use this sub-skill when the task is to create a new RAGs bot, diagnose the Home page builder flow, or use the builder APIs directly. RAGs is a Streamlit app that asks a builder agent to create a retrieval-augmented chat agent over a single data source.
Read This When
- The user wants to build a RAG bot from local files, one directory, or URLs.
- The task mentions the Home page, builder agent, task description, system
prompt generation,
RAGAgentBuilder, orRAGParams. - The user needs to choose
top_k,chunk_size, embedding model, LLM provider, summarization, or optionalweb_search. - The user asks why source loading, OpenAI secrets, web search, or multimodal setup fails before the agent exists.
If the bot already exists and the user wants to edit or delete it, read
../configuration/SKILL.md. If the user wants to
ask questions to an existing bot, read ../chat/SKILL.md.
Core Workflow
- Confirm dependencies and secrets first. The app expects a Streamlit secret
named
openai_key; provider-specific keys are needed only for their routes. - Validate the data-source choice with
scripts/validate_source_selection.pybefore invoking builder logic. RAGs accepts exactly one source kind: local files, one directory, or URLs. - Use the builder conversation to collect the task description and let the builder create the system prompt.
- Load data, inspect or set RAG parameters, optionally add
web_searchwhen ametaphor_keysecret is configured, then create the agent. - After creation, route to the configuration and chat sub-skills for later editing and querying.
For detailed step-by-step routes, model identifiers, data-source rules, and
validation checks, read references/workflows.md.
For signatures and defaults verified from the package inspection environment,
read references/api-reference.md.
For failure symptoms and fixes, read
references/troubleshooting.md.
Important Operating Facts
RAGParamsdefaults areinclude_summarization=False,top_k=2,chunk_size=1024,embed_model="default", andllm="gpt-4-1106-preview".load_datarequires exactly one offile_names,directory, orurlsand raises aValueErrorwhen zero or multiple source kinds are supplied.- Unprefixed LLM names are treated as OpenAI models. Recognized prefixes are
openai:,anthropic:,replicate:, andlocal:. - The web-search tool is only exposed when a
metaphor_keyStreamlit secret is present, and its tool name isweb_search. - The beta multimodal builder path is optional. The minimum verified environment imported multimodal classes but did not install the torch, torchvision, or CLIP runtime stack and did not run external model calls.
Boundaries
Do not claim that a full OpenAI, Anthropic, Replicate, Metaphor, URL-loading, or multimodal chat call was verified unless the user supplies credentials/network and asks for that execution. For safe checks, use the bundled validator and the root installation diagnostic instead of launching a long-running Streamlit server.
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).