interface DatasourcesListResponse {
success: boolean;
error?: string;
datasources?: Datasource[];
}
interface Datasource {
id: string; // e.g., "valyu/valyu-arxiv"
name: string; // e.g., "Arxiv"
description: string; // Full description
category: DatasourceCategoryId; // e.g., "research"
type: string; // e.g., "paper", "dataset"
modality: DatasourceModality[]; // e.g., ["text", "images"]
topics: string[]; // e.g., ["Research Papers", "Physics"]
languages?: string[]; // e.g., ["English"]
source?: string; // Data provider
example_queries: string[]; // Sample queries for few-shot prompting
pricing: DatasourcePricing; // Cost information
response_schema?: Record<string, any>; // JSON schema for responses
update_frequency?: string; // e.g., "Monthly", "Quarterly"
size?: number; // Number of records
coverage?: DatasourceCoverage; // Date range coverage
}
interface DatasourcePricing {
cpm: number; // Cost per million tokens
}
interface DatasourceCoverage {
start_date?: string | null;
end_date?: string | null;
}
type DatasourceCategoryId =
| "research"
| "healthcare"
| "patents"
| "markets"
| "company"
| "economic"
| "predictions"
| "transportation"
| "legal"
| "politics";
type DatasourceModality = "text" | "images" | "tabular";