settings.py 782 B

1234567891011121314151617
  1. from typing import List, Literal
  2. # Settings for LLMs
  3. DEFAULT_MAX_INPUT_TOKENS: int = 5800 # The LLM will truncate the input messages if they exceed this limit
  4. # Settings for agents
  5. MAX_LLM_CALL_PER_RUN: int = 8
  6. # Settings for tools
  7. DEFAULT_WORKSPACE: str = 'workspace'
  8. # Settings for RAG
  9. DEFAULT_MAX_REF_TOKEN: int = 4000 # The window size reserved for RAG materials
  10. DEFAULT_PARSER_PAGE_SIZE: int = 500 # Max tokens per chunk when doing RAG
  11. DEFAULT_RAG_KEYGEN_STRATEGY: Literal['None', 'GenKeyword', 'SplitQueryThenGenKeyword', 'GenKeywordWithKnowledge',
  12. 'SplitQueryThenGenKeywordWithKnowledge'] = 'SplitQueryThenGenKeyword'
  13. DEFAULT_RAG_SEARCHERS: List[str] = ['keyword_search', 'front_page_search'] # Sub-searchers for hybrid retrieval