Saltar al contenido
Skillpedia
Análisis y hojas de cálculo16 mil · #10817

wiki-retrieve

Qué hace

Esta skill crea un índice de búsqueda de tu wiki y devuelve los pasajes más relevantes para una pregunta. Está pensada para personas con muchas notas que quieren búsquedas rápidas y precisas.

Cuándo usarla

  • ✓Cuando tu wiki es grande y quieres encontrar pasajes relevantes para una pregunta.
  • ✓Cuando quieres crear o actualizar el índice de búsqueda local de tu bóveda.
  • ✓Cuando necesitas diagnosticar por qué una búsqueda devuelve los resultados que devuelve.

Link de la skill

https://github.com/AgriciDaniel/claude-obsidian/blob/main/skills/wiki-retrieve/SKILL.md

Cópialo y pégalo en tu IA (Claude, ChatGPT o Cursor) pidiéndole que siga las instrucciones.

Cómo usar

La forma más fácil: copia el mensaje y pégalo en tu IA. Ella lee la skill y sigue las instrucciones.

Mensaje listo para pegar

Usa esta skill para ayudarme: https://github.com/AgriciDaniel/claude-obsidian/blob/main/skills/wiki-retrieve/SKILL.md Lee el archivo SKILL.md de ese link y sigue sus instrucciones en mi tarea.
¿Quieres que tu IA encuentre skills como esta por sí sola?Instala el MCP gratis de Skillpedia: una línea, y busca entre 15.000+ skills antes de cada tarea.Instalar en 1 minuto →

Ejemplo de qué pedirle a la IA

“Crea un índice de búsqueda para mi wiki y encuentra los pasajes sobre nuestro proceso de contratación.”

5 skills nuevas por semana. 1 minuto de lectura.

Cómo funciona

El agente divide tus páginas en fragmentos, construye un índice de palabras clave en este ordenador y devuelve los fragmentos que mejor coinciden con sus páginas. Cualquier procesamiento remoto necesita tu consentimiento explícito.

Contenido técnico (SKILL.md original)

Texto original del autor, en inglés, directo de GitHub.

Retrieve relevant passages

This extension derives search data from wiki/ into .vault-meta/. It never changes canonical notes. Always pass the selected vault explicitly.

Resolve the installed product root from this skill's own location, not from the vault or current working directory:

PRODUCT_ROOT=/absolute/path/to/installed/claude-obsidian
PREFIX="$PRODUCT_ROOT/scripts/contextual-prefix.py"
BM25="$PRODUCT_ROOT/scripts/bm25-index.py"
RETRIEVE="$PRODUCT_ROOT/scripts/retrieve.py"
RERANK="$PRODUCT_ROOT/scripts/rerank.py"
test -f "$PREFIX" && test -f "$BM25" && test -f "$RETRIEVE" && test -f "$RERANK"

Pipeline

  1. contextual-prefix.py splits pages on paragraph boundaries and stores the raw chunk plus a short page-level prefix.
  2. bm25-index.py builds a local, standard-library BM25 index over the contextualized text.
  3. retrieve.py selects BM25 candidates, optionally reranks them, rejects invalid records, deduplicates by page, and returns paths and snippets.
  4. The caller reads the returned pages and performs synthesis; retrieval output is not itself evidence.

Provision locally

Preview first, then build synthetic prefixes without network egress:

python3 "$PREFIX" --vault "$VAULT" --all --no-llm --peek
python3 "$PREFIX" --vault "$VAULT" --all --no-llm
python3 "$BM25" --vault "$VAULT" build
python3 "$RETRIEVE" --vault "$VAULT" "wiki" --top 1 --no-rerank --explain

Chunk and index files are disposable runtime state. Incremental prefixing skips records whose chunk hashes, page hashes and provider/model profile still match. Legacy records without that profile regenerate on an explicit build. A complete scan removes surplus records for deleted pages, and the prefixer invalidates the BM25 index before changing its chunk set so a mixed stale index is not served. Prefix and BM25 build operations share the vault-wide mutation lock with every other writer; a busy vault fails closed instead of publishing a partial index.

Contextual-prefix privacy

Synthetic prefixes use only local frontmatter and page text. The explicit Anthropic API profile can send page bodies off-machine and requires the user's consent plus --allow-egress and a configured API key. There is no Claude CLI generation tier or ambient subprocess fallback. Never infer consent from an API key or installed binary. Preview the scope first and state which provider will receive what data.

Remote Ollama endpoints also require explicit approval and --allow-remote-ollama; the default reranker accepts localhost only.

Local model prefixes are a separate explicit option. Use an already installed exact name:tag; no server is started and no model is installed or pulled:

python3 "$PREFIX" --vault "$VAULT" --all --local-ollama --ollama-model installed:tag --peek
python3 "$PREFIX" --vault "$VAULT" --all --local-ollama --ollama-model installed:tag

The prefix adapter verifies cloud-disabled server status and local model identity before sending page text. Unsupported or unavailable preflight falls back to synthetic prefixes for new or changed chunks only; prefixes from the same endpoint and model stay in place, so a transient outage leaves an unchanged vault's chunks and BM25 index untouched. This requirement can exclude older Ollama servers. Reranking and tiling use the same local-only proof before query, page, chunk, or embedding cache work. --allow-remote-ollama approves the endpoint, not cloud delegation by the server. See prefix providers for the exact policy, cloud model selection and verification limits. The reranker has its own model and endpoint policy; selecting local prefixes does not enable reranking.

Query

For a strictly read-only lookup, use the prebuilt BM25 index:

python3 "$RETRIEVE" --vault "$VAULT" "$QUERY" --top 5 --no-rerank --explain

For an explicitly requested rerank, omit --no-rerank. The default is Ollama's multilingual nomic-embed-text-v2-moe model (approximately 958 MB); the product never pulls it automatically. To use an already-installed, smaller, English-oriented v1.5 model, pass --model nomic-embed-text explicitly. Nomic models use search_query: for the query and search_document: for candidate text. Nomic v2 has a 512-token input context and Ollama truncates longer embedding inputs by default; BM25 still scores the complete chunk. Embeddings are cached by exact model, verified digest, input scheme, and hash of

Preguntas frecuentes

¿Envía mis notas a internet?

No, salvo que lo aceptes de forma explícita. El procesamiento remoto necesita tu consentimiento, y el índice se queda en tu ordenador en otro caso.

¿Cambia mis notas?

No. El índice se guarda como datos derivados y las notas canónicas no cambian.

¿Qué pasa si el paso de reordenación no está disponible?

La búsqueda vuelve al método más sencillo por palabras clave, así que los resultados se devuelven igualmente.

Detalles

Descripción original del autor

Build and query a vault-local contextual BM25 retrieval index with optional multilingual Nomic cosine reranking; use for retrieve, hybrid retrieval, BM25, rerank, contextual retrieval, chunk search, vault search, semantic search, find relevant passages, or retrieval diagnostics. Derived caches stay under .vault-meta, remote egress requires explicit consent, and unavailable reranking falls back deterministically.

repo: AgriciDaniel/claude-obsidian

Popularidad

Estrellas en GitHub
16 mil
Posición en el ranking
#10817
Licencia
MIT
Actualizada
25/10/2026

¿Te sirve esta skill?

0

Entra para votar.

Comentarios

  • …

Más skills de este repositorio

Skills parecidas