serve-search
Use PixelRAG serve and search APIs for FAISS or Qdrant visual retrieval indexes.
- License 许可
- Apache-2.0
- 最近更新
- 2026-09-03
- Stars
- ★ 351
- Forks
- 27
01 前言 Front Matter
- name
- serve-search
- license
- Apache 2.0
- metadata
- { "disco-role": "operating" }
- description
- Use PixelRAG serve and search APIs for FAISS or Qdrant visual retrieval indexes.
- disable-model-invocation
- true
02 资源文件 4
- 参考文档references/api-reference.md2.8 KB
- 参考文档references/index-layout-and-backends.md2.4 KB
- 参考文档references/troubleshooting.md2.6 KB
- 脚本scripts/pixelrag_search_smoke.py2.4 KB
03 SKILL.md 正文
PixelRAG Serve Search
Use this sub-skill when the task is to run pixelrag serve, query a PixelRAG search endpoint, debug search results, choose FAISS/Qdrant serving options, or integrate PixelRAG search into an agent.
Start Here
-
Ensure an index exists. If not, use
../index-build/SKILL.md. -
Start the API:
pixelrag serve --index-dir ./index --articles-json ./index/articles.json --tiles-dir ./index/tiles --port 30001 -
Check readiness:
curl -s http://localhost:30001/health curl -s http://localhost:30001/status -
Query:
curl -s -X POST http://localhost:30001/search \ -H "Content-Type: application/json" \ -d '{"queries":[{"text":"overview diagram"}],"n_docs":5}'
Read or Run
- Read api-reference.md for request/response fields and endpoints.
- Read index-layout-and-backends.md for FAISS, Qdrant, tile paths, departments, and memory mapping.
- Read troubleshooting.md for server startup, backend, model, tile, and query errors.
- Run pixelrag_search_smoke.py to check
/health,/status, and optionally a text query.
Common Routes
| Request | Action |
|---|---|
| "Serve this local index" | Use pixelrag serve --index-dir ... --articles-json ... --tiles-dir .... |
| "Search and include tile images" | POST /search with include_images: true; watch payload size. |
| "Use Qdrant" | Start with --backend qdrant --qdrant-url ... --collection ..., or let summary.json infer backend. |
| "Filter by department" | Call /departments, then pass department in /search; departments come from local-source subdirectories. |
| "Use precomputed embeddings" | Send queries: [{"embedding": [...]}] and do not mix with text/image queries in the same request. |
| "Render missing tiles on demand" | Use --render-on-demand --kiwix-url ... for Kiwix-backed indexes; expect slower first queries. |
Safety Defaults
- Do not launch a long-running server without user approval in restricted sessions.
- Do not download models or indexes implicitly; serving loads the query encoder for text/image queries.
- Do not expose filesystem paths from server responses to end users; PixelRAG returns relative tile paths and
/tile/...endpoints. - Keep API keys for Qdrant Cloud or downstream agents in environment variables, not in generated notes.
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).