Oma search

From gracefullight/docusaurus-plugins · View interactive version

Oma search is an AI agent skill from the GitHub repository gracefullight/docusaurus-plugins. Intent-based search router with trust scoring. Routes queries to optimal channels (Context7 docs, native web search, gh/glab code search, Serena local) and attaches domain trust labels. Use for search, find, lookup, reference, docs, code search, and web research.

How to use this skill

Skill file

Search Agent - Intent-Based Search Router

Scheduling

Goal

Classify information-seeking requests, route them to the best search channel, attach trust labels, and return source-grounded results.

Intent signature

When to use

When NOT to use

Expected inputs

Expected outputs

Dependencies

Control-flow features

Structural Flow

Entry

  1. Parse the query and flags.
  2. Classify the search intent.
  3. Select one best route unless ambiguity or flags justify more.

Scenes

  1. PREPARE: Parse query and classify route.
  2. ACT: Dispatch to docs, web, code, or local search.
  3. ACQUIRE: Collect search results and source metadata.
  4. VERIFY: Apply trust scoring and route-specific quality checks.
  5. FINALIZE: Present ranked results or fallback status.

Transitions

Failure and recovery

Exit

Logical Operations

Actions

| Action | SSL primitive | Evidence |

|--------|---------------|----------|

| Parse query and flags | READ | User request |

| Classify intent | SELECT | Intent rules |

| Dispatch search route | CALL_TOOL | Docs, web, code, local tools |

| Collect results | READ | Search outputs |

| Score trust | VALIDATE | Trust registry |

| Rank and format | INFER | Relevance and trust |

| Report results | NOTIFY | Final answer |

Tools and instruments

Canonical command path

gh search code "<query>"
glab api "/search?scope=blobs&search=<query>"

For docs and web routes, use the runtime's available official-docs or web-search tools after classifying intent; do not duplicate routes unless the intent is ambiguous.

Resource scope

| Scope | Resource target |

|-------|-----------------|

| NETWORK | Web/docs/source-code search targets |

| CODEBASE | Local files when local search is selected |

| PROCESS | gh, glab, and CLI search commands |

| MEMORY | Query classification, trust labels, selected results |

Preconditions

Effects and side effects

Guardrails

  1. Classify intent before searching: every query goes through IntentClassifier first
  2. One query, one best route: avoid redundant multi-route unless intent is ambiguous
  3. Trust score every result: all non-local results get domain trust labels from the registry
  4. Flags override classifier: user-provided flags (--docs, --code, --web, --strict, --wide, --gitlab) always take precedence
  5. Fail forward: if primary route fails, fall back gracefully (docs->web, web->oma search fetch strategies)
  6. No additional MCP required: Context7 for docs, runtime native for web, CLI for code, Serena for local
  7. Vendor-agnostic web search: use whatever the current runtime provides (WebSearch, Google, Bing)
  8. Domain-level trust only: do not attempt sub-path or page-level scoring

Routes

| Route | Primary Tool | Fallback | Trigger |

|-------|-------------|----------|---------|

| docs | Context7 MCP (resolve-library-id → query-docs) | web route | Official docs, API reference |

| web | Runtime native search | oma search fetch (api/probe/impersonate/browser) | Tutorials, examples, solutions |

| code | gh search code / glab api | (none) | Implementation patterns, repos |

| local | Serena MCP (delegate) | (none) | Current project files, symbols |

Default Workflow

  1. Parse: Extract query, detect flags, classify intent
  2. Route: Dispatch to the appropriate search channel(s)
  3. Collect: Gather results from dispatched routes
  4. Score: Attach trust labels to each result domain
  5. Present: Format and rank results for the user

Invocation

Standalone
/oma-search "React Server Components streaming"
/oma-search --docs "Next.js middleware"
/oma-search --code "PKCE implementation"
/oma-search --strict "JWT refresh token rotation"
Shared Infrastructure (from other skills)

Other skills reference oma-search by specifying intent and query:

  1. State intent: docs | web | code | local
  2. Pass query string
  3. Use Trust Score in results to weigh source reliability

References

Follow resources/execution-protocol.md step by step.

See resources/examples.md for input/output examples.

Use resources/intent-rules.md for intent classification reference.

Use resources/trust-registry.md for domain trust scoring reference.

Before submitting, run resources/checklist.md.

Vendor-specific execution protocols are injected automatically by oma agent:spawn.

Source files live under ../_shared/runtime/execution-protocols/{vendor}.md.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.