Corpus Stats • AI Agent SDK
CorpusStats: Statistics about an indexed corpus.
CorpusStats
Defined in the indexing module.
AI Agent
Statistics about an indexed corpus.
Used for strategy selection and monitoring.
Attributes: file_count: Number of files in corpus chunk_count: Number of chunks created total_tokens: Estimated total tokens indexed_at: Timestamp of last indexing path: Path to corpus root strategy_recommendation: Recommended retrieval strategy
Properties
ResponseField
intNo description available.
ResponseField
intNo description available.
ResponseField
intNo description available.
ResponseField
Optional[str]No description available.
ResponseField
Optional[str]No description available.
Methods
from_directory()
Create CorpusStats from directory scan.
strategy_recommendation()Recommend retrieval strategy based on corpus size.
Internal & Generic Methods
- from_dict: Create from dictionary.
- to_dict: Convert to dictionary.
Source
View on GitHubpraisonaiagents/knowledge/indexing.py at line 37