agentleFS
etalab-iaetalab-ia/skills/skills/.experimental/rag-search/SKILL.md

rag-search

Skill29 starsChanged 28 days agoMITView on GitHub

Rechercher dans une base de connaissances indexée. Utiliser quand l'utilisateur veut trouver des documents, effectuer une recherche sémantique, ou interroger un index de documents.

2 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 4 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Search the qmd index for relevant documents.

    line 13
  2. Distinctive:

    Should show your collection(s) with document counts.

    line 34
  3. Distinctive:

    When using this skill:

    line 109
  4. Distinctive:

    Run the search query

    line 111
  5. Very specific:

    Check collection exists: qmd status

    line 119
  6. Very specific:

    Verify embeddings generated: qmd embed

    line 120

≈ “Common” is an estimate: at least 1 in 5 of the 372,429 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

rag-search Skill

Search the qmd index for relevant documents. This skill uses qmd under the hood.

Prerequisites

  • qmd installed: bun install -g @tobilu/qmd
  • Collection set up: Use /rag-index first

Verify setup:

qmd status

Workflow

1. Verify Knowledge Base

qmd status

Should show your collection(s) with document counts.

2. Run Search

qmd query "<query>" --json

Examples:

qmd query "authentication flow" --json
qmd query "API design patterns" --json
qmd query "deployment process" --json

3. Present Results

Parse the JSON output and present:

  • Document path
  • Relevance score
  • Relevant excerpt

Arguments

ArgumentTypeDefaultDescription
querystringrequiredSearch query
modestringquerySearch mode: query, vsearch, search
limitint5Number of results
collectionstringallRestrict to specific collection

Search Modes

ModeDescription
querySemantic search (default)
vsearchVector search with scores
searchHybrid search

Examples

# Basic search
qmd query "authentication" --json

# Limit results
qmd query "API design" --limit 10 --json

# Search specific collection
qmd query "deployment" --collection api-docs --json

# Vector search with scores
qmd vsearch "configuration" --json

Output Format

JSON output structure:

{
  "results": [
    {
      "path": "docs/guide.md",
      "score": 0.89,
      "content": "..."
    }
  ]
}

Integration with Agents

When using this skill:

  1. Run the search query
  2. Parse JSON results
  3. Present top results with scores
  4. Optionally read full documents for deeper context

Troubleshooting

If no results:

  1. Check collection exists: qmd status
  2. Verify embeddings generated: qmd embed
  3. Try broader query terms

Provider-Specific Notes

qmd (current)

  • Storage: Local SQLite with sqlite-vec extension
  • Embeddings: Local model (no API key required)
  • Best for: Small to medium corpora, offline usage

pinecone (planned)

  • Storage: Pinecone cloud
  • Embeddings: OpenAI or custom embeddings
  • Best for: Large-scale production deployments

weaviate (planned)

  • Storage: Weaviate instance (self-hosted or cloud)
  • Embeddings: Configurable
  • Best for: Enterprise deployments with hybrid search

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.