import { exaSearch } from 'praisonai/tools';
const searchTool = exaSearch({
// Search type: auto, neural, fast, deep
type: 'auto',
// Number of results (default: 10)
numResults: 10,
// Category filter
category: 'news', // company, research paper, news, pdf, github, etc.
// Domain filters
includeDomains: ['github.com', 'arxiv.org'],
excludeDomains: ['wikipedia.org'],
// Date filters (ISO 8601)
startPublishedDate: '2024-01-01T00:00:00.000Z',
endPublishedDate: '2024-12-31T23:59:59.999Z',
// Text filters
includeText: ['AI', 'machine learning'],
excludeText: ['spam'],
// Content options
contents: {
text: { maxCharacters: 1000 },
summary: true,
livecrawl: 'fallback', // never, fallback, always, preferred
},
});