Skip to content

Exnest Brain Search (EBS)

Exnest Brain Search (EBS) is an API-powered MongoDB search with 2-layer AI processing to find and analyze data intelligently.

  • AI analyzes user query
  • Extracts 3-7 most relevant keywords
  • Example: “machine learning best practices” → ["machine", "learning", "practices"]
  • MongoDB search using keywords
  • AI re-ranks results with persona context
  • Scores each result 0-100
  • Returns only highly relevant results (≥50)
  • Provides reasoning for each result

ParameterTypeDescription
querystringSearch query (3-2000 chars)
mongoUrlstringMongoDB connection string
dbNamestringDatabase name
collectionstringCollection name
ParameterTypeDefaultDescription
modelstringAPI key defaultAI model to use
personastring”helpful assistant”Personality for AI analysis
limitnumber10Max results (1-100)
systemPromptstringdefaultCustom system prompt
metadataobjectCustom metadata

Terminal window
curl -X POST https://api.exnest.app/v1/ebs/search \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"query": "machine learning algorithms",
"mongoUrl": "mongodb://localhost:27017",
"dbName": "testdb",
"collection": "articles"
}'

{
"success": true,
"status_code": 200,
"message": "EBS search completed successfully.",
"data": {
"query": "machine learning",
"keywords": ["machine", "learning", "algorithms"],
"raw_results": [
{
"_id": 1,
"title": "...",
"content": "..."
}
],
"ai_analysis": {
"summary": "Found 3 articles about ML...",
"filtered_results": [
{
"original_data": {...},
"relevance_score": 95,
"reason": "Directly addresses ML algorithms"
}
],
"recommendations": ["...", "..."]
}
},
"meta": {
"timestamp": "2025-12-07T...",
"execution_time": "2.543s",
"execution_time_ms": 2543,
"request_id": "req_...",
"version": "v1.0"
}
}