Overview
Moorcheh’s Search API allows you to perform advanced semantic searches across one or multiple namespaces using text queries or vector embeddings. The API uses ITS (Information Theoretic Similarity) scoring to provide highly accurate relevance rankings.The Search API supports both text and vector namespaces, with automatic embedding generation for text queries and advanced binarization techniques for optimal performance.
Search Types
- Text Search
- Vector Search
Text Search
Search text namespaces using natural language queries. Moorcheh automatically generates embeddings for your query.- Document search
- Q&A systems
- Knowledge base queries
Basic Search
Search Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
namespaces | array | Yes | Array of namespace names to search |
query | string or array | Yes | Text query or vector array |
top_k | number | No | Number of results (default: 10) |
threshold | number | No | Minimum score threshold (0-1) |
kiosk_mode | boolean | No | Enable strict filtering |
Metadata Filtering
Filter search results using metadata fields for highly targeted results.Syntax
- Metadata filters:
#key:value - Keyword filters:
#keyword
Examples
Filters only apply to text search and metadata must be included when uploading documents.
Multi-Namespace Search
Search across multiple namespaces simultaneously:Kiosk Mode
Enable kiosk mode for production environments with strict filtering:- Filters results below threshold
- More controlled results
- Better for production environments
Response Format
Best Practices
Optimize top_k
Use lower values (3-5) for focused results, higher values (10-20) for broader exploration
Use Metadata Filters
Combine semantic search with metadata for precise targeting
Set Thresholds
Use threshold parameter to filter low-relevance results
Multi-Namespace Search
Search across related namespaces for comprehensive results