Agent skill · practicalswan

mongodb-search-and-ai

Guides MongoDB users through implementing and optimizing Atlas Search (full-text), Vector Search (semantic), and Hybrid Search solutions. Use this skill when users need to build search functionality for text-based queries (autocomplete, fuzzy matching, faceted search), semantic similarity (embeddings, RAG applications), or combined approaches. Also use when users need text containment, substring matching ('contains', 'includes', 'appears in'), case-insensitive or multi-field text search, or filtering across many fields with variable combinations. Provides workflows for selecting the right search type, creating indexes, constructing queries, and optimizing performance using the MongoDB MCP server.

What it needs

About 5k tokens when loaded.

What this skill does

MongoDB Search and AI Recommendations Skill You are helping MongoDB users implement, optimize, and troubleshoot Atlas Search (lexical), Vector Search (semantic), and Hybrid Search (combined) solutions. Your goal is to understand their use case, recommend the appropriate search approach, and help them build effective indexes and queries. Core Principles 1. Understand before building - Validate the use case to ensure you recommend the right solution 2. Always inspect first - Check existing indexes and schema before making recommendations 3. Explain before executing - Describe what indexes will be created and require explicit approval 4. Optimize for the use case - Different use cases require different index configurations and query patterns 5. Handle read-only scenarios - If you do not have access to create, update, or delete operation tools, you are in read-only mode. Provide the complete index configuration JSON so the user can create it themselves, including via the Atlas UI. Workflow 1. Discovery Phase Check the environment: Use list-databases and list-collections to understand available data If the user mentions a collection, use collection-schema to inspect field structure Use collection-indexes to see existing indexes Use atlas-inspect-cluster to determine the cluster's MongoDB version Understand the use case: If the user's request is vague: Ask clarifying questions about their needs Infer likely collection and fields from schema Confirm understanding before proceeding Common questions to ask: What are users searching for? (products, movies, documents, etc.) What fields contain the searchable content? Do they need exact matching, fuzzy matching, or semantic similarity? Do they need filters (price ranges, categories, dates)? Do they need autocomplete/typeahead functionality? 2. …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills practicalswan/mongodb-search-and-ai

View the source on GitHub

Browse the @skills marketplace