File size: 1,353 Bytes
d04a792
 
 
051e64b
 
 
d04a792
051e64b
 
 
 
 
 
 
 
 
 
 
 
d04a792
051e64b
 
 
 
d04a792
051e64b
 
 
 
d04a792
051e64b
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
from pydantic import BaseModel

class AgentConfig:
    """Configuration settings for the advanced research agent."""
    
    # Model settings
    WRITER_MODEL = "gemini-2.5-flash-lite-preview-06-17"
    PLANNER_MODEL = "gemini-2.5-flash-lite-preview-06-17"
    
    # Research settings - Deep search parameters
    INITIAL_SEARCH_RESULTS = 8  # For initial planning phase
    DEEP_DIVE_SEARCH_RESULTS = 12  # Per query in each section
    MAX_QUERIES_PER_SECTION = 4  # Limit queries to avoid rate limits
    
    # RAG settings - Document processing
    CHUNKS_TO_RETRIEVE = 50  # Initial retrieval before re-ranking
    CHUNKS_TO_USE_FOR_WRITING = 15  # Final chunks after re-ranking
    CHUNK_SIZE = 1000  # Size of text chunks
    CHUNK_OVERLAP = 200  # Overlap between chunks
    
    # LLM settings - Temperature controls
    WRITER_TEMPERATURE = 0.4  # Balanced creativity for writing
    PLANNER_TEMPERATURE = 0.2  # Low for structured planning
    VERIFICATION_TEMPERATURE = 0.1  # Very low for fact-checking
    
    # Quality settings
    ENABLE_VERIFICATION = True  # Enable fact-checking step
    ENABLE_CITATIONS = True  # Include source citations
    MIN_SOURCES_PER_SECTION = 3  # Minimum sources per section
    
    # Rate limiting
    SEARCH_DELAY = 0.5  # Seconds between searches
    SECTION_DELAY = 1.0  # Seconds between sections