SYMBOL INDEX (5851 symbols across 980 files) FILE: app/__main__.py function check_env_file (line 42) | def check_env_file(): function main (line 113) | def main(): FILE: app/constants/model_capabilities.py class ModelCapabilityLevel (line 17) | class ModelCapabilityLevel(IntEnum): class ModelRole (line 26) | class ModelRole(str, Enum): class ModelFeature (line 33) | class ModelFeature(str, Enum): function get_model_capability_badge (line 353) | def get_model_capability_badge(level: int) -> Dict[str, str]: function get_role_badge (line 365) | def get_role_badge(role: ModelRole) -> Dict[str, str]: function get_feature_badge (line 375) | def get_feature_badge(feature: ModelFeature) -> Dict[str, str]: function is_aggregator_model (line 431) | def is_aggregator_model(model_name: str) -> bool: function parse_aggregator_model (line 444) | def parse_aggregator_model(model_name: str) -> Tuple[str, str]: FILE: app/core/config.py class Settings (line 22) | class Settings(BaseSettings): method MONGO_URI (line 45) | def MONGO_URI(self) -> str: method MONGO_DB (line 53) | def MONGO_DB(self) -> str: method REDIS_URL (line 66) | def REDIS_URL(self) -> str: method log_dir (line 257) | def log_dir(self) -> str: method is_production (line 280) | def is_production(self) -> bool: function get_settings (line 299) | def get_settings() -> Settings: FILE: app/core/config_bridge.py function bridge_config_to_env (line 15) | def bridge_config_to_env(): function _bridge_datasource_details (line 295) | def _bridge_datasource_details(data_source_configs) -> int: function _bridge_system_settings (line 355) | def _bridge_system_settings() -> int: function get_bridged_api_key (line 494) | def get_bridged_api_key(provider: str) -> Optional[str]: function get_bridged_model (line 508) | def get_bridged_model(model_type: str = "default") -> Optional[str]: function clear_bridged_config (line 526) | def clear_bridged_config(): function reload_bridged_config (line 580) | def reload_bridged_config(): function _sync_pricing_config (line 591) | def _sync_pricing_config(llm_configs): function sync_pricing_config_now (line 630) | def sync_pricing_config_now(): function _handle_sync_task_result (line 659) | def _handle_sync_task_result(task): function _sync_pricing_config_from_db (line 669) | async def _sync_pricing_config_from_db(): FILE: app/core/config_compat.py class ConfigManagerCompat (line 19) | class ConfigManagerCompat: method __init__ (line 26) | def __init__(self): method _emit_deprecation_warning (line 31) | def _emit_deprecation_warning(self): method get_data_dir (line 43) | def get_data_dir(self) -> str: method load_settings (line 58) | def load_settings(self) -> Dict[str, Any]: method save_settings (line 84) | def save_settings(self, settings_dict: Dict[str, Any]) -> bool: method get_models (line 111) | def get_models(self) -> List[Dict[str, Any]]: method get_model_config (line 144) | def get_model_config(self, provider: str, model_name: str) -> Optional... method _get_default_settings (line 161) | def _get_default_settings(self) -> Dict[str, Any]: class TokenTrackerCompat (line 179) | class TokenTrackerCompat: method __init__ (line 186) | def __init__(self): method track_usage (line 190) | def track_usage( method get_usage_summary (line 228) | def get_usage_summary(self) -> Dict[str, Any]: method reset_usage (line 237) | def reset_usage(self): function get_config_manager (line 248) | def get_config_manager() -> ConfigManagerCompat: function get_token_tracker (line 258) | def get_token_tracker() -> TokenTrackerCompat: FILE: app/core/database.py class DatabaseManager (line 30) | class DatabaseManager: method __init__ (line 33) | def __init__(self): method init_mongodb (line 41) | async def init_mongodb(self): method init_redis (line 74) | async def init_redis(self): method close_connections (line 104) | async def close_connections(self): method health_check (line 134) | async def health_check(self) -> dict: method is_healthy (line 180) | def is_healthy(self) -> bool: function init_database (line 189) | async def init_database(): function init_database_views_and_indexes (line 214) | async def init_database_views_and_indexes(): function create_stock_screening_view (line 232) | async def create_stock_screening_view(db): function create_database_indexes (line 347) | async def create_database_indexes(db): function close_database (line 371) | async def close_database(): function get_mongo_client (line 384) | def get_mongo_client() -> AsyncIOMotorClient: function get_mongo_db (line 391) | def get_mongo_db() -> AsyncIOMotorDatabase: function get_mongo_db_sync (line 398) | def get_mongo_db_sync() -> Database: function get_redis_client (line 422) | def get_redis_client() -> Redis: function get_database_health (line 429) | async def get_database_health() -> dict: function get_database (line 439) | def get_database(): FILE: app/core/dev_config.py class DevConfig (line 10) | class DevConfig: method get_uvicorn_config (line 100) | def get_uvicorn_config(cls, debug: bool = True) -> dict: method setup_logging (line 112) | def setup_logging(cls, debug: bool = True): FILE: app/core/logging_config.py function resolve_logging_cfg_path (line 31) | def resolve_logging_cfg_path() -> Path: class SimpleJsonFormatter (line 41) | class SimpleJsonFormatter(logging.Formatter): method format (line 43) | def format(self, record: logging.LogRecord) -> str: function _parse_size (line 55) | def _parse_size(size_str: str) -> int: function setup_logging (line 66) | def setup_logging(log_level: str = "INFO"): FILE: app/core/logging_context.py class LoggingContextFilter (line 8) | class LoggingContextFilter(logging.Filter): method filter (line 13) | def filter(self, record: logging.LogRecord) -> bool: FILE: app/core/rate_limiter.py class RateLimiter (line 14) | class RateLimiter: method __init__ (line 21) | def __init__(self, max_calls: int, time_window: float, name: str = "Ra... method acquire (line 43) | async def acquire(self): method get_stats (line 79) | def get_stats(self) -> dict: method reset_stats (line 92) | def reset_stats(self): class TushareRateLimiter (line 100) | class TushareRateLimiter(RateLimiter): method __init__ (line 116) | def __init__(self, tier: str = "standard", safety_margin: float = 0.8): class AKShareRateLimiter (line 147) | class AKShareRateLimiter(RateLimiter): method __init__ (line 154) | def __init__(self, max_calls: int = 60, time_window: float = 60): class BaoStockRateLimiter (line 169) | class BaoStockRateLimiter(RateLimiter): method __init__ (line 176) | def __init__(self, max_calls: int = 100, time_window: float = 60): function get_tushare_rate_limiter (line 197) | def get_tushare_rate_limiter(tier: str = "standard", safety_margin: floa... function get_akshare_rate_limiter (line 205) | def get_akshare_rate_limiter() -> AKShareRateLimiter: function get_baostock_rate_limiter (line 213) | def get_baostock_rate_limiter() -> BaoStockRateLimiter: function reset_all_limiters (line 221) | def reset_all_limiters(): FILE: app/core/redis_client.py function init_redis (line 17) | async def init_redis(): function close_redis (line 49) | async def close_redis(): function get_redis (line 63) | def get_redis() -> redis.Redis: class RedisKeys (line 70) | class RedisKeys: class RedisService (line 104) | class RedisService: method __init__ (line 107) | def __init__(self): method set_with_ttl (line 110) | async def set_with_ttl(self, key: str, value: str, ttl: int = 3600): method get_json (line 114) | async def get_json(self, key: str): method set_json (line 122) | async def set_json(self, key: str, value: dict, ttl: int = None): method increment_with_ttl (line 131) | async def increment_with_ttl(self, key: str, ttl: int = 3600): method add_to_queue (line 139) | async def add_to_queue(self, queue_key: str, item: dict): method pop_from_queue (line 144) | async def pop_from_queue(self, queue_key: str, timeout: int = 1): method get_queue_length (line 152) | async def get_queue_length(self, queue_key: str): method add_to_set (line 156) | async def add_to_set(self, set_key: str, value: str): method remove_from_set (line 160) | async def remove_from_set(self, set_key: str, value: str): method is_in_set (line 164) | async def is_in_set(self, set_key: str, value: str): method get_set_size (line 168) | async def get_set_size(self, set_key: str): method acquire_lock (line 172) | async def acquire_lock(self, lock_key: str, timeout: int = 30): method release_lock (line 181) | async def release_lock(self, lock_key: str, lock_value: str): function get_redis_service (line 197) | def get_redis_service() -> RedisService: FILE: app/core/response.py function ok (line 9) | def ok(data: Any = None, message: str = "ok") -> Dict[str, Any]: function fail (line 21) | def fail(message: str = "error", code: int = 500, data: Any = None) -> D... FILE: app/core/startup_validator.py class ConfigLevel (line 16) | class ConfigLevel(Enum): class ConfigItem (line 24) | class ConfigItem: class ValidationResult (line 35) | class ValidationResult: class StartupValidator (line 44) | class StartupValidator: method __init__ (line 115) | def __init__(self): method _is_valid_api_key (line 124) | def _is_valid_api_key(self, api_key: str) -> bool: method validate (line 158) | def validate(self) -> ValidationResult: method _validate_required_configs (line 184) | def _validate_required_configs(self): method _validate_recommended_configs (line 198) | def _validate_recommended_configs(self): method _check_security_configs (line 213) | def _check_security_configs(self): method _print_validation_result (line 236) | def _print_validation_result(self): method raise_if_failed (line 289) | def raise_if_failed(self): class ConfigurationError (line 310) | class ConfigurationError(Exception): function validate_startup_config (line 315) | def validate_startup_config() -> ValidationResult: FILE: app/core/unified_config.py class ConfigPaths (line 21) | class ConfigPaths: class UnifiedConfigManager (line 34) | class UnifiedConfigManager: method __init__ (line 37) | def __init__(self): method _get_file_mtime (line 42) | def _get_file_mtime(self, file_path: Path) -> float: method _is_cache_valid (line 49) | def _is_cache_valid(self, cache_key: str, file_path: Path) -> bool: method _load_json_file (line 59) | def _load_json_file(self, file_path: Path, cache_key: str = None) -> D... method _save_json_file (line 79) | def _save_json_file(self, file_path: Path, data: Dict[str, Any], cache... method get_legacy_models (line 93) | def get_legacy_models(self) -> List[Dict[str, Any]]: method get_llm_configs (line 97) | def get_llm_configs(self) -> List[LLMConfig]: method save_llm_config (line 125) | def save_llm_config(self, llm_config: LLMConfig) -> bool: method get_system_settings (line 163) | def get_system_settings(self) -> Dict[str, Any]: method save_system_settings (line 167) | def save_system_settings(self, settings: Dict[str, Any]) -> bool: method get_default_model (line 226) | def get_default_model(self) -> str: method set_default_model (line 232) | def set_default_model(self, model_name: str) -> bool: method get_quick_analysis_model (line 238) | def get_quick_analysis_model(self) -> str: method get_deep_analysis_model (line 244) | def get_deep_analysis_model(self) -> str: method set_analysis_models (line 250) | def set_analysis_models(self, quick_model: str, deep_model: str) -> bool: method get_data_source_configs (line 259) | def get_data_source_configs(self) -> List[DataSourceConfig]: method get_data_source_configs_async (line 327) | async def get_data_source_configs_async(self) -> List[DataSourceConfig]: method get_database_configs (line 408) | def get_database_configs(self) -> List[DatabaseConfig]: method get_unified_system_config (line 440) | async def get_unified_system_config(self) -> SystemConfig: method sync_to_legacy_format (line 466) | def sync_to_legacy_format(self, system_config: SystemConfig) -> bool: FILE: app/main.py function get_version (line 74) | def get_version() -> str: function _print_config_summary (line 85) | async def _print_config_summary(logger): function lifespan (line 216) | async def lifespan(app: FastAPI): function log_requests (line 636) | async def log_requests(request: Request, call_next): function global_exception_handler (line 664) | async def global_exception_handler(request: Request, exc: Exception): function test_log (line 680) | async def test_log(): function root (line 734) | async def root(): FILE: app/middleware/error_handler.py class ErrorHandlerMiddleware (line 15) | class ErrorHandlerMiddleware(BaseHTTPMiddleware): method dispatch (line 18) | async def dispatch(self, request: Request, call_next: Callable) -> Res... method handle_error (line 25) | async def handle_error(self, request: Request, exc: Exception) -> JSON... FILE: app/middleware/operation_log_middleware.py function set_operation_log_enabled (line 21) | def set_operation_log_enabled(flag: bool) -> None: class OperationLogMiddleware (line 27) | class OperationLogMiddleware(BaseHTTPMiddleware): method __init__ (line 30) | def __init__(self, app, skip_paths: Optional[list] = None): method dispatch (line 57) | async def dispatch(self, request: Request, call_next): method _should_skip_logging (line 98) | def _should_skip_logging(self, request: Request) -> bool: method _get_client_ip (line 121) | def _get_client_ip(self, request: Request) -> str: method _get_user_info (line 138) | async def _get_user_info(self, request: Request) -> Optional[Dict[str,... method _get_action_type (line 169) | def _get_action_type(self, path: str) -> str: method _get_action_description (line 177) | def _get_action_description(self, method: str, path: str, request: Req... method _log_operation (line 230) | async def _log_operation( function manual_log_operation (line 283) | async def manual_log_operation( FILE: app/middleware/rate_limit.py class RateLimitMiddleware (line 15) | class RateLimitMiddleware(BaseHTTPMiddleware): method __init__ (line 18) | def __init__(self, app, default_rate_limit: int = 100): method dispatch (line 31) | async def dispatch(self, request: Request, call_next: Callable) -> Res... method check_rate_limit (line 53) | async def check_rate_limit(self, user_id: str, endpoint: str): class QuotaMiddleware (line 98) | class QuotaMiddleware(BaseHTTPMiddleware): method __init__ (line 101) | def __init__(self, app, daily_quota: int = 1000): method dispatch (line 112) | async def dispatch(self, request: Request, call_next: Callable) -> Res... method check_daily_quota (line 134) | async def check_daily_quota(self, user_id: str): FILE: app/middleware/request_id.py class RequestIDMiddleware (line 19) | class RequestIDMiddleware(BaseHTTPMiddleware): method dispatch (line 22) | async def dispatch(self, request: Request, call_next: Callable) -> Res... FILE: app/models/analysis.py class AnalysisStatus (line 14) | class AnalysisStatus(str, Enum): class BatchStatus (line 23) | class BatchStatus(str, Enum): class AnalysisParameters (line 33) | class AnalysisParameters(BaseModel): class AnalysisResult (line 56) | class AnalysisResult(BaseModel): class AnalysisTask (line 72) | class AnalysisTask(BaseModel): class AnalysisBatch (line 106) | class AnalysisBatch(BaseModel): class StockInfo (line 139) | class StockInfo(BaseModel): class SingleAnalysisRequest (line 154) | class SingleAnalysisRequest(BaseModel): method get_symbol (line 160) | def get_symbol(self) -> str: class BatchAnalysisRequest (line 165) | class BatchAnalysisRequest(BaseModel): method get_symbols (line 173) | def get_symbols(self) -> List[str]: class AnalysisTaskResponse (line 178) | class AnalysisTaskResponse(BaseModel): method serialize_datetime (line 193) | def serialize_datetime(self, dt: Optional[datetime], _info) -> Optiona... class AnalysisBatchResponse (line 200) | class AnalysisBatchResponse(BaseModel): method serialize_datetime (line 216) | def serialize_datetime(self, dt: Optional[datetime], _info) -> Optiona... class AnalysisHistoryQuery (line 223) | class AnalysisHistoryQuery(BaseModel): method get_symbol (line 234) | def get_symbol(self) -> Optional[str]: FILE: app/models/config.py class ModelProvider (line 14) | class ModelProvider(str, Enum): class LLMProvider (line 42) | class LLMProvider(BaseModel): class ModelInfo (line 69) | class ModelInfo(BaseModel): class ModelCatalog (line 88) | class ModelCatalog(BaseModel): class LLMProviderRequest (line 100) | class LLMProviderRequest(BaseModel): class LLMProviderResponse (line 121) | class LLMProviderResponse(BaseModel): class DataSourceType (line 146) | class DataSourceType(str, Enum): class DatabaseType (line 177) | class DatabaseType(str, Enum): class LLMConfig (line 186) | class LLMConfig(BaseModel): class DataSourceConfig (line 237) | class DataSourceConfig(BaseModel): class DatabaseConfig (line 258) | class DatabaseConfig(BaseModel): class MarketCategory (line 274) | class MarketCategory(BaseModel): class DataSourceGrouping (line 286) | class DataSourceGrouping(BaseModel): class UsageRecord (line 296) | class UsageRecord(BaseModel): class UsageStatistics (line 311) | class UsageStatistics(BaseModel): class SystemConfig (line 323) | class SystemConfig(BaseModel): class LLMConfigRequest (line 356) | class LLMConfigRequest(BaseModel): class DataSourceConfigRequest (line 389) | class DataSourceConfigRequest(BaseModel): class MarketCategoryRequest (line 408) | class MarketCategoryRequest(BaseModel): class DataSourceGroupingRequest (line 418) | class DataSourceGroupingRequest(BaseModel): class DataSourceOrderRequest (line 426) | class DataSourceOrderRequest(BaseModel): class DatabaseConfigRequest (line 431) | class DatabaseConfigRequest(BaseModel): class SystemConfigResponse (line 447) | class SystemConfigResponse(BaseModel): method serialize_datetime (line 463) | def serialize_datetime(self, dt: Optional[datetime], _info) -> Optiona... class ConfigTestRequest (line 470) | class ConfigTestRequest(BaseModel): class ConfigTestResponse (line 476) | class ConfigTestResponse(BaseModel): FILE: app/models/notification.py function to_str_id (line 12) | def to_str_id(v: Any) -> str: class NotificationCreate (line 25) | class NotificationCreate(BaseModel): class NotificationDB (line 36) | class NotificationDB(BaseModel): class NotificationOut (line 50) | class NotificationOut(BaseModel): method serialize_datetime (line 61) | def serialize_datetime(self, dt: Optional[datetime], _info) -> Optiona... class NotificationList (line 68) | class NotificationList(BaseModel): FILE: app/models/operation_log.py class OperationLogCreate (line 11) | class OperationLogCreate(BaseModel): class OperationLogResponse (line 24) | class OperationLogResponse(BaseModel): method serialize_datetime (line 42) | def serialize_datetime(self, dt: datetime, _info) -> Optional[str]: class OperationLogQuery (line 49) | class OperationLogQuery(BaseModel): class OperationLogListResponse (line 61) | class OperationLogListResponse(BaseModel): class OperationLogStats (line 68) | class OperationLogStats(BaseModel): class OperationLogStatsResponse (line 78) | class OperationLogStatsResponse(BaseModel): class ClearLogsRequest (line 85) | class ClearLogsRequest(BaseModel): class ClearLogsResponse (line 91) | class ClearLogsResponse(BaseModel): class ActionType (line 99) | class ActionType: function convert_objectid_to_str (line 132) | def convert_objectid_to_str(doc: Dict[str, Any]) -> Dict[str, Any]: FILE: app/models/screening.py class OperatorType (line 10) | class OperatorType(str, Enum): class FieldType (line 26) | class FieldType(str, Enum): class ScreeningCondition (line 33) | class ScreeningCondition(BaseModel): class Config (line 40) | class Config: class ScreeningRequest (line 44) | class ScreeningRequest(BaseModel): class ScreeningResponse (line 62) | class ScreeningResponse(BaseModel): class FieldInfo (line 71) | class FieldInfo(BaseModel): class FieldStatistics (line 92) | class FieldStatistics(BaseModel): FILE: app/models/stock_models.py function to_str_id (line 11) | def to_str_id(v: Any) -> str: class MarketInfo (line 28) | class MarketInfo(BaseModel): class TechnicalIndicators (line 38) | class TechnicalIndicators(BaseModel): class StockBasicInfoExtended (line 54) | class StockBasicInfoExtended(BaseModel): class Config (line 119) | class Config: class MarketQuotesExtended (line 153) | class MarketQuotesExtended(BaseModel): class Config (line 197) | class Config: class StockBasicInfoResponse (line 224) | class StockBasicInfoResponse(BaseModel): class MarketQuotesResponse (line 231) | class MarketQuotesResponse(BaseModel): class StockListResponse (line 238) | class StockListResponse(BaseModel): FILE: app/models/user.py function validate_object_id (line 14) | def validate_object_id(v: Any) -> ObjectId: function serialize_object_id (line 24) | def serialize_object_id(v: ObjectId) -> str: class UserPreferences (line 37) | class UserPreferences(BaseModel): class FavoriteStock (line 61) | class FavoriteStock(BaseModel): class User (line 73) | class User(BaseModel): class UserCreate (line 102) | class UserCreate(BaseModel): class UserUpdate (line 109) | class UserUpdate(BaseModel): class UserResponse (line 117) | class UserResponse(BaseModel): method serialize_datetime (line 134) | def serialize_datetime(self, dt: Optional[datetime], _info) -> Optiona... class UserLogin (line 141) | class UserLogin(BaseModel): class UserSession (line 147) | class UserSession(BaseModel): method serialize_datetime (line 158) | def serialize_datetime(self, dt: Optional[datetime], _info) -> Optiona... class TokenResponse (line 165) | class TokenResponse(BaseModel): FILE: app/routers/akshare_init.py class InitializationRequest (line 33) | class InitializationRequest(BaseModel): class SyncRequest (line 40) | class SyncRequest(BaseModel): function get_database_status (line 47) | async def get_database_status(): function test_akshare_connection (line 109) | async def test_akshare_connection(): function start_full_initialization (line 146) | async def start_full_initialization( function start_basic_sync (line 204) | async def start_basic_sync( function get_initialization_status (line 260) | async def get_initialization_status(): function stop_initialization (line 287) | async def stop_initialization(current_user: dict = Depends(get_current_u... function _run_full_initialization_background (line 326) | async def _run_full_initialization_background(historical_days: int, forc... function _run_basic_sync_background (line 352) | async def _run_basic_sync_background(force_update: bool): FILE: app/routers/analysis.py class SingleAnalyzeRequest (line 29) | class SingleAnalyzeRequest(BaseModel): class BatchAnalyzeRequest (line 33) | class BatchAnalyzeRequest(BaseModel): function submit_single_analysis (line 41) | async def submit_single_analysis( function test_route (line 100) | async def test_route(): function get_task_status_new (line 106) | async def get_task_status_new( function get_task_result (line 222) | async def get_task_result( function list_all_tasks (line 707) | async def list_all_tasks( function list_user_tasks (line 739) | async def list_user_tasks( function submit_batch_analysis (line 772) | async def submit_batch_analysis( function analyze_single (line 876) | async def analyze_single( function analyze_batch (line 893) | async def analyze_batch( function get_batch (line 910) | async def get_batch(batch_id: str, user: dict = Depends(get_current_user... function cancel_task (line 949) | async def cancel_task( function get_user_queue_status (line 970) | async def get_user_queue_status( function get_user_analysis_history (line 985) | async def get_user_analysis_history( function websocket_task_progress (line 1063) | async def websocket_task_progress(websocket: WebSocket, task_id: str): function get_task_details (line 1100) | async def get_task_details( function get_zombie_tasks (line 1115) | async def get_zombie_tasks( function cleanup_zombie_tasks (line 1143) | async def cleanup_zombie_tasks( function mark_task_as_failed (line 1170) | async def mark_task_as_failed( function delete_task (line 1225) | async def delete_task( FILE: app/routers/auth_db.py function get_logger (line 24) | def get_logger(name: str) -> logging.Logger: class ApiResponse (line 30) | class ApiResponse(BaseModel): class LoginRequest (line 37) | class LoginRequest(BaseModel): class LoginResponse (line 41) | class LoginResponse(BaseModel): class RefreshTokenRequest (line 47) | class RefreshTokenRequest(BaseModel): class RefreshTokenResponse (line 50) | class RefreshTokenResponse(BaseModel): class ChangePasswordRequest (line 55) | class ChangePasswordRequest(BaseModel): class ResetPasswordRequest (line 59) | class ResetPasswordRequest(BaseModel): class CreateUserRequest (line 63) | class CreateUserRequest(BaseModel): function get_current_user (line 69) | async def get_current_user(authorization: Optional[str] = Header(default... function login (line 117) | async def login(payload: LoginRequest, request: Request): function refresh_token (line 220) | async def refresh_token(payload: RefreshTokenRequest): function logout (line 268) | async def logout(request: Request, user: dict = Depends(get_current_user)): function me (line 304) | async def me(user: dict = Depends(get_current_user)): function update_me (line 313) | async def update_me( function change_password (line 370) | async def change_password( function reset_password (line 399) | async def reset_password( function create_user (line 428) | async def create_user( function list_users (line 479) | async def list_users( FILE: app/routers/baostock_init.py class InitializationRequest (line 30) | class InitializationRequest(BaseModel): class InitializationResponse (line 36) | class InitializationResponse(BaseModel): function get_database_status (line 45) | async def get_database_status(): function test_baostock_connection (line 63) | async def test_baostock_connection(): function start_full_initialization (line 84) | async def start_full_initialization( function start_basic_initialization (line 136) | async def start_basic_initialization(background_tasks: BackgroundTasks): function get_initialization_status (line 178) | async def get_initialization_status(): function stop_initialization (line 222) | async def stop_initialization(): function _run_full_initialization_task (line 252) | async def _run_full_initialization_task(historical_days: int, force: boo... function _run_basic_initialization_task (line 285) | async def _run_basic_initialization_task(task_id: str): function get_service_status (line 316) | async def get_service_status(): FILE: app/routers/cache.py function get_cache_stats (line 19) | async def get_cache_stats(current_user: dict = Depends(get_current_user)): function cleanup_old_cache (line 57) | async def cleanup_old_cache( function clear_all_cache (line 94) | async def clear_all_cache(current_user: dict = Depends(get_current_user)): function get_cache_details (line 126) | async def get_cache_details( function get_cache_backend_info (line 175) | async def get_cache_backend_info(current_user: dict = Depends(get_curren... FILE: app/routers/config.py function reload_config (line 38) | async def reload_config(current_user: dict = Depends(get_current_user)): function _sanitize_llm_configs (line 83) | def _sanitize_llm_configs(items): function _sanitize_datasource_configs (line 89) | def _sanitize_datasource_configs(items): function _sanitize_database_configs (line 141) | def _sanitize_database_configs(items): function _sanitize_kv (line 147) | def _sanitize_kv(d: Dict[str, Any]) -> Dict[str, Any]: class SetDefaultRequest (line 166) | class SetDefaultRequest(BaseModel): function get_system_config (line 172) | async def get_system_config( function get_llm_providers (line 208) | async def get_llm_providers( function add_llm_provider (line 279) | async def add_llm_provider( function update_llm_provider (line 316) | async def update_llm_provider( function delete_llm_provider (line 380) | async def delete_llm_provider( function toggle_llm_provider (line 421) | async def toggle_llm_provider( function fetch_provider_models (line 464) | async def fetch_provider_models( function migrate_env_to_providers (line 485) | async def migrate_env_to_providers( function init_aggregator_providers (line 523) | async def init_aggregator_providers( function test_provider_api (line 562) | async def test_provider_api( function add_llm_config (line 583) | async def add_llm_config( function add_data_source_config (line 692) | async def add_data_source_config( function add_database_config (line 795) | async def add_database_config( function test_config (line 847) | async def test_config( function test_saved_database_config (line 879) | async def test_saved_database_config( function get_llm_configs (line 928) | async def get_llm_configs( function delete_llm_config (line 970) | async def delete_llm_config( function set_default_llm (line 1021) | async def set_default_llm( function get_data_source_configs (line 1057) | async def get_data_source_configs( function update_data_source_config (line 1074) | async def update_data_source_config( function delete_data_source_config (line 1284) | async def delete_data_source_config( function get_market_categories (line 1340) | async def get_market_categories( function add_market_category (line 1355) | async def add_market_category( function update_market_category (line 1393) | async def update_market_category( function delete_market_category (line 1431) | async def delete_market_category( function get_datasource_groupings (line 1470) | async def get_datasource_groupings( function add_datasource_to_category (line 1485) | async def add_datasource_to_category( function remove_datasource_from_category (line 1523) | async def remove_datasource_from_category( function update_datasource_grouping (line 1561) | async def update_datasource_grouping( function update_category_datasource_order (line 1600) | async def update_category_datasource_order( function set_default_data_source (line 1638) | async def set_default_data_source( function get_system_settings (line 1674) | async def get_system_settings( function get_system_settings_meta (line 1689) | async def get_system_settings_meta( function update_system_settings (line 1709) | async def update_system_settings( function export_config (line 1774) | async def export_config( function import_config (line 1805) | async def import_config( function migrate_legacy_config (line 1841) | async def migrate_legacy_config( function set_default_llm (line 1876) | async def set_default_llm( function set_default_data_source (line 1914) | async def set_default_data_source( function get_available_models (line 1952) | async def get_available_models( function get_model_catalog (line 1969) | async def get_model_catalog( function get_provider_model_catalog (line 1984) | async def get_provider_model_catalog( class ModelCatalogRequest (line 2006) | class ModelCatalogRequest(BaseModel): function save_model_catalog (line 2014) | async def save_model_catalog( function delete_model_catalog (line 2064) | async def delete_model_catalog( function init_model_catalog (line 2097) | async def init_model_catalog( function get_database_configs (line 2122) | async def get_database_configs( function get_database_config (line 2140) | async def get_database_config( function add_database_config (line 2167) | async def add_database_config( function update_database_config (line 2209) | async def update_database_config( function delete_database_config (line 2259) | async def delete_database_config( FILE: app/routers/database.py class BackupRequest (line 22) | class BackupRequest(BaseModel): class ImportRequest (line 27) | class ImportRequest(BaseModel): class ExportRequest (line 33) | class ExportRequest(BaseModel): class DatabaseStatusResponse (line 40) | class DatabaseStatusResponse(BaseModel): class DatabaseStatsResponse (line 45) | class DatabaseStatsResponse(BaseModel): class BackupResponse (line 52) | class BackupResponse(BaseModel): function get_database_status (line 64) | async def get_database_status( function get_database_stats (line 84) | async def get_database_stats( function test_database_connections (line 104) | async def test_database_connections( function create_backup (line 124) | async def create_backup( function list_backups (line 149) | async def list_backups( function import_data (line 168) | async def import_data( function export_data (line 211) | async def export_data( function delete_backup (line 239) | async def delete_backup( function cleanup_old_data (line 259) | async def cleanup_old_data( function cleanup_analysis_results (line 280) | async def cleanup_analysis_results( function cleanup_operation_logs (line 301) | async def cleanup_operation_logs( FILE: app/routers/favorites.py class AddFavoriteRequest (line 20) | class AddFavoriteRequest(BaseModel): class UpdateFavoriteRequest (line 31) | class UpdateFavoriteRequest(BaseModel): class FavoriteStockResponse (line 39) | class FavoriteStockResponse(BaseModel): function get_favorites (line 56) | async def get_favorites( function add_favorite (line 71) | async def add_favorite( function update_favorite (line 128) | async def update_favorite( function remove_favorite (line 162) | async def remove_favorite( function check_favorite (line 188) | async def check_favorite( function get_user_tags (line 204) | async def get_user_tags( class SyncFavoritesRequest (line 218) | class SyncFavoritesRequest(BaseModel): function sync_favorites_realtime (line 224) | async def sync_favorites_realtime( FILE: app/routers/financial_data.py class FinancialSyncRequest (line 22) | class FinancialSyncRequest(BaseModel): class SingleStockSyncRequest (line 37) | class SingleStockSyncRequest(BaseModel): function query_financial_data (line 50) | async def query_financial_data( function get_latest_financial_data (line 91) | async def get_latest_financial_data( function get_financial_statistics (line 124) | async def get_financial_statistics() -> dict: function start_financial_sync (line 148) | async def start_financial_sync( function sync_single_stock_financial (line 184) | async def sync_single_stock_financial( function get_sync_statistics (line 221) | async def get_sync_statistics() -> dict: function health_check (line 242) | async def health_check() -> dict: function _execute_financial_sync (line 277) | async def _execute_financial_sync( FILE: app/routers/health.py function get_version (line 8) | def get_version() -> str: function health (line 20) | async def health(): function healthz (line 34) | async def healthz(): function readyz (line 39) | async def readyz(): FILE: app/routers/historical_data.py class HistoricalDataQuery (line 19) | class HistoricalDataQuery(BaseModel): class HistoricalDataResponse (line 29) | class HistoricalDataResponse(BaseModel): function get_historical_data (line 37) | async def get_historical_data( function query_historical_data (line 95) | async def query_historical_data(request: HistoricalDataQuery): function get_latest_date (line 132) | async def get_latest_date( function get_data_statistics (line 157) | async def get_data_statistics(): function compare_data_sources (line 175) | async def compare_data_sources( function health_check (line 220) | async def health_check(): FILE: app/routers/internal_messages.py class InternalMessage (line 20) | class InternalMessage(BaseModel): class InternalMessageBatchRequest (line 50) | class InternalMessageBatchRequest(BaseModel): class InternalMessageQueryRequest (line 56) | class InternalMessageQueryRequest(BaseModel): function save_internal_messages (line 78) | async def save_internal_messages(request: InternalMessageBatchRequest): function query_internal_messages (line 102) | async def query_internal_messages(request: InternalMessageQueryRequest): function get_latest_messages (line 144) | async def get_latest_messages( function search_messages (line 170) | async def search_messages( function get_research_reports (line 196) | async def get_research_reports( function get_analyst_notes (line 220) | async def get_analyst_notes( function get_statistics (line 244) | async def get_statistics( function get_message_types (line 275) | async def get_message_types(): function get_categories (line 314) | async def get_categories(): function health_check (line 348) | async def health_check(): FILE: app/routers/logs.py class LogReadRequest (line 20) | class LogReadRequest(BaseModel): class LogExportRequest (line 30) | class LogExportRequest(BaseModel): class LogFileInfo (line 40) | class LogFileInfo(BaseModel): class LogContentResponse (line 50) | class LogContentResponse(BaseModel): class LogStatisticsResponse (line 57) | class LogStatisticsResponse(BaseModel): function list_log_files (line 67) | async def list_log_files( function read_log_file (line 89) | async def read_log_file( function export_logs (line 125) | async def export_logs( function get_log_statistics (line 173) | async def get_log_statistics( function delete_log_file (line 200) | async def delete_log_file( FILE: app/routers/model_capabilities.py class ModelCapabilityInfo (line 31) | class ModelCapabilityInfo(BaseModel): class ModelRecommendationRequest (line 42) | class ModelRecommendationRequest(BaseModel): class ModelRecommendationResponse (line 47) | class ModelRecommendationResponse(BaseModel): class ModelValidationRequest (line 56) | class ModelValidationRequest(BaseModel): class ModelValidationResponse (line 63) | class ModelValidationResponse(BaseModel): class BatchInitRequest (line 70) | class BatchInitRequest(BaseModel): function get_default_model_configs (line 78) | async def get_default_model_configs(): function get_depth_requirements (line 109) | async def get_depth_requirements(): function get_capability_descriptions (line 134) | async def get_capability_descriptions(): function get_all_badges (line 144) | async def get_all_badges(): function recommend_models (line 173) | async def recommend_models(request: ModelRecommendationRequest): function validate_models (line 235) | async def validate_models(request: ModelValidationRequest): function batch_init_capabilities (line 258) | async def batch_init_capabilities(request: BatchInitRequest): function get_model_capability (line 314) | async def get_model_capability(model_name: str): FILE: app/routers/multi_market_stocks.py function get_supported_markets (line 27) | async def get_supported_markets(current_user: dict = Depends(get_current... function search_stocks (line 79) | async def search_stocks( function get_stock_info (line 136) | async def get_stock_info( function get_stock_quote (line 199) | async def get_stock_quote( function get_stock_daily_quotes (line 260) | async def get_stock_daily_quotes( FILE: app/routers/multi_period_sync.py class MultiPeriodSyncRequest (line 19) | class MultiPeriodSyncRequest(BaseModel): class MultiPeriodSyncResponse (line 29) | class MultiPeriodSyncResponse(BaseModel): function start_multi_period_sync (line 37) | async def start_multi_period_sync( function start_daily_sync (line 73) | async def start_daily_sync( function start_weekly_sync (line 104) | async def start_weekly_sync( function start_monthly_sync (line 135) | async def start_monthly_sync( function start_all_history_sync (line 166) | async def start_all_history_sync( function start_incremental_sync (line 203) | async def start_incremental_sync( function get_sync_statistics (line 248) | async def get_sync_statistics(): function compare_period_data (line 266) | async def compare_period_data( function get_supported_periods (line 314) | async def get_supported_periods(): function health_check (line 365) | async def health_check(): FILE: app/routers/multi_source_sync.py class SyncRequest (line 19) | class SyncRequest(BaseModel): class SyncResponse (line 25) | class SyncResponse(BaseModel): class DataSourceStatus (line 32) | class DataSourceStatus(BaseModel): function get_data_sources_status (line 41) | async def get_data_sources_status(): function get_current_data_source (line 89) | async def get_current_data_source(): function get_sync_status (line 138) | async def get_sync_status(): function run_stock_basics_sync (line 155) | async def run_stock_basics_sync( function _test_single_adapter (line 193) | async def _test_single_adapter(adapter) -> dict: class TestSourceRequest (line 272) | class TestSourceRequest(BaseModel): function test_data_sources (line 278) | async def test_data_sources(request: TestSourceRequest = TestSourceReque... function get_sync_recommendations (line 350) | async def get_sync_recommendations(): function get_sync_history (line 403) | async def get_sync_history( function clear_sync_cache (line 449) | async def clear_sync_cache(): FILE: app/routers/news_data.py class NewsQueryRequest (line 20) | class NewsQueryRequest(BaseModel): class NewsSyncRequest (line 35) | class NewsSyncRequest(BaseModel): function query_stock_news (line 44) | async def query_stock_news( function query_news_advanced (line 134) | async def query_news_advanced( function get_latest_news (line 184) | async def get_latest_news( function search_news (line 229) | async def search_news( function get_news_statistics (line 273) | async def get_news_statistics( function start_news_sync (line 330) | async def start_news_sync( function sync_single_stock_news (line 382) | async def sync_single_stock_news( function cleanup_old_news (line 435) | async def cleanup_old_news( function health_check (line 469) | async def health_check(): function _execute_stock_news_sync (line 490) | async def _execute_stock_news_sync(sync_service, request: NewsSyncRequest): function _execute_market_news_sync (line 503) | async def _execute_market_news_sync(sync_service, request: NewsSyncReque... FILE: app/routers/notifications.py function list_notifications (line 18) | async def list_notifications( function get_unread_count (line 33) | async def get_unread_count(user: dict = Depends(get_current_user)): function mark_read (line 40) | async def mark_read(notif_id: str, user: dict = Depends(get_current_user)): function mark_all_read (line 49) | async def mark_all_read(user: dict = Depends(get_current_user)): function debug_redis_pool (line 56) | async def debug_redis_pool(user: dict = Depends(get_current_user)): FILE: app/routers/operation_logs.py function get_operation_logs (line 26) | async def get_operation_logs( function get_operation_log_stats (line 74) | async def get_operation_log_stats( function get_operation_log_detail (line 100) | async def get_operation_log_detail( function clear_operation_logs (line 134) | async def clear_operation_logs( function create_operation_log (line 169) | async def create_operation_log( function export_logs_csv (line 207) | async def export_logs_csv( FILE: app/routers/paper.py class PlaceOrderRequest (line 24) | class PlaceOrderRequest(BaseModel): function _detect_market_and_code (line 33) | def _detect_market_and_code(code: str) -> Tuple[str, str]: function _get_or_create_account (line 65) | async def _get_or_create_account(user_id: str) -> Dict[str, Any]: function _get_market_rules (line 118) | async def _get_market_rules(market: str) -> Optional[Dict[str, Any]]: function _calculate_commission (line 127) | def _calculate_commission(market: str, side: str, amount: float, rules: ... function _get_available_quantity (line 160) | async def _get_available_quantity(user_id: str, code: str, market: str) ... function _get_last_price (line 194) | async def _get_last_price(code: str, market: str) -> Optional[float]: function _zfill_code (line 263) | def _zfill_code(code: str) -> str: function get_account (line 271) | async def get_account(current_user: dict = Depends(get_current_user)): function place_order (line 345) | async def place_order(payload: PlaceOrderRequest, current_user: dict = D... function list_positions (line 534) | async def list_positions(current_user: dict = Depends(get_current_user)): function list_orders (line 564) | async def list_orders(limit: int = Query(50, ge=1, le=200), current_user... function reset_account (line 574) | async def reset_account(confirm: bool = Query(False), current_user: dict... FILE: app/routers/queue.py function queue_stats (line 8) | async def queue_stats(user: dict = Depends(get_current_user), svc: Queue... FILE: app/routers/reports.py function get_stock_name (line 24) | def get_stock_name(stock_code: str) -> str: function _build_report_query (line 89) | def _build_report_query(report_id: str) -> Dict[str, Any]: class ReportFilter (line 103) | class ReportFilter(BaseModel): class ReportListResponse (line 112) | class ReportListResponse(BaseModel): function get_reports_list (line 120) | async def get_reports_list( function get_report_detail (line 239) | async def get_report_detail( function get_report_module_content (line 356) | async def get_report_module_content( function delete_report (line 398) | async def delete_report( function download_report (line 429) | async def download_report( FILE: app/routers/scheduler.py class JobTriggerRequest (line 20) | class JobTriggerRequest(BaseModel): class JobUpdateRequest (line 26) | class JobUpdateRequest(BaseModel): class JobMetadataUpdateRequest (line 33) | class JobMetadataUpdateRequest(BaseModel): function list_jobs (line 40) | async def list_jobs( function update_job_metadata_route (line 58) | async def update_job_metadata_route( function get_job_detail (line 95) | async def get_job_detail( function pause_job (line 121) | async def pause_job( function resume_job (line 152) | async def resume_job( function trigger_job (line 183) | async def trigger_job( function get_job_history (line 224) | async def get_job_history( function get_all_history (line 260) | async def get_all_history( function get_scheduler_stats (line 303) | async def get_scheduler_stats( function scheduler_health_check (line 321) | async def scheduler_health_check( function get_job_executions (line 339) | async def get_job_executions( function get_single_job_executions (line 381) | async def get_single_job_executions( function get_job_execution_stats (line 423) | async def get_job_execution_stats( function cancel_execution (line 445) | async def cancel_execution( function mark_execution_failed (line 475) | async def mark_execution_failed( function delete_execution (line 506) | async def delete_execution( FILE: app/routers/screening.py class FieldConfigResponse (line 19) | class FieldConfigResponse(BaseModel): class OrderByItem (line 25) | class OrderByItem(BaseModel): class ScreeningRequest (line 29) | class ScreeningRequest(BaseModel): class ScreeningResponse (line 38) | class ScreeningResponse(BaseModel): function get_screening_fields (line 48) | async def get_screening_fields(user: dict = Depends(get_current_user)): function _convert_legacy_conditions_to_new_format (line 74) | def _convert_legacy_conditions_to_new_format(legacy_conditions: Dict[str... function run_screening (line 157) | async def run_screening(req: ScreeningRequest, user: dict = Depends(get_... function enhanced_screening (line 194) | async def enhanced_screening(req: NewScreeningRequest, user: dict = Depe... function get_supported_fields (line 235) | async def get_supported_fields(user: dict = Depends(get_current_user)): function get_field_info (line 247) | async def get_field_info(field_name: str, user: dict = Depends(get_curre... function validate_conditions (line 263) | async def validate_conditions(conditions: List[ScreeningCondition], user... function get_industries (line 276) | async def get_industries(user: dict = Depends(get_current_user)): FILE: app/routers/social_media.py class SocialMediaMessage (line 20) | class SocialMediaMessage(BaseModel): class SocialMediaBatchRequest (line 43) | class SocialMediaBatchRequest(BaseModel): class SocialMediaQueryRequest (line 49) | class SocialMediaQueryRequest(BaseModel): function save_social_media_messages (line 69) | async def save_social_media_messages(request: SocialMediaBatchRequest): function query_social_media_messages (line 94) | async def query_social_media_messages(request: SocialMediaQueryRequest): function get_latest_messages (line 135) | async def get_latest_messages( function search_messages (line 159) | async def search_messages( function get_statistics (line 186) | async def get_statistics( function get_supported_platforms (line 217) | async def get_supported_platforms(): function get_sentiment_analysis (line 266) | async def get_sentiment_analysis( function health_check (line 340) | async def health_check(): FILE: app/routers/sse.py function task_progress_generator (line 18) | async def task_progress_generator(task_id: str, user_id: str): function batch_progress_generator (line 113) | async def batch_progress_generator(batch_id: str, user_id: str): function stream_task_progress (line 225) | async def stream_task_progress(task_id: str, user: dict = Depends(get_cu... function stream_batch_progress (line 244) | async def stream_batch_progress(batch_id: str, user: dict = Depends(get_... FILE: app/routers/stock_data.py function get_stock_basic_info (line 24) | async def get_stock_basic_info( function get_market_quotes (line 61) | async def get_market_quotes( function get_stock_list (line 98) | async def get_stock_list( function get_combined_stock_data (line 146) | async def get_combined_stock_data( function search_stocks (line 204) | async def search_stocks( function get_market_summary (line 291) | async def get_market_summary( function get_quotes_sync_status (line 344) | async def get_quotes_sync_status( FILE: app/routers/stock_sync.py function _sync_latest_to_market_quotes (line 25) | async def _sync_latest_to_market_quotes(symbol: str) -> None: class SingleStockSyncRequest (line 101) | class SingleStockSyncRequest(BaseModel): class BatchStockSyncRequest (line 112) | class BatchStockSyncRequest(BaseModel): function sync_single_stock (line 123) | async def sync_single_stock( function sync_batch_stocks (line 527) | async def sync_batch_stocks( function get_sync_status (line 718) | async def get_sync_status( FILE: app/routers/stocks.py function _zfill_code (line 21) | def _zfill_code(code: str) -> str: function _detect_market_and_code (line 31) | def _detect_market_and_code(code: str) -> Tuple[str, str]: function get_quote (line 67) | async def get_quote( function get_fundamentals (line 216) | async def get_fundamentals( function get_kline (line 422) | async def get_kline( function get_news (line 625) | async def get_news(code: str, days: int = 30, limit: int = 50, include_a... FILE: app/routers/sync.py function run_stock_basics_sync (line 17) | async def run_stock_basics_sync(force: bool = False): function get_stock_basics_status (line 27) | async def get_stock_basics_status(): FILE: app/routers/system_config.py function _mask_value (line 24) | def _mask_value(key: str, value: Any) -> Any: function _build_summary (line 40) | def _build_summary() -> Dict[str, Any]: function get_config_summary (line 53) | async def get_config_summary(current_user: dict = Depends(get_current_us... function validate_config (line 64) | async def validate_config(): FILE: app/routers/tags.py class TagCreate (line 15) | class TagCreate(BaseModel): class TagUpdate (line 21) | class TagUpdate(BaseModel): class TagResponse (line 27) | class TagResponse(BaseModel): function list_tags (line 37) | async def list_tags(current_user: dict = Depends(get_current_user)): function create_tag (line 46) | async def create_tag(payload: TagCreate, current_user: dict = Depends(ge... function update_tag (line 61) | async def update_tag(tag_id: str, payload: TagUpdate, current_user: dict... function delete_tag (line 80) | async def delete_tag(tag_id: str, current_user: dict = Depends(get_curre... FILE: app/routers/tushare_init.py class InitializationRequest (line 19) | class InitializationRequest(BaseModel): class DatabaseStatusResponse (line 26) | class DatabaseStatusResponse(BaseModel): class InitializationStatusResponse (line 36) | class InitializationStatusResponse(BaseModel): function get_database_status (line 56) | async def get_database_status( function get_initialization_status (line 112) | async def get_initialization_status( function start_basic_initialization (line 137) | async def start_basic_initialization( function start_full_initialization (line 161) | async def start_full_initialization( function stop_initialization (line 194) | async def stop_initialization( function _run_basic_initialization (line 226) | async def _run_basic_initialization(): function _run_full_initialization (line 253) | async def _run_full_initialization(historical_days: int, force_update: b... FILE: app/routers/usage_statistics.py function get_usage_records (line 20) | async def get_usage_records( function get_usage_statistics (line 57) | async def get_usage_statistics( function get_cost_by_provider (line 82) | async def get_cost_by_provider( function get_cost_by_model (line 101) | async def get_cost_by_model( function get_daily_cost (line 120) | async def get_daily_cost( function delete_old_records (line 139) | async def delete_old_records( FILE: app/routers/websocket_notifications.py class ConnectionManager (line 18) | class ConnectionManager: method __init__ (line 21) | def __init__(self): method connect (line 26) | async def connect(self, websocket: WebSocket, user_id: str): method disconnect (line 40) | async def disconnect(self, websocket: WebSocket, user_id: str): method send_personal_message (line 51) | async def send_personal_message(self, message: dict, user_id: str): method broadcast (line 81) | async def broadcast(self, message: dict): method get_stats (line 96) | def get_stats(self) -> dict: function websocket_notifications_endpoint (line 110) | async def websocket_notifications_endpoint( function websocket_task_progress_endpoint (line 201) | async def websocket_task_progress_endpoint( function get_websocket_stats (line 266) | async def get_websocket_stats(): function send_notification_via_websocket (line 272) | async def send_notification_via_websocket(user_id: str, notification: di... function send_task_progress_via_websocket (line 287) | async def send_task_progress_via_websocket(task_id: str, progress_data: ... FILE: app/scripts/init_providers.py function init_providers (line 17) | async def init_providers(): FILE: app/services/analysis/status_update_utils.py function perform_update_task_status (line 16) | async def perform_update_task_status( function perform_update_task_status_with_tracker (line 57) | async def perform_update_task_status_with_tracker( FILE: app/services/analysis_service.py class AnalysisService (line 46) | class AnalysisService: method __init__ (line 49) | def __init__(self): method _convert_user_id (line 59) | def _convert_user_id(self, user_id: str) -> PyObjectId: method _get_trading_graph (line 82) | def _get_trading_graph(self, config: Dict[str, Any]) -> TradingAgentsG... method _execute_analysis_sync_with_progress (line 99) | def _execute_analysis_sync_with_progress(self, task: AnalysisTask, pro... method _execute_analysis_sync (line 236) | def _execute_analysis_sync(self, task: AnalysisTask) -> AnalysisResult: method _execute_single_analysis_async (line 348) | async def _execute_single_analysis_async(self, task: AnalysisTask): method submit_single_analysis (line 422) | async def submit_single_analysis( method submit_batch_analysis (line 514) | async def submit_batch_analysis( method execute_analysis_task (line 616) | async def execute_analysis_task( method _update_task_status (line 740) | async def _update_task_status( method _update_task_status_with_tracker (line 754) | async def _update_task_status_with_tracker( method get_task_status (line 768) | async def get_task_status(self, task_id: str) -> Optional[Dict[str, An... method cancel_task (line 861) | async def cancel_task(self, task_id: str) -> bool: method _record_token_usage (line 877) | async def _record_token_usage( function get_analysis_service (line 949) | def get_analysis_service() -> AnalysisService: FILE: app/services/auth_service.py class TokenData (line 9) | class TokenData(BaseModel): class AuthService (line 13) | class AuthService: method create_access_token (line 15) | def create_access_token(sub: str, expires_minutes: int | None = None, ... method verify_token (line 27) | def verify_token(token: str) -> Optional[TokenData]: FILE: app/services/basics_sync/processing.py function add_financial_metrics (line 8) | def add_financial_metrics(doc: Dict, daily_metrics: Dict) -> None: FILE: app/services/basics_sync/utils.py function fetch_stock_basic_df (line 12) | def fetch_stock_basic_df(): function find_latest_trade_date (line 93) | def find_latest_trade_date() -> str: function fetch_daily_basic_mv_map (line 118) | def fetch_daily_basic_mv_map(trade_date: str) -> Dict[str, Dict[str, flo... function fetch_latest_roe_map (line 168) | def fetch_latest_roe_map() -> Dict[str, Dict[str, float]]: FILE: app/services/basics_sync_service.py class SyncStats (line 40) | class SyncStats: class BasicsSyncService (line 52) | class BasicsSyncService: method __init__ (line 53) | def __init__(self) -> None: method _ensure_indexes (line 59) | async def _ensure_indexes(self, db: AsyncIOMotorDatabase) -> None: method get_status (line 113) | async def get_status(self, db: Optional[AsyncIOMotorDatabase] = None) ... method _persist_status (line 125) | async def _persist_status(self, db: AsyncIOMotorDatabase, stats: Dict[... method _execute_bulk_write_with_retry (line 130) | async def _execute_bulk_write_with_retry( method run_full_sync (line 175) | async def run_full_sync(self, force: bool = False) -> Dict[str, Any]: method _fetch_stock_basic_df (line 361) | def _fetch_stock_basic_df(self): method _find_latest_trade_date (line 365) | def _find_latest_trade_date(self) -> str: method _fetch_daily_basic_mv_map (line 369) | def _fetch_daily_basic_mv_map(self, trade_date: str) -> Dict[str, Dict... method _fetch_latest_roe_map (line 373) | def _fetch_latest_roe_map(self) -> Dict[str, Dict[str, float]]: method _generate_full_symbol (line 377) | def _generate_full_symbol(self, code: str) -> str: function get_basics_sync_service (line 414) | def get_basics_sync_service() -> BasicsSyncService: FILE: app/services/config_provider.py class ConfigProvider (line 10) | class ConfigProvider: method __init__ (line 18) | def __init__(self, ttl_seconds: int = 60) -> None: method invalidate (line 23) | def invalidate(self) -> None: method _is_cache_valid (line 27) | def _is_cache_valid(self) -> bool: method get_effective_system_settings (line 34) | async def get_effective_system_settings(self) -> Dict[str, Any]: method get_system_settings_meta (line 72) | async def get_system_settings_meta(self) -> Dict[str, Dict[str, Any]]: FILE: app/services/config_service.py class ConfigService (line 24) | class ConfigService: method __init__ (line 27) | def __init__(self, db_manager=None): method _get_db (line 31) | async def _get_db(self): method get_market_categories (line 44) | async def get_market_categories(self) -> List[MarketCategory]: method _create_default_market_categories (line 64) | async def _create_default_market_categories(self) -> List[MarketCatego... method add_market_category (line 118) | async def add_market_category(self, category: MarketCategory) -> bool: method update_market_category (line 135) | async def update_market_category(self, category_id: str, updates: Dict... method delete_market_category (line 151) | async def delete_market_category(self, category_id: str) -> bool: method get_datasource_groupings (line 173) | async def get_datasource_groupings(self) -> List[DataSourceGrouping]: method add_datasource_to_category (line 185) | async def add_datasource_to_category(self, grouping: DataSourceGroupin... method remove_datasource_from_category (line 205) | async def remove_datasource_from_category(self, data_source_name: str,... method update_datasource_grouping (line 220) | async def update_datasource_grouping(self, data_source_name: str, cate... method update_category_datasource_order (line 288) | async def update_category_datasource_order(self, category_id: str, ord... method get_system_config (line 362) | async def get_system_config(self) -> Optional[SystemConfig]: method _create_default_config (line 396) | async def _create_default_config(self) -> SystemConfig: method save_system_config (line 516) | async def save_system_config(self, config: SystemConfig) -> bool: method delete_llm_config (line 575) | async def delete_llm_config(self, provider: str, model_name: str) -> b... method set_default_llm (line 619) | async def set_default_llm(self, model_name: str) -> bool: method set_default_data_source (line 641) | async def set_default_data_source(self, data_source_name: str) -> bool: method update_system_settings (line 663) | async def update_system_settings(self, settings: Dict[str, Any]) -> bool: method get_system_settings (line 708) | async def get_system_settings(self) -> Dict[str, Any]: method export_config (line 719) | async def export_config(self) -> Dict[str, Any]: method import_config (line 771) | async def import_config(self, config_data: Dict[str, Any]) -> bool: method _validate_config_data (line 822) | def _validate_config_data(self, config_data: Dict[str, Any]) -> bool: method migrate_legacy_config (line 837) | async def migrate_legacy_config(self) -> bool: method update_llm_config (line 851) | async def update_llm_config(self, llm_config: LLMConfig) -> bool: method test_llm_config (line 878) | async def test_llm_config(self, llm_config: LLMConfig) -> Dict[str, Any]: method _truncate_api_key (line 1110) | def _truncate_api_key(self, api_key: str, prefix_len: int = 6, suffix_... method test_data_source_config (line 1127) | async def test_data_source_config(self, ds_config: DataSourceConfig) -... method test_database_config (line 1686) | async def test_database_config(self, db_config: DatabaseConfig) -> Dic... method add_database_config (line 2142) | async def add_database_config(self, db_config: DatabaseConfig) -> bool: method update_database_config (line 2176) | async def update_database_config(self, db_config: DatabaseConfig) -> b... method delete_database_config (line 2213) | async def delete_database_config(self, db_name: str) -> bool: method get_database_config (line 2253) | async def get_database_config(self, db_name: str) -> Optional[Database... method get_database_configs (line 2270) | async def get_database_configs(self) -> List[DatabaseConfig]: method get_model_catalog (line 2285) | async def get_model_catalog(self) -> List[ModelCatalog]: method get_provider_models (line 2300) | async def get_provider_models(self, provider: str) -> Optional[ModelCa... method save_model_catalog (line 2314) | async def save_model_catalog(self, catalog: ModelCatalog) -> bool: method delete_model_catalog (line 2334) | async def delete_model_catalog(self, provider: str) -> bool: method init_default_model_catalog (line 2346) | async def init_default_model_catalog(self) -> bool: method _get_default_model_catalog (line 2371) | def _get_default_model_catalog(self) -> List[Dict[str, Any]]: method get_available_models (line 2667) | async def get_available_models(self) -> List[Dict[str, Any]]: method set_default_llm (line 2705) | async def set_default_llm(self, model_name: str) -> bool: method set_default_data_source (line 2727) | async def set_default_data_source(self, source_name: str) -> bool: method get_llm_providers (line 2751) | async def get_llm_providers(self) -> List[LLMProvider]: method _is_valid_api_key (line 2798) | def _is_valid_api_key(self, api_key: Optional[str]) -> bool: method _get_env_api_key (line 2842) | def _get_env_api_key(self, provider_name: str) -> Optional[str]: method add_llm_provider (line 2874) | async def add_llm_provider(self, provider: LLMProvider) -> str: method update_llm_provider (line 2899) | async def update_llm_provider(self, provider_id: str, update_data: Dic... method delete_llm_provider (line 2939) | async def delete_llm_provider(self, provider_id: str) -> bool: method toggle_llm_provider (line 2991) | async def toggle_llm_provider(self, provider_id: str, is_active: bool)... method init_aggregator_providers (line 3023) | async def init_aggregator_providers(self) -> Dict[str, Any]: method migrate_env_to_providers (line 3128) | async def migrate_env_to_providers(self) -> Dict[str, Any]: method test_provider_api (line 3251) | async def test_provider_api(self, provider_id: str) -> dict: method _test_provider_connection (line 3309) | async def _test_provider_connection(self, provider_name: str, api_key:... method _test_google_api (line 3367) | def _test_google_api(self, api_key: str, display_name: str, base_url: ... method _test_deepseek_api (line 3546) | def _test_deepseek_api(self, api_key: str, display_name: str, model_na... method _test_dashscope_api (line 3607) | def _test_dashscope_api(self, api_key: str, display_name: str, model_n... method _test_openrouter_api (line 3669) | def _test_openrouter_api(self, api_key: str, display_name: str) -> dict: method _test_openai_api (line 3725) | def _test_openai_api(self, api_key: str, display_name: str) -> dict: method _test_anthropic_api (line 3779) | def _test_anthropic_api(self, api_key: str, display_name: str) -> dict: method _test_qianfan_api (line 3833) | def _test_qianfan_api(self, api_key: str, display_name: str) -> dict: method fetch_provider_models (line 3906) | async def fetch_provider_models(self, provider_id: str) -> dict: method _fetch_models_from_api (line 3972) | def _fetch_models_from_api(self, api_key: str, base_url: str, display_... method _format_models_with_pricing (line 4078) | def _format_models_with_pricing(self, models: list) -> list: method _filter_popular_models (line 4157) | def _filter_popular_models(self, models: list) -> list: method _test_openai_compatible_api (line 4233) | def _test_openai_compatible_api(self, api_key: str, display_name: str,... FILE: app/services/data_consistency_checker.py class DataConsistencyResult (line 15) | class DataConsistencyResult: class FinancialMetricComparison (line 26) | class FinancialMetricComparison: class DataConsistencyChecker (line 35) | class DataConsistencyChecker: method __init__ (line 38) | def __init__(self): method check_daily_basic_consistency (line 59) | def check_daily_basic_consistency( method _find_common_stocks (line 133) | def _find_common_stocks(self, df1: pd.DataFrame, df2: pd.DataFrame) ->... method _compare_metric (line 149) | def _compare_metric( method _get_stock_metric_value (line 201) | def _get_stock_metric_value(self, df: pd.DataFrame, stock_code: str, m... method _calculate_overall_consistency (line 216) | def _calculate_overall_consistency( method resolve_data_conflicts (line 290) | def resolve_data_conflicts( FILE: app/services/data_sources/akshare_adapter.py class AKShareAdapter (line 14) | class AKShareAdapter(DataSourceAdapter): method __init__ (line 17) | def __init__(self): method name (line 21) | def name(self) -> str: method _get_default_priority (line 24) | def _get_default_priority(self) -> int: method is_available (line 27) | def is_available(self) -> bool: method get_stock_list (line 35) | def get_stock_list(self) -> Optional[pd.DataFrame]: method get_daily_basic (line 115) | def get_daily_basic(self, trade_date: str) -> Optional[pd.DataFrame]: method _safe_float (line 186) | def _safe_float(self, value) -> Optional[float]: method get_realtime_quotes (line 195) | def get_realtime_quotes(self, source: str = "eastmoney"): method get_kline (line 295) | def get_kline(self, code: str, period: str = "day", limit: int = 120, ... method get_news (line 345) | def get_news(self, code: str, days: int = 2, limit: int = 50, include_... method find_latest_trade_date (line 388) | def find_latest_trade_date(self) -> Optional[str]: FILE: app/services/data_sources/baostock_adapter.py class BaoStockAdapter (line 14) | class BaoStockAdapter(DataSourceAdapter): method __init__ (line 17) | def __init__(self): method name (line 21) | def name(self) -> str: method _get_default_priority (line 24) | def _get_default_priority(self) -> int: method is_available (line 27) | def is_available(self) -> bool: method get_stock_list (line 34) | def get_stock_list(self) -> Optional[pd.DataFrame]: method get_daily_basic (line 107) | def get_daily_basic(self, trade_date: str, max_stocks: int = None) -> ... method _safe_float (line 222) | def _safe_float(self, value) -> Optional[float]: method get_realtime_quotes (line 231) | def get_realtime_quotes(self): method get_kline (line 239) | def get_kline(self, code: str, period: str = "day", limit: int = 120, ... method get_news (line 245) | def get_news(self, code: str, days: int = 2, limit: int = 50, include_... method find_latest_trade_date (line 255) | def find_latest_trade_date(self) -> Optional[str]: FILE: app/services/data_sources/base.py class DataSourceAdapter (line 9) | class DataSourceAdapter(ABC): method __init__ (line 12) | def __init__(self): method name (line 17) | def name(self) -> str: method priority (line 22) | def priority(self) -> int: method _get_default_priority (line 30) | def _get_default_priority(self) -> int: method is_available (line 35) | def is_available(self) -> bool: method get_stock_list (line 40) | def get_stock_list(self) -> Optional[pd.DataFrame]: method get_daily_basic (line 45) | def get_daily_basic(self, trade_date: str) -> Optional[pd.DataFrame]: method find_latest_trade_date (line 50) | def find_latest_trade_date(self) -> Optional[str]: method get_realtime_quotes (line 56) | def get_realtime_quotes(self) -> Optional[Dict[str, Dict[str, Optional... method get_kline (line 62) | def get_kline(self, code: str, period: str = "day", limit: int = 120, ... method get_news (line 67) | def get_news(self, code: str, days: int = 2, limit: int = 50, include_... FILE: app/services/data_sources/data_consistency_checker.py class DataConsistencyResult (line 13) | class DataConsistencyResult: method __post_init__ (line 19) | def __post_init__(self): class DataConsistencyChecker (line 24) | class DataConsistencyChecker: method check_daily_basic_consistency (line 30) | def check_daily_basic_consistency( method resolve_data_conflicts (line 40) | def resolve_data_conflicts( FILE: app/services/data_sources/manager.py class DataSourceManager (line 17) | class DataSourceManager: method __init__ (line 25) | def __init__(self): method _load_priority_from_database (line 45) | def _load_priority_from_database(self): method get_available_adapters (line 91) | def get_available_adapters(self) -> List[DataSourceAdapter]: method get_stock_list_with_fallback (line 103) | def get_stock_list_with_fallback(self, preferred_sources: Optional[Lis... method get_daily_basic_with_fallback (line 140) | def get_daily_basic_with_fallback(self, trade_date: str, preferred_sou... method find_latest_trade_date_with_fallback (line 172) | def find_latest_trade_date_with_fallback(self, preferred_sources: Opti... method get_realtime_quotes_with_fallback (line 202) | def get_realtime_quotes_with_fallback(self) -> Tuple[Optional[Dict], O... method get_daily_basic_with_consistency_check (line 221) | def get_daily_basic_with_consistency_check( method get_kline_with_fallback (line 282) | def get_kline_with_fallback(self, code: str, period: str = "day", limi... method get_news_with_fallback (line 296) | def get_news_with_fallback(self, code: str, days: int = 2, limit: int ... FILE: app/services/data_sources/tushare_adapter.py class TushareAdapter (line 14) | class TushareAdapter(DataSourceAdapter): method __init__ (line 17) | def __init__(self): method _initialize (line 22) | def _initialize(self): method name (line 32) | def name(self) -> str: method _get_default_priority (line 35) | def _get_default_priority(self) -> int: method get_token_source (line 38) | def get_token_source(self) -> Optional[str]: method is_available (line 44) | def is_available(self) -> bool: method get_stock_list (line 59) | def get_stock_list(self) -> Optional[pd.DataFrame]: method get_daily_basic (line 82) | def get_daily_basic(self, trade_date: str) -> Optional[pd.DataFrame]: method get_realtime_quotes (line 100) | def get_realtime_quotes(self): method get_kline (line 169) | def get_kline(self, code: str, period: str = "day", limit: int = 120, ... method get_news (line 240) | def get_news(self, code: str, days: int = 2, limit: int = 50, include_... method find_latest_trade_date (line 295) | def find_latest_trade_date(self) -> Optional[str]: FILE: app/services/database/backups.py function _check_mongodump_available (line 25) | def _check_mongodump_available() -> bool: function create_backup_native (line 30) | async def create_backup_native(name: str, backup_dir: str, collections: ... function create_backup (line 137) | async def create_backup(name: str, backup_dir: str, collections: Optiona... function list_backups (line 203) | async def list_backups() -> List[Dict[str, Any]]: function delete_backup (line 219) | async def delete_backup(backup_id: str) -> None: function _convert_date_fields (line 236) | def _convert_date_fields(doc: dict) -> dict: function import_data (line 265) | async def import_data(content: bytes, collection: str, *, format: str = ... function _sanitize_document (line 402) | def _sanitize_document(doc: Any) -> Any: function export_data (line 448) | async def export_data(collections: Optional[List[str]] = None, *, export... FILE: app/services/database/cleanup.py function cleanup_old_data (line 12) | async def cleanup_old_data(days: int) -> Dict[str, Any]: function cleanup_analysis_results (line 44) | async def cleanup_analysis_results(days: int) -> Dict[str, Any]: function cleanup_operation_logs (line 71) | async def cleanup_operation_logs(days: int) -> Dict[str, Any]: FILE: app/services/database/serialization.py function serialize_document (line 10) | def serialize_document(doc: dict) -> dict: FILE: app/services/database/status_checks.py function get_mongodb_status (line 13) | async def get_mongodb_status() -> Dict[str, Any]: function get_redis_status (line 40) | async def get_redis_status() -> Dict[str, Any]: function get_database_status (line 67) | async def get_database_status() -> Dict[str, Any]: function test_mongodb_connection (line 73) | async def test_mongodb_connection() -> Dict[str, Any]: function test_redis_connection (line 84) | async def test_redis_connection() -> Dict[str, Any]: function test_connections (line 95) | async def test_connections() -> Dict[str, Any]: FILE: app/services/database_screening_service.py class DatabaseScreeningService (line 16) | class DatabaseScreeningService: method __init__ (line 19) | def __init__(self): method can_handle_conditions (line 70) | async def can_handle_conditions(self, conditions: List[Dict[str, Any]]... method screen_stocks (line 96) | async def screen_stocks( method _build_query (line 191) | async def _build_query(self, conditions: List[Dict[str, Any]]) -> Dict... method _build_sort_conditions (line 231) | def _build_sort_conditions(self, order_by: Optional[List[Dict[str, str... method _enrich_with_financial_data (line 253) | async def _enrich_with_financial_data(self, results: List[Dict[str, An... method _format_result (line 324) | def _format_result(self, doc: Dict[str, Any]) -> Dict[str, Any]: method get_field_statistics (line 390) | async def get_field_statistics(self, field: str) -> Dict[str, Any]: method _separate_conditions (line 439) | def _separate_conditions(self, conditions: List[Dict[str, Any]]) -> Tu... method _filter_by_quotes (line 464) | async def _filter_by_quotes( method get_available_values (line 556) | async def get_available_values(self, field: str, limit: int = 100) -> ... function get_database_screening_service (line 593) | def get_database_screening_service() -> DatabaseScreeningService: FILE: app/services/database_service.py class DatabaseService (line 29) | class DatabaseService: method __init__ (line 32) | def __init__(self): method get_database_status (line 40) | async def get_database_status(self) -> Dict[str, Any]: method _get_mongodb_status (line 44) | async def _get_mongodb_status(self) -> Dict[str, Any]: method _get_redis_status (line 48) | async def _get_redis_status(self) -> Dict[str, Any]: method get_database_stats (line 52) | async def get_database_stats(self) -> Dict[str, Any]: method test_connections (line 112) | async def test_connections(self) -> Dict[str, Any]: method _test_mongodb_connection (line 116) | async def _test_mongodb_connection(self) -> Dict[str, Any]: method _test_redis_connection (line 120) | async def _test_redis_connection(self) -> Dict[str, Any]: method create_backup (line 124) | async def create_backup(self, name: str, collections: List[str] = None... method list_backups (line 150) | async def list_backups(self) -> List[Dict[str, Any]]: method delete_backup (line 154) | async def delete_backup(self, backup_id: str) -> None: method cleanup_old_data (line 158) | async def cleanup_old_data(self, days: int) -> Dict[str, Any]: method cleanup_analysis_results (line 162) | async def cleanup_analysis_results(self, days: int) -> Dict[str, Any]: method cleanup_operation_logs (line 166) | async def cleanup_operation_logs(self, days: int) -> Dict[str, Any]: method import_data (line 170) | async def import_data(self, content: bytes, collection: str, format: s... method export_data (line 175) | async def export_data(self, collections: List[str] = None, format: str... method _serialize_document (line 179) | def _serialize_document(self, doc: dict) -> dict: FILE: app/services/enhanced_screening/utils.py function analyze_conditions (line 11) | def analyze_conditions(conditions: List[ScreeningCondition]) -> Dict[str... function convert_conditions_to_traditional_format (line 56) | def convert_conditions_to_traditional_format(conditions: List[ScreeningC... FILE: app/services/enhanced_screening_service.py class EnhancedScreeningService (line 24) | class EnhancedScreeningService: method __init__ (line 27) | def __init__(self): method screen_stocks (line 34) | async def screen_stocks( method _analyze_conditions (line 151) | def _analyze_conditions(self, conditions: List[ScreeningCondition]) ->... method _screen_with_database (line 157) | async def _screen_with_database( method _screen_with_traditional_method (line 174) | async def _screen_with_traditional_method( method _convert_conditions_to_traditional_format (line 205) | def _convert_conditions_to_traditional_format( method _enrich_results_with_realtime_metrics (line 212) | async def _enrich_results_with_realtime_metrics(self, items: List[Dict... method get_field_info (line 233) | async def get_field_info(self, field: str) -> Optional[Dict[str, Any]]: method get_all_supported_fields (line 268) | async def get_all_supported_fields(self) -> List[Dict[str, Any]]: method validate_conditions (line 279) | async def validate_conditions(self, conditions: List[ScreeningConditio... function get_enhanced_screening_service (line 343) | def get_enhanced_screening_service() -> EnhancedScreeningService: FILE: app/services/favorites_service.py class FavoritesService (line 14) | class FavoritesService: method __init__ (line 17) | def __init__(self): method _get_db (line 20) | async def _get_db(self): method _is_valid_object_id (line 26) | def _is_valid_object_id(self, user_id: str) -> bool: method _format_favorite (line 35) | def _format_favorite(self, favorite: Dict[str, Any]) -> Dict[str, Any]: method get_user_favorites (line 57) | async def get_user_favorites(self, user_id: str) -> List[Dict[str, Any]]: method add_favorite (line 154) | async def add_favorite( method remove_favorite (line 236) | async def remove_favorite(self, user_id: str, stock_code: str) -> bool: method update_favorite (line 263) | async def update_favorite( method is_favorite (line 315) | async def is_favorite(self, user_id: str, stock_code: str) -> bool: method get_user_tags (line 364) | async def get_user_tags(self, user_id: str) -> List[str]: method _get_mock_price (line 389) | def _get_mock_price(self, stock_code: str) -> float: method _get_mock_change (line 395) | def _get_mock_change(self, stock_code: str) -> float: method _get_mock_volume (line 401) | def _get_mock_volume(self, stock_code: str) -> int: FILE: app/services/financial_data_service.py class FinancialDataService (line 17) | class FinancialDataService: method __init__ (line 20) | def __init__(self): method initialize (line 24) | async def initialize(self): method _ensure_indexes (line 40) | async def _ensure_indexes(self): method save_financial_data (line 76) | async def save_financial_data( method get_financial_data (line 164) | async def get_financial_data( method get_latest_financial_data (line 218) | async def get_latest_financial_data( method get_financial_statistics (line 232) | async def get_financial_statistics(self) -> Dict[str, Any]: method _standardize_financial_data (line 289) | def _standardize_financial_data( method _standardize_tushare_data (line 323) | def _standardize_tushare_data( method _standardize_akshare_data (line 360) | def _standardize_akshare_data( method _standardize_baostock_data (line 388) | def _standardize_baostock_data( method _get_full_symbol (line 415) | def _get_full_symbol(self, symbol: str, market: str) -> str: method _extract_latest_period (line 424) | def _extract_latest_period(self, financial_data: Dict[str, Any]) -> str: method _extract_akshare_indicators (line 440) | def _extract_akshare_indicators(self, financial_data: Dict[str, Any]) ... method _generate_current_period (line 481) | def _generate_current_period(self) -> str: method _safe_float (line 503) | def _safe_float(self, value) -> Optional[float]: function get_financial_data_service (line 520) | async def get_financial_data_service() -> FinancialDataService: FILE: app/services/foreign_stock_service.py class ForeignStockService (line 24) | class ForeignStockService: method __init__ (line 41) | def __init__(self, db=None): method get_quote (line 59) | async def get_quote(self, market: str, code: str, force_refresh: bool ... method get_basic_info (line 84) | async def get_basic_info(self, market: str, code: str, force_refresh: ... method get_kline (line 103) | async def get_kline(self, market: str, code: str, period: str = 'day', method _get_hk_quote (line 125) | async def _get_hk_quote(self, code: str, force_refresh: bool = False) ... method _get_source_priority (line 239) | async def _get_source_priority(self, market: str) -> List[str]: method _get_hk_quote_from_yfinance (line 276) | def _get_hk_quote_from_yfinance(self, code: str) -> Dict: method _get_hk_quote_from_akshare (line 283) | def _get_hk_quote_from_akshare(self, code: str) -> Dict: method _get_us_quote (line 296) | async def _get_us_quote(self, code: str, force_refresh: bool = False) ... method _get_us_quote_from_yfinance (line 424) | def _get_us_quote_from_yfinance(self, code: str) -> Dict: method _get_us_quote_from_alpha_vantage (line 449) | def _get_us_quote_from_alpha_vantage(self, code: str) -> Dict: method _get_us_quote_from_finnhub (line 492) | def _get_us_quote_from_finnhub(self, code: str) -> Dict: method _get_hk_info (line 529) | async def _get_hk_info(self, code: str, force_refresh: bool = False) -... method _get_us_info (line 608) | async def _get_us_info(self, code: str, force_refresh: bool = False) -... method _get_hk_kline (line 711) | async def _get_hk_kline(self, code: str, period: str, limit: int, forc... method _get_us_kline (line 788) | async def _get_us_kline(self, code: str, period: str, limit: int, forc... method _format_hk_quote (line 865) | def _format_hk_quote(self, data: Dict, code: str, source: str) -> Dict: method _format_hk_info (line 882) | def _format_hk_info(self, data: Dict, code: str, source: str) -> Dict: method _parse_cached_data (line 910) | def _parse_cached_data(self, cached_data: str, market: str, code: str)... method _parse_cached_kline (line 931) | def _parse_cached_kline(self, cached_data: str) -> List[Dict]: method _get_us_info_from_yfinance (line 950) | def _get_us_info_from_yfinance(self, code: str) -> Dict: method _safe_float (line 971) | def _safe_float(self, value, default=None): method _get_us_info_from_alpha_vantage (line 980) | def _get_us_info_from_alpha_vantage(self, code: str) -> Dict: method _get_us_info_from_finnhub (line 1007) | def _get_us_info_from_finnhub(self, code: str) -> Dict: method _get_us_kline_from_yfinance (line 1037) | def _get_us_kline_from_yfinance(self, code: str, period: str, limit: i... method _get_us_kline_from_alpha_vantage (line 1076) | def _get_us_kline_from_alpha_vantage(self, code: str, period: str, lim... method _get_us_kline_from_finnhub (line 1134) | def _get_us_kline_from_finnhub(self, code: str, period: str, limit: in... method get_hk_news (line 1204) | async def get_hk_news(self, code: str, days: int = 2, limit: int = 50)... method get_us_news (line 1300) | async def get_us_news(self, code: str, days: int = 2, limit: int = 50)... method _get_us_news_from_alpha_vantage (line 1396) | def _get_us_news_from_alpha_vantage(self, code: str, days: int, limit:... method _get_us_news_from_finnhub (line 1459) | def _get_us_news_from_finnhub(self, code: str, days: int, limit: int) ... method _get_hk_news_from_finnhub (line 1506) | def _get_hk_news_from_finnhub(self, code: str, days: int, limit: int) ... method _get_hk_info_from_akshare (line 1556) | def _get_hk_info_from_akshare(self, code: str) -> Dict: method _get_hk_info_from_yfinance (line 1615) | def _get_hk_info_from_yfinance(self, code: str) -> Dict: method _get_hk_info_from_finnhub (line 1633) | def _get_hk_info_from_finnhub(self, code: str) -> Dict: method _get_hk_kline_from_akshare (line 1666) | def _get_hk_kline_from_akshare(self, code: str, period: str, limit: in... method _get_hk_kline_from_yfinance (line 1703) | def _get_hk_kline_from_yfinance(self, code: str, period: str, limit: i... method _get_hk_kline_from_finnhub (line 1743) | def _get_hk_kline_from_finnhub(self, code: str, period: str, limit: in... method _get_hk_news_from_akshare (line 1799) | def _get_hk_news_from_akshare(self, code: str, days: int, limit: int) ... FILE: app/services/historical_data_service.py class HistoricalDataService (line 18) | class HistoricalDataService: method __init__ (line 21) | def __init__(self): method initialize (line 26) | async def initialize(self): method _ensure_indexes (line 40) | async def _ensure_indexes(self): method save_historical_data (line 70) | async def save_historical_data( method _execute_bulk_write_with_retry (line 193) | async def _execute_bulk_write_with_retry( method _standardize_record (line 248) | def _standardize_record( method _get_full_symbol (line 330) | def _get_full_symbol(self, symbol: str, market: str) -> str: method _format_date (line 346) | def _format_date(self, date_value) -> str: method _safe_float (line 364) | def _safe_float(self, value) -> Optional[float]: method get_historical_data (line 373) | async def get_historical_data( method get_latest_date (line 432) | async def get_latest_date(self, symbol: str, data_source: str) -> Opti... method get_data_statistics (line 451) | async def get_data_statistics(self) -> Dict[str, Any]: function get_historical_data_service (line 500) | async def get_historical_data_service() -> HistoricalDataService: FILE: app/services/internal_message_service.py function convert_objectid_to_str (line 18) | def convert_objectid_to_str(data: Union[Dict, List[Dict]]) -> Union[Dict... class InternalMessageQueryParams (line 41) | class InternalMessageQueryParams: class InternalMessageStats (line 65) | class InternalMessageStats: class InternalMessageService (line 77) | class InternalMessageService: method __init__ (line 80) | def __init__(self): method initialize (line 85) | async def initialize(self): method _get_collection (line 95) | async def _get_collection(self): method save_internal_messages (line 101) | async def save_internal_messages( method query_internal_messages (line 158) | async def query_internal_messages( method get_latest_messages (line 245) | async def get_latest_messages( method search_messages (line 263) | async def search_messages( method get_research_reports (line 300) | async def get_research_reports( method get_analyst_notes (line 317) | async def get_analyst_notes( method get_internal_statistics (line 334) | async def get_internal_statistics( function get_internal_message_service (line 410) | async def get_internal_message_service() -> InternalMessageService: FILE: app/services/log_export_service.py class LogExportService (line 18) | class LogExportService: method __init__ (line 21) | def __init__(self, log_dir: str = "./logs"): method list_log_files (line 45) | def list_log_files(self) -> List[Dict[str, Any]]: method _get_log_type (line 107) | def _get_log_type(self, filename: str) -> str: method read_log_file (line 128) | def read_log_file( method export_logs (line 217) | def export_logs( method get_log_statistics (line 317) | def get_log_statistics(self, days: int = 7) -> Dict[str, Any]: function get_log_export_service (line 379) | def get_log_export_service() -> LogExportService: function _get_log_directory (line 391) | def _get_log_directory() -> str: FILE: app/services/memory_state_manager.py class TaskStatus (line 16) | class TaskStatus(Enum): class TaskState (line 25) | class TaskState: method to_dict (line 48) | def to_dict(self) -> Dict[str, Any]: class MemoryStateManager (line 94) | class MemoryStateManager: method __init__ (line 97) | def __init__(self): method set_websocket_manager (line 105) | def set_websocket_manager(self, websocket_manager): method create_task (line 109) | async def create_task( method _calculate_estimated_duration (line 140) | def _calculate_estimated_duration(self, parameters: Dict[str, Any]) ->... method update_task_status (line 180) | async def update_task_status( method get_task (line 246) | async def get_task(self, task_id: str) -> Optional[TaskState]: method get_task_dict (line 259) | async def get_task_dict(self, task_id: str) -> Optional[Dict[str, Any]]: method list_all_tasks (line 264) | async def list_all_tasks( method list_user_tasks (line 287) | async def list_user_tasks( method delete_task (line 312) | async def delete_task(self, task_id: str) -> bool: method get_statistics (line 321) | async def get_statistics(self) -> Dict[str, Any]: method cleanup_old_tasks (line 339) | async def cleanup_old_tasks(self, max_age_hours: int = 24) -> int: method cleanup_zombie_tasks (line 356) | async def cleanup_zombie_tasks(self, max_running_hours: int = 2) -> int: method remove_task (line 394) | async def remove_task(self, task_id: str) -> bool: function get_memory_state_manager (line 415) | def get_memory_state_manager() -> MemoryStateManager: FILE: app/services/model_capability_service.py class ModelCapabilityService (line 22) | class ModelCapabilityService: method _parse_aggregator_model_name (line 25) | def _parse_aggregator_model_name(self, model_name: str) -> Tuple[Optio... method _get_model_capability_with_mapping (line 64) | def _get_model_capability_with_mapping(self, model_name: str) -> Tuple... method get_model_capability (line 87) | def get_model_capability(self, model_name: str) -> int: method get_model_config (line 113) | def get_model_config(self, model_name: str) -> Dict[str, Any]: method validate_model_pair (line 217) | def validate_model_pair( method recommend_models_for_depth (line 312) | def recommend_models_for_depth( method _get_default_models (line 395) | def _get_default_models(self) -> Tuple[str, str]: method _recommend_model (line 406) | def _recommend_model(self, model_type: str, min_level: int) -> str: function get_model_capability_service (line 424) | def get_model_capability_service() -> ModelCapabilityService: FILE: app/services/multi_source_basics_sync_service.py class DataSourcePriority (line 33) | class DataSourcePriority(Enum): class SyncStats (line 41) | class SyncStats: class MultiSourceBasicsSyncService (line 58) | class MultiSourceBasicsSyncService: method __init__ (line 61) | def __init__(self): method get_status (line 66) | async def get_status(self) -> Dict[str, Any]: method _persist_status (line 79) | async def _persist_status(self, db: AsyncIOMotorDatabase, stats: Dict[... method _execute_bulk_write_with_retry (line 98) | async def _execute_bulk_write_with_retry( method run_full_sync (line 143) | async def run_full_sync(self, force: bool = False, preferred_sources: ... method _add_financial_metrics (line 336) | def _add_financial_metrics(self, doc: Dict, daily_metrics: Dict) -> None: method _generate_full_symbol (line 340) | def _generate_full_symbol(self, code: str) -> str: function get_multi_source_sync_service (line 376) | def get_multi_source_sync_service() -> MultiSourceBasicsSyncService: FILE: app/services/news_data_service.py function convert_objectid_to_str (line 18) | def convert_objectid_to_str(data: Union[Dict, List[Dict]]) -> Union[Dict... class NewsQueryParams (line 41) | class NewsQueryParams: class NewsStats (line 59) | class NewsStats: method __post_init__ (line 71) | def __post_init__(self): class NewsDataService (line 78) | class NewsDataService: method __init__ (line 81) | def __init__(self): method _ensure_indexes (line 87) | async def _ensure_indexes(self): method _get_collection (line 139) | def _get_collection(self): method save_news_data (line 146) | async def save_news_data( method save_news_data_sync (line 244) | def save_news_data_sync( method _standardize_news_data (line 347) | def _standardize_news_data( method _get_full_symbol (line 400) | def _get_full_symbol(self, symbol: str, market: str) -> str: method _parse_datetime (line 414) | def _parse_datetime(self, dt_value) -> Optional[datetime]: method _safe_float (line 447) | def _safe_float(self, value) -> Optional[float]: method query_news (line 457) | async def query_news(self, params: NewsQueryParams) -> List[Dict[str, ... method get_latest_news (line 552) | async def get_latest_news( method get_news_statistics (line 581) | async def get_news_statistics( method delete_old_news (line 683) | async def delete_old_news(self, days_to_keep: int = 90) -> int: method search_news (line 711) | async def search_news( function get_news_data_service (line 760) | async def get_news_data_service() -> NewsDataService: FILE: app/services/notifications_service.py class NotificationsService (line 19) | class NotificationsService: method __init__ (line 20) | def __init__(self): method _ensure_indexes (line 26) | async def _ensure_indexes(self): method create_and_publish (line 34) | async def create_and_publish(self, payload: NotificationCreate) -> str: method unread_count (line 91) | async def unread_count(self, user_id: str) -> int: method list (line 95) | async def list(self, user_id: str, *, status: Optional[str] = None, nt... method mark_read (line 118) | async def mark_read(self, user_id: str, notif_id: str) -> bool: method mark_all_read (line 127) | async def mark_all_read(self, user_id: str) -> int: function get_notifications_service (line 136) | def get_notifications_service() -> NotificationsService: FILE: app/services/operation_log_service.py class OperationLogService (line 24) | class OperationLogService: method __init__ (line 27) | def __init__(self): method create_log (line 30) | async def create_log( method get_logs (line 71) | async def get_logs(self, query: OperationLogQuery) -> Tuple[List[Opera... method get_stats (line 131) | async def get_stats(self, days: int = 30) -> OperationLogStats: method clear_logs (line 197) | async def clear_logs(self, days: Optional[int] = None, action_type: Op... method get_log_by_id (line 228) | async def get_log_by_id(self, log_id: str) -> Optional[OperationLogRes... function get_operation_log_service (line 249) | def get_operation_log_service() -> OperationLogService: function log_operation (line 258) | async def log_operation( FILE: app/services/progress/log_handler.py class ProgressLogHandler (line 15) | class ProgressLogHandler(logging.Handler): method __init__ (line 18) | def __init__(self): method register_tracker (line 61) | def register_tracker(self, task_id: str, tracker: RedisProgressTracker): method unregister_tracker (line 67) | def unregister_tracker(self, task_id: str): method emit (line 74) | def emit(self, record): method _extract_progress_message (line 104) | def _extract_progress_message(self, message: str) -> Optional[str]: method _extract_stock_symbol (line 124) | def _extract_stock_symbol(self, message: str) -> Optional[str]: function get_progress_log_handler (line 146) | def get_progress_log_handler() -> ProgressLogHandler: function register_analysis_tracker (line 175) | def register_analysis_tracker(task_id: str, tracker: RedisProgressTracker): function unregister_analysis_tracker (line 181) | def unregister_analysis_tracker(task_id: str): FILE: app/services/progress/tracker.py class AnalysisStep (line 21) | class AnalysisStep: function safe_serialize (line 31) | def safe_serialize(data): class RedisProgressTracker (line 46) | class RedisProgressTracker: method __init__ (line 49) | def __init__(self, task_id: str, analysts: List[str], research_depth: ... method _init_redis (line 91) | def _init_redis(self) -> bool: method _generate_dynamic_steps (line 133) | def _generate_dynamic_steps(self) -> List[AnalysisStep]: method _get_debate_rounds (line 176) | def _get_debate_rounds(self) -> int: method _get_analyst_step_info (line 184) | def _get_analyst_step_info(self, analyst: str) -> Dict[str, str]: method _estimate_step_time (line 194) | def _estimate_step_time(self, step: AnalysisStep) -> float: method _get_base_total_time (line 198) | def _get_base_total_time(self) -> float: method _calculate_time_estimates (line 256) | def _calculate_time_estimates(self) -> tuple[float, float, float]: method _calculate_static_time_estimates (line 277) | def _calculate_static_time_estimates(progress_data: dict) -> dict: method update_progress (line 300) | def update_progress(self, progress_update: Any) -> Dict[str, Any]: method _update_steps_by_progress (line 345) | def _update_steps_by_progress(self, progress_pct: float) -> None: method _detect_current_step (line 374) | def _detect_current_step(self) -> int: method _find_step_by_name (line 394) | def _find_step_by_name(self, step_name: str) -> Optional[AnalysisStep]: method _find_step_by_pattern (line 400) | def _find_step_by_pattern(self, pattern: str) -> Optional[AnalysisStep]: method _save_progress (line 406) | def _save_progress(self) -> None: method mark_completed (line 421) | def mark_completed(self) -> Dict[str, Any]: method mark_failed (line 437) | def mark_failed(self, reason: str = "") -> Dict[str, Any]: method to_dict (line 453) | def to_dict(self) -> Dict[str, Any]: function get_progress_by_id (line 477) | def get_progress_by_id(task_id: str) -> Optional[Dict[str, Any]]: FILE: app/services/queue/helpers.py function check_user_concurrent_limit (line 18) | async def check_user_concurrent_limit(r: Redis, user_id: str, limit: int... function check_global_concurrent_limit (line 25) | async def check_global_concurrent_limit(r: Redis, limit: int) -> bool: function mark_task_processing (line 31) | async def mark_task_processing(r: Redis, task_id: str, user_id: str) -> ... function unmark_task_processing (line 38) | async def unmark_task_processing(r: Redis, task_id: str, user_id: str) -... function set_visibility_timeout (line 45) | async def set_visibility_timeout(r: Redis, task_id: str, worker_id: str,... function clear_visibility_timeout (line 57) | async def clear_visibility_timeout(r: Redis, task_id: str) -> None: FILE: app/services/queue_service.py class QueueService (line 45) | class QueueService: method __init__ (line 48) | def __init__(self, redis: Redis): method enqueue_task (line 54) | async def enqueue_task( method dequeue_task (line 100) | async def dequeue_task(self, worker_id: str) -> Optional[Dict[str, Any]]: method ack_task (line 143) | async def ack_task(self, task_id: str, success: bool = True) -> bool: method create_batch (line 179) | async def create_batch(self, user_id: str, symbols: List[str], params:... method get_task (line 194) | async def get_task(self, task_id: str) -> Optional[Dict[str, Any]]: method get_batch (line 211) | async def get_batch(self, batch_id: str) -> Optional[Dict[str, Any]]: method stats (line 225) | async def stats(self) -> Dict[str, int]: method _check_user_concurrent_limit (line 238) | async def _check_user_concurrent_limit(self, user_id: str) -> bool: method _check_global_concurrent_limit (line 242) | async def _check_global_concurrent_limit(self) -> bool: method _mark_task_processing (line 246) | async def _mark_task_processing(self, task_id: str, user_id: str, work... method _unmark_task_processing (line 250) | async def _unmark_task_processing(self, task_id: str, user_id: str): method _set_visibility_timeout (line 254) | async def _set_visibility_timeout(self, task_id: str, worker_id: str): method _clear_visibility_timeout (line 258) | async def _clear_visibility_timeout(self, task_id: str): method get_user_queue_status (line 262) | async def get_user_queue_status(self, user_id: str) -> Dict[str, int]: method cleanup_expired_tasks (line 273) | async def cleanup_expired_tasks(self): method _handle_expired_task (line 301) | async def _handle_expired_task(self, task_id: str): method cancel_task (line 331) | async def cancel_task(self, task_id: str) -> bool: function get_queue_service (line 363) | def get_queue_service() -> QueueService: FILE: app/services/quotes_ingestion_service.py class QuotesIngestionService (line 16) | class QuotesIngestionService: method __init__ (line 28) | def __init__(self, collection_name: str = "market_quotes") -> None: method _normalize_stock_code (line 48) | def _normalize_stock_code(code: str) -> str: method ensure_indexes (line 87) | async def ensure_indexes(self) -> None: method _record_sync_status (line 96) | async def _record_sync_status( method get_sync_status (line 139) | async def get_sync_status(self) -> Dict[str, any]: method _check_tushare_permission (line 207) | def _check_tushare_permission(self) -> bool: method _can_call_tushare (line 255) | def _can_call_tushare(self) -> bool: method _record_tushare_call (line 285) | def _record_tushare_call(self) -> None: method _get_next_source (line 289) | def _get_next_source(self) -> Tuple[str, Optional[str]]: method _is_trading_time (line 315) | def _is_trading_time(self, now: Optional[datetime] = None) -> bool: method _collection_empty (line 343) | async def _collection_empty(self) -> bool: method _collection_stale (line 352) | async def _collection_stale(self, latest_trade_date: Optional[str]) ->... method _bulk_upsert (line 367) | async def _bulk_upsert(self, quotes_map: Dict[str, Dict], trade_date: ... method backfill_from_historical_data (line 413) | async def backfill_from_historical_data(self) -> None: method backfill_last_close_snapshot (line 500) | async def backfill_last_close_snapshot(self) -> None: method backfill_last_close_snapshot_if_needed (line 517) | async def backfill_last_close_snapshot_if_needed(self) -> None: method _fetch_quotes_from_source (line 537) | def _fetch_quotes_from_source(self, source_type: str, akshare_api: Opt... method run_once (line 597) | async def run_once(self) -> None: FILE: app/services/quotes_service.py function _safe_float (line 16) | def _safe_float(v) -> Optional[float]: class QuotesService (line 34) | class QuotesService: method __init__ (line 35) | def __init__(self, ttl_seconds: int = 30) -> None: method get_quotes (line 41) | async def get_quotes(self, codes: List[str]) -> Dict[str, Dict[str, Op... method _fetch_spot_akshare (line 57) | def _fetch_spot_akshare(self) -> Dict[str, Dict[str, Optional[float]]]: function get_quotes_service (line 106) | def get_quotes_service() -> QuotesService: FILE: app/services/scheduler_service.py function get_utc8_now (line 30) | def get_utc8_now(): class TaskCancelledException (line 40) | class TaskCancelledException(Exception): class SchedulerService (line 45) | class SchedulerService: method __init__ (line 48) | def __init__(self, scheduler: AsyncIOScheduler): method _get_db (line 61) | def _get_db(self): method list_jobs (line 67) | async def list_jobs(self) -> List[Dict[str, Any]]: method get_job (line 87) | async def get_job(self, job_id: str) -> Optional[Dict[str, Any]]: method pause_job (line 108) | async def pause_job(self, job_id: str) -> bool: method resume_job (line 130) | async def resume_job(self, job_id: str) -> bool: method trigger_job (line 152) | async def trigger_job(self, job_id: str, kwargs: Optional[Dict[str, An... method get_job_history (line 221) | async def get_job_history( method count_job_history (line 254) | async def count_job_history(self, job_id: str) -> int: method get_all_history (line 272) | async def get_all_history( method count_all_history (line 313) | async def count_all_history( method get_job_executions (line 344) | async def get_job_executions( method count_job_executions (line 409) | async def count_job_executions( method cancel_job_execution (line 451) | async def cancel_job_execution(self, execution_id: str) -> bool: method mark_execution_as_failed (line 496) | async def mark_execution_as_failed(self, execution_id: str, reason: st... method delete_execution (line 538) | async def delete_execution(self, execution_id: str) -> bool: method get_job_execution_stats (line 577) | async def get_job_execution_stats(self, job_id: str) -> Dict[str, Any]: method get_stats (line 635) | async def get_stats(self) -> Dict[str, Any]: method health_check (line 656) | async def health_check(self) -> Dict[str, Any]: method _job_to_dict (line 670) | def _job_to_dict(self, job: Job, include_details: bool = False) -> Dic... method _setup_event_listeners (line 700) | def _setup_event_listeners(self): method _check_zombie_tasks (line 733) | async def _check_zombie_tasks(self): method _on_job_executed (line 766) | def _on_job_executed(self, event: JobExecutionEvent): method _on_job_error (line 783) | def _on_job_error(self, event: JobExecutionEvent): method _on_job_missed (line 801) | def _on_job_missed(self, event: JobExecutionEvent): method _record_job_execution (line 810) | async def _record_job_execution( method _record_job_action (line 931) | async def _record_job_action( method _get_job_metadata (line 959) | async def _get_job_metadata(self, job_id: str) -> Optional[Dict[str, A... method update_job_metadata (line 980) | async def update_job_metadata( function set_scheduler_instance (line 1034) | def set_scheduler_instance(scheduler: AsyncIOScheduler): function get_scheduler_service (line 1046) | def get_scheduler_service() -> SchedulerService: function update_job_progress (line 1065) | async def update_job_progress( FILE: app/services/screening/eval_utils.py function collect_fields_from_conditions (line 12) | def collect_fields_from_conditions(node: Dict[str, Any], allowed_fields:... function evaluate_fund_conditions (line 31) | def evaluate_fund_conditions(snap: Dict[str, Any], node: Dict[str, Any],... function evaluate_conditions (line 78) | def evaluate_conditions( function safe_float (line 160) | def safe_float(v: Any) -> Optional[float]: FILE: app/services/screening_service.py class ScreeningParams (line 59) | class ScreeningParams: class ScreeningService (line 71) | class ScreeningService: method __init__ (line 72) | def __init__(self): method run (line 77) | def run(self, conditions: Dict[str, Any], params: ScreeningParams) -> ... method _evaluate_fund_conditions (line 187) | def _evaluate_fund_conditions(self, snap: Dict[str, Any], node: Dict[s... method _collect_fields_from_conditions (line 192) | def _collect_fields_from_conditions(self, node: Dict[str, Any]) -> Lis... method _evaluate_conditions (line 197) | def _evaluate_conditions(self, df: pd.DataFrame, node: Dict[str, Any])... method _safe_float (line 202) | def _safe_float(self, v: Any) -> Optional[float]: method _get_universe (line 206) | def _get_universe(self) -> List[str]: FILE: app/services/simple_analysis_service.py function _get_stock_info_safe (line 40) | def _get_stock_info_safe(stock_code: str): function get_provider_by_model_name (line 53) | async def get_provider_by_model_name(model_name: str) -> str: function get_provider_by_model_name_sync (line 86) | def get_provider_by_model_name_sync(model_name: str) -> str: function get_provider_and_url_by_model_sync (line 100) | def get_provider_and_url_by_model_sync(model_name: str) -> dict: function _get_env_api_key_for_provider (line 272) | def _get_env_api_key_for_provider(provider: str) -> str: function _get_default_backend_url (line 305) | def _get_default_backend_url(provider: str) -> str: function _get_default_provider_by_model (line 331) | def _get_default_provider_by_model(model_name: str) -> str: function create_analysis_config (line 372) | def create_analysis_config( class SimpleAnalysisService (line 591) | class SimpleAnalysisService: method __init__ (line 594) | def __init__(self): method _update_progress_async (line 621) | async def _update_progress_async(self, task_id: str, progress: int, me... method _resolve_stock_name (line 652) | def _resolve_stock_name(self, code: Optional[str]) -> str: method _enrich_stock_names (line 673) | def _enrich_stock_names(self, tasks: List[Dict[str, Any]]) -> List[Dic... method _convert_user_id (line 685) | def _convert_user_id(self, user_id: str) -> PyObjectId: method _get_trading_graph (line 707) | def _get_trading_graph(self, config: Dict[str, Any]) -> TradingAgentsG... method create_analysis_task (line 730) | async def create_analysis_task( method execute_analysis_background (line 809) | async def execute_analysis_background( method _execute_analysis_sync (line 1063) | async def _execute_analysis_sync( method _run_analysis_sync (line 1086) | def _run_analysis_sync( method get_task_status (line 1849) | async def get_task_status(self, task_id: str) -> Optional[Dict[str, An... method list_all_tasks (line 1936) | async def list_all_tasks( method list_user_tasks (line 2021) | async def list_user_tasks( method cleanup_zombie_tasks (line 2222) | async def cleanup_zombie_tasks(self, max_running_hours: int = 2) -> Di... method get_zombie_tasks (line 2284) | async def get_zombie_tasks(self, max_running_hours: int = 2) -> List[D... method _update_task_status (line 2339) | async def _update_task_status( method _save_analysis_result (line 2373) | async def _save_analysis_result(self, task_id: str, result: Dict[str, ... method _save_analysis_result_web_style (line 2385) | async def _save_analysis_result_web_style(self, task_id: str, result: ... method _save_analysis_results_complete (line 2673) | async def _save_analysis_results_complete(self, task_id: str, result: ... method _save_modular_reports_to_data_dir (line 2715) | async def _save_modular_reports_to_data_dir(self, result: Dict[str, An... function get_simple_analysis_service (line 2900) | def get_simple_analysis_service() -> SimpleAnalysisService: FILE: app/services/social_media_service.py class SocialMediaQueryParams (line 18) | class SocialMediaQueryParams: class SocialMediaStats (line 40) | class SocialMediaStats: class SocialMediaService (line 56) | class SocialMediaService: method __init__ (line 59) | def __init__(self): method initialize (line 64) | async def initialize(self): method _get_collection (line 74) | async def _get_collection(self): method save_social_media_messages (line 80) | async def save_social_media_messages( method query_social_media_messages (line 138) | async def query_social_media_messages( method get_latest_messages (line 216) | async def get_latest_messages( method search_messages (line 232) | async def search_messages( method get_social_media_statistics (line 269) | async def get_social_media_statistics( function get_social_media_service (line 346) | async def get_social_media_service() -> SocialMediaService: FILE: app/services/stock_data_service.py class StockDataService (line 23) | class StockDataService: method __init__ (line 29) | def __init__(self): method get_stock_basic_info (line 33) | async def get_stock_basic_info( method get_market_quotes (line 91) | async def get_market_quotes(self, symbol: str) -> Optional[MarketQuote... method get_stock_list (line 121) | async def get_stock_list( method update_stock_basic_info (line 188) | async def update_stock_basic_info( method update_market_quotes (line 235) | async def update_market_quotes( method _standardize_basic_info (line 274) | def _standardize_basic_info(self, doc: Dict[str, Any]) -> Dict[str, Any]: method _standardize_market_quotes (line 353) | def _standardize_market_quotes(self, doc: Dict[str, Any]) -> Dict[str,... function get_stock_data_service (line 397) | def get_stock_data_service() -> StockDataService: FILE: app/services/tags_service.py class TagsService (line 12) | class TagsService: method __init__ (line 13) | def __init__(self) -> None: method _get_db (line 17) | async def _get_db(self): method ensure_indexes (line 22) | async def ensure_indexes(self) -> None: method _normalize_user_id (line 31) | def _normalize_user_id(self, user_id: str) -> str: method _format_doc (line 35) | def _format_doc(self, doc: Dict[str, Any]) -> Dict[str, Any]: method list_tags (line 45) | async def list_tags(self, user_id: str) -> List[Dict[str, Any]]: method create_tag (line 54) | async def create_tag(self, user_id: str, name: str, color: Optional[st... method update_tag (line 70) | async def update_tag(self, user_id: str, tag_id: str, *, name: Optiona... method delete_tag (line 88) | async def delete_tag(self, user_id: str, tag_id: str) -> bool: FILE: app/services/unified_stock_service.py class UnifiedStockService (line 25) | class UnifiedStockService: method __init__ (line 28) | def __init__(self, db: AsyncIOMotorDatabase): method get_stock_info (line 56) | async def get_stock_info( method _get_source_priority (line 102) | async def _get_source_priority(self, market: str) -> List[str]: method get_stock_quote (line 144) | async def get_stock_quote(self, market: str, code: str) -> Optional[Di... method search_stocks (line 159) | async def search_stocks( method get_daily_quotes (line 221) | async def get_daily_quotes( method get_supported_markets (line 256) | async def get_supported_markets(self) -> List[Dict]: FILE: app/services/usage_statistics_service.py class UsageStatisticsService (line 17) | class UsageStatisticsService: method __init__ (line 20) | def __init__(self): method add_usage_record (line 24) | async def add_usage_record(self, record: UsageRecord) -> bool: method get_usage_records (line 39) | async def get_usage_records( method get_usage_statistics (line 79) | async def get_usage_statistics( method get_cost_by_provider (line 189) | async def get_cost_by_provider(self, days: int = 7) -> Dict[str, float]: method get_cost_by_model (line 197) | async def get_cost_by_model(self, days: int = 7) -> Dict[str, float]: method get_daily_cost (line 205) | async def get_daily_cost(self, days: int = 7) -> Dict[str, float]: method delete_old_records (line 213) | async def delete_old_records(self, days: int = 90) -> int: FILE: app/services/user_service.py function get_logger (line 21) | def get_logger(name: str) -> logging.Logger: class UserService (line 27) | class UserService: method __init__ (line 30) | def __init__(self): method close (line 35) | def close(self): method __del__ (line 41) | def __del__(self): method hash_password (line 46) | def hash_password(password: str) -> str: method verify_password (line 52) | def verify_password(plain_password: str, hashed_password: str) -> bool: method create_user (line 56) | async def create_user(self, user_data: UserCreate) -> Optional[User]: method authenticate_user (line 119) | async def authenticate_user(self, username: str, password: str) -> Opt... method get_user_by_username (line 164) | async def get_user_by_username(self, username: str) -> Optional[User]: method get_user_by_id (line 175) | async def get_user_by_id(self, user_id: str) -> Optional[User]: method update_user (line 189) | async def update_user(self, username: str, user_data: UserUpdate) -> O... method change_password (line 231) | async def change_password(self, username: str, old_password: str, new_... method reset_password (line 263) | async def reset_password(self, username: str, new_password: str) -> bool: method create_admin_user (line 288) | async def create_admin_user(self, username: str = "admin", password: s... method list_users (line 337) | async def list_users(self, skip: int = 0, limit: int = 100) -> List[Us... method deactivate_user (line 367) | async def deactivate_user(self, username: str) -> bool: method activate_user (line 391) | async def activate_user(self, username: str) -> bool: FILE: app/services/websocket_manager.py class WebSocketManager (line 14) | class WebSocketManager: method __init__ (line 17) | def __init__(self): method connect (line 22) | async def connect(self, websocket: WebSocket, task_id: str): method disconnect (line 33) | async def disconnect(self, websocket: WebSocket, task_id: str): method send_progress_update (line 43) | async def send_progress_update(self, task_id: str, message: Dict[str, ... method broadcast_to_user (line 61) | async def broadcast_to_user(self, user_id: str, message: Dict[str, Any]): method get_connection_count (line 67) | async def get_connection_count(self, task_id: str) -> int: method get_total_connections (line 72) | async def get_total_connections(self) -> int: function get_websocket_manager (line 83) | def get_websocket_manager() -> WebSocketManager: FILE: app/utils/api_key_utils.py function is_valid_api_key (line 11) | def is_valid_api_key(api_key: Optional[str]) -> bool: function truncate_api_key (line 56) | def truncate_api_key(api_key: Optional[str]) -> Optional[str]: function get_env_api_key_for_provider (line 76) | def get_env_api_key_for_provider(provider_name: str) -> Optional[str]: function get_env_api_key_for_datasource (line 97) | def get_env_api_key_for_datasource(ds_type: str) -> Optional[str]: function should_skip_api_key_update (line 137) | def should_skip_api_key_update(api_key: Optional[str]) -> bool: FILE: app/utils/error_formatter.py class ErrorCategory (line 12) | class ErrorCategory(str, Enum): class ErrorFormatter (line 31) | class ErrorFormatter: method format_error (line 57) | def format_error(cls, error_message: str, context: Optional[Dict] = No... method _categorize_error (line 83) | def _categorize_error(cls, error_message: str, context: Dict) -> Tuple... method _extract_llm_provider (line 178) | def _extract_llm_provider(cls, error_message: str) -> Optional[str]: method _extract_data_source (line 187) | def _extract_data_source(cls, error_message: str) -> Optional[str]: method _generate_friendly_message (line 196) | def _generate_friendly_message( FILE: app/utils/report_exporter.py class ReportExporter (line 64) | class ReportExporter: method __init__ (line 67) | def __init__(self): method generate_markdown_report (line 77) | def generate_markdown_report(self, report_doc: Dict[str, Any]) -> str: method _clean_markdown_for_pandoc (line 167) | def _clean_markdown_for_pandoc(self, md_content: str) -> str: method _create_pdf_css (line 210) | def _create_pdf_css(self) -> str: method generate_docx_report (line 284) | def generate_docx_report(self, report_doc: Dict[str, Any]) -> bytes: method _markdown_to_html (line 378) | def _markdown_to_html(self, md_content: str) -> str: method _generate_pdf_with_pdfkit (line 612) | def _generate_pdf_with_pdfkit(self, html_content: str) -> bytes: method generate_pdf_report (line 635) | def generate_pdf_report(self, report_doc: Dict[str, Any]) -> bytes: FILE: app/utils/timezone.py function get_tz_name (line 10) | def get_tz_name() -> str: function get_tz (line 28) | def get_tz() -> ZoneInfo: function now_tz (line 32) | def now_tz() -> datetime: function to_config_tz (line 37) | def to_config_tz(dt: Optional[datetime]) -> Optional[datetime]: function ensure_timezone (line 46) | def ensure_timezone(dt: Optional[datetime]) -> Optional[datetime]: FILE: app/utils/trading_time.py function is_trading_time (line 14) | def is_trading_time(now: Optional[datetime] = None) -> bool: function is_strict_trading_time (line 53) | def is_strict_trading_time(now: Optional[datetime] = None) -> bool: function is_pre_market_time (line 85) | def is_pre_market_time(now: Optional[datetime] = None) -> bool: function is_after_market_time (line 109) | def is_after_market_time(now: Optional[datetime] = None) -> bool: function get_trading_status (line 133) | def get_trading_status(now: Optional[datetime] = None) -> str: FILE: app/worker.py function publish_progress (line 35) | async def publish_progress(task_id: str, message: str, step: Optional[in... function process_task (line 54) | async def process_task(task_id: str) -> None: function worker_loop (line 185) | async def worker_loop(stop_event: asyncio.Event): function main (line 204) | async def main(): FILE: app/worker/akshare_init_service.py class AKShareInitializationStats (line 18) | class AKShareInitializationStats: method __post_init__ (line 34) | def __post_init__(self): class AKShareInitService (line 39) | class AKShareInitService: method __init__ (line 52) | def __init__(self): method initialize (line 57) | async def initialize(self): method run_full_initialization (line 63) | async def run_full_initialization( method _step_check_database_status (line 182) | async def _step_check_database_status(self, skip_if_exists: bool): method _step_initialize_basic_info (line 202) | async def _step_initialize_basic_info(self): method _step_initialize_historical_data (line 218) | async def _step_initialize_historical_data(self, historical_days: int): method _step_initialize_weekly_data (line 249) | async def _step_initialize_weekly_data(self, historical_days: int): method _step_initialize_monthly_data (line 285) | async def _step_initialize_monthly_data(self, historical_days: int): method _step_initialize_financial_data (line 321) | async def _step_initialize_financial_data(self): method _step_initialize_quotes (line 339) | async def _step_initialize_quotes(self): method _step_initialize_news_data (line 357) | async def _step_initialize_news_data(self): method _step_verify_data_integrity (line 377) | async def _step_verify_data_integrity(self): method _get_initialization_summary (line 406) | def _get_initialization_summary(self) -> Dict[str, Any]: function get_akshare_init_service (line 437) | async def get_akshare_init_service() -> AKShareInitService: function run_akshare_full_initialization (line 447) | async def run_akshare_full_initialization( FILE: app/worker/akshare_sync_service.py class AKShareSyncService (line 18) | class AKShareSyncService: method __init__ (line 29) | def __init__(self): method initialize (line 37) | async def initialize(self): method sync_stock_basic_info (line 62) | async def sync_stock_basic_info(self, force_update: bool = False) -> D... method _process_basic_info_batch (line 133) | async def _process_basic_info_batch(self, batch: List[Dict[str, Any]],... method _is_data_fresh (line 206) | def _is_data_fresh(self, updated_at: Any, hours: int = 24) -> bool: method sync_realtime_quotes (line 234) | async def sync_realtime_quotes(self, symbols: List[str] = None, force:... method _process_quotes_batch (line 389) | async def _process_quotes_batch(self, batch: List[str]) -> Dict[str, A... method _process_quotes_batch_fallback (line 455) | async def _process_quotes_batch_fallback(self, batch: List[str]) -> Di... method _get_and_save_quotes (line 490) | async def _get_and_save_quotes(self, symbol: str) -> bool: method sync_historical_data (line 532) | async def sync_historical_data( method _process_historical_batch (line 632) | async def _process_historical_batch( method _get_last_sync_date (line 698) | async def _get_last_sync_date(self, symbol: str = None) -> str: method sync_financial_data (line 754) | async def sync_financial_data(self, symbols: List[str] = None) -> Dict... method _process_financial_batch (line 835) | async def _process_financial_batch(self, batch: List[str]) -> Dict[str... method _save_financial_data (line 879) | async def _save_financial_data(self, symbol: str, financial_data: Dict... method run_status_check (line 902) | async def run_status_check(self) -> Dict[str, Any]: method _get_favorite_stocks (line 952) | async def _get_favorite_stocks(self) -> List[str]: method sync_news_data (line 998) | async def sync_news_data( method _process_news_batch (line 1092) | async def _process_news_batch( function get_akshare_sync_service (line 1148) | async def get_akshare_sync_service() -> AKShareSyncService: function run_akshare_basic_info_sync (line 1158) | async def run_akshare_basic_info_sync(force_update: bool = False): function run_akshare_quotes_sync (line 1170) | async def run_akshare_quotes_sync(force: bool = False): function run_akshare_historical_sync (line 1188) | async def run_akshare_historical_sync(incremental: bool = True): function run_akshare_financial_sync (line 1200) | async def run_akshare_financial_sync(): function run_akshare_status_check (line 1212) | async def run_akshare_status_check(): function run_akshare_news_sync (line 1224) | async def run_akshare_news_sync(max_news_per_stock: int = 20): FILE: app/worker/analysis_worker.py class AnalysisWorker (line 32) | class AnalysisWorker: method __init__ (line 35) | def __init__(self, worker_id: Optional[str] = None): method _signal_handler (line 51) | def _signal_handler(self, signum, frame): method start (line 56) | async def start(self): method _work_loop (line 112) | async def _work_loop(self): method _process_task (line 133) | async def _process_task(self, task_data: Dict[str, Any]): method _progress_callback (line 183) | def _progress_callback(self, progress: int, message: str): method _heartbeat_loop (line 187) | async def _heartbeat_loop(self): method _send_heartbeat (line 199) | async def _send_heartbeat(self): method _cleanup_loop (line 218) | async def _cleanup_loop(self): method _cleanup (line 230) | async def _cleanup(self): function main (line 251) | async def main(): FILE: app/worker/baostock_init_service.py class BaoStockInitializationStats (line 20) | class BaoStockInitializationStats: method duration (line 36) | def duration(self) -> float: method progress (line 43) | def progress(self) -> str: class BaoStockInitService (line 48) | class BaoStockInitService: method __init__ (line 51) | def __init__(self): method initialize (line 66) | async def initialize(self): method check_database_status (line 81) | async def check_database_status(self) -> Dict[str, Any]: method full_initialization (line 118) | async def full_initialization(self, historical_days: int = 365, method _sync_financial_data (line 235) | async def _sync_financial_data(self) -> int: method _verify_data_integrity (line 278) | async def _verify_data_integrity(self, stats: BaoStockInitializationSt... method basic_initialization (line 297) | async def basic_initialization(self) -> BaoStockInitializationStats: function run_baostock_full_initialization (line 345) | async def run_baostock_full_initialization(): function run_baostock_basic_initialization (line 356) | async def run_baostock_basic_initialization(): FILE: app/worker/baostock_sync_service.py class BaoStockSyncStats (line 21) | class BaoStockSyncStats: method __post_init__ (line 29) | def __post_init__(self): class BaoStockSyncService (line 34) | class BaoStockSyncService: method __init__ (line 37) | def __init__(self): method initialize (line 54) | async def initialize(self): method sync_stock_basic_info (line 71) | async def sync_stock_basic_info(self, batch_size: int = 100) -> BaoSto... method _sync_basic_info_batch (line 117) | async def _sync_basic_info_batch(self, stock_batch: List[Dict[str, Any... method _get_total_shares (line 172) | async def _get_total_shares(self, code: str) -> Optional[float]: method _safe_float (line 221) | def _safe_float(self, value) -> Optional[float]: method _update_stock_basic_info (line 230) | async def _update_stock_basic_info(self, basic_info: Dict[str, Any]): method sync_daily_quotes (line 254) | async def sync_daily_quotes(self, batch_size: int = 50) -> BaoStockSyn... method _sync_quotes_batch (line 306) | async def _sync_quotes_batch(self, code_batch: List[str]) -> BaoStockS... method _update_stock_quotes (line 327) | async def _update_stock_quotes(self, quotes: Dict[str, Any]): method sync_historical_data (line 348) | async def sync_historical_data(self, days: int = 30, batch_size: int =... method _sync_historical_batch (line 413) | async def _sync_historical_batch( method _update_historical_data (line 452) | async def _update_historical_data(self, code: str, hist_data, period: ... method _get_last_sync_date (line 493) | async def _get_last_sync_date(self, symbol: str = None) -> str: method check_service_status (line 528) | async def check_service_status(self) -> Dict[str, Any]: function run_baostock_basic_info_sync (line 566) | async def run_baostock_basic_info_sync(): function run_baostock_daily_quotes_sync (line 577) | async def run_baostock_daily_quotes_sync(): function run_baostock_historical_sync (line 588) | async def run_baostock_historical_sync(): function run_baostock_status_check (line 599) | async def run_baostock_status_check(): FILE: app/worker/example_sdk_sync_service.py class ExampleSDKSyncService (line 23) | class ExampleSDKSyncService: method __init__ (line 40) | def __init__(self): method sync_all_data (line 58) | async def sync_all_data(self): method sync_basic_info (line 95) | async def sync_basic_info(self): method sync_realtime_quotes (line 126) | async def sync_realtime_quotes(self): method sync_financial_data (line 159) | async def sync_financial_data(self): method _process_basic_info_batch (line 190) | async def _process_basic_info_batch(self, batch: List[Dict[str, Any]]): method _process_quotes_batch (line 211) | async def _process_quotes_batch(self, batch: List[str]): method _process_financial_data (line 234) | async def _process_financial_data(self, code: str): method _record_sync_status (line 268) | async def _record_sync_status(self, status: str, start_time: datetime,... method _log_sync_stats (line 293) | def _log_sync_stats(self): method sync_incremental (line 304) | async def sync_incremental(self): function run_full_sync (line 329) | async def run_full_sync(): function run_incremental_sync (line 335) | async def run_incremental_sync(): function main (line 343) | async def main(): FILE: app/worker/financial_data_sync_service.py class FinancialSyncStats (line 22) | class FinancialSyncStats: method to_dict (line 33) | def to_dict(self) -> Dict[str, Any]: class FinancialDataSyncService (line 48) | class FinancialDataSyncService: method __init__ (line 51) | def __init__(self): method initialize (line 56) | async def initialize(self): method sync_financial_data (line 75) | async def sync_financial_data( method _sync_source_financial_data (line 143) | async def _sync_source_financial_data( method _sync_symbol_financial_data (line 215) | async def _sync_symbol_financial_data( method _get_stock_symbols (line 248) | async def _get_stock_symbols(self) -> List[str]: method get_sync_statistics (line 271) | async def get_sync_statistics(self) -> Dict[str, Any]: method sync_single_stock (line 283) | async def sync_single_stock( function get_financial_sync_service (line 329) | async def get_financial_sync_service() -> FinancialDataSyncService: FILE: app/worker/hk_data_service.py class HKDataService (line 36) | class HKDataService: method __init__ (line 39) | def __init__(self): method initialize (line 53) | async def initialize(self): method get_stock_info (line 57) | async def get_stock_info( method _get_cached_info (line 117) | async def _get_cached_info(self, code: str, source: str) -> Optional[D... method _save_to_cache (line 134) | async def _save_to_cache(self, stock_info: Dict[str, Any]) -> bool: method _normalize_stock_info (line 148) | def _normalize_stock_info(self, stock_info: Dict, source: str) -> Dict: function get_hk_data_service (line 186) | async def get_hk_data_service() -> HKDataService: FILE: app/worker/hk_sync_service.py class HKDataService (line 38) | class HKDataService: method __init__ (line 41) | def __init__(self): method initialize (line 60) | async def initialize(self): method _get_hk_stock_list_from_akshare (line 64) | def _get_hk_stock_list_from_akshare(self) -> List[str]: method _get_fallback_stock_list (line 110) | def _get_fallback_stock_list(self) -> List[str]: method sync_basic_info_from_source (line 140) | async def sync_basic_info_from_source( method _sync_basic_info_from_akshare_batch (line 235) | async def _sync_basic_info_from_akshare_batch(self, force_update: bool... method _normalize_stock_info (line 342) | def _normalize_stock_info(self, stock_info: Dict, source: str) -> Dict: method sync_quotes_from_source (line 376) | async def sync_quotes_from_source( function get_hk_sync_service (line 466) | async def get_hk_sync_service() -> HKSyncService: function run_hk_yfinance_basic_info_sync (line 477) | async def run_hk_yfinance_basic_info_sync(force_update: bool = False): function run_hk_akshare_basic_info_sync (line 489) | async def run_hk_akshare_basic_info_sync(force_update: bool = False): function run_hk_yfinance_quotes_sync (line 501) | async def run_hk_yfinance_quotes_sync(): function run_hk_status_check (line 513) | async def run_hk_status_check(): FILE: app/worker/multi_period_sync_service.py class MultiPeriodSyncStats (line 21) | class MultiPeriodSyncStats: method __post_init__ (line 31) | def __post_init__(self): class MultiPeriodSyncService (line 36) | class MultiPeriodSyncService: method __init__ (line 39) | def __init__(self): method initialize (line 45) | async def initialize(self): method sync_multi_period_data (line 66) | async def sync_multi_period_data( method _sync_period_data (line 143) | async def _sync_period_data( method _sync_batch_period_data (line 194) | async def _sync_batch_period_data( method _get_all_symbols (line 245) | async def _get_all_symbols(self) -> List[str]: method _get_full_history_date_range (line 263) | async def _get_full_history_date_range(self) -> tuple[str, str]: method get_sync_statistics (line 288) | async def get_sync_statistics(self) -> Dict[str, Any]: function get_multi_period_sync_service (line 340) | async def get_multi_period_sync_service() -> MultiPeriodSyncService: function run_multi_period_sync (line 350) | async def run_multi_period_sync(periods: List[str] = None): function run_daily_sync (line 362) | async def run_daily_sync(): function run_weekly_sync (line 367) | async def run_weekly_sync(): function run_monthly_sync (line 372) | async def run_monthly_sync(): FILE: app/worker/news_data_sync_service.py class NewsSyncStats (line 20) | class NewsSyncStats: method duration_seconds (line 31) | def duration_seconds(self) -> float: method success_rate (line 38) | def success_rate(self) -> float: class NewsDataSyncService (line 45) | class NewsDataSyncService: method __init__ (line 48) | def __init__(self): method _get_news_service (line 55) | async def _get_news_service(self): method _get_tushare_provider (line 61) | async def _get_tushare_provider(self): method _get_tushare_provider (line 68) | async def _get_tushare_provider(self): method _get_akshare_provider (line 76) | async def _get_akshare_provider(self): method _get_realtime_aggregator (line 83) | async def _get_realtime_aggregator(self): method sync_stock_news (line 89) | async def sync_stock_news( method _sync_tushare_news (line 183) | async def _sync_tushare_news( method _sync_akshare_news (line 228) | async def _sync_akshare_news( method _sync_realtime_news (line 260) | async def _sync_realtime_news( method _standardize_tushare_news (line 291) | def _standardize_tushare_news(self, news: Dict[str, Any], symbol: str)... method _standardize_akshare_news (line 313) | def _standardize_akshare_news(self, news: Dict[str, Any], symbol: str)... method _standardize_realtime_news (line 335) | def _standardize_realtime_news(self, news_item, symbol: str) -> Option... method _classify_news_category (line 357) | def _classify_news_category(self, title: str) -> str: method _analyze_sentiment (line 372) | def _analyze_sentiment(self, text: str) -> str: method _assess_importance (line 389) | def _assess_importance(self, title: str) -> str: method _extract_keywords (line 403) | def _extract_keywords(self, text: str) -> List[str]: method _deduplicate_news (line 419) | def _deduplicate_news(self, news_list: List[Dict[str, Any]]) -> List[D... method sync_market_news (line 433) | async def sync_market_news( function get_news_data_sync_service (line 512) | async def get_news_data_sync_service() -> NewsDataSyncService: FILE: app/worker/tushare_init_service.py class InitializationStats (line 18) | class InitializationStats: method __post_init__ (line 34) | def __post_init__(self): class TushareInitService (line 39) | class TushareInitService: method __init__ (line 52) | def __init__(self): method initialize (line 57) | async def initialize(self): method run_full_initialization (line 63) | async def run_full_initialization( method _step_check_database_status (line 174) | async def _step_check_database_status(self, skip_if_exists: bool): method _step_initialize_basic_info (line 194) | async def _step_initialize_basic_info(self): method _step_initialize_historical_data (line 210) | async def _step_initialize_historical_data(self, historical_days: int): method _step_initialize_weekly_data (line 241) | async def _step_initialize_weekly_data(self, historical_days: int): method _step_initialize_monthly_data (line 277) | async def _step_initialize_monthly_data(self, historical_days: int): method _step_initialize_financial_data (line 313) | async def _step_initialize_financial_data(self): method _step_initialize_quotes (line 331) | async def _step_initialize_quotes(self): method _step_initialize_news_data (line 349) | async def _step_initialize_news_data(self, historical_days: int): method _step_verify_data_integrity (line 373) | async def _step_verify_data_integrity(self): method _get_initialization_summary (line 402) | def _get_initialization_summary(self) -> Dict[str, Any]: function get_tushare_init_service (line 434) | async def get_tushare_init_service() -> TushareInitService: function run_tushare_full_initialization (line 444) | async def run_tushare_full_initialization( FILE: app/worker/tushare_sync_service.py function get_utc8_now (line 25) | def get_utc8_now(): class TushareSyncService (line 35) | class TushareSyncService: method __init__ (line 41) | def __init__(self): method initialize (line 59) | async def initialize(self): method sync_stock_basic_info (line 75) | async def sync_stock_basic_info(self, force_update: bool = False, job_... method _process_basic_info_batch (line 160) | async def _process_basic_info_batch(self, batch: List[Dict[str, Any]],... method sync_realtime_quotes (line 228) | async def sync_realtime_quotes(self, symbols: List[str] = None, force:... method _process_quotes_batch (line 420) | async def _process_quotes_batch(self, batch: List[str]) -> Dict[str, A... method _is_rate_limit_error (line 466) | def _is_rate_limit_error(self, error_msg: str) -> bool: method _is_trading_time (line 479) | def _is_trading_time(self) -> bool: method _get_and_save_quotes (line 517) | async def _get_and_save_quotes(self, symbol: str) -> bool: method sync_historical_data (line 543) | async def sync_historical_data( method _save_historical_data (line 759) | async def _save_historical_data(self, symbol: str, df, period: str = "... method _get_last_sync_date (line 780) | async def _get_last_sync_date(self, symbol: str = None) -> str: method sync_financial_data (line 838) | async def sync_financial_data(self, symbols: List[str] = None, limit: ... method _save_financial_data (line 949) | async def _save_financial_data(self, symbol: str, financial_data: Dict... method _is_data_fresh (line 975) | def _is_data_fresh(self, updated_at: datetime, hours: int = 24) -> bool: method get_sync_status (line 983) | async def get_sync_status(self) -> Dict[str, Any]: method sync_news_data (line 1021) | async def sync_news_data( method _process_news_batch (line 1121) | async def _process_news_batch( method _should_stop (line 1177) | async def _should_stop(self, job_id: str) -> bool: method _update_progress (line 1203) | async def _update_progress(self, job_id: str, progress: int, message: ... function get_tushare_sync_service (line 1267) | async def get_tushare_sync_service() -> TushareSyncService: function run_tushare_basic_info_sync (line 1277) | async def run_tushare_basic_info_sync(force_update: bool = False): function run_tushare_quotes_sync (line 1289) | async def run_tushare_quotes_sync(force: bool = False): function run_tushare_historical_sync (line 1306) | async def run_tushare_historical_sync(incremental: bool = True): function run_tushare_financial_sync (line 1322) | async def run_tushare_financial_sync(): function run_tushare_status_check (line 1334) | async def run_tushare_status_check(): function run_tushare_news_sync (line 1346) | async def run_tushare_news_sync(hours_back: int = 24, max_news_per_stock... FILE: app/worker/us_data_service.py class USDataService (line 35) | class USDataService: method __init__ (line 38) | def __init__(self): method initialize (line 52) | async def initialize(self): method get_stock_info (line 56) | async def get_stock_info( method _get_cached_info (line 116) | async def _get_cached_info(self, code: str, source: str) -> Optional[D... method _save_to_cache (line 133) | async def _save_to_cache(self, stock_info: Dict[str, Any]) -> bool: method _normalize_stock_info (line 147) | def _normalize_stock_info(self, stock_info: Dict, source: str) -> Dict: function get_us_data_service (line 185) | async def get_us_data_service() -> USDataService: FILE: app/worker/us_sync_service.py class USSyncService (line 36) | class USSyncService: method __init__ (line 39) | def __init__(self): method initialize (line 54) | async def initialize(self): method _get_finnhub_client (line 58) | def _get_finnhub_client(self): method _get_us_stock_list_from_finnhub (line 78) | def _get_us_stock_list_from_finnhub(self) -> List[str]: method _get_fallback_stock_list (line 132) | def _get_fallback_stock_list(self) -> List[str]: method sync_basic_info_from_source (line 173) | async def sync_basic_info_from_source( method _normalize_stock_info (line 262) | def _normalize_stock_info(self, stock_info: Dict, source: str) -> Dict: method sync_quotes_from_source (line 296) | async def sync_quotes_from_source( function get_us_sync_service (line 389) | async def get_us_sync_service() -> USSyncService: function run_us_yfinance_basic_info_sync (line 400) | async def run_us_yfinance_basic_info_sync(force_update: bool = False): function run_us_yfinance_quotes_sync (line 412) | async def run_us_yfinance_quotes_sync(): function run_us_status_check (line 424) | async def run_us_status_check(): FILE: cli/akshare_init.py function check_database_status (line 34) | async def check_database_status(): function run_full_initialization (line 88) | async def run_full_initialization( function run_basic_sync_only (line 143) | async def run_basic_sync_only(): function test_akshare_connection (line 165) | async def test_akshare_connection(): function print_help_detail (line 199) | def print_help_detail(): function main (line 259) | async def main(): FILE: cli/baostock_init.py function print_banner (line 33) | def print_banner(): function print_stats (line 40) | def print_stats(stats): function test_connection (line 59) | async def test_connection(): function check_database_status (line 79) | async def check_database_status(): function run_full_initialization (line 103) | async def run_full_initialization(historical_days: int = 365, force: boo... function run_basic_initialization (line 124) | async def run_basic_initialization(): function print_help_detail (line 145) | def print_help_detail(): function main (line 200) | async def main(): FILE: cli/main.py function setup_cli_logging (line 57) | def setup_cli_logging(): class CLIUserInterface (line 92) | class CLIUserInterface: method __init__ (line 95) | def __init__(self): method show_user_message (line 99) | def show_user_message(self, message: str, style: str = ""): method show_progress (line 106) | def show_progress(self, message: str): method show_success (line 112) | def show_success(self, message: str): method show_error (line 117) | def show_error(self, message: str): method show_warning (line 122) | def show_warning(self, message: str): method show_step_header (line 127) | def show_step_header(self, step_num: int, title: str): method show_data_info (line 132) | def show_data_info(self, data_type: str, symbol: str, details: str = ""): class MessageBuffer (line 152) | class MessageBuffer: method __init__ (line 153) | def __init__(self, max_length=DEFAULT_MESSAGE_BUFFER_SIZE): method add_message (line 188) | def add_message(self, message_type, content): method add_tool_call (line 192) | def add_tool_call(self, tool_name, args): method update_agent_status (line 196) | def update_agent_status(self, agent, status): method update_report_section (line 201) | def update_report_section(self, section_name, content): method _update_current_report (line 206) | def _update_current_report(self): method _update_final_report (line 235) | def _update_final_report(self): function create_layout (line 287) | def create_layout(): function update_display (line 307) | def update_display(layout, spinner_text=None): function get_user_selections (line 520) | def get_user_selections(): function select_market (line 643) | def select_market(): function get_ticker (line 694) | def get_ticker(market): function get_analysis_date (line 737) | def get_analysis_date(): function display_complete_report (line 757) | def display_complete_report(final_state): function update_research_team_status (line 947) | def update_research_team_status(status): function extract_content_string (line 959) | def extract_content_string(content): function check_api_keys (line 989) | def check_api_keys(llm_provider: str) -> bool: function run_analysis (line 1028) | def run_analysis(): function analyze (line 1611) | def analyze(): function config (line 1623) | def config(): function version (line 1732) | def version(): function data_config (line 1777) | def data_config( function examples (line 1874) | def examples(): function test (line 1929) | def test(): function help_chinese (line 1961) | def help_chinese(): function main (line 2022) | def main(): FILE: cli/models.py class AnalystType (line 10) | class AnalystType(str, Enum): FILE: cli/tushare_init.py function print_banner (line 21) | def print_banner(): function print_help (line 29) | def print_help(): function check_database_status (line 82) | async def check_database_status(): function run_basic_initialization (line 135) | async def run_basic_initialization(): function run_full_initialization (line 158) | async def run_full_initialization(historical_days: int, force: bool, mul... function main (line 209) | async def main(): FILE: cli/utils.py function get_ticker (line 20) | def get_ticker() -> str: function get_analysis_date (line 40) | def get_analysis_date() -> str: function select_analysts (line 73) | def select_analysts(ticker: str = None) -> List[AnalystType]: function select_research_depth (line 113) | def select_research_depth() -> int: function select_shallow_thinking_agent (line 145) | def select_shallow_thinking_agent(provider) -> str: function select_deep_thinking_agent (line 239) | def select_deep_thinking_agent(provider) -> str: function select_llm_provider (line 336) | def select_llm_provider() -> tuple[str, str]: FILE: docs/LLM_ADAPTER_TEMPLATE.py class ChatProviderTemplate (line 17) | class ChatProviderTemplate(OpenAICompatibleBase): method __init__ (line 20) | def __init__( FILE: examples/batch_analysis.py function batch_stock_analysis (line 28) | def batch_stock_analysis(): function generate_summary_report (line 98) | def generate_summary_report(results, llm): function format_results_for_summary (line 158) | def format_results_for_summary(results): FILE: examples/cli_demo.py function run_command (line 16) | def run_command(command, description): function main (line 40) | def main(): FILE: examples/config_management_demo.py function demo_model_management (line 22) | def demo_model_management(): function demo_cost_calculation (line 44) | def demo_cost_calculation(): function demo_usage_tracking (line 68) | def demo_usage_tracking(): function demo_usage_statistics (line 125) | def demo_usage_statistics(): function demo_cost_estimation (line 148) | def demo_cost_estimation(): function demo_settings_management (line 204) | def demo_settings_management(): function main (line 222) | def main(): FILE: examples/crawlers/internal_message_crawler.py class InternalMessageCrawler (line 33) | class InternalMessageCrawler: method __init__ (line 36) | def __init__(self, source_type: str): method __aenter__ (line 45) | async def __aenter__(self): method __aexit__ (line 53) | async def __aexit__(self, exc_type, exc_val, exc_tb): method clean_content (line 58) | def clean_content(self, text: str) -> str: method extract_keywords (line 70) | def extract_keywords(self, text: str) -> List[str]: method analyze_sentiment (line 89) | def analyze_sentiment(self, text: str) -> tuple: method extract_risk_factors (line 110) | def extract_risk_factors(self, text: str) -> List[str]: method extract_opportunities (line 126) | def extract_opportunities(self, text: str) -> List[str]: class ResearchReportCrawler (line 143) | class ResearchReportCrawler(InternalMessageCrawler): method __init__ (line 146) | def __init__(self): method crawl_research_reports (line 150) | async def crawl_research_reports(self, symbol: str, limit: int = 10) -... method _simulate_research_api (line 172) | async def _simulate_research_api(self, symbol: str, limit: int) -> Lis... method _generate_report_title (line 207) | def _generate_report_title(self, symbol: str, report_type: str) -> str: method _generate_report_content (line 217) | def _generate_report_content(self, symbol: str, report_type: str) -> str: method _generate_report_summary (line 237) | def _generate_report_summary(self, symbol: str, report_type: str) -> str: method _generate_report_tags (line 247) | def _generate_report_tags(self, report_type: str) -> List[str]: method _standardize_research_report (line 257) | async def _standardize_research_report(self, raw_report: Dict[str, Any... class AnalystNoteCrawler (line 319) | class AnalystNoteCrawler(InternalMessageCrawler): method __init__ (line 322) | def __init__(self): method crawl_analyst_notes (line 326) | async def crawl_analyst_notes(self, symbol: str, limit: int = 20) -> L... method _simulate_analyst_api (line 348) | async def _simulate_analyst_api(self, symbol: str, limit: int) -> List... method _generate_note_title (line 378) | def _generate_note_title(self, symbol: str, note_type: str) -> str: method _generate_note_content (line 388) | def _generate_note_content(self, symbol: str, note_type: str) -> str: method _generate_note_tags (line 398) | def _generate_note_tags(self, note_type: str) -> List[str]: method _standardize_analyst_note (line 408) | async def _standardize_analyst_note(self, raw_note: Dict[str, Any], sy... method _map_category (line 471) | def _map_category(self, note_type: str) -> str: function crawl_and_save_internal_messages (line 482) | async def crawl_and_save_internal_messages(symbols: List[str], message_t... function main (line 542) | async def main(): FILE: examples/crawlers/message_crawler_scheduler.py class MessageCrawlerScheduler (line 39) | class MessageCrawlerScheduler: method __init__ (line 42) | def __init__(self, config_file: str = None): method _load_config (line 47) | def _load_config(self) -> Dict[str, Any]: method run_social_media_crawl (line 108) | async def run_social_media_crawl(self) -> Dict[str, Any]: method run_internal_message_crawl (line 143) | async def run_internal_message_crawl(self) -> Dict[str, Any]: method run_full_crawl (line 178) | async def run_full_crawl(self) -> Dict[str, Any]: method _save_run_log (line 235) | async def _save_run_log(self, summary: Dict[str, Any]): method get_crawl_statistics (line 268) | async def get_crawl_statistics(self) -> Dict[str, Any]: method print_config (line 315) | def print_config(self): function main (line 325) | async def main(): FILE: examples/crawlers/social_media_crawler.py class SocialMediaCrawler (line 33) | class SocialMediaCrawler: method __init__ (line 36) | def __init__(self, platform: str): method __aenter__ (line 44) | async def __aenter__(self): method __aexit__ (line 52) | async def __aexit__(self, exc_type, exc_val, exc_tb): method clean_content (line 57) | def clean_content(self, text: str) -> str: method extract_hashtags (line 71) | def extract_hashtags(self, text: str) -> List[str]: method extract_mentions (line 76) | def extract_mentions(self, text: str) -> List[str]: method analyze_sentiment (line 81) | def analyze_sentiment(self, text: str) -> tuple: method extract_keywords (line 102) | def extract_keywords(self, text: str) -> List[str]: method assess_importance (line 119) | def assess_importance(self, engagement: Dict[str, Any], author_influen... method assess_credibility (line 134) | def assess_credibility(self, author: Dict[str, Any], content: str) -> ... class WeiboCrawler (line 160) | class WeiboCrawler(SocialMediaCrawler): method __init__ (line 163) | def __init__(self): method crawl_stock_messages (line 167) | async def crawl_stock_messages(self, symbol: str, limit: int = 50) -> ... method _simulate_weibo_api (line 189) | async def _simulate_weibo_api(self, symbol: str, limit: int) -> List[D... method _generate_mock_weibo_text (line 217) | def _generate_mock_weibo_text(self, symbol: str, index: int) -> str: method _standardize_weibo_message (line 229) | async def _standardize_weibo_message(self, raw_msg: Dict[str, Any], sy... class DouyinCrawler (line 307) | class DouyinCrawler(SocialMediaCrawler): method __init__ (line 310) | def __init__(self): method crawl_stock_messages (line 313) | async def crawl_stock_messages(self, symbol: str, limit: int = 30) -> ... method _simulate_douyin_api (line 335) | async def _simulate_douyin_api(self, symbol: str, limit: int) -> List[... method _generate_mock_douyin_text (line 366) | def _generate_mock_douyin_text(self, symbol: str, index: int) -> str: method _standardize_douyin_message (line 378) | async def _standardize_douyin_message(self, raw_msg: Dict[str, Any], s... function crawl_and_save_social_media (line 456) | async def crawl_and_save_social_media(symbols: List[str], platforms: Lis... function main (line 516) | async def main(): FILE: examples/custom_analysis_demo.py function analyze_stock_custom (line 26) | def analyze_stock_custom(symbol, analysis_focus="comprehensive"): function interactive_analysis (line 151) | def interactive_analysis(): function batch_analysis_demo (line 218) | def batch_analysis_demo(): function main (line 251) | def main(): FILE: examples/dashscope_examples/demo_dashscope.py function main (line 26) | def main(): FILE: examples/dashscope_examples/demo_dashscope_chinese.py function analyze_stock_with_chinese_output (line 26) | def analyze_stock_with_chinese_output(stock_symbol="AAPL", analysis_date... function compare_models_chinese (line 150) | def compare_models_chinese(): function main (line 176) | def main(): FILE: examples/dashscope_examples/demo_dashscope_no_memory.py function main (line 26) | def main(): FILE: examples/dashscope_examples/demo_dashscope_simple.py function test_simple_llm (line 24) | def test_simple_llm(): function test_multiple_models (line 91) | def test_multiple_models(): function main (line 120) | def main(): FILE: examples/data_dir_config_demo.py function show_current_config (line 27) | def show_current_config(): function demo_set_custom_data_dir (line 72) | def demo_set_custom_data_dir(): function demo_config_integration (line 102) | def demo_config_integration(): function demo_environment_variable_override (line 120) | def demo_environment_variable_override(): function demo_directory_auto_creation (line 138) | def demo_directory_auto_creation(): function show_configuration_guide (line 170) | def show_configuration_guide(): function main (line 213) | def main(): FILE: examples/demo_deepseek_analysis.py function check_deepseek_config (line 23) | def check_deepseek_config(): function demo_simple_chat (line 46) | def demo_simple_chat(): function demo_reasoning_analysis (line 79) | def demo_reasoning_analysis(): function demo_stock_analysis_with_tools (line 122) | def demo_stock_analysis_with_tools(): function demo_trading_system (line 202) | def demo_trading_system(): function main (line 240) | def main(): FILE: examples/demo_deepseek_simple.py class SimpleDeepSeekAdapter (line 13) | class SimpleDeepSeekAdapter: method __init__ (line 16) | def __init__(self): method chat (line 26) | def chat(self, message: str) -> str: function demo_simple_chat (line 36) | def demo_simple_chat(): function demo_stock_analysis (line 63) | def demo_stock_analysis(): function main (line 100) | def main(): FILE: examples/demo_news_filtering.py function demo_basic_filtering (line 13) | def demo_basic_filtering(): function demo_real_news_filtering (line 58) | def demo_real_news_filtering(): function demo_enhanced_filtering (line 106) | def demo_enhanced_filtering(): function demo_integrated_filtering (line 152) | def demo_integrated_filtering(): function main (line 189) | def main(): FILE: examples/enhanced_history_demo.py function demo_load_analysis_results (line 17) | def demo_load_analysis_results(): function demo_text_similarity (line 49) | def demo_text_similarity(): function demo_report_content_extraction (line 91) | def demo_report_content_extraction(): function demo_stock_grouping (line 148) | def demo_stock_grouping(): function create_demo_data (line 203) | def create_demo_data(): function main (line 238) | def main(): FILE: examples/my_stock_analysis.py function analyze_my_stock (line 26) | def analyze_my_stock(): FILE: examples/run_message_crawlers.py function run_social_media_crawler_example (line 23) | async def run_social_media_crawler_example(): function run_internal_message_crawler_example (line 45) | async def run_internal_message_crawler_example(): function run_scheduler_example (line 67) | async def run_scheduler_example(): function query_saved_messages (line 88) | async def query_saved_messages(): function main (line 144) | async def main(): FILE: examples/simple_analysis_demo.py function quick_analysis_demo (line 19) | def quick_analysis_demo(): function show_analysis_workflow (line 99) | def show_analysis_workflow(): function show_model_comparison (line 161) | def show_model_comparison(): function main (line 196) | def main(): FILE: examples/stock_data_model_usage.py function demo_basic_info (line 22) | async def demo_basic_info(): function demo_market_quotes (line 52) | async def demo_market_quotes(): function demo_stock_list (line 82) | async def demo_stock_list(): function demo_data_update (line 122) | async def demo_data_update(): function demo_data_validation (line 180) | async def demo_data_validation(): function main (line 239) | async def main(): FILE: examples/stock_list_example.py function demo_stock_list_fetcher (line 17) | def demo_stock_list_fetcher(): function show_usage_examples (line 75) | def show_usage_examples(): FILE: examples/stock_query_examples.py function demo_service_status (line 34) | def demo_service_status(): function demo_single_stock_query (line 60) | def demo_single_stock_query(): function demo_stock_search (line 103) | def demo_stock_search(): function demo_market_overview (line 130) | def demo_market_overview(): function demo_stock_data_query (line 160) | def demo_stock_data_query(): function demo_fallback_mechanism (line 187) | def demo_fallback_mechanism(): function main (line 215) | def main(): FILE: examples/test_enhanced_data_integration.py function test_enhanced_data_adapter (line 21) | def test_enhanced_data_adapter(): function test_optimized_china_data_provider (line 76) | def test_optimized_china_data_provider(): function test_cache_mode_comparison (line 111) | def test_cache_mode_comparison(): function main (line 153) | def main(): FILE: examples/test_installation.py class InstallationTester (line 17) | class InstallationTester: method __init__ (line 20) | def __init__(self): method test_python_version (line 24) | def test_python_version(self) -> bool: method test_virtual_environment (line 36) | def test_virtual_environment(self) -> bool: method test_core_modules (line 52) | def test_core_modules(self) -> bool: method test_dependencies (line 75) | def test_dependencies(self) -> bool: method test_config_files (line 103) | def test_config_files(self) -> bool: method test_environment_variables (line 127) | def test_environment_variables(self) -> bool: method test_web_application (line 169) | def test_web_application(self) -> bool: method test_data_directories (line 190) | def test_data_directories(self) -> bool: method run_all_tests (line 214) | def run_all_tests(self) -> Dict[str, bool]: method print_summary (line 244) | def print_summary(self, test_results: Dict[str, bool]): function main (line 280) | def main(): FILE: examples/test_news_timeout.py function test_news_for_stock (line 23) | def test_news_for_stock(ticker): function main (line 52) | def main(): FILE: examples/token_tracking_demo.py function print_separator (line 35) | def print_separator(title=""): function display_config_status (line 43) | def display_config_status(): function display_current_statistics (line 72) | def display_current_statistics(): function demo_basic_usage (line 96) | def demo_basic_usage(): function demo_cost_estimation (line 153) | def demo_cost_estimation(): function demo_mongodb_features (line 178) | def demo_mongodb_features(): function display_pricing_info (line 222) | def display_pricing_info(): function main (line 243) | def main(): FILE: examples/tushare_demo.py function demo_basic_usage (line 20) | def demo_basic_usage(): function demo_interface_functions (line 79) | def demo_interface_functions(): function demo_batch_operations (line 129) | def demo_batch_operations(): function demo_cache_performance (line 173) | def demo_cache_performance(): function check_environment (line 232) | def check_environment(): function main (line 266) | def main(): FILE: examples/tushare_unified_demo.py function test_tushare_provider (line 25) | async def test_tushare_provider(): function test_tushare_sync_service (line 133) | async def test_tushare_sync_service(): function performance_test (line 151) | async def performance_test(): function main (line 192) | async def main(): FILE: frontend/env.d.ts type ImportMetaEnv (line 9) | interface ImportMetaEnv { type ImportMeta (line 15) | interface ImportMeta { FILE: frontend/src/api/analysis.ts type AnalysisRequest (line 9) | interface AnalysisRequest { type SingleAnalysisRequest (line 23) | interface SingleAnalysisRequest { type AnalysisProgress (line 40) | interface AnalysisProgress { type AnalysisStep (line 52) | interface AnalysisStep { type AnalysisResult (line 63) | interface AnalysisResult { type AnalysisHistory (line 111) | interface AnalysisHistory { method startAnalysis (line 121) | startAnalysis(analysisRequest: AnalysisRequest): Promise<{ analysis_id: ... method startSingleAnalysis (line 126) | startSingleAnalysis(analysisRequest: SingleAnalysisRequest): Promise> { method getProgress (line 136) | getProgress(analysisId: string): Promise { method getResult (line 141) | getResult(analysisId: string): Promise { method stopAnalysis (line 146) | stopAnalysis(analysisId: string): Promise<{ message: string }> { method getHistory (line 151) | getHistory(params?: { method deleteAnalysis (line 165) | deleteAnalysis(analysisId: string): Promise<{ message: string }> { method exportAnalysis (line 170) | exportAnalysis(analysisId: string, format: 'pdf' | 'excel' | 'json' = 'p... method startBatchAnalysis (line 178) | startBatchAnalysis(batchRequest: { method getBatch (line 189) | getBatch(batchId: string): Promise { method getTaskDetails (line 194) | getTaskDetails(taskId: string): Promise { method getTaskList (line 199) | getTaskList(params?: { status?: string; limit?: number; offset?: number ... method getTaskResult (line 204) | getTaskResult(taskId: string): Promise{ method markTaskAsFailed (line 209) | markTaskAsFailed(taskId: string): Promise<{ success: boolean; message: s... method deleteTask (line 214) | deleteTask(taskId: string): Promise<{ success: boolean; message: string ... method shareAnalysis (line 219) | shareAnalysis(analysisId: string, options: { method getStockInfo (line 228) | getStockInfo(symbol: string, market: string): Promise<{ method searchStocks (line 247) | searchStocks(query: string, market?: string): Promise { method getLLMProviders (line 170) | getLLMProviders(): Promise { method addLLMProvider (line 175) | addLLMProvider(provider: Partial): Promise<{ message: strin... method updateLLMProvider (line 180) | updateLLMProvider(id: string, provider: Partial): Promise<{... method deleteLLMProvider (line 185) | deleteLLMProvider(id: string): Promise<{ message: string }> { method toggleLLMProvider (line 190) | toggleLLMProvider(id: string, isActive: boolean): Promise<{ message: str... method migrateEnvToProviders (line 195) | migrateEnvToProviders(): Promise<{ message: string; data: any }> { method initAggregatorProviders (line 200) | initAggregatorProviders(): Promise<{ success: boolean; message: string; ... method testProviderAPI (line 205) | testProviderAPI(providerId: string): Promise<{ success: boolean; message... method getAvailableModels (line 210) | getAvailableModels(): Promise { method fetchProviderModels (line 282) | fetchProviderModels(provider: string): Promise<{ method getLLMConfigs (line 297) | getLLMConfigs(): Promise { method updateLLMConfig (line 302) | updateLLMConfig(config: Partial): Promise<{ message: string; ... method deleteLLMConfig (line 307) | deleteLLMConfig(provider: string, modelName: string): Promise<{ message:... method setDefaultLLM (line 312) | setDefaultLLM(name: string): Promise<{ message: string; default_llm: str... method getDataSourceConfigs (line 317) | getDataSourceConfigs(): Promise { method addDataSourceConfig (line 322) | addDataSourceConfig(config: Partial): Promise<{ messag... method setDefaultDataSource (line 327) | setDefaultDataSource(name: string): Promise<{ message: string; default_d... method updateDataSourceConfig (line 332) | updateDataSourceConfig(name: string, config: Partial):... method deleteDataSourceConfig (line 337) | deleteDataSourceConfig(name: string): Promise<{ message: string }> { method getMarketCategories (line 342) | getMarketCategories(): Promise { method addMarketCategory (line 346) | addMarketCategory(category: Partial): Promise<{ message:... method updateMarketCategory (line 350) | updateMarketCategory(id: string, category: Partial): Pro... method deleteMarketCategory (line 354) | deleteMarketCategory(id: string): Promise<{ message: string }> { method getDataSourceGroupings (line 359) | getDataSourceGroupings(): Promise { method addDataSourceToCategory (line 363) | addDataSourceToCategory(dataSourceName: string, categoryId: string, prio... method removeDataSourceFromCategory (line 372) | removeDataSourceFromCategory(dataSourceName: string, categoryId: string)... method updateDataSourceGrouping (line 376) | updateDataSourceGrouping(dataSourceName: string, categoryId: string, upd... method updateCategoryDataSourceOrder (line 381) | updateCategoryDataSourceOrder(categoryId: string, orderedDataSources: Ar... method getSystemSettingsMeta (line 388) | getSystemSettingsMeta(): Promise<{ items: SettingMeta[] }> { method getDatabaseConfigs (line 396) | getDatabaseConfigs(): Promise { method getDatabaseConfig (line 401) | getDatabaseConfig(dbName: string): Promise { method addDatabaseConfig (line 406) | addDatabaseConfig(config: Partial): Promise<{ success: b... method updateDatabaseConfig (line 411) | updateDatabaseConfig(dbName: string, config: Partial): P... method deleteDatabaseConfig (line 416) | deleteDatabaseConfig(dbName: string): Promise<{ success: boolean; messag... method testDatabaseConfig (line 421) | testDatabaseConfig(dbName: string): Promise { method getSystemSettings (line 426) | getSystemSettings(): Promise> { method getDefaultModels (line 431) | getDefaultModels(): Promise<{ quick_analysis_model: string; deep_analysi... method updateSystemSettings (line 439) | updateSystemSettings(settings: Record): Promise<{ message: ... method testConfig (line 444) | testConfig(testRequest: ConfigTestRequest): Promise { method exportConfig (line 449) | exportConfig(): Promise<{ message: string; data: any; exported_at: strin... method importConfig (line 454) | importConfig(configData: Record): Promise<{ message: string... method migrateLegacyConfig (line 459) | migrateLegacyConfig(): Promise<{ message: string }> { method reloadConfig (line 464) | reloadConfig(): Promise<{ success: boolean; message: string; data?: any ... constant CONFIG_PROVIDERS (line 470) | const CONFIG_PROVIDERS = { constant DATA_SOURCE_TYPES (line 484) | const DATA_SOURCE_TYPES = { constant DATABASE_TYPES (line 509) | const DATABASE_TYPES = { constant DEFAULT_LLM_CONFIG (line 517) | const DEFAULT_LLM_CONFIG: Partial = { constant DEFAULT_DATA_SOURCE_CONFIG (line 525) | const DEFAULT_DATA_SOURCE_CONFIG: Partial = { constant DEFAULT_MARKET_CATEGORIES (line 535) | const DEFAULT_MARKET_CATEGORIES: Partial[] = [ constant DEFAULT_DATABASE_CONFIG (line 578) | const DEFAULT_DATABASE_CONFIG: Partial = { FILE: frontend/src/api/database.ts type DatabaseStatus (line 8) | interface DatabaseStatus { type DatabaseStats (line 37) | interface DatabaseStats { type BackupInfo (line 52) | interface BackupInfo { type ConnectionTestResult (line 63) | interface ConnectionTestResult { method getStatus (line 82) | async getStatus(): Promise { method getStats (line 88) | async getStats(): Promise { method testConnections (line 94) | testConnections(): Promise<{ success: boolean; message: string; data: Co... method createBackup (line 99) | createBackup(data: { method getBackups (line 107) | getBackups(): Promise<{ success: boolean; data: BackupInfo[] }> { method deleteBackup (line 112) | deleteBackup(backupId: string): Promise<{ success: boolean; message: str... method importData (line 117) | importData( method exportData (line 152) | exportData(options: { method cleanupOldData (line 163) | cleanupOldData(days: number = 30): Promise<{ method cleanupAnalysisResults (line 176) | cleanupAnalysisResults(days: number = 30): Promise<{ method cleanupOperationLogs (line 189) | cleanupOperationLogs(days: number = 90): Promise<{ FILE: frontend/src/api/favorites.ts type FavoriteItem (line 3) | interface FavoriteItem { type AddFavoriteReq (line 20) | interface AddFavoriteReq { FILE: frontend/src/api/logs.ts type LogFileInfo (line 7) | interface LogFileInfo { type LogContentResponse (line 16) | interface LogContentResponse { type LogStatistics (line 29) | interface LogStatistics { type LogReadRequest (line 37) | interface LogReadRequest { type LogExportRequest (line 46) | interface LogExportRequest { method listLogFiles (line 58) | listLogFiles(): Promise { method readLogFile (line 65) | readLogFile(request: LogReadRequest): Promise { method exportLogs (line 72) | async exportLogs(request: LogExportRequest): Promise { method getStatistics (line 82) | getStatistics(days: number = 7): Promise { method deleteLogFile (line 89) | deleteLogFile(filename: string): Promise<{ success: boolean; message: st... FILE: frontend/src/api/modelCapabilities.ts type ModelCapabilityInfo (line 10) | interface ModelCapabilityInfo { type ModelRecommendationResponse (line 27) | interface ModelRecommendationResponse { type ModelValidationResponse (line 38) | interface ModelValidationResponse { type BadgeStyle (line 47) | interface BadgeStyle { type AllBadges (line 56) | interface AllBadges { type DepthRequirement (line 65) | interface DepthRequirement { function getDefaultModelConfigs (line 76) | function getDefaultModelConfigs() { function getDepthRequirements (line 86) | function getDepthRequirements() { function getCapabilityDescriptions (line 96) | function getCapabilityDescriptions() { function getAllBadges (line 106) | function getAllBadges() { function recommendModels (line 117) | function recommendModels(researchDepth: string) { function validateModels (line 133) | function validateModels(quickModel: string, deepModel: string, researchD... function batchInitCapabilities (line 149) | function batchInitCapabilities(overwrite: boolean = false) { function getModelCapability (line 163) | function getModelCapability(modelName: string) { FILE: frontend/src/api/multiMarket.ts type Market (line 7) | interface Market { type StockInfo (line 16) | interface StockInfo { type StockQuote (line 33) | interface StockQuote { type DailyQuote (line 48) | interface DailyQuote { function getSupportedMarkets (line 61) | function getSupportedMarkets() { function searchStocks (line 71) | function searchStocks(market: string, query: string, limit: number = 20) { function getStockInfo (line 82) | function getStockInfo(market: string, code: string, source?: string) { function getStockQuote (line 93) | function getStockQuote(market: string, code: string) { function getStockDailyQuotes (line 103) | function getStockDailyQuotes( FILE: frontend/src/api/news.ts type NewsItem (line 6) | interface NewsItem { type LatestNewsResponse (line 24) | interface LatestNewsResponse { type NewsQueryResponse (line 35) | interface NewsQueryResponse { type NewsSyncResponse (line 45) | interface NewsSyncResponse { method getLatestNews (line 63) | async getLatestNews(symbol?: string, limit: number = 10, hours_back: num... method queryStockNews (line 77) | async queryStockNews(symbol: string, hours_back: number = 24, limit: num... method syncMarketNews (line 89) | async syncMarketNews(hours_back: number = 24, max_news_per_source: numbe... FILE: frontend/src/api/notifications.ts type NotificationItem (line 3) | interface NotificationItem { type NotificationListResponse (line 14) | interface NotificationListResponse { method getUnreadCount (line 22) | async getUnreadCount(): Promise<{ success: boolean; data: { count: numbe... method getList (line 31) | async getList(params?: { status?: 'unread' | 'all'; page?: number; page_... method markRead (line 45) | async markRead(id: string): Promise<{ success: boolean }> { method markAllRead (line 53) | async markAllRead(): Promise<{ success: boolean }> { FILE: frontend/src/api/operationLogs.ts type OperationLog (line 8) | interface OperationLog { type OperationLogQuery (line 26) | interface OperationLogQuery { type OperationLogListResponse (line 37) | interface OperationLogListResponse { type OperationLogStats (line 50) | interface OperationLogStats { type OperationLogStatsResponse (line 63) | interface OperationLogStatsResponse { type CreateOperationLogRequest (line 70) | interface CreateOperationLogRequest { type ClearLogsRequest (line 81) | interface ClearLogsRequest { type ClearLogsResponse (line 87) | interface ClearLogsResponse { class OperationLogsApi (line 97) | class OperationLogsApi { method getOperationLogs (line 101) | static getOperationLogs(params: OperationLogQuery = {}): Promise { type RequestConfig (line 19) | interface RequestConfig extends AxiosRequestConfig { constant MESSAGE_THROTTLE_TIME (line 31) | const MESSAGE_THROTTLE_TIME = 3000 // 3秒内相同消息不重复显示 class ApiClient (line 492) | class ApiClient { method get (line 494) | static async get( method post (line 504) | static async post( method put (line 514) | static async put( method delete (line 524) | static async delete( method patch (line 533) | static async patch( method upload (line 543) | static async upload( method download (line 568) | static async download( FILE: frontend/src/api/scheduler.ts type Job (line 7) | interface Job { type JobHistory (line 22) | interface JobHistory { type JobExecution (line 30) | interface JobExecution { type JobExecutionStats (line 51) | interface JobExecutionStats { type SchedulerStats (line 64) | interface SchedulerStats { type SchedulerHealth (line 72) | interface SchedulerHealth { function getJobs (line 82) | function getJobs() { function getJobDetail (line 89) | function getJobDetail(jobId: string) { function pauseJob (line 96) | function pauseJob(jobId: string) { function resumeJob (line 103) | function resumeJob(jobId: string) { function triggerJob (line 110) | function triggerJob(jobId: string, force: boolean = true) { function getJobHistory (line 117) | function getJobHistory(jobId: string, params?: { limit?: number; offset?... function getAllHistory (line 129) | function getAllHistory(params?: { function getSchedulerStats (line 146) | function getSchedulerStats() { function getSchedulerHealth (line 153) | function getSchedulerHealth() { function updateJobMetadata (line 160) | function updateJobMetadata( function getJobExecutions (line 170) | function getJobExecutions(params?: { function getSingleJobExecutions (line 188) | function getSingleJobExecutions( function getJobExecutionStats (line 208) | function getJobExecutionStats(jobId: string) { function cancelExecution (line 215) | function cancelExecution(executionId: string) { function markExecutionFailed (line 222) | function markExecutionFailed(executionId: string, reason?: string) { function deleteExecution (line 231) | function deleteExecution(executionId: string) { FILE: frontend/src/api/screening.ts type ScreeningOrderBy (line 3) | interface ScreeningOrderBy { field: string; direction: 'asc' | 'desc' } type ScreeningRunReq (line 4) | interface ScreeningRunReq { type ScreeningRunItem (line 14) | interface ScreeningRunItem { type ScreeningRunResp (line 29) | interface ScreeningRunResp { total: number; items: ScreeningRunItem[] } type FieldInfo (line 32) | interface FieldInfo { type FieldConfigResponse (line 41) | interface FieldConfigResponse { type IndustryOption (line 47) | interface IndustryOption { type IndustriesResponse (line 53) | interface IndustriesResponse { FILE: frontend/src/api/stockSync.ts type SingleStockSyncRequest (line 7) | interface SingleStockSyncRequest { type BatchStockSyncRequest (line 17) | interface BatchStockSyncRequest { type SyncResult (line 26) | interface SyncResult { type SingleStockSyncResponse (line 33) | interface SingleStockSyncResponse { type BatchStockSyncResponse (line 41) | interface BatchStockSyncResponse { type StockSyncStatus (line 64) | interface StockSyncStatus { method syncSingle (line 82) | syncSingle(request: SingleStockSyncRequest) { method syncBatch (line 91) | syncBatch(request: BatchStockSyncRequest) { method getStatus (line 100) | getStatus(symbol: string) { FILE: frontend/src/api/stocks.ts type QuoteResponse (line 3) | interface QuoteResponse { type FundamentalsResponse (line 19) | interface FundamentalsResponse { type KlineBar (line 45) | interface KlineBar { type KlineResponse (line 55) | interface KlineResponse { type NewsItem (line 65) | interface NewsItem { type NewsResponse (line 73) | interface NewsResponse { method getQuote (line 88) | async getQuote(symbol: string) { method getFundamentals (line 96) | async getFundamentals(symbol: string) { method getKline (line 107) | async getKline(symbol: string, period: KlineResponse['period'] = 'day', ... method getNews (line 118) | async getNews(symbol: string, days = 30, limit = 50, includeAnnouncement... FILE: frontend/src/api/sync.ts type DataSourceStatus (line 7) | interface DataSourceStatus { type SyncStatus (line 16) | interface SyncStatus { type SyncRequest (line 32) | interface SyncRequest { type ApiResponse (line 38) | interface ApiResponse { type BaseTestResult (line 45) | interface BaseTestResult { type DataSourceTestResult (line 53) | interface DataSourceTestResult { type SyncRecommendations (line 62) | interface SyncRecommendations { FILE: frontend/src/api/tags.ts type TagItem (line 4) | interface TagItem { type CreateTagDto (line 13) | interface CreateTagDto { type UpdateTagDto (line 19) | interface UpdateTagDto { method list (line 26) | async list(): Promise> { method create (line 29) | async create(payload: CreateTagDto): Promise> { method update (line 32) | async update(id: string, payload: UpdateTagDto): Promise> { FILE: frontend/src/api/templates.ts type TemplateItem (line 3) | interface TemplateItem { type CreateTemplatePayload (line 13) | interface CreateTemplatePayload { type UpdateTemplatePayload (line 20) | interface UpdateTemplatePayload extends Partial {} method list (line 23) | list(params?: Record) { method get (line 27) | get(id: string) { method create (line 31) | create(payload: CreateTemplatePayload) { method update (line 35) | update(id: string, payload: UpdateTemplatePayload) { method remove (line 39) | remove(id: string) { method listAgentTemplates (line 43) | listAgentTemplates(params?: Record) { FILE: frontend/src/api/usage.ts type UsageRecord (line 8) | interface UsageRecord { type UsageStatistics (line 21) | interface UsageStatistics { function getUsageRecords (line 35) | function getUsageRecords(params?: { function getUsageStatistics (line 51) | function getUsageStatistics(params?: { function getCostByProvider (line 65) | function getCostByProvider(days: number = 7) { function getCostByModel (line 76) | function getCostByModel(days: number = 7) { function getDailyCost (line 87) | function getDailyCost(days: number = 7) { function deleteOldRecords (line 98) | function deleteOldRecords(days: number = 90) { FILE: frontend/src/components/index.ts function setupGlobalComponents (line 6) | function setupGlobalComponents(app: App) { FILE: frontend/src/constants/analysts.ts type Analyst (line 5) | interface Analyst { constant ANALYSTS (line 13) | const ANALYSTS: Analyst[] = [ constant ANALYST_NAMES (line 41) | const ANALYST_NAMES = ANALYSTS.map(analyst => analyst.name) constant DEFAULT_ANALYSTS (line 44) | const DEFAULT_ANALYSTS = ['市场分析师', '基本面分析师'] constant ANALYST_NAME_TO_ID_MAP (line 62) | const ANALYST_NAME_TO_ID_MAP: Record = { constant MODEL_TO_PROVIDER_MAP (line 83) | const MODEL_TO_PROVIDER_MAP: Record = { FILE: frontend/src/router/index.ts method scrollBehavior (line 401) | scrollBehavior(to, from, savedPosition) { FILE: frontend/src/stores/app.ts type AppState (line 5) | interface AppState { method isDarkTheme (line 76) | isDarkTheme(): boolean { method actualSidebarWidth (line 84) | actualSidebarWidth(): number { method currentPageTitle (line 89) | currentPageTitle(): string { method appInfo (line 94) | appInfo(): Record { method setLoading (line 107) | setLoading(loading: boolean, progress = 0) { method setLoadingProgress (line 113) | setLoadingProgress(progress: number) { method toggleTheme (line 118) | toggleTheme() { method setTheme (line 126) | setTheme(theme: 'light' | 'dark' | 'auto') { method applyTheme (line 134) | applyTheme() { method setLanguage (line 146) | setLanguage(language: 'zh-CN' | 'en-US') { method toggleSidebar (line 154) | toggleSidebar() { method setSidebarCollapsed (line 159) | setSidebarCollapsed(collapsed: boolean) { method setSidebarWidth (line 166) | setSidebarWidth(width: number) { method setCurrentRoute (line 173) | setCurrentRoute(route: RouteLocationNormalized) { method updatePreferences (line 178) | updatePreferences(preferences: Partial) { method resetPreferences (line 185) | resetPreferences() { method setOnlineStatus (line 196) | setOnlineStatus(isOnline: boolean) { method setApiConnected (line 201) | setApiConnected(connected: boolean) { method checkApiConnection (line 207) | async checkApiConnection() { method fetchApiVersion (line 234) | async fetchApiVersion() { method resetAppState (line 265) | resetAppState() { FILE: frontend/src/stores/auth.ts type AuthState (line 6) | interface AuthState { method userAvatar (line 71) | userAvatar(): string | undefined { method userDisplayName (line 76) | userDisplayName(): string { method isAdmin (line 81) | isAdmin(): boolean { method hasPermission (line 86) | hasPermission(): (permission: string) => boolean { method hasRole (line 93) | hasRole(): (role: string) => boolean { method userStats (line 100) | userStats(): Record { method setAuthInfo (line 113) | setAuthInfo(token: string, refreshToken?: string, user?: User) { method clearAuthInfo (line 146) | clearAuthInfo() { method redirectToLogin (line 164) | redirectToLogin() { method setAuthHeader (line 177) | setAuthHeader(token: string | null) { method login (line 183) | async login(loginForm: LoginForm) { method register (line 228) | async register(registerForm: RegisterForm) { method logout (line 247) | async logout() { method refreshAccessToken (line 264) | async refreshAccessToken() { method fetchUserInfo (line 316) | async fetchUserInfo() { method fetchUserPermissions (line 341) | async fetchUserPermissions() { method updateUserInfo (line 348) | async updateUserInfo(userInfo: Partial) { method syncUserPreferencesToAppStore (line 372) | syncUserPreferencesToAppStore() { method changePassword (line 410) | async changePassword(oldPassword: string, newPassword: string) { method setRedirectPath (line 432) | setRedirectPath(path: string) { method getAndClearRedirectPath (line 437) | getAndClearRedirectPath(): string { method checkAuthStatus (line 444) | async checkAuthStatus() { FILE: frontend/src/stores/notifications.ts function refreshUnreadCount (line 24) | async function refreshUnreadCount() { function loadList (line 33) | async function loadList(status: 'unread' | 'all' = 'all') { function markRead (line 45) | async function markRead(id: string) { function markAllRead (line 52) | async function markAllRead() { function addNotification (line 58) | function addNotification(n: Omit>(obj: T): T { function normalizeStockArray (line 197) | function normalizeStockArray>(arr: T[]): T... FILE: frontend/src/utils/stockValidator.ts type StockValidationResult (line 6) | interface StockValidationResult { function validateAStock (line 22) | function validateAStock(code: string): StockValidationResult { function validateUSStock (line 57) | function validateUSStock(code: string): StockValidationResult { function validateHKStock (line 90) | function validateHKStock(code: string): StockValidationResult { function validateStockCode (line 117) | function validateStockCode( function getStockCodeFormatHelp (line 178) | function getStockCodeFormatHelp(market: 'A股' | '美股' | '港股'): string { function getStockCodeExamples (line 194) | function getStockCodeExamples(market: 'A股' | '美股' | '港股'): string[] { function formatStockCode (line 212) | function formatStockCode(code: string, market: 'A股' | '美股' | '港股'): stri... FILE: scripts/add_302ai_provider.py function add_302ai_provider (line 15) | async def add_302ai_provider(): FILE: scripts/akshare_force_sync_all.py function main (line 37) | async def main(batch_size: int = 50): FILE: scripts/akshare_sync_optimized.py function sync_stock_basic_info (line 41) | async def sync_stock_basic_info( function main (line 215) | def main(): FILE: scripts/analyze_amount_distribution.py function analyze_amount (line 22) | async def analyze_amount(): FILE: scripts/analyze_data_calls.py class DataCallAnalyzer (line 22) | class DataCallAnalyzer: method __init__ (line 25) | def __init__(self, log_file: Path): method parse_logs (line 31) | def parse_logs(self): method _process_structured_entry (line 59) | def _process_structured_entry(self, entry: Dict[str, Any], line_num: i... method _process_regular_log (line 111) | def _process_regular_log(self, line: str, line_num: int): method analyze_data_calls (line 157) | def analyze_data_calls(self) -> Dict[str, Any]: method analyze_tool_calls (line 266) | def analyze_tool_calls(self) -> Dict[str, Any]: method generate_report (line 308) | def generate_report(self) -> str: function main (line 353) | def main(): FILE: scripts/archived/container_quick_init.py function print_status (line 14) | def print_status(message, status="info"): function check_mongodb_connection (line 37) | def check_mongodb_connection(): function hash_password (line 61) | def hash_password(password: str) -> str: function create_admin_user (line 65) | def create_admin_user(client): function create_web_user_config (line 143) | def create_web_user_config(): function create_admin_password_config (line 177) | def create_admin_password_config(): function main (line 202) | def main(): FILE: scripts/batch_update_docs.py class DocumentationUpdater (line 18) | class DocumentationUpdater: method __init__ (line 21) | def __init__(self): method create_version_header (line 47) | def create_version_header(self, status: str = "待更新") -> str: method add_version_headers (line 58) | def add_version_headers(self) -> List[str]: method fix_code_blocks (line 88) | def fix_code_blocks(self) -> List[str]: method update_status_tracking (line 138) | def update_status_tracking(self, updated_files: List[str], fixed_files... method generate_summary_report (line 180) | def generate_summary_report(self, updated_files: List[str], fixed_file... function main (line 220) | def main(): FILE: scripts/build_docker_with_pdf.py function run_command (line 16) | def run_command(command, description, timeout=300): function check_dockerfile (line 47) | def check_dockerfile(): function build_docker_image (line 80) | def build_docker_image(): function test_docker_container (line 88) | def test_docker_container(): function main (line 115) | def main(): FILE: scripts/capture_web_screenshots.py function check_dependencies (line 21) | def check_dependencies(): function check_web_service (line 33) | def check_web_service(): function start_web_service (line 48) | def start_web_service(): function capture_screenshots (line 85) | def capture_screenshots(): function create_screenshot_guide (line 173) | def create_screenshot_guide(): function main (line 253) | def main(): FILE: scripts/check_000001_data.py function check_data (line 15) | async def check_data(): FILE: scripts/check_akshare_data_structure.py function check_data (line 16) | async def check_data(): FILE: scripts/check_akshare_fields.py function check_akshare_fields (line 7) | async def check_akshare_fields(): FILE: scripts/check_amount_unit.py function check_amount_unit (line 22) | async def check_amount_unit(): FILE: scripts/check_api_config.py function check_env_file (line 16) | def check_env_file(): function check_dashscope_config (line 28) | def check_dashscope_config(): function check_other_apis (line 66) | def check_other_apis(): function check_memory_functionality (line 92) | def check_memory_functionality(): function provide_recommendations (line 120) | def provide_recommendations(dashscope_ok, configured_apis, missing_apis): function main (line 158) | def main(): FILE: scripts/check_config_coverage.py function extract_sidebar_providers (line 19) | def extract_sidebar_providers(): function extract_sidebar_models (line 45) | def extract_sidebar_models(): function extract_sidebar_api_keys (line 88) | def extract_sidebar_api_keys(): function extract_sidebar_advanced_settings (line 101) | def extract_sidebar_advanced_settings(): function check_provider_coverage (line 121) | def check_provider_coverage(): function check_model_coverage (line 152) | def check_model_coverage(): function check_api_key_coverage (line 174) | def check_api_key_coverage(): function check_advanced_settings_coverage (line 207) | def check_advanced_settings_coverage(): function main (line 236) | def main(): FILE: scripts/check_config_reports.py function check_config_reports (line 9) | async def check_config_reports(): FILE: scripts/check_db_data.py function check (line 19) | async def check(): FILE: scripts/check_doc_consistency.py class DocumentationChecker (line 19) | class DocumentationChecker: method __init__ (line 22) | def __init__(self): method check_all (line 28) | def check_all(self) -> Dict[str, List[str]]: method check_version_consistency (line 42) | def check_version_consistency(self) -> List[str]: method check_agent_architecture (line 87) | def check_agent_architecture(self) -> List[str]: method check_code_examples (line 131) | def check_code_examples(self) -> List[str]: method check_api_references (line 168) | def check_api_references(self) -> List[str]: method check_file_existence (line 186) | def check_file_existence(self) -> List[str]: method generate_report (line 212) | def generate_report(self, results: Dict[str, List[str]]) -> str: function main (line 232) | def main(): FILE: scripts/check_existing_reports.py function check_reports (line 10) | async def check_reports(): FILE: scripts/check_export_file.py function check_export_file (line 7) | def check_export_file(filepath: str): FILE: scripts/check_financial_data.py function check_financial_data (line 24) | async def check_financial_data(): function main (line 201) | async def main(): FILE: scripts/check_financial_sample.py function main (line 8) | async def main(): FILE: scripts/check_financial_structure.py function main (line 9) | async def main(): FILE: scripts/check_gemini_config.py function check_gemini_config (line 14) | async def check_gemini_config(): FILE: scripts/check_license.py function check_license_file (line 14) | def check_license_file(file_path: Path, component_name: str) -> bool: function main (line 40) | def main(): FILE: scripts/check_llm_pricing.py function check_pricing (line 6) | async def check_pricing(): FILE: scripts/check_missing_dependencies.py function extract_imports_from_file (line 73) | def extract_imports_from_file(file_path: Path) -> Set[str]: function scan_directory (line 95) | def scan_directory(directory: Path) -> Set[str]: function get_declared_dependencies (line 110) | def get_declared_dependencies() -> Set[str]: function normalize_package_name (line 139) | def normalize_package_name(import_name: str) -> str: function main (line 149) | def main(): FILE: scripts/check_missing_stocks.py function get_akshare_stock_codes (line 39) | async def get_akshare_stock_codes() -> Set[str]: function get_db_stock_codes (line 53) | async def get_db_stock_codes() -> Set[str]: function test_fetch_missing_stocks (line 76) | async def test_fetch_missing_stocks(missing_codes: List[str], limit: int... function main (line 110) | async def main(test_fetch: bool = False): FILE: scripts/check_mongodb_data_range.py function check_data_range (line 7) | def check_data_range(): FILE: scripts/check_mongodb_financial_data.py function check_mongodb_data (line 13) | def check_mongodb_data(): FILE: scripts/check_mongodb_system_config.py function check_system_config (line 17) | def check_system_config(): FILE: scripts/check_news_data.py function check_news_data (line 17) | async def check_news_data(): FILE: scripts/check_ningde_data.py function check_ningde (line 22) | async def check_ningde(): FILE: scripts/check_null_code.py function main (line 14) | async def main(): FILE: scripts/check_old_mongodb_volume.py function run_command (line 20) | def run_command(cmd, shell=True): function check_old_volume (line 35) | def check_old_volume(): FILE: scripts/check_pdf_tools.py function print_header (line 12) | def print_header(text): function check_command (line 18) | def check_command(command, name): function check_python_package (line 42) | def check_python_package(package_name, import_name=None): function get_install_instructions (line 55) | def get_install_instructions(): function main (line 116) | def main(): FILE: scripts/check_provider_values.py function main (line 10) | async def main(): FILE: scripts/check_redis_cache.py function check_redis_cache (line 16) | def check_redis_cache(): FILE: scripts/check_redis_connections.py function check_redis_connections (line 21) | async def check_redis_connections(): function kill_idle_pubsub_connections (line 154) | async def kill_idle_pubsub_connections(idle_threshold: int = 300): FILE: scripts/check_roe.py function main (line 8) | async def main(): FILE: scripts/check_stock_daily_data.py function check_stock_daily_data (line 15) | async def check_stock_daily_data(symbol: str = "000001"): FILE: scripts/check_stock_daily_quotes_fields.py function check_fields (line 9) | def check_fields(): FILE: scripts/check_stock_fields.py function check_fields (line 14) | async def check_fields(): FILE: scripts/check_stock_source.py function check_stock_source (line 12) | def check_stock_source(): FILE: scripts/check_token_usage_collection.py function main (line 17) | async def main(): FILE: scripts/check_tushare_data_range.py function check_data_range (line 8) | async def check_data_range(): FILE: scripts/check_usage_records.py function main (line 15) | async def main(): FILE: scripts/clean_invalid_trade_date.py function clean_invalid_trade_date (line 15) | async def clean_invalid_trade_date(): FILE: scripts/cleanup_old_system_config.py function check_and_cleanup (line 24) | def check_and_cleanup(): FILE: scripts/compare_requirements.py function parse_requirements_txt (line 14) | def parse_requirements_txt() -> Dict[str, str]: function parse_pyproject_toml (line 36) | def parse_pyproject_toml() -> Dict[str, str]: function main (line 63) | def main(): FILE: scripts/config/cleanup_sensitive_in_db.py function redact_dict (line 29) | def redact_dict(d: Dict[str, Any]) -> Dict[str, Any]: function cleanup_system_configs (line 44) | def cleanup_system_configs(db, apply: bool): function cleanup_llm_providers (line 91) | def cleanup_llm_providers(db, apply: bool): function _id_str (line 111) | def _id_str(doc: Dict[str, Any]) -> str: function main (line 118) | def main(): FILE: scripts/convert_prints_to_logs.py class PrintToLogConverter (line 13) | class PrintToLogConverter: method __init__ (line 16) | def __init__(self, project_root: Path): method should_skip_file (line 33) | def should_skip_file(self, file_path: Path) -> bool: method get_log_level_from_message (line 47) | def get_log_level_from_message(self, message: str) -> str: method add_logging_import (line 71) | def add_logging_import(self, content: str, file_path: Path) -> str: method convert_print_statements (line 139) | def convert_print_statements(self, content: str) -> str: method convert_file (line 188) | def convert_file(self, file_path: Path) -> bool: method convert_project (line 228) | def convert_project(self) -> Dict[str, int]: method generate_report (line 247) | def generate_report(self) -> str: function main (line 269) | def main(): FILE: scripts/create_default_admin.py function hash_password (line 33) | def hash_password(password: str) -> str: function connect_mongodb (line 38) | def connect_mongodb() -> MongoClient: function create_admin_user (line 56) | def create_admin_user( function list_users (line 118) | def list_users(db: any): function main (line 149) | def main(): FILE: scripts/create_default_users.py function create_user_via_api (line 13) | def create_user_via_api(username: str, email: str, password: str): function main (line 40) | def main(): FILE: scripts/debug/check_industry_data.py function check_industries (line 9) | async def check_industries(): FILE: scripts/debug/check_log_timezone.py function check_log_timezone (line 18) | async def check_log_timezone(): FILE: scripts/debug/check_mongodb_data.py function check_mongodb_data (line 11) | def check_mongodb_data(): FILE: scripts/debug/check_real_estate_data.py function check_real_estate (line 9) | async def check_real_estate(): FILE: scripts/debug/check_report_detail.py function check_report (line 9) | async def check_report(): FILE: scripts/debug/check_report_fields.py function check_report_fields (line 15) | async def check_report_fields(): FILE: scripts/debug/check_timezone.py function check_timezone (line 11) | def check_timezone(): FILE: scripts/debug/check_zhipu_config.py function main (line 6) | async def main(): FILE: scripts/debug/debug_000002_detailed.py function debug_000002_detailed (line 14) | def debug_000002_detailed(): FILE: scripts/debug/debug_000002_pe.py function debug_000002_pe (line 16) | def debug_000002_pe(): FILE: scripts/debug/debug_000002_simple.py function debug_000002_simple (line 14) | def debug_000002_simple(): FILE: scripts/debug/debug_analysis_issue.py function debug_analysis_result (line 18) | def debug_analysis_result(): FILE: scripts/debug/debug_api_response.py function debug_api_response (line 12) | def debug_api_response(): FILE: scripts/debug/debug_industries.py function debug_industries (line 13) | async def debug_industries(): FILE: scripts/debug/debug_providers.py function debug_providers (line 34) | async def debug_providers(): FILE: scripts/debug/debug_valuation_data.py function debug_valuation_data (line 9) | def debug_valuation_data(stock_code): FILE: scripts/debug/quick_test_stock_code.py function quick_test (line 10) | def quick_test(): FILE: scripts/debug_backfill.py function main (line 7) | async def main(): FILE: scripts/debug_bulk_write_issue.py function debug_bulk_write_issue (line 24) | async def debug_bulk_write_issue(): FILE: scripts/debug_data_save_process.py function debug_data_save_process (line 21) | async def debug_data_save_process(): FILE: scripts/debug_default_base_url.py function main (line 11) | def main(): FILE: scripts/debug_enhanced_adapter.py function check_mongodb_data (line 12) | def check_mongodb_data(): function test_date_format_query (line 90) | def test_date_format_query(): function test_enhanced_adapter_with_correct_format (line 149) | def test_enhanced_adapter_with_correct_format(): FILE: scripts/debug_frontend_api.py function debug_frontend_api (line 11) | def debug_frontend_api(): FILE: scripts/debug_mongodb_daily_data.py function debug_mongodb_daily_data (line 23) | async def debug_mongodb_daily_data(): FILE: scripts/debug_mongodb_query.py function test_mongodb_query (line 22) | async def test_mongodb_query(): FILE: scripts/debug_mongodb_time.py function check_mongodb_time (line 13) | def check_mongodb_time(): FILE: scripts/debug_news_format.py function debug_news_format (line 17) | async def debug_news_format(): FILE: scripts/debug_tushare_historical_sync.py function debug_tushare_historical_sync (line 19) | async def debug_tushare_historical_sync(): FILE: scripts/demo_user_activity.py function demo_user_activities (line 22) | def demo_user_activities(): function demo_activity_management (line 119) | def demo_activity_management(): function main (line 147) | def main(): FILE: scripts/deployment/create_github_release.py function run_command (line 17) | def run_command(command, cwd=None): function create_release_notes (line 32) | def create_release_notes(): function show_release_info (line 132) | def show_release_info(): function main (line 161) | def main(): FILE: scripts/deployment/release_v0.1.2.py function run_command (line 17) | def run_command(command, cwd=None): function check_git_status (line 32) | def check_git_status(): function create_release_tag (line 49) | def create_release_tag(): function generate_release_notes (line 71) | def generate_release_notes(): function show_release_summary (line 164) | def show_release_summary(): function main (line 197) | def main(): FILE: scripts/deployment/release_v0.1.3.py function run_command (line 17) | def run_command(command, cwd=None): function check_git_status (line 32) | def check_git_status(): function update_version_files (line 51) | def update_version_files(): function run_tests (line 68) | def run_tests(): function create_git_tag (line 88) | def create_git_tag(): function commit_changes (line 115) | def commit_changes(): function push_to_remote (line 148) | def push_to_remote(): function generate_release_summary (line 167) | def generate_release_summary(): function main (line 197) | def main(): FILE: scripts/deployment/release_v0.1.9.py function run_command (line 17) | def run_command(command, cwd=None): function check_version_consistency (line 32) | def check_version_consistency(): function create_git_tag (line 70) | def create_git_tag(): function generate_release_summary (line 92) | def generate_release_summary(): function validate_release (line 166) | def validate_release(): function main (line 202) | def main(): FILE: scripts/development/adaptive_cache_manager.py class AdaptiveCacheManager (line 28) | class AdaptiveCacheManager: method __init__ (line 31) | def __init__(self, cache_dir: str = "data_cache"): method _load_smart_config (line 47) | def _load_smart_config(self): method _init_backends (line 87) | def _init_backends(self): method _get_cache_key (line 143) | def _get_cache_key(self, symbol: str, start_date: str, end_date: str, method _get_ttl_seconds (line 149) | def _get_ttl_seconds(self, symbol: str, data_type: str = "stock_data")... method _is_cache_valid (line 162) | def _is_cache_valid(self, cache_time: datetime, ttl_seconds: int) -> b... method _save_to_file (line 170) | def _save_to_file(self, cache_key: str, data: Any, metadata: Dict) -> ... method _load_from_file (line 188) | def _load_from_file(self, cache_key: str) -> Optional[Dict]: method _save_to_redis (line 203) | def _save_to_redis(self, cache_key: str, data: Any, metadata: Dict, tt... method _load_from_redis (line 222) | def _load_from_redis(self, cache_key: str) -> Optional[Dict]: method save_stock_data (line 242) | def save_stock_data(self, symbol: str, data: Any, start_date: str = None, method load_stock_data (line 282) | def load_stock_data(self, cache_key: str) -> Optional[Any]: method find_cached_stock_data (line 313) | def find_cached_stock_data(self, symbol: str, start_date: str = None, method get_cache_stats (line 324) | def get_cache_stats(self) -> Dict[str, Any]: function get_cache (line 350) | def get_cache() -> AdaptiveCacheManager: function main (line 358) | def main(): FILE: scripts/development/calculate_valuation_300750.py function calculate_valuation_ratios (line 9) | def calculate_valuation_ratios(stock_code): FILE: scripts/development/calculate_valuation_300750_v2.py function calculate_valuation_ratios_v2 (line 9) | def calculate_valuation_ratios_v2(stock_code): FILE: scripts/development/download_finnhub_sample_data.py function create_sample_news_data (line 27) | def create_sample_news_data(ticker, data_dir, days=7): function create_sample_insider_data (line 129) | def create_sample_insider_data(ticker, data_dir, data_type): function main (line 188) | def main(): FILE: scripts/development/extract_comparison_results.py function extract_comparison_results (line 10) | def extract_comparison_results(): FILE: scripts/development/fix_streamlit_watcher.py function clean_pycache_files (line 22) | def clean_pycache_files(): function check_streamlit_config (line 73) | def check_streamlit_config(): function set_environment_variables (line 97) | def set_environment_variables(): function main (line 119) | def main(): FILE: scripts/development/organize_scripts.py function create_scripts_structure (line 16) | def create_scripts_structure(): function main (line 248) | def main(): FILE: scripts/development/prepare_upstream_contribution.py class UpstreamContributionPreparer (line 20) | class UpstreamContributionPreparer: method __init__ (line 23) | def __init__(self, source_dir: str = ".", target_dir: str = "./upstrea... method analyze_chinese_content (line 61) | def analyze_chinese_content(self) -> Dict[str, List[str]]: method clean_chinese_content (line 86) | def clean_chinese_content(self, file_path: Path, target_path: Path): method extract_generic_improvements (line 131) | def extract_generic_improvements(self, batch_name: str): method generate_batch_documentation (line 151) | def generate_batch_documentation(self, batch_name: str, batch_dir: Path): method generate_pr_template (line 197) | def generate_pr_template(self, batch_name: str): method validate_contribution (line 245) | def validate_contribution(self, batch_name: str) -> bool: method generate_contribution_summary (line 271) | def generate_contribution_summary(self): method prepare_all_batches (line 296) | def prepare_all_batches(self): function main (line 324) | def main(): FILE: scripts/development/test_hk_data_fields.py function test_hk_stock_data_fields (line 19) | def test_hk_stock_data_fields(): function test_multiple_stocks (line 190) | def test_multiple_stocks(): FILE: scripts/development/test_hk_data_with_preclose.py function test_hk_data_with_preclose (line 15) | def test_hk_data_with_preclose(): FILE: scripts/development/test_hk_pe_pb.py function test_akshare_hk_spot (line 16) | def test_akshare_hk_spot(): function test_akshare_hk_valuation (line 53) | def test_akshare_hk_valuation(): function test_akshare_hk_individual_stock (line 87) | def test_akshare_hk_individual_stock(): function test_tushare_hk (line 132) | def test_tushare_hk(): function main (line 186) | def main(): FILE: scripts/development/test_hk_technical_indicators.py function test_hk_technical_indicators (line 15) | def test_hk_technical_indicators(): FILE: scripts/development/test_hk_valuation_apis.py function test_stock_hk_valuation_baidu (line 17) | def test_stock_hk_valuation_baidu(): function test_stock_hk_indicator_eniu (line 53) | def test_stock_hk_indicator_eniu(): function test_stock_financial_hk_analysis_indicator_em (line 87) | def test_stock_financial_hk_analysis_indicator_em(): function test_stock_hk_spot_em (line 130) | def test_stock_hk_spot_em(): function main (line 170) | def main(): FILE: scripts/development/test_hk_with_financials.py function test_financial_indicators (line 17) | def test_financial_indicators(): function test_historical_data_with_pe_pb (line 60) | def test_historical_data_with_pe_pb(): function test_pe_pb_calculation (line 110) | def test_pe_pb_calculation(): function main (line 207) | def main(): FILE: scripts/development/test_lookback_days.py function test_lookback_days (line 15) | def test_lookback_days(): FILE: scripts/development/test_pre_close_fix.py function test_pre_close_calculation (line 17) | def test_pre_close_calculation(): FILE: scripts/development/test_rsi_styles.py function test_rsi_methods (line 18) | def test_rsi_methods(): function test_a_stock_compatibility (line 93) | def test_a_stock_compatibility(): FILE: scripts/development/test_unified_indicators.py function test_hk_indicators (line 14) | def test_hk_indicators(): function test_us_indicators (line 51) | def test_us_indicators(): function test_indicator_library (line 94) | def test_indicator_library(): FILE: scripts/development/verify_601899_stock_info.py function verify_stock_601899 (line 23) | async def verify_stock_601899(): FILE: scripts/diagnose_empty_data.py function test_time_parameters (line 15) | def test_time_parameters(): function test_stock_codes (line 77) | def test_stock_codes(): function test_api_limits (line 126) | def test_api_limits(): function test_date_formats (line 182) | def test_date_formats(): function main (line 220) | def main(): FILE: scripts/diagnose_env_vars.py function diagnose_env_vars (line 10) | def diagnose_env_vars(): FILE: scripts/diagnose_historical_data_sync.py function diagnose_historical_data_sync (line 16) | async def diagnose_historical_data_sync(): FILE: scripts/diagnose_pe_pb_data.py function diagnose_stock (line 36) | async def diagnose_stock(code: str): function main (line 230) | def main(): FILE: scripts/diagnose_system.py class Colors (line 18) | class Colors: function print_success (line 27) | def print_success(msg): print(f"{Colors.GREEN}✅ {msg}{Colors.END}") function print_warning (line 28) | def print_warning(msg): print(f"{Colors.YELLOW}⚠️ {msg}{Colors.END}") function print_error (line 29) | def print_error(msg): print(f"{Colors.RED}❌ {msg}{Colors.END}") function print_info (line 30) | def print_info(msg): print(f"{Colors.CYAN}ℹ️ {msg}{Colors.END}") function print_header (line 31) | def print_header(msg): print(f"\n{Colors.BOLD}{Colors.BLUE}{'='*60}\n{ms... function check_python_version (line 33) | def check_python_version() -> Tuple[bool, str]: function check_pip_version (line 43) | def check_pip_version() -> Tuple[bool, str]: function check_virtual_env (line 59) | def check_virtual_env() -> Tuple[bool, str]: function check_required_packages (line 71) | def check_required_packages() -> Tuple[bool, List[str]]: function check_env_file (line 95) | def check_env_file() -> Tuple[bool, str]: function check_api_keys (line 109) | def check_api_keys() -> Tuple[bool, List[str]]: function check_port_availability (line 136) | def check_port_availability() -> Tuple[bool, str]: function check_network_connectivity (line 149) | def check_network_connectivity() -> Tuple[bool, str]: function check_disk_space (line 168) | def check_disk_space() -> Tuple[bool, str]: function main (line 183) | def main(): FILE: scripts/diagnose_usage_statistics.py function main (line 16) | async def main(): FILE: scripts/disable_structured_logs.py function disable_structured_logging (line 8) | def disable_structured_logging(): FILE: scripts/docker_deployment_init.py function check_docker_services (line 23) | async def check_docker_services(): function wait_for_services (line 50) | async def wait_for_services(): function init_mongodb (line 85) | async def init_mongodb(): function create_database_indexes (line 123) | async def create_database_indexes(db): function insert_basic_data (line 156) | async def insert_basic_data(db): function create_default_admin_user (line 175) | async def create_default_admin_user(db): function create_system_config (line 214) | async def create_system_config(db): function create_model_config (line 258) | async def create_model_config(db): function setup_admin_password (line 291) | async def setup_admin_password(): function create_env_file (line 317) | async def create_env_file(): function main (line 342) | async def main(): FILE: scripts/download_finnhub_data.py class FinnhubDataDownloader (line 39) | class FinnhubDataDownloader: method __init__ (line 42) | def __init__(self, api_key: str = None, data_dir: str = None): method _make_request (line 75) | def _make_request(self, endpoint: str, params: Dict[str, Any]) -> Dict... method download_news_data (line 105) | def download_news_data(self, symbols: List[str], days: int = 7, force_... method download_insider_sentiment (line 192) | def download_insider_sentiment(self, symbols: List[str], force_refresh... method download_insider_transactions (line 231) | def download_insider_transactions(self, symbols: List[str], force_refr... function main (line 270) | def main(): FILE: scripts/ensure_logs_dir.py function ensure_logs_directory (line 11) | def ensure_logs_directory(): function main (line 95) | def main(): FILE: scripts/extract_error_files.py function run_syntax_check (line 14) | def run_syntax_check(): function extract_error_files (line 31) | def extract_error_files(output): function generate_report (line 51) | def generate_report(error_files): function main (line 98) | def main(): FILE: scripts/fix_auth_imports.py function fix_file (line 43) | def fix_file(filepath: str) -> bool: function main (line 78) | def main(): FILE: scripts/fix_depth_value.py function fix_depth_value (line 21) | def fix_depth_value(): FILE: scripts/fix_docker_logging.py function fix_docker_logging_config (line 10) | def fix_docker_logging_config(): function create_docker_logging_config (line 48) | def create_docker_logging_config(): function update_docker_compose (line 134) | def update_docker_compose(): function create_test_script (line 165) | def create_test_script(): function main (line 240) | def main(): FILE: scripts/fix_duplicate_loggers.py function find_python_files (line 17) | def find_python_files(root_dir: str, exclude_dirs: List[str] = None) -> ... function analyze_logger_definitions (line 33) | def analyze_logger_definitions(file_path: str) -> Dict: function find_import_section_end (line 58) | def find_import_section_end(lines: List[str]) -> int: function fix_duplicate_loggers (line 98) | def fix_duplicate_loggers(file_path: str) -> Dict: function main (line 165) | def main(): FILE: scripts/fix_full_symbol_index.py function generate_full_symbol (line 30) | def generate_full_symbol(code: str) -> str: function fix_full_symbol_index (line 54) | async def fix_full_symbol_index(): function main (line 202) | async def main(): FILE: scripts/fix_logger_position.py class LoggerPositionFixer (line 17) | class LoggerPositionFixer: method __init__ (line 23) | def __init__(self): method find_python_files (line 28) | def find_python_files(self, directory: str) -> List[str]: method analyze_file_structure (line 52) | def analyze_file_structure(self, content: str) -> dict: method fix_logger_position (line 115) | def fix_logger_position(self, file_path: str) -> bool: method fix_all_files (line 194) | def fix_all_files(self, directory: str) -> dict: method generate_report (line 223) | def generate_report(self, output_file: str = 'logger_position_fix_repo... function main (line 250) | def main(): FILE: scripts/fix_logging_config_error.py function fix_logging_docker_config (line 9) | def fix_logging_docker_config(): function fix_main_logging_config (line 122) | def fix_main_logging_config(): function create_simple_test (line 153) | def create_simple_test(): function main (line 252) | def main(): FILE: scripts/fix_logging_imports.py class LoggingImportFixer (line 11) | class LoggingImportFixer: method __init__ (line 14) | def __init__(self, project_root: Path): method should_skip_file (line 19) | def should_skip_file(self, file_path: Path) -> bool: method fix_logging_import_position (line 36) | def fix_logging_import_position(self, content: str, file_path: Path) -... method fix_file (line 120) | def fix_file(self, file_path: Path) -> bool: method fix_project (line 156) | def fix_project(self) -> Dict[str, int]: method generate_report (line 175) | def generate_report(self) -> str: function main (line 197) | def main(): FILE: scripts/fix_market_quotes_null_code.py function fix_null_code_records (line 35) | async def fix_null_code_records(): function check_index (line 101) | async def check_index(): function main (line 123) | async def main(): FILE: scripts/fix_null_full_symbol.py function generate_full_symbol (line 32) | def generate_full_symbol(code: str) -> str: function fix_null_full_symbol (line 65) | async def fix_null_full_symbol(): FILE: scripts/fix_paper_trading_initial_cash.py function fix_accounts (line 29) | async def fix_accounts(dry_run=False): function main (line 110) | async def main(): FILE: scripts/fix_provider_id_types.py function fix_provider_id_types (line 22) | async def fix_provider_id_types(): FILE: scripts/fix_stock_code_issue.py function clear_all_caches (line 14) | def clear_all_caches(): function add_stock_code_validation (line 42) | def add_stock_code_validation(): function create_test_script (line 81) | def create_test_script(): function main (line 170) | def main(): FILE: scripts/fix_us_datasource_enabled.py function fix_us_datasource_enabled (line 28) | def fix_us_datasource_enabled(): FILE: scripts/fixes/fix_level3_deadlock.py function apply_fundamentals_analyst_fix (line 24) | def apply_fundamentals_analyst_fix(): function apply_conditional_logic_fix (line 141) | def apply_conditional_logic_fix(): function create_test_script (line 251) | def create_test_script(): function main (line 357) | def main(): FILE: scripts/get_container_logs.py function run_command (line 12) | def run_command(cmd, capture_output=True): function find_container (line 24) | def find_container(): function explore_container_filesystem (line 53) | def explore_container_filesystem(container_name): function get_log_file_info (line 90) | def get_log_file_info(container_name, log_file): function preview_log_file (line 110) | def preview_log_file(container_name, log_file, lines=20): function copy_log_file (line 123) | def copy_log_file(container_name, log_file, local_path=None): function get_docker_logs (line 156) | def get_docker_logs(container_name): function main (line 174) | def main(): FILE: scripts/get_main_branch_logs.py function run_command (line 12) | def run_command(cmd, capture_output=True): function find_tradingagents_container (line 24) | def find_tradingagents_container(): function get_container_info (line 53) | def get_container_info(container_name): function explore_log_locations (line 73) | def explore_log_locations(container_name): function get_docker_logs (line 121) | def get_docker_logs(container_name): function copy_log_files (line 156) | def copy_log_files(container_name, log_files): function check_log_configuration (line 202) | def check_log_configuration(container_name): function get_recent_activity (line 237) | def get_recent_activity(container_name): function main (line 258) | def main(): FILE: scripts/git/branch_manager.py class BranchManager (line 17) | class BranchManager: method __init__ (line 18) | def __init__(self): method run_git_command (line 21) | def run_git_command(self, command: List[str]) -> tuple: method get_current_branch (line 34) | def get_current_branch(self) -> str: method get_all_branches (line 39) | def get_all_branches(self) -> Dict[str, List[str]]: method get_merged_branches (line 61) | def get_merged_branches(self, target_branch: str = 'main') -> List[str]: method get_unmerged_branches (line 75) | def get_unmerged_branches(self, target_branch: str = 'main') -> List[s... method check_status (line 89) | def check_status(self): method release_version (line 136) | def release_version(self, version: str): method cleanup_branches (line 186) | def cleanup_branches(self, dry_run: bool = True): method create_feature_branch (line 226) | def create_feature_branch(self, branch_name: str, base_branch: str = '... function main (line 255) | def main(): FILE: scripts/git/check_branch_overlap.py class BranchAnalyzer (line 16) | class BranchAnalyzer: method __init__ (line 17) | def __init__(self): method run_git_command (line 24) | def run_git_command(self, command: List[str]) -> tuple: method get_branch_commits (line 37) | def get_branch_commits(self, branch: str) -> Set[str]: method get_branch_files (line 44) | def get_branch_files(self, branch: str) -> Set[str]: method check_branch_exists (line 51) | def check_branch_exists(self, branch: str) -> bool: method get_merge_base (line 56) | def get_merge_base(self, branch1: str, branch2: str) -> str: method is_branch_merged (line 61) | def is_branch_merged(self, branch: str, target: str = 'main') -> bool: method analyze_branches (line 69) | def analyze_branches(self): method generate_cleanup_recommendations (line 145) | def generate_cleanup_recommendations(self, branch_data: Dict): method create_backup_script (line 189) | def create_backup_script(self): function main (line 215) | def main(): FILE: scripts/import_config_and_create_user.py function load_env_config (line 33) | def load_env_config(script_dir: Path) -> dict: function hash_password (line 109) | def hash_password(password: str) -> str: function convert_to_bson (line 114) | def convert_to_bson(data: Any) -> Any: function load_export_file (line 147) | def load_export_file(file_path: str) -> Dict[str, Any]: function connect_mongodb (line 178) | def connect_mongodb(use_docker: bool = True, config: dict = None) -> Mon... function import_collection (line 226) | def import_collection( function create_default_admin (line 288) | def create_default_admin(db: Any, overwrite: bool = False) -> bool: function main (line 343) | def main(): FILE: scripts/init_model_catalog.py function main (line 20) | async def main(): FILE: scripts/init_paper_trading_market_rules.py function init_market_rules (line 132) | async def init_market_rules(): function show_market_rules (line 175) | async def show_market_rules(): function main (line 247) | async def main(): FILE: scripts/init_scheduler_metadata.py function init_metadata (line 96) | async def init_metadata(): function list_metadata (line 166) | async def list_metadata(): function main (line 197) | async def main(): FILE: scripts/init_system_data.py function create_default_users (line 28) | async def create_default_users(db): function create_system_config (line 88) | async def create_system_config(db): function create_model_config (line 164) | async def create_model_config(db): function create_sync_status (line 244) | async def create_sync_status(db): function main (line 300) | async def main(): FILE: scripts/inspect_view_data.py function inspect_view (line 22) | async def inspect_view(): FILE: scripts/install_and_run.py function check_virtual_env (line 12) | def check_virtual_env(): function install_project (line 28) | def install_project(): function install_web_dependencies (line 48) | def install_web_dependencies(): function check_env_file (line 72) | def check_env_file(): function start_web_app (line 99) | def start_web_app(): function main (line 136) | def main(): FILE: scripts/install_pandoc.py function check_pandoc (line 17) | def check_pandoc(): function install_pandoc_python (line 32) | def install_pandoc_python(): function install_pandoc_system (line 48) | def install_pandoc_system(): function install_pandoc_windows (line 62) | def install_pandoc_windows(): function install_pandoc_macos (line 101) | def install_pandoc_macos(): function install_pandoc_linux (line 124) | def install_pandoc_linux(): function main (line 165) | def main(): FILE: scripts/install_pdf_tools.py function check_tool (line 17) | def check_tool(command, name): function install_wkhtmltopdf (line 32) | def install_wkhtmltopdf(): function install_wkhtmltopdf_windows (line 48) | def install_wkhtmltopdf_windows(): function install_wkhtmltopdf_macos (line 86) | def install_wkhtmltopdf_macos(): function install_wkhtmltopdf_linux (line 106) | def install_wkhtmltopdf_linux(): function test_pdf_generation (line 145) | def test_pdf_generation(): function main (line 208) | def main(): FILE: scripts/log_analyzer.py class LogAnalyzer (line 22) | class LogAnalyzer: method __init__ (line 25) | def __init__(self, log_file: Path): method parse_logs (line 30) | def parse_logs(self): method _parse_regular_log (line 61) | def _parse_regular_log(self, line: str, line_num: int) -> Optional[Dic... method analyze_performance (line 85) | def analyze_performance(self) -> Dict[str, Any]: method analyze_errors (line 147) | def analyze_errors(self) -> Dict[str, Any]: method analyze_usage (line 204) | def analyze_usage(self) -> Dict[str, Any]: method _extract_duration (line 258) | def _extract_duration(self, message: str, entry: Dict[str, Any]) -> Op... method _extract_cost (line 271) | def _extract_cost(self, message: str, entry: Dict[str, Any]) -> Option... method _extract_provider (line 284) | def _extract_provider(self, message: str, entry: Dict[str, Any]) -> Op... method generate_report (line 298) | def generate_report(self) -> str: function main (line 344) | def main(): FILE: scripts/maintenance/branch_manager.py class BranchManager (line 16) | class BranchManager: method __init__ (line 19) | def __init__(self): method run_git_command (line 43) | def run_git_command(self, command): method check_git_status (line 53) | def check_git_status(self): method get_current_branch (line 67) | def get_current_branch(self): method branch_exists (line 71) | def branch_exists(self, branch_name): method remote_branch_exists (line 76) | def remote_branch_exists(self, branch_name): method create_branch (line 81) | def create_branch(self, branch_type, branch_name, description=None): method create_branch_info (line 130) | def create_branch_info(self, branch_name, branch_type, description): method list_branches (line 150) | def list_branches(self, branch_type=None): method switch_branch (line 179) | def switch_branch(self, branch_name): method delete_branch (line 203) | def delete_branch(self, branch_name, force=False): method cleanup_branches (line 240) | def cleanup_branches(self): function main (line 270) | def main(): FILE: scripts/maintenance/cleanup_cache.py function cleanup_file_cache (line 20) | def cleanup_file_cache(max_age_days: int = 7): function cleanup_database_cache (line 53) | def cleanup_database_cache(max_age_days: int = 7): function cleanup_python_cache (line 74) | def cleanup_python_cache(): function get_cache_statistics (line 105) | def get_cache_statistics(): function main (line 139) | def main(): FILE: scripts/maintenance/cleanup_duplicate_stocks.py function build_mongo_uri (line 13) | def build_mongo_uri(): function cleanup_duplicate_stocks (line 24) | def cleanup_duplicate_stocks(): FILE: scripts/maintenance/dumpmongodb.py class MongoMigrator (line 8) | class MongoMigrator: method __init__ (line 9) | def __init__(self, source_host, target_host, source_container, target_... method log (line 21) | def log(self, message): method run_command (line 25) | def run_command(self, command, description): method check_source_connection (line 47) | def check_source_connection(self): method check_target_connection (line 53) | def check_target_connection(self): method get_source_stats (line 58) | def get_source_stats(self): method migrate_data (line 63) | def migrate_data(self): method verify_migration (line 73) | def verify_migration(self): method run_migration (line 78) | def run_migration(self): FILE: scripts/maintenance/finalize_script_organization.py function finalize_script_organization (line 15) | def finalize_script_organization(): function main (line 317) | def main(): FILE: scripts/maintenance/fix_imports.py function fix_imports_in_file (line 12) | def fix_imports_in_file(file_path: Path) -> bool: function main (line 44) | def main(): FILE: scripts/maintenance/fix_mongodb_reports.py function main (line 34) | def main(): function show_report_details (line 124) | def show_report_details(): FILE: scripts/maintenance/fix_timezone_data.py function fix_timezone_data (line 19) | async def fix_timezone_data(): FILE: scripts/maintenance/migrate_env_direct.py function migrate_env_direct (line 32) | async def migrate_env_direct(): FILE: scripts/maintenance/optimize_mongodb_indexes.py function analyze_existing_indexes (line 28) | async def analyze_existing_indexes(collection): function create_optimized_indexes (line 49) | async def create_optimized_indexes(collection): function drop_redundant_indexes (line 132) | async def drop_redundant_indexes(collection): function get_collection_stats (line 161) | async def get_collection_stats(collection): function test_query_performance (line 186) | async def test_query_performance(collection): function main (line 254) | async def main(): FILE: scripts/maintenance/organize_root_scripts.py function organize_root_scripts (line 15) | def organize_root_scripts(): function main (line 213) | def main(): FILE: scripts/maintenance/reset_stock_basics.py function build_mongo_uri (line 14) | def build_mongo_uri(): function reset_stock_basics (line 25) | def reset_stock_basics(): FILE: scripts/maintenance/restart_api_and_test.py function check_api_running (line 13) | def check_api_running(): function test_analysis_with_save (line 21) | def test_analysis_with_save(): FILE: scripts/maintenance/sync_upstream.py class UpstreamSyncer (line 17) | class UpstreamSyncer: method __init__ (line 20) | def __init__(self): method check_git_status (line 26) | def check_git_status(self): method fetch_upstream (line 43) | def fetch_upstream(self): method get_upstream_commits (line 54) | def get_upstream_commits(self): method analyze_changes (line 69) | def analyze_changes(self): method _analyze_commit_types (line 92) | def _analyze_commit_types(self, commits): method create_sync_branch (line 114) | def create_sync_branch(self): method merge_upstream (line 128) | def merge_upstream(self, strategy="merge"): method check_conflicts (line 145) | def check_conflicts(self): method generate_sync_report (line 164) | def generate_sync_report(self, changes, conflicts=None): method run_sync (line 184) | def run_sync(self, strategy="merge", auto_merge=False): function main (line 250) | def main(): FILE: scripts/maintenance/version_manager.py class VersionManager (line 19) | class VersionManager: method __init__ (line 20) | def __init__(self): method get_current_version (line 25) | def get_current_version(self): method set_version (line 33) | def set_version(self, version): method bump_version (line 39) | def bump_version(self, bump_type): method create_git_tag (line 73) | def create_git_tag(self, version, message=None): method update_changelog (line 92) | def update_changelog(self, version, changes=None): method release (line 127) | def release(self, bump_type, message=None, changes=None): method show_info (line 168) | def show_info(self): function main (line 185) | def main(): FILE: scripts/manual_sync_trigger.py function get_auth_token (line 15) | def get_auth_token(): function trigger_historical_data_sync (line 31) | def trigger_historical_data_sync(): function trigger_financial_data_sync (line 49) | def trigger_financial_data_sync(): function trigger_news_data_sync (line 76) | def trigger_news_data_sync(token): function trigger_stock_news_sync (line 103) | def trigger_stock_news_sync(token, symbol="000001"): function check_sync_status (line 131) | def check_sync_status(): function main (line 157) | def main(): FILE: scripts/migrate_add_market_type.py function migrate_add_market_type (line 27) | async def migrate_add_market_type(dry_run: bool = False): function verify_migration (line 124) | async def verify_migration(): function main (line 173) | async def main(): FILE: scripts/migrate_auth_to_db.py function get_logger (line 26) | def get_logger(name: str) -> logging.Logger: function migrate_config_file_auth (line 31) | async def migrate_config_file_auth(): function migrate_web_users (line 90) | async def migrate_web_users(): function backup_config_files (line 139) | async def backup_config_files(): function verify_migration (line 170) | async def verify_migration(): function create_migration_guide (line 218) | async def create_migration_guide(): function main (line 286) | async def main(): FILE: scripts/migrate_config.py function check_existing_configs (line 20) | def check_existing_configs(): function migrate_models_config (line 43) | def migrate_models_config(): function migrate_system_settings (line 62) | def migrate_system_settings(): function migrate_data_sources (line 79) | def migrate_data_sources(): function migrate_database_configs (line 98) | def migrate_database_configs(): function create_unified_config (line 117) | async def create_unified_config(): function backup_existing_configs (line 138) | def backup_existing_configs(): function test_unified_config (line 161) | def test_unified_config(): function main (line 184) | async def main(): FILE: scripts/migrate_config_to_db.py class ConfigMigrator (line 37) | class ConfigMigrator: method __init__ (line 40) | def __init__(self, dry_run: bool = False, backup: bool = True, force: ... method connect_db (line 57) | async def connect_db(self): method close_db (line 78) | async def close_db(self): method backup_configs (line 84) | def backup_configs(self): method load_json_file (line 114) | def load_json_file(self, file_path: Path) -> Optional[Any]: method migrate_llm_configs (line 127) | async def migrate_llm_configs(self): method migrate_system_settings (line 231) | async def migrate_system_settings(self): method verify_migration (line 294) | async def verify_migration(self): method run (line 321) | async def run(self): function main (line 369) | async def main(): FILE: scripts/migrate_config_to_webapi.py class ConfigMigrator (line 31) | class ConfigMigrator: method __init__ (line 34) | def __init__(self): method initialize (line 40) | async def initialize(self): method migrate_all_configs (line 53) | async def migrate_all_configs(self): method migrate_model_configs (line 85) | async def migrate_model_configs(self): method _convert_model_config (line 115) | def _convert_model_config(self, legacy_model: ModelConfig) -> LLMConfig: method migrate_system_settings (line 144) | async def migrate_system_settings(self): method migrate_usage_records (line 183) | async def migrate_usage_records(self): method create_unified_system_config (line 206) | async def create_unified_system_config(self): function main (line 228) | async def main(): FILE: scripts/migrate_data_directories.py class DataDirectoryMigrator (line 29) | class DataDirectoryMigrator: method __init__ (line 32) | def __init__(self, project_root: str = None): method create_backup (line 74) | def create_backup(self) -> bool: method create_new_structure (line 103) | def create_new_structure(self) -> bool: method migrate_data (line 134) | def migrate_data(self) -> bool: method _merge_directories (line 172) | def _merge_directories(self, source: Path, target: Path): method update_env_file (line 187) | def update_env_file(self) -> bool: method create_migration_report (line 235) | def create_migration_report(self) -> bool: method cleanup_old_directories (line 258) | def cleanup_old_directories(self, confirm: bool = False) -> bool: method run_migration (line 286) | def run_migration(self, cleanup_old: bool = False) -> bool: function main (line 314) | def main(): FILE: scripts/migrate_financial_data_symbol_to_code.py function main (line 24) | async def main(): FILE: scripts/migrate_paper_trading_multi_market.py function migrate_accounts (line 21) | async def migrate_accounts(dry_run=False): function migrate_positions (line 110) | async def migrate_positions(dry_run=False): function migrate_orders (line 178) | async def migrate_orders(dry_run=False): function migrate_trades (line 240) | async def migrate_trades(dry_run=False): function main (line 299) | async def main(): FILE: scripts/migrate_to_unified_logging.py class LoggingMigrator (line 20) | class LoggingMigrator: method __init__ (line 23) | def __init__(self, project_root: Path): method migrate_file (line 41) | def migrate_file(self, file_path: Path) -> bool: method _add_logging_import (line 81) | def _add_logging_import(self, content: str, file_path: Path) -> str: method _get_logger_function (line 114) | def _get_logger_function(self, file_path: Path) -> str: method _replace_get_logger (line 125) | def _replace_get_logger(self, content: str, file_path: Path) -> str: method _replace_print_statements (line 150) | def _replace_print_statements(self, content: str) -> str: method _replace_traceback_print (line 194) | def _replace_traceback_print(self, content: str) -> str: method migrate_directory (line 208) | def migrate_directory(self, directory: Path, recursive: bool = True) -... method generate_report (line 229) | def generate_report(self) -> str: function main (line 259) | def main(): FILE: scripts/migrate_user_preferences.py function migrate_user_preferences (line 24) | def migrate_user_preferences(): FILE: scripts/migrate_users_to_api.py function hash_password (line 26) | def hash_password(password: str) -> str: function load_old_users (line 32) | async def load_old_users(): function sha256_to_bcrypt (line 56) | def sha256_to_bcrypt(sha256_hash: str, original_password: str) -> str: function migrate_users (line 61) | async def migrate_users(): function main (line 128) | async def main(): FILE: scripts/migration/migrate_paper_accounts_cash_structure.py function get_mongo_params (line 22) | def get_mongo_params(): function is_scalar (line 33) | def is_scalar(value): function migrate_one (line 37) | def migrate_one(doc, coll): function main (line 55) | def main(): FILE: scripts/migration/standardize_stock_code_fields.py class StockCodeFieldMigration (line 37) | class StockCodeFieldMigration: method __init__ (line 40) | def __init__(self, dry_run: bool = True): method connect (line 46) | def connect(self): method disconnect (line 62) | def disconnect(self): method backup_collection (line 68) | def backup_collection(self, collection_name: str): method migrate_stock_basic_info (line 85) | def migrate_stock_basic_info(self): method migrate_analysis_tasks (line 210) | def migrate_analysis_tasks(self): method verify_collection (line 264) | def verify_collection(self, collection_name: str): method run (line 298) | def run(self): function main (line 333) | def main(): FILE: scripts/migrations/add_symbol_field_to_stock_basic_info.py function get_mongo_db (line 33) | async def get_mongo_db() -> Optional[AsyncIOMotorDatabase]: function migrate_add_symbol_field (line 49) | async def migrate_add_symbol_field(): function main (line 140) | async def main(): FILE: scripts/migrations/fix_stock_basic_info_symbol.py function fix_stock_basic_info_symbol (line 24) | async def fix_stock_basic_info_symbol(): function process_batch (line 163) | async def process_batch(collection, batch): function check_and_fix_unique_index (line 183) | async def check_and_fix_unique_index(): function main (line 227) | async def main(): FILE: scripts/migrations/migrate_financial_data_add_symbol.py function migrate_financial_data (line 25) | async def migrate_financial_data(): function process_batch (line 192) | async def process_batch(collection, batch): function rollback_migration (line 212) | async def rollback_migration(): function main (line 239) | async def main(): FILE: scripts/migrations/migrate_stock_basic_info_add_source_index.py function migrate_stock_basic_info (line 43) | async def migrate_stock_basic_info(): function rollback_migration (line 230) | async def rollback_migration(): FILE: scripts/quick_login_fix.py function fix_admin_password (line 18) | def fix_admin_password(): function create_web_users_config (line 62) | def create_web_users_config(): function check_mongodb_connection (line 108) | def check_mongodb_connection(): function create_basic_mongodb_data (line 152) | def create_basic_mongodb_data(client): function check_env_file (line 230) | def check_env_file(): function main (line 261) | def main(): FILE: scripts/quick_syntax_check.py function find_python_files (line 20) | def find_python_files(root_dir: str, exclude_dirs: List[str] = None) -> ... function check_syntax (line 36) | def check_syntax(file_path: str) -> Tuple[bool, str]: function main (line 47) | def main(): FILE: scripts/quick_test.py function test_database_connections (line 17) | async def test_database_connections(): function test_queue_service (line 45) | async def test_queue_service(): function test_analysis_service (line 95) | async def test_analysis_service(): function test_api_imports (line 141) | async def test_api_imports(): function main (line 181) | async def main(): FILE: scripts/quick_test_pe_pb.py function test_pe_pb_from_basic_info (line 27) | def test_pe_pb_from_basic_info(code: str): function main (line 88) | def main(code: str): FILE: scripts/restore_user_analysts.py function restore_user_analysts (line 21) | def restore_user_analysts(): FILE: scripts/setup-docker.py function setup_docker_env (line 15) | def setup_docker_env(): function check_docker (line 88) | def check_docker(): function main (line 117) | def main(): FILE: scripts/setup/configure_pip_source.py function configure_pip_source (line 15) | def configure_pip_source(): function install_database_packages (line 133) | def install_database_packages(): function create_pip_upgrade_script (line 159) | def create_pip_upgrade_script(): function main (line 199) | def main(): FILE: scripts/setup/create_financial_data_collection.py function create_financial_data_collection (line 25) | async def create_financial_data_collection(): function main (line 230) | async def main(): FILE: scripts/setup/create_historical_data_collection.py function create_historical_data_collection (line 21) | async def create_historical_data_collection(): function main (line 149) | async def main(): FILE: scripts/setup/create_message_collections.py function create_social_media_collection (line 25) | async def create_social_media_collection(): function create_internal_messages_collection (line 128) | async def create_internal_messages_collection(): function main (line 238) | async def main(): FILE: scripts/setup/create_news_data_collection.py function create_news_collection (line 32) | async def create_news_collection(): function insert_sample_news_data (line 183) | async def insert_sample_news_data(collection): function main (line 275) | async def main(): FILE: scripts/setup/create_stock_screening_view.py function create_stock_screening_view (line 24) | async def create_stock_screening_view(): function create_indexes_on_view (line 163) | async def create_indexes_on_view(): function main (line 194) | async def main(): FILE: scripts/setup/init_database.py function now_tz (line 19) | def now_tz(): function init_mongodb (line 27) | def init_mongodb(): function init_redis (line 144) | def init_redis(): function test_database_connection (line 222) | def test_database_connection(): function main (line 263) | def main(): FILE: scripts/setup/init_mongodb_indexes.py function build_mongo_uri (line 20) | def build_mongo_uri() -> str: function ensure_indexes (line 32) | def ensure_indexes(): FILE: scripts/setup/init_multi_market_collections.py function create_hk_collections (line 42) | async def create_hk_collections(db): function create_us_collections (line 113) | async def create_us_collections(db): function verify_collections (line 184) | async def verify_collections(db): function main (line 226) | async def main(): FILE: scripts/setup/initialize_system.py function initialize_system (line 20) | def initialize_system(): function main (line 314) | def main(): FILE: scripts/setup/install_pdf_tools.py function run_command (line 22) | def run_command(command, description): function check_installed (line 48) | def check_installed(package_name, import_name=None): function install_weasyprint (line 62) | def install_weasyprint(): function install_pdfkit (line 100) | def install_pdfkit(): function install_pandoc (line 153) | def install_pandoc(): function install_markdown (line 204) | def install_markdown(): function main (line 219) | def main(): FILE: scripts/setup/manual_pip_config.py function create_pip_config (line 15) | def create_pip_config(): function install_packages (line 108) | def install_packages(): function upgrade_pip (line 148) | def upgrade_pip(): function check_pip_version (line 190) | def check_pip_version(): function main (line 223) | def main(): FILE: scripts/setup/migrate_env_to_config.py function load_env_config (line 21) | def load_env_config(): function migrate_model_configs (line 42) | def migrate_model_configs(env_config): function migrate_system_settings (line 86) | def migrate_system_settings(env_config): function main (line 131) | def main(): FILE: scripts/setup/quick_install.py class Colors (line 14) | class Colors: function print_colored (line 23) | def print_colored(text, color=Colors.GREEN): function print_header (line 27) | def print_header(): function check_python_version (line 34) | def check_python_version(): function check_git (line 47) | def check_git(): function check_docker (line 63) | def check_docker(): function choose_installation_method (line 89) | def choose_installation_method(): function docker_install (line 101) | def docker_install(): function local_install (line 146) | def local_install(): function main (line 226) | def main(): FILE: scripts/setup/setup_databases.py function run_command (line 17) | def run_command(command, description=""): function install_python_packages (line 32) | def install_python_packages(): function setup_mongodb_windows (line 50) | def setup_mongodb_windows(): function setup_redis_windows (line 75) | def setup_redis_windows(): function setup_mongodb_linux (line 102) | def setup_mongodb_linux(): function setup_redis_linux (line 129) | def setup_redis_linux(): function setup_docker_option (line 156) | def setup_docker_option(): function create_env_template (line 186) | def create_env_template(): function test_connections (line 191) | def test_connections(): function main (line 224) | def main(): FILE: scripts/setup/update_historical_data_indexes.py function update_historical_data_indexes (line 21) | async def update_historical_data_indexes(): function main (line 111) | async def main(): FILE: scripts/simple_async_test.py function test_basic_functionality (line 11) | def test_basic_functionality(): FILE: scripts/simple_auth_migration.py function hash_password (line 17) | def hash_password(password: str) -> str: function migrate_auth_to_db (line 21) | def migrate_auth_to_db(): function main (line 236) | def main(): FILE: scripts/simple_log_test.py function simple_log_test (line 11) | def simple_log_test(): FILE: scripts/start_worker.py function setup_logging (line 18) | def setup_logging(): function main (line 30) | async def main(): FILE: scripts/startup/start_api.py class ServiceManager (line 21) | class ServiceManager: method __init__ (line 24) | def __init__(self): method _signal_handler (line 32) | def _signal_handler(self, signum, frame): method start_service (line 39) | def start_service(self, name: str, command: List[str], cwd: Optional[s... method stop_all_services (line 66) | def stop_all_services(self): method check_services (line 91) | def check_services(self): method monitor_services (line 102) | def monitor_services(self): function check_dependencies (line 123) | def check_dependencies(): function check_services (line 158) | def check_services(): function main (line 198) | def main(): FILE: scripts/startup/start_backend.py function main (line 13) | def main(): FILE: scripts/startup/start_backend_direct.py function setup_logging (line 15) | def setup_logging(): function main (line 35) | def main(): FILE: scripts/startup/start_frontend.py function check_node_version (line 12) | def check_node_version(): function check_npm (line 34) | def check_npm(): function install_dependencies (line 49) | def install_dependencies(): function start_dev_server (line 80) | def start_dev_server(): function main (line 116) | def main(): FILE: scripts/startup/start_production.py function main (line 19) | def main(): FILE: scripts/startup/start_web.py function main (line 12) | def main(): FILE: scripts/stock_code_validator.py function validate_stock_code (line 7) | def validate_stock_code(original_code: str, processed_content: str) -> str: FILE: scripts/sync_financial_data.py function sync_single_stock_financial_data (line 40) | async def sync_single_stock_financial_data( function _safe_float (line 221) | def _safe_float(value) -> Optional[float]: function _calculate_ttm_metric (line 231) | def _calculate_ttm_metric(df, metric_name: str) -> Optional[float]: function _calculate_ttm_revenue (line 315) | def _calculate_ttm_revenue(df) -> Optional[float]: function _parse_share_value (line 324) | def _parse_share_value(value_str: str) -> Optional[float]: function main (line 342) | async def main(code: Optional[str] = None, sync_all: bool = False, batch... FILE: scripts/sync_market_news.py function main (line 19) | async def main(): FILE: scripts/sync_model_config_to_json.py function main (line 8) | async def main(): FILE: scripts/sync_pricing_now.py function main (line 7) | async def main(): FILE: scripts/syntax_checker.py function find_python_files (line 20) | def find_python_files(root_dir: str, exclude_dirs: List[str] = None) -> ... function check_syntax (line 40) | def check_syntax(file_path: str) -> Tuple[bool, str]: function main (line 57) | def main(): FILE: scripts/syntax_test_script.py function find_python_files (line 14) | def find_python_files(root_dir: str, exclude_dirs: List[str] = None) -> ... function check_syntax (line 38) | def check_syntax(file_path: str) -> Tuple[bool, str]: function main (line 63) | def main(): FILE: scripts/test/test_hk_sync.py function test_hk_yfinance_sync (line 32) | async def test_hk_yfinance_sync(): function test_hk_akshare_sync (line 54) | async def test_hk_akshare_sync(): function verify_hk_data (line 76) | async def verify_hk_data(): function test_unified_service (line 138) | async def test_unified_service(): function main (line 197) | async def main(): FILE: scripts/test_000001_sync.py function test_000001 (line 19) | async def test_000001(): FILE: scripts/test_actual_analysis_url.py function main (line 10) | def main(): FILE: scripts/test_aggregator_support.py function test_aggregator_model_parsing (line 24) | def test_aggregator_model_parsing(): function test_model_capability_mapping (line 49) | def test_model_capability_mapping(): function test_aggregator_providers_config (line 87) | def test_aggregator_providers_config(): function test_model_recommendation (line 102) | def test_model_recommendation(): function main (line 137) | def main(): FILE: scripts/test_akshare_baostock_multi_period.py function test_provider_multi_period (line 17) | async def test_provider_multi_period(provider_name: str, provider, symbo... function main (line 117) | async def main(): FILE: scripts/test_akshare_batch_quotes.py function main (line 15) | async def main(): FILE: scripts/test_akshare_date_format.py function test_akshare_date_format (line 14) | async def test_akshare_date_format(): FILE: scripts/test_akshare_docker.py function test_with_different_headers (line 10) | def test_with_different_headers(): FILE: scripts/test_akshare_news.py function test_akshare_news (line 15) | async def test_akshare_news(): FILE: scripts/test_akshare_news_sync.py function test_akshare_news_sync (line 17) | async def test_akshare_news_sync(): FILE: scripts/test_akshare_rate_limit.py function test_single_request (line 12) | def test_single_request(): function test_continuous_requests (line 37) | def test_continuous_requests(count=10, interval=0): function test_different_intervals (line 124) | def test_different_intervals(): function main (line 196) | def main(): FILE: scripts/test_akshare_with_curl_cffi.py function patched_get (line 16) | def patched_get(url, **kwargs): FILE: scripts/test_all_base_url_fixes.py function test_create_llm_by_provider (line 8) | def test_create_llm_by_provider(): function test_trading_graph_init (line 43) | def test_trading_graph_init(): function test_fundamentals_analyst (line 93) | def test_fundamentals_analyst(): function main (line 165) | def main(): FILE: scripts/test_all_sources_historical_days.py function test_date_calculation (line 7) | def test_date_calculation(): function print_summary (line 50) | def print_summary(): function main (line 192) | def main(): FILE: scripts/test_analyst_base_url.py function main (line 8) | def main(): FILE: scripts/test_api_key_edit.py function test_add_provider_with_key (line 28) | async def test_add_provider_with_key(): function test_update_provider_key (line 82) | async def test_update_provider_key(provider_id: str): function test_clear_provider_key (line 122) | async def test_clear_provider_key(provider_id: str): function test_cleanup (line 162) | async def test_cleanup(provider_id: str): function _mask_key (line 186) | def _mask_key(key: str) -> str: function main (line 195) | async def main(): FILE: scripts/test_api_key_priority.py function test_api_key_validation (line 28) | async def test_api_key_validation(): function test_provider_key_priority (line 58) | async def test_provider_key_priority(): function _mask_key (line 98) | def _mask_key(key: str) -> str: function main (line 107) | async def main(): FILE: scripts/test_api_key_validation.py function test_api_key_validation (line 18) | def test_api_key_validation(): FILE: scripts/test_api_report_000002.py function test_report_generation (line 11) | def test_report_generation(): FILE: scripts/test_api_settings.py function main (line 9) | def main(): FILE: scripts/test_async_progress.py function simulate_analysis (line 14) | def simulate_analysis(tracker: AsyncProgressTracker): function monitor_progress (line 54) | def monitor_progress(analysis_id: str, max_duration: int = 120): function test_async_progress (line 86) | def test_async_progress(): FILE: scripts/test_bridge_system_settings.py function main (line 22) | async def main(): FILE: scripts/test_concurrent_api.py function test_notifications_api (line 10) | async def test_notifications_api(session: aiohttp.ClientSession, test_id... function test_data_sources_api (line 38) | async def test_data_sources_api(session: aiohttp.ClientSession): function concurrent_test (line 72) | async def concurrent_test(): function sequential_test (line 132) | async def sequential_test(): function main (line 158) | async def main(): FILE: scripts/test_config_bridge.py function test_config_bridge (line 16) | async def test_config_bridge(): FILE: scripts/test_config_compatibility.py function test_read_legacy_configs (line 21) | async def test_read_legacy_configs(): function test_write_legacy_configs (line 44) | async def test_write_legacy_configs(): function test_unified_system_config (line 100) | async def test_unified_system_config(): function test_config_sync (line 120) | async def test_config_sync(): function test_default_model_management (line 149) | async def test_default_model_management(): function test_data_source_configs (line 185) | async def test_data_source_configs(): function test_database_configs (line 202) | async def test_database_configs(): function test_cache_functionality (line 219) | async def test_cache_functionality(): function main (line 249) | async def main(): FILE: scripts/test_config_reload.py function get_test_token (line 28) | def get_test_token(): function test_config_reload (line 54) | def test_config_reload(): function check_backend_logs (line 114) | def check_backend_logs(): function main (line 142) | def main(): FILE: scripts/test_config_service.py function main (line 14) | async def main(): FILE: scripts/test_config_usage.py function test_config_manager (line 18) | def test_config_manager(): function test_llm_adapter (line 73) | def test_llm_adapter(): function test_env_variables (line 115) | def test_env_variables(): function test_config_files (line 181) | def test_config_files(): function main (line 222) | def main(): FILE: scripts/test_curl_cffi.py function get_stock_news_with_curl_cffi (line 18) | def get_stock_news_with_curl_cffi(symbol: str, page_size: int = 10): FILE: scripts/test_data_preparation.py function test_data_preparation (line 19) | def test_data_preparation(): function test_database_check (line 72) | def test_database_check(): function test_data_sync_async (line 108) | async def test_data_sync_async(): function test_data_sync (line 158) | def test_data_sync(): FILE: scripts/test_data_source_logging.py function test_china_stock_data (line 23) | def test_china_stock_data(): function test_us_stock_data (line 79) | def test_us_stock_data(): function test_hk_stock_data (line 121) | def test_hk_stock_data(): FILE: scripts/test_database_api.py function login (line 15) | async def login() -> str: function test_database_status (line 36) | async def test_database_status(token: str): function test_database_stats (line 55) | async def test_database_stats(token: str): function test_database_test_connection (line 129) | async def test_database_test_connection(token: str): function main (line 148) | async def main(): FILE: scripts/test_datasource_groupings.py function test_datasource_groupings (line 17) | def test_datasource_groupings(): function test_all_groupings (line 102) | def test_all_groupings(): FILE: scripts/test_date_format_fix.py function test_date_format (line 18) | def test_date_format(): function test_mongodb_query (line 48) | async def test_mongodb_query(): function test_adapter (line 98) | async def test_adapter(): FILE: scripts/test_default_base_url.py function test_default_base_url (line 22) | def test_default_base_url(): FILE: scripts/test_default_base_url_fix.py function main (line 8) | def main(): FILE: scripts/test_direct_mongodb.py function test_direct (line 16) | def test_direct(): FILE: scripts/test_direct_news_api.py function get_stock_news_direct (line 11) | def get_stock_news_direct(symbol: str, page_size: int = 10): FILE: scripts/test_docker_logging.py function test_logging (line 14) | def test_logging(): FILE: scripts/test_docker_pdf.py function test_docker_environment (line 14) | def test_docker_environment(): function test_docker_dependencies (line 27) | def test_docker_dependencies(): function test_docker_pdf_generation (line 40) | def test_docker_pdf_generation(): function test_report_exporter (line 53) | def test_report_exporter(): function main (line 108) | def main(): FILE: scripts/test_enhanced_logging.py function test_enhanced_logging (line 15) | def test_enhanced_logging(): function test_direct_tushare_provider (line 85) | def test_direct_tushare_provider(): function test_adapter_layer (line 119) | def test_adapter_layer(): function main (line 152) | def main(): FILE: scripts/test_env_config.py function test_env_variables (line 22) | def test_env_variables(): function test_service_integration (line 123) | def test_service_integration(): function main (line 164) | def main(): FILE: scripts/test_env_validation.py function test_env_validation (line 22) | def test_env_validation(): FILE: scripts/test_error_formatter.py function print_formatted_error (line 17) | def print_formatted_error(title: str, error_message: str, context: dict ... function main (line 36) | def main(): FILE: scripts/test_estimated_total_time.py function test_estimated_total_time (line 12) | def test_estimated_total_time(): FILE: scripts/test_fallback_mechanism.py function test_data_source_availability (line 14) | def test_data_source_availability(): function test_fallback_mechanism (line 36) | def test_fallback_mechanism(manager): function test_specific_sources (line 71) | def test_specific_sources(manager): function main (line 103) | def main(): FILE: scripts/test_financial_data_flow.py function test_financial_data_flow (line 20) | def test_financial_data_flow(): FILE: scripts/test_financial_fallback.py function test_financial_fallback (line 20) | def test_financial_fallback(): FILE: scripts/test_fixed_historical_sync.py function test_fixed_historical_sync (line 18) | async def test_fixed_historical_sync(): FILE: scripts/test_foreign_stock_api.py function test_hk_quote (line 16) | async def test_hk_quote(): function test_us_quote (line 42) | async def test_us_quote(): function test_cache (line 68) | async def test_cache(): function test_market_detection (line 108) | async def test_market_detection(): function main (line 132) | async def main(): FILE: scripts/test_foreign_stock_priority.py function test_priority (line 17) | async def test_priority(): FILE: scripts/test_frontend_api.py function test_api_endpoint (line 10) | def test_api_endpoint(url, method="GET", data=None): function print_result (line 30) | def print_result(test_name, result): function main (line 46) | def main(): FILE: scripts/test_fundamentals_realtime.py function test (line 9) | async def test(): FILE: scripts/test_fundamentals_unified.py function test_fundamentals_from_mongodb (line 23) | def test_fundamentals_from_mongodb(): function test_fundamentals_from_tushare (line 75) | def test_fundamentals_from_tushare(): function test_fundamentals_fallback (line 128) | def test_fundamentals_fallback(): function test_interface_function (line 165) | def test_interface_function(): function test_data_source_priority (line 201) | def test_data_source_priority(): FILE: scripts/test_fundamentals_with_stock_name.py function test_fundamentals_stock_name (line 13) | def test_fundamentals_stock_name(): function test_stock_info_direct (line 68) | def test_stock_info_direct(): function test_fundamentals_with_fallback (line 94) | def test_fundamentals_with_fallback(): function test_complete_fundamentals_flow (line 133) | def test_complete_fundamentals_flow(): FILE: scripts/test_google_api_connection.py function test_connection (line 39) | def test_connection(host, port=443, timeout=5): function get_weather (line 104) | def get_weather(city: str) -> str: FILE: scripts/test_google_api_with_proxy.py function test_connection (line 52) | def test_connection(host, port=443, timeout=5): FILE: scripts/test_google_base_url.py function test_google_base_url (line 15) | def test_google_base_url(): FILE: scripts/test_historical_days_fix.py function test_historical_days_calculation (line 9) | async def test_historical_days_calculation(): function test_service_initialization (line 50) | async def test_service_initialization(): function check_existing_data (line 68) | async def check_existing_data(): function main (line 127) | async def main(): FILE: scripts/test_hk_error_handling.py function test_hk_network_limitation_handling (line 15) | def test_hk_network_limitation_handling(): function test_error_message_formatting (line 90) | def test_error_message_formatting(): function test_web_cli_integration (line 134) | def test_web_cli_integration(): FILE: scripts/test_import_export.py function test_export_import (line 16) | async def test_export_import(): FILE: scripts/test_integration_validation.py function test_web_integration (line 15) | def test_web_integration(): function test_cli_integration (line 68) | def test_cli_integration(): function test_error_handling (line 129) | def test_error_handling(): function test_performance (line 168) | def test_performance(): FILE: scripts/test_kline_realtime.py function test_kline_realtime (line 23) | async def test_kline_realtime(): function _is_trading_time (line 121) | def _is_trading_time(now: datetime) -> bool: FILE: scripts/test_market_type_fix.py function test_market_type_detection (line 17) | def test_market_type_detection(): function test_mongodb_document_structure (line 51) | def test_mongodb_document_structure(): FILE: scripts/test_migration.py function test_migration (line 20) | async def test_migration(): function test_config_files (line 87) | def test_config_files(): function test_env_file (line 109) | def test_env_file(): function main (line 137) | async def main(): FILE: scripts/test_model_api_base.py function main (line 8) | def main(): FILE: scripts/test_model_config_params.py function test_model_config_params (line 20) | def test_model_config_params(): FILE: scripts/test_model_features_fix.py function test_model_config (line 18) | def test_model_config(): function test_model_validation (line 70) | def test_model_validation(): function test_database_config (line 107) | def test_database_config(): FILE: scripts/test_mongodb_as_datasource.py function test_mongodb_as_datasource (line 22) | def test_mongodb_as_datasource(): function test_mongodb_fallback (line 112) | def test_mongodb_fallback(): FILE: scripts/test_mongodb_model_config.py function test_mongodb_config (line 19) | async def test_mongodb_config(): function test_model_config_service (line 64) | def test_model_config_service(): function test_model_validation (line 118) | def test_model_validation(): FILE: scripts/test_mongodb_storage_init.py function main (line 19) | def main(): FILE: scripts/test_monkey_patch.py function main (line 20) | async def main(): FILE: scripts/test_multi_period_data.py function print_section (line 20) | def print_section(title: str): function test_data_source_priority (line 26) | def test_data_source_priority(): function test_daily_data (line 47) | def test_daily_data(): function test_weekly_data (line 83) | def test_weekly_data(): function test_monthly_data (line 119) | def test_monthly_data(): function test_fallback_mechanism (line 155) | def test_fallback_mechanism(): function main (line 189) | def main(): FILE: scripts/test_multi_period_sync.py function test_multi_period_sync (line 19) | async def test_multi_period_sync(): FILE: scripts/test_multi_source_sync.py function test_api_endpoint (line 16) | def test_api_endpoint(url: str, method: str = "GET", data: Dict = None) ... function print_section (line 34) | def print_section(title: str): function print_result (line 40) | def print_result(test_name: str, result: Dict[str, Any]): function main (line 57) | def main(): FILE: scripts/test_news_from_db.py function test_news_from_db (line 10) | async def test_news_from_db(): FILE: scripts/test_news_sentiment_analysis.py function test_sentiment_analysis (line 17) | async def test_sentiment_analysis(): FILE: scripts/test_news_sync.py function test_news_sync (line 17) | async def test_news_sync(): FILE: scripts/test_news_unified.py function print_section (line 20) | def print_section(title: str): function test_data_source_priority (line 26) | def test_data_source_priority(): function test_stock_news (line 47) | def test_stock_news(): function test_market_news (line 88) | def test_market_news(): function test_fallback_mechanism (line 126) | def test_fallback_mechanism(): function test_different_time_ranges (line 165) | def test_different_time_ranges(): function main (line 190) | def main(): FILE: scripts/test_no_data_error.py function test_no_data_error (line 19) | def test_no_data_error(): FILE: scripts/test_no_infinite_retry.py class TimeoutException (line 15) | class TimeoutException(Exception): function timeout_handler (line 18) | def timeout_handler(): function test_no_infinite_retry_stock_data (line 23) | def test_no_infinite_retry_stock_data(): function test_no_infinite_retry_stock_info (line 67) | def test_no_infinite_retry_stock_info(): function test_fallback_mechanism_logic (line 104) | def test_fallback_mechanism_logic(): function test_real_stock_performance (line 141) | def test_real_stock_performance(): FILE: scripts/test_pct_chg_filter.py function test_pct_chg_filter (line 22) | async def test_pct_chg_filter(): FILE: scripts/test_pe_pb_fix.py function test_parse_mongodb_financial_data (line 32) | def test_parse_mongodb_financial_data(code: str): function test_realtime_metrics (line 94) | def test_realtime_metrics(code: str): function test_fundamentals_report (line 151) | def test_fundamentals_report(code: str): function main (line 212) | def main(code: str): FILE: scripts/test_preferred_sources.py function test_default_order (line 9) | async def test_default_order(): function test_preferred_sources_akshare (line 33) | async def test_preferred_sources_akshare(): function test_preferred_sources_baostock (line 58) | async def test_preferred_sources_baostock(): function test_preferred_sources_multiple (line 83) | async def test_preferred_sources_multiple(): function test_preferred_sources_invalid (line 109) | async def test_preferred_sources_invalid(): function test_api_integration (line 135) | async def test_api_integration(): function main (line 185) | async def main(): FILE: scripts/test_progress_fix.py function test_progress_tracker (line 12) | def test_progress_tracker(): FILE: scripts/test_progress_tracking.py function test_node_mapping (line 21) | def test_node_mapping(): function test_progress_calculation (line 102) | def test_progress_calculation(): function test_step_coverage (line 178) | def test_step_coverage(): function main (line 240) | def main(): FILE: scripts/test_provider_lookup.py function test_provider_lookup (line 14) | def test_provider_lookup(): FILE: scripts/test_ps_calculation_verification.py class PSCalculationVerifier (line 34) | class PSCalculationVerifier: method __init__ (line 37) | def __init__(self): method connect (line 41) | async def connect(self): method close (line 65) | async def close(self): method get_stock_info (line 71) | async def get_stock_info(self, code: str) -> Optional[Dict[str, Any]]: method get_financial_data (line 76) | async def get_financial_data(self, code: str) -> Optional[Dict[str, An... method get_market_quote (line 81) | async def get_market_quote(self, code: str) -> Optional[Dict[str, Any]]: method calculate_ps_manually (line 86) | def calculate_ps_manually( method verify_stock (line 138) | async def verify_stock(self, code: str): function main (line 303) | async def main(): FILE: scripts/test_qianfan_connect.py function getenv_stripped (line 33) | def getenv_stripped(key: str) -> Optional[str]: function main (line 38) | def main() -> int: FILE: scripts/test_qianfan_raw.py function test_qianfan_with_sdk (line 15) | def test_qianfan_with_sdk(): function test_qianfan_with_requests (line 69) | def test_qianfan_with_requests(): function main (line 202) | def main(): FILE: scripts/test_queue.py function test_queue_operations (line 20) | async def test_queue_operations(): function test_concurrent_limits (line 104) | async def test_concurrent_limits(): function main (line 153) | async def main(): FILE: scripts/test_rate_limiter.py function test_basic_rate_limiter (line 10) | async def test_basic_rate_limiter(): function test_different_tiers (line 48) | async def test_different_tiers(): function test_concurrent_calls (line 80) | async def test_concurrent_calls(): function test_safety_margin (line 118) | async def test_safety_margin(): function test_global_limiter (line 150) | async def test_global_limiter(): function main (line 172) | async def main(): FILE: scripts/test_scheduler_api_response.py function login (line 15) | def login() -> str: function test_jobs_response (line 34) | def test_jobs_response(token: str): function test_stats_response (line 71) | def test_stats_response(token: str): function main (line 106) | def main(): FILE: scripts/test_scheduler_frontend.py function login (line 19) | def login() -> str: function get_headers (line 41) | def get_headers() -> Dict[str, str]: function test_get_jobs (line 49) | def test_get_jobs(): function test_get_stats (line 77) | def test_get_stats(): function test_get_job_detail (line 103) | def test_get_job_detail(job_id: str): function test_pause_job (line 129) | def test_pause_job(job_id: str): function test_resume_job (line 151) | def test_resume_job(job_id: str): function test_get_history (line 172) | def test_get_history(job_id: str = None): function test_health (line 207) | def test_health(): function main (line 232) | def main(): FILE: scripts/test_scheduler_management.py function get_auth_token (line 11) | def get_auth_token(): function test_list_jobs (line 29) | def test_list_jobs(token): function test_get_job_detail (line 61) | def test_get_job_detail(token, job_id): function test_pause_job (line 92) | def test_pause_job(token, job_id): function test_resume_job (line 114) | def test_resume_job(token, job_id): function test_trigger_job (line 136) | def test_trigger_job(token, job_id): function test_get_stats (line 158) | def test_get_stats(token): function test_get_history (line 186) | def test_get_history(token): function main (line 220) | def main(): FILE: scripts/test_scheduler_metadata.py function login (line 14) | def login() -> str: function test_list_jobs (line 33) | def test_list_jobs(token: str): function test_update_metadata (line 63) | def test_update_metadata(token: str, job_id: str): function test_get_job_detail (line 93) | def test_get_job_detail(token: str, job_id: str): function test_clear_metadata (line 121) | def test_clear_metadata(token: str, job_id: str): function main (line 151) | def main(): FILE: scripts/test_screening_view.py function test_screening (line 23) | async def test_screening(): FILE: scripts/test_selective_sync.py function check_data_counts (line 15) | async def check_data_counts(): function test_selective_sync (line 32) | async def test_selective_sync(): FILE: scripts/test_settings_meta.py function main (line 9) | def main(): FILE: scripts/test_smart_progress.py function test_progress_tracker (line 17) | def test_progress_tracker(): function test_time_estimation (line 96) | def test_time_estimation(): FILE: scripts/test_ssl_retry.py function main (line 20) | async def main(): FILE: scripts/test_startup_validator.py function main (line 21) | def main(): FILE: scripts/test_stock_data_api.py class StockDataAPITester (line 22) | class StockDataAPITester: method __init__ (line 25) | def __init__(self, base_url: str = BASE_URL, token: str = None): method test_basic_info_api (line 32) | async def test_basic_info_api(self): method test_quotes_api (line 62) | async def test_quotes_api(self): method test_stock_list_api (line 92) | async def test_stock_list_api(self): method test_combined_api (line 122) | async def test_combined_api(self): method test_search_api (line 157) | async def test_search_api(self): method test_market_summary_api (line 200) | async def test_market_summary_api(self): function main (line 232) | async def main(): FILE: scripts/test_stock_data_preparation.py function test_stock_data_preparation (line 15) | def test_stock_data_preparation(): function test_format_validation (line 112) | def test_format_validation(): function test_performance (line 156) | def test_performance(): FILE: scripts/test_stock_fundamentals_enhanced.py function test_stock_fundamentals (line 24) | async def test_stock_fundamentals(stock_code: str = "000001"): function test_multiple_stocks (line 190) | async def test_multiple_stocks(): function main (line 209) | async def main(): FILE: scripts/test_stock_info.py function test_stock_info_retrieval (line 13) | def test_stock_info_retrieval(): function test_tushare_stock_basic_api (line 63) | def test_tushare_stock_basic_api(): function test_stock_basic_all (line 110) | def test_stock_basic_all(): FILE: scripts/test_stock_info_fallback.py function test_tushare_stock_info_failure (line 13) | def test_tushare_stock_info_failure(): function test_akshare_stock_info (line 49) | def test_akshare_stock_info(): function test_baostock_stock_info (line 86) | def test_baostock_stock_info(): function analyze_current_fallback_mechanism (line 134) | def analyze_current_fallback_mechanism(): FILE: scripts/test_stock_info_fallback_fixed.py function test_stock_info_fallback_mechanism (line 13) | def test_stock_info_fallback_mechanism(): function test_real_stock_fallback (line 44) | def test_real_stock_fallback(): function test_individual_data_sources (line 77) | def test_individual_data_sources(): function test_fundamentals_with_fallback (line 103) | def test_fundamentals_with_fallback(): FILE: scripts/test_stock_info_unified.py function print_section (line 20) | def print_section(title: str): function test_data_source_priority (line 26) | def test_data_source_priority(): function test_mongodb_stock_info (line 46) | def test_mongodb_stock_info(): function test_tushare_stock_info (line 97) | def test_tushare_stock_info(): function test_fallback_mechanism (line 138) | def test_fallback_mechanism(): function main (line 168) | def main(): FILE: scripts/test_stock_name_issue.py function test_get_company_name (line 15) | def test_get_company_name(): function test_data_source_config (line 91) | def test_data_source_config(): FILE: scripts/test_time_estimation.py function format_time (line 13) | def format_time(seconds): function test_time_estimation (line 19) | def test_time_estimation(): FILE: scripts/test_token_tracking.py function main (line 16) | async def main(): FILE: scripts/test_ttm_calculation.py function test_ttm_calculation (line 19) | def test_ttm_calculation(): function test_ps_calculation (line 108) | def test_ps_calculation(): FILE: scripts/test_ttm_calculation_logic.py function test_ttm_calculation (line 13) | def test_ttm_calculation(): FILE: scripts/test_tushare_rt_k.py function test_rt_k_interface (line 24) | async def test_rt_k_interface(): function test_single_stock (line 67) | async def test_single_stock(): function test_trading_time_check (line 92) | async def test_trading_time_check(): function test_sync_service (line 108) | async def test_sync_service(): function main (line 139) | async def main(): FILE: scripts/test_unified_config.py function main (line 15) | def main(): FILE: scripts/test_update_quotes.py function main (line 15) | async def main(): FILE: scripts/test_usage_recording.py function test_usage_recording (line 16) | async def test_usage_recording(): function test_analysis_service_recording (line 129) | async def test_analysis_service_recording(): function main (line 193) | async def main(): FILE: scripts/trigger_quotes_backfill.py function main (line 14) | async def main(): FILE: scripts/unified_data_manager.py class UnifiedDataDirectoryManager (line 16) | class UnifiedDataDirectoryManager: method __init__ (line 19) | def __init__(self, project_root: Optional[Union[str, Path]] = None): method get_path (line 81) | def get_path(self, key: str, create: bool = True) -> Path: method get_all_paths (line 114) | def get_all_paths(self, create: bool = True) -> Dict[str, Path]: method create_all_directories (line 133) | def create_all_directories(self) -> bool: method get_config_summary (line 155) | def get_config_summary(self) -> Dict[str, str]: method validate_structure (line 174) | def validate_structure(self) -> Dict[str, bool]: method print_structure (line 192) | def print_structure(self): function get_data_manager (line 226) | def get_data_manager(project_root: Optional[Union[str, Path]] = None) ->... function get_data_path (line 241) | def get_data_path(key: str, create: bool = True) -> Path: function main (line 254) | def main(): FILE: scripts/update_analysis_models.py function main (line 9) | async def main(): FILE: scripts/update_db_api_keys.py function update_api_keys (line 27) | async def update_api_keys(): function main (line 160) | async def main(): FILE: scripts/update_model_catalog_with_pricing.py function main (line 21) | async def main(): FILE: scripts/user_activity_manager.py function get_activity_dir (line 18) | def get_activity_dir(): function load_activities (line 22) | def load_activities(start_date: datetime = None, end_date: datetime = No... function list_activities (line 61) | def list_activities(args): function show_statistics (line 116) | def show_statistics(args): function export_activities (line 197) | def export_activities(args): function cleanup_activities (line 260) | def cleanup_activities(args): function main (line 303) | def main(): FILE: scripts/user_password_manager.py function get_users_file_path (line 16) | def get_users_file_path() -> Path: function hash_password (line 24) | def hash_password(password: str) -> str: function load_users (line 28) | def load_users() -> Dict: function save_users (line 43) | def save_users(users: Dict) -> bool: function list_users (line 60) | def list_users(): function change_password (line 81) | def change_password(username: str, new_password: str) -> bool: function create_user (line 98) | def create_user(username: str, password: str, role: str = "user", permis... function delete_user (line 125) | def delete_user(username: str) -> bool: function reset_to_default (line 147) | def reset_to_default(): function main (line 173) | def main(): FILE: scripts/validate_api_keys.py class Colors (line 28) | class Colors: function print_success (line 37) | def print_success(msg): print(f"{Colors.GREEN}✅ {msg}{Colors.END}") function print_warning (line 38) | def print_warning(msg): print(f"{Colors.YELLOW}⚠️ {msg}{Colors.END}") function print_error (line 39) | def print_error(msg): print(f"{Colors.RED}❌ {msg}{Colors.END}") function print_info (line 40) | def print_info(msg): print(f"{Colors.CYAN}ℹ️ {msg}{Colors.END}") function print_header (line 41) | def print_header(msg): print(f"\n{Colors.BOLD}{Colors.BLUE}{'='*60}\n{ms... function validate_deepseek (line 43) | def validate_deepseek(api_key: str) -> Tuple[bool, str]: function validate_dashscope (line 66) | def validate_dashscope(api_key: str) -> Tuple[bool, str]: function validate_google (line 98) | def validate_google(api_key: str) -> Tuple[bool, str]: function validate_openai (line 116) | def validate_openai(api_key: str) -> Tuple[bool, str]: function main (line 139) | def main(): FILE: scripts/validation/analyze_missing_pe.py function build_mongo_uri (line 13) | def build_mongo_uri(): function analyze_missing_pe (line 24) | def analyze_missing_pe(): FILE: scripts/validation/analyze_stock_count.py function build_mongo_uri (line 13) | def build_mongo_uri(): function analyze_stock_count (line 24) | def analyze_stock_count(): FILE: scripts/validation/check_dependencies.py function check_mongodb_availability (line 16) | def check_mongodb_availability(): function check_redis_availability (line 45) | def check_redis_availability(): function check_basic_dependencies (line 73) | def check_basic_dependencies(): function create_fallback_config (line 96) | def create_fallback_config(): function test_cache_without_database (line 127) | def test_cache_without_database(): function generate_installation_guide (line 165) | def generate_installation_guide(): function main (line 229) | def main(): FILE: scripts/validation/check_extended_fields.py function build_mongo_uri (line 12) | def build_mongo_uri(): function verify_extended_fields (line 23) | def verify_extended_fields(): FILE: scripts/validation/check_imports.py class ImportChecker (line 15) | class ImportChecker: method __init__ (line 18) | def __init__(self, project_root: Path): method find_python_files (line 24) | def find_python_files(self, exclude_dirs: Set[str] = None) -> List[Path]: method extract_imports (line 44) | def extract_imports(self, file_path: Path) -> List[Tuple[str, int, str]]: method check_module_path (line 75) | def check_module_path(self, module_name: str) -> Tuple[bool, str]: method check_file (line 113) | def check_file(self, file_path: Path) -> int: method check_all (line 133) | def check_all(self) -> int: method print_report (line 147) | def print_report(self): function main (line 183) | def main(): FILE: scripts/validation/check_stock_collections.py function check_stock_collections (line 9) | def check_stock_collections(): FILE: scripts/validation/check_system_status.py function check_system_status (line 19) | def check_system_status(): function main (line 242) | def main(): FILE: scripts/validation/debug_tushare_data.py function debug_tushare_data (line 13) | def debug_tushare_data(): FILE: scripts/validation/diagnose_missing_fields.py function build_mongo_uri (line 14) | def build_mongo_uri(): function diagnose_missing_fields (line 25) | def diagnose_missing_fields(): FILE: scripts/validation/inspect_analysis_tasks_schema.py function _tname (line 34) | def _tname(v: Any) -> str: function main (line 41) | async def main(): FILE: scripts/validation/smart_config.py class SmartConfigManager (line 18) | class SmartConfigManager: method __init__ (line 21) | def __init__(self): method _detect_mongodb (line 35) | def _detect_mongodb(self) -> Tuple[bool, str]: method _detect_redis (line 58) | def _detect_redis(self) -> Tuple[bool, str]: method _detect_services (line 80) | def _detect_services(self): method _generate_config (line 108) | def _generate_config(self): method get_config (line 166) | def get_config(self) -> Dict[str, Any]: method save_config (line 170) | def save_config(self, config_path: str = "smart_config.json"): method load_config (line 179) | def load_config(self, config_path: str = "smart_config.json") -> bool: method get_cache_backend_info (line 191) | def get_cache_backend_info(self) -> Dict[str, Any]: method print_status (line 200) | def print_status(self): function get_smart_config (line 241) | def get_smart_config() -> SmartConfigManager: function get_config (line 248) | def get_config() -> Dict[str, Any]: function is_mongodb_available (line 252) | def is_mongodb_available() -> bool: function is_redis_available (line 256) | def is_redis_available() -> bool: function get_cache_backend (line 260) | def get_cache_backend() -> str: function main (line 266) | def main(): FILE: scripts/validation/verify_extended_fields.py function verify_extended_fields (line 17) | async def verify_extended_fields(): FILE: scripts/validation/verify_gitignore.py function run_git_command (line 16) | def run_git_command(cmd, cwd=None): function main (line 30) | def main(): FILE: scripts/verify_docker_logs.py function run_command (line 11) | def run_command(cmd): function check_container_status (line 19) | def check_container_status(): function trigger_logs_in_container (line 38) | def trigger_logs_in_container(): function check_local_logs (line 93) | def check_local_logs(): function check_container_logs (line 134) | def check_container_logs(): function check_docker_stdout_logs (line 165) | def check_docker_stdout_logs(): function main (line 181) | def main(): FILE: scripts/verify_fix.py function verify_fix (line 16) | async def verify_fix(): FILE: scripts/verify_imported_config.py function main (line 18) | def main(): FILE: scripts/verify_migration.py function verify_migration (line 20) | async def verify_migration(): function test_config_api (line 124) | async def test_config_api(): function main (line 169) | async def main(): FILE: scripts/verify_ttm_calculation_000001.py function main (line 16) | async def main(): FILE: scripts/view_logs.py function get_log_files (line 13) | def get_log_files(): function show_log_files (line 25) | def show_log_files(): function view_log_file (line 56) | def view_log_file(log_file, lines=50): function tail_log_file (line 94) | def tail_log_file(log_file): function search_logs (line 118) | def search_logs(keyword, log_files=None): function main (line 160) | def main(): FILE: scripts/补充行业信息_akshare.py function get_stock_industry_from_akshare (line 40) | async def get_stock_industry_from_akshare(code: str) -> Dict[str, str]: FILE: tests/0.1.14/cleanup_test_data.py function cleanup_test_files (line 13) | def cleanup_test_files(): function cleanup_mongodb_test_data (line 28) | def cleanup_mongodb_test_data(): function main (line 52) | def main(): FILE: tests/0.1.14/create_sample_reports.py function create_sample_report (line 14) | def create_sample_report(stock_symbol: str, stock_name: str): function main (line 137) | def main(): FILE: tests/0.1.14/test_analysis_save.py function create_mock_analysis_results (line 14) | def create_mock_analysis_results(): function test_save_analysis_result (line 68) | def test_save_analysis_result(): function test_mongodb_save (line 160) | def test_mongodb_save(): function main (line 193) | def main(): FILE: tests/0.1.14/test_data_structure.py function test_data_structure (line 10) | def test_data_structure(): FILE: tests/0.1.14/test_google_tool_handler_fix.py function test_tool_call_validation (line 18) | def test_tool_call_validation(): function test_tool_call_fixing (line 59) | def test_tool_call_fixing(): function test_duplicate_prevention (line 95) | def test_duplicate_prevention(): function main (line 141) | def main(): FILE: tests/0.1.14/test_guide_auto_hide.py function test_guide_auto_hide_logic (line 14) | def test_guide_auto_hide_logic(): function test_ui_behavior (line 125) | def test_ui_behavior(): FILE: tests/0.1.14/test_online_tools_config.py function test_online_tools_config (line 15) | def test_online_tools_config(): function test_toolkit_integration (line 77) | def test_toolkit_integration(): function show_config_examples (line 112) | def show_config_examples(): function main (line 146) | def main(): FILE: tests/0.1.14/test_real_scenario_fix.py function test_configuration_status (line 19) | def test_configuration_status(): function test_social_media_analyst_tools (line 52) | def test_social_media_analyst_tools(): function test_google_tool_handler_improvements (line 108) | def test_google_tool_handler_improvements(): function main (line 188) | def main(): FILE: tests/0.1.14/test_tool_selection_logic.py function test_tool_selection_scenarios (line 15) | def test_tool_selection_scenarios(): function test_trading_graph_integration (line 130) | def test_trading_graph_integration(): function test_us_stock_data_independence (line 199) | def test_us_stock_data_independence(): function main (line 258) | def main(): FILE: tests/0.1.14/test_us_stock_independence.py function test_us_stock_data_independence (line 22) | def test_us_stock_data_independence(): FILE: tests/akshare_check_fixed.py function check_akshare_import (line 14) | def check_akshare_import(): function check_akshare_utils (line 24) | def check_akshare_utils(): function check_data_source_manager (line 37) | def check_data_source_manager(): function test_akshare_adapter (line 63) | def test_akshare_adapter(): function test_data_source_switching (line 94) | def test_data_source_switching(): function test_unified_interface (line 116) | def test_unified_interface(): function test_basic_akshare (line 142) | def test_basic_akshare(): function main (line 162) | def main(): FILE: tests/akshare_isolated_test.py function test_akshare_direct (line 14) | def test_akshare_direct(): function test_akshare_utils_direct (line 45) | def test_akshare_utils_direct(): function check_data_source_enum (line 98) | def check_data_source_enum(): function analyze_yfinance_issue (line 135) | def analyze_yfinance_issue(): function main (line 164) | def main(): FILE: tests/analyze_akshare_data.py function analyze_akshare_data (line 18) | def analyze_akshare_data(): FILE: tests/check_key_metrics.py function check_key_metrics (line 18) | def check_key_metrics(): FILE: tests/config/test_deprecations.py function test_legacy_env_aliases_map_to_new (line 5) | def test_legacy_env_aliases_map_to_new(monkeypatch): FILE: tests/config/test_logging_config.py function test_logging_uses_expected_toml (line 28) | def test_logging_uses_expected_toml(profile, expect_name, monkeypatch, t... FILE: tests/config/test_logging_json.py function test_json_console_formatter_enabled (line 5) | def test_json_console_formatter_enabled(monkeypatch, tmp_path): FILE: tests/config/test_settings.py function test_settings_defaults_and_env_override (line 4) | def test_settings_defaults_and_env_override(monkeypatch): function test_redis_url_builds (line 26) | def test_redis_url_builds(monkeypatch): FILE: tests/dataflows/test_realtime_metrics.py function test_validate_pe_pb (line 12) | def test_validate_pe_pb(): function test_calculate_realtime_pe_pb_with_mock_data (line 33) | def test_calculate_realtime_pe_pb_with_mock_data(monkeypatch): function test_calculate_realtime_pe_pb_missing_data (line 81) | def test_calculate_realtime_pe_pb_missing_data(monkeypatch): function test_get_pe_pb_with_fallback_success (line 102) | def test_get_pe_pb_with_fallback_success(monkeypatch): function test_get_pe_pb_with_fallback_to_static (line 128) | def test_get_pe_pb_with_fallback_to_static(monkeypatch): FILE: tests/debug_akshare_daily_basic.py function test_akshare_spot_data (line 18) | def test_akshare_spot_data(): function test_akshare_adapter (line 71) | def test_akshare_adapter(): function test_akshare_alternative_apis (line 127) | def test_akshare_alternative_apis(): FILE: tests/debug_baostock_fields.py function debug_baostock_fields (line 19) | def debug_baostock_fields(): FILE: tests/debug_baostock_stock_list.py function debug_baostock_query_all_stock (line 18) | def debug_baostock_query_all_stock(): function debug_baostock_stock_basic (line 104) | def debug_baostock_stock_basic(): function test_baostock_adapter_stock_list (line 152) | def test_baostock_adapter_stock_list(): FILE: tests/debug_deepseek_cost.py function test_pricing_config (line 18) | def test_pricing_config(): function test_cost_calculation (line 32) | def test_cost_calculation(): function test_token_tracking (line 51) | def test_token_tracking(): function test_deepseek_adapter (line 76) | def test_deepseek_adapter(): function check_usage_statistics (line 111) | def check_usage_statistics(): function main (line 134) | def main(): FILE: tests/debug_deepseek_cost_issue.py function debug_config_manager (line 18) | def debug_config_manager(): function debug_token_tracker (line 84) | def debug_token_tracker(): function debug_deepseek_adapter (line 138) | def debug_deepseek_adapter(): function debug_model_name_issue (line 181) | def debug_model_name_issue(): function main (line 233) | def main(): FILE: tests/debug_full_flow.py function debug_full_flow (line 18) | def debug_full_flow(): FILE: tests/debug_imports.py function test_google_news_import (line 13) | def test_google_news_import(): function test_reddit_import (line 50) | def test_reddit_import(): function check_dependencies (line 88) | def check_dependencies(): function check_actual_file_contents (line 111) | def check_actual_file_contents(): function main (line 154) | def main(): FILE: tests/debug_test_execution.py function step1_basic_check (line 11) | def step1_basic_check(): function step2_path_check (line 26) | def step2_path_check(): function step3_import_check (line 56) | def step3_import_check(): function step4_env_check (line 82) | def step4_env_check(): function step5_simple_llm_test (line 107) | def step5_simple_llm_test(): function step6_tool_binding_test (line 138) | def step6_tool_binding_test(): function step7_actual_call_test (line 171) | def step7_actual_call_test(): function main (line 217) | def main(): FILE: tests/debug_tool_binding_issue.py function test_tool_isolation (line 10) | def test_tool_isolation(): function test_llm_instance_reuse (line 127) | def test_llm_instance_reuse(): function main (line 172) | def main(): FILE: tests/debug_web_issue.py function test_form_data_structure (line 13) | def test_form_data_structure(): function test_validation_function (line 60) | def test_validation_function(): function test_analysis_runner_import (line 92) | def test_analysis_runner_import(): function test_streamlit_components (line 117) | def test_streamlit_components(): function check_potential_output_sources (line 136) | def check_potential_output_sources(): function main (line 160) | def main(): FILE: tests/demo_fallback_system.py function demo_database_config_fixes (line 16) | def demo_database_config_fixes(): function demo_fallback_mechanism (line 51) | def demo_fallback_mechanism(): function demo_configuration_benefits (line 107) | def demo_configuration_benefits(): function demo_usage_scenarios (line 129) | def demo_usage_scenarios(): function demo_migration_guide (line 169) | def demo_migration_guide(): function main (line 204) | def main(): FILE: tests/final_gemini_test.py function test_recommended_model (line 18) | def test_recommended_model(): function compare_models (line 116) | def compare_models(): function main (line 153) | def main(): FILE: tests/fundamentals_analyst_clean.py function create_fundamentals_analyst (line 10) | def create_fundamentals_analyst(llm, toolkit): FILE: tests/integration/test_dashscope_integration.py function test_import (line 20) | def test_import(): function test_api_key (line 35) | def test_api_key(): function test_dashscope_connection (line 58) | def test_dashscope_connection(): function test_langchain_adapter (line 88) | def test_langchain_adapter(): function test_trading_graph_config (line 110) | def test_trading_graph_config(): function main (line 136) | def main(): FILE: tests/middleware/test_trace_id.py function create_app (line 15) | def create_app(): function test_trace_id_header_and_logging (line 27) | def test_trace_id_header_and_logging(): FILE: tests/quick_akshare_check.py function check_akshare_import (line 6) | def check_akshare_import(): function check_akshare_utils (line 17) | def check_akshare_utils(): function check_data_source_manager (line 28) | def check_data_source_manager(): function test_basic_akshare (line 45) | def test_basic_akshare(): function main (line 65) | def main(): FILE: tests/quick_redis_test.py function quick_redis_test (line 10) | def quick_redis_test(host=None, port=None, password=None): function main (line 109) | def main(): FILE: tests/quick_test_hk.py function test_stock_recognition (line 12) | def test_stock_recognition(): function test_akshare_basic (line 36) | def test_akshare_basic(): function test_unified_interface (line 62) | def test_unified_interface(): function main (line 89) | def main(): FILE: tests/services/test_quotes_backfill.py function test_offhours_backfill_when_empty (line 4) | def test_offhours_backfill_when_empty(monkeypatch): FILE: tests/services/test_quotes_ingestion_and_enrichment.py function test_enhanced_screening_enriches_from_db (line 5) | def test_enhanced_screening_enriches_from_db(monkeypatch): function test_quotes_ingestion_run_once_writes_bulk (line 78) | def test_quotes_ingestion_run_once_writes_bulk(monkeypatch): FILE: tests/services/test_scheduler_quotes_job.py function test_scheduler_adds_quotes_job (line 8) | def test_scheduler_adds_quotes_job(monkeypatch): FILE: tests/services/test_screening_roe_field.py function test_database_screening_builds_roe_query (line 4) | def test_database_screening_builds_roe_query(): function test_database_screening_formats_roe_in_result (line 21) | def test_database_screening_formats_roe_in_result(monkeypatch): FILE: tests/simple_akshare_test.py function test_basic_imports (line 14) | def test_basic_imports(): function test_akshare_provider (line 45) | def test_akshare_provider(): function test_data_source_manager (line 71) | def test_data_source_manager(): function main (line 103) | def main(): FILE: tests/simple_env_test.py function test_env_reading (line 8) | def test_env_reading(): FILE: tests/system/test_config_summary.py function _auth_headers (line 10) | def _auth_headers() -> dict: function test_config_summary_requires_auth (line 15) | def test_config_summary_requires_auth(): function test_config_summary_masks_sensitive_fields_with_auth (line 21) | def test_config_summary_masks_sensitive_fields_with_auth(): FILE: tests/system/test_llm_provider_sanitization.py function test_app (line 20) | def test_app(): function test_add_llm_provider_sanitizes_api_key (line 34) | def test_add_llm_provider_sanitizes_api_key(monkeypatch, test_app: TestC... function test_update_llm_provider_sanitizes_api_key (line 66) | def test_update_llm_provider_sanitizes_api_key(monkeypatch, test_app: Te... FILE: tests/test_000002_valuation.py function test_000002_valuation (line 15) | def test_000002_valuation(): FILE: tests/test_002027_specific.py function test_002027_specifically (line 13) | def test_002027_specifically(): FILE: tests/test_300750_final.py function test_300750_fundamentals (line 15) | def test_300750_fundamentals(): FILE: tests/test_agent_utils_tushare_fix.py function test_get_china_stock_data_fix (line 16) | def test_get_china_stock_data_fix(): function test_get_china_market_overview_fix (line 60) | def test_get_china_market_overview_fix(): function test_stock_name_mapping_fix (line 103) | def test_stock_name_mapping_fix(): function check_debug_output (line 144) | def check_debug_output(): function main (line 172) | def main(): FILE: tests/test_akshare_alternative.py function test_akshare_individual_info (line 18) | def test_akshare_individual_info(): function test_akshare_financial_apis (line 51) | def test_akshare_financial_apis(): function test_akshare_market_data (line 99) | def test_akshare_market_data(): FILE: tests/test_akshare_amount.py function test_akshare_amount (line 12) | async def test_akshare_amount(): FILE: tests/test_akshare_api.py function test_akshare_apis (line 12) | def test_akshare_apis(): FILE: tests/test_akshare_code_format.py function test_akshare_interfaces (line 12) | def test_akshare_interfaces(): FILE: tests/test_akshare_debug.py function test_akshare_financial_data (line 18) | def test_akshare_financial_data(): FILE: tests/test_akshare_direct.py function test_akshare_financial_apis (line 10) | def test_akshare_financial_apis(): function test_akshare_stock_info (line 69) | def test_akshare_stock_info(): function main (line 90) | def main(): FILE: tests/test_akshare_fixed.py function test_akshare_adapter_fixed (line 18) | def test_akshare_adapter_fixed(): function test_data_source_manager_akshare (line 93) | def test_data_source_manager_akshare(): FILE: tests/test_akshare_functionality.py function test_akshare_import (line 12) | def test_akshare_import(): function test_data_source_manager (line 23) | def test_data_source_manager(): function test_akshare_adapter (line 49) | def test_akshare_adapter(): function test_akshare_utils_file (line 72) | def test_akshare_utils_file(): function test_akshare_basic_functionality (line 92) | def test_akshare_basic_functionality(): function test_data_source_switching (line 128) | def test_data_source_switching(): function test_unified_data_interface (line 151) | def test_unified_data_interface(): function create_missing_akshare_utils (line 178) | def create_missing_akshare_utils(): function main (line 280) | def main(): FILE: tests/test_akshare_hk.py function test_akshare_hk_basic (line 12) | def test_akshare_hk_basic(): function test_akshare_hk_data (line 48) | def test_akshare_hk_data(): function test_akshare_hk_info (line 95) | def test_akshare_hk_info(): function test_unified_interface (line 130) | def test_unified_interface(): function main (line 172) | def main(): FILE: tests/test_akshare_hk_apis.py function print_separator (line 9) | def print_separator(title): function test_api (line 15) | def test_api(api_name, api_func, *args, **kwargs): function main (line 38) | def main(): FILE: tests/test_akshare_performance.py function test_akshare_performance (line 19) | def test_akshare_performance(): function test_web_api_simulation (line 85) | def test_web_api_simulation(): FILE: tests/test_akshare_priority.py function test_data_source_connection (line 15) | def test_data_source_connection(): function test_akshare_financial_data (line 37) | def test_akshare_financial_data(): function test_financial_metrics_with_data_source (line 77) | def test_financial_metrics_with_data_source(): function test_data_source_priority (line 133) | def test_data_source_priority(): function main (line 171) | def main(): FILE: tests/test_akshare_priority_clean.py function clean_import_test (line 15) | def clean_import_test(): function test_env_variable_directly (line 57) | def test_env_variable_directly(): function test_manual_env_setting (line 98) | def test_manual_env_setting(): function test_fallback_order (line 138) | def test_fallback_order(): function main (line 192) | def main(): FILE: tests/test_akshare_priority_fix.py function test_default_data_source (line 14) | def test_default_data_source(): function test_fallback_priority (line 43) | def test_fallback_priority(): function test_environment_variable_override (line 82) | def test_environment_variable_override(): function test_akshare_availability (line 124) | def test_akshare_availability(): function test_data_source_switching (line 149) | def test_data_source_switching(): function main (line 194) | def main(): FILE: tests/test_all_analysts_hk_fix.py function test_market_analyst_hk_config (line 12) | def test_market_analyst_hk_config(): function test_fundamentals_analyst_hk_config (line 41) | def test_fundamentals_analyst_hk_config(): function test_optimized_us_data_hk_support (line 70) | def test_optimized_us_data_hk_support(): function test_toolkit_hk_method_availability (line 99) | def test_toolkit_hk_method_availability(): function test_data_source_priority_summary (line 128) | def test_data_source_priority_summary(): function main (line 155) | def main(): FILE: tests/test_all_apis.py function check_all_api_keys (line 19) | def check_all_api_keys(): function test_google_api (line 51) | def test_google_api(): function test_reddit_api (line 73) | def test_reddit_api(): function test_tradingagents_with_new_apis (line 120) | def test_tradingagents_with_new_apis(): function test_social_media_analyst (line 152) | def test_social_media_analyst(): function main (line 175) | def main(): FILE: tests/test_amount_fix.py function test_amount_fix (line 13) | async def test_amount_fix(): FILE: tests/test_amplitude_api.py function login (line 10) | def login(): function get_quote (line 26) | def get_quote(token, code): function main (line 40) | def main(): FILE: tests/test_analysis.py function test_basic_imports (line 19) | def test_basic_imports(): function test_environment_variables (line 30) | def test_environment_variables(): function test_graph_initialization (line 40) | def test_graph_initialization(): function test_simple_analysis (line 74) | def test_simple_analysis(): function main (line 93) | def main(): FILE: tests/test_analysis_result.py function test_analysis_result (line 9) | def test_analysis_result(): FILE: tests/test_analysis_with_apis.py function test_news_analyst_with_google (line 18) | def test_news_analyst_with_google(): function test_social_analyst_with_reddit (line 80) | def test_social_analyst_with_reddit(): function main (line 141) | def main(): FILE: tests/test_analyst_loop_fix.py function create_mock_message (line 15) | def create_mock_message(has_tool_calls=False): function test_fundamentals_no_report_with_tool_calls (line 25) | def test_fundamentals_no_report_with_tool_calls(): function test_fundamentals_has_report_with_tool_calls (line 40) | def test_fundamentals_has_report_with_tool_calls(): function test_all_analysts (line 55) | def test_all_analysts(): function test_conditional_logic_fix (line 88) | def test_conditional_logic_fix(): FILE: tests/test_api_analysis.py function test_api_analysis (line 10) | def test_api_analysis(): FILE: tests/test_api_format.py function test_api_format (line 10) | def test_api_format(): FILE: tests/test_app_error_logging.py function test_error_logging_toml_config (line 17) | def test_error_logging_toml_config(): function test_error_logging_functionality (line 61) | def test_error_logging_functionality(): function test_webapi_and_worker_loggers (line 114) | def test_webapi_and_worker_loggers(): FILE: tests/test_async_analysis.py function test_async_analysis (line 14) | async def test_async_analysis(): function test_websocket_progress (line 153) | async def test_websocket_progress(task_id: str, ws_url: str): function test_concurrent_requests (line 193) | async def test_concurrent_requests(): FILE: tests/test_asyncio_thread_pool_fix.py function test_asyncio_in_thread_pool (line 14) | def test_asyncio_in_thread_pool(): function test_data_source_manager_in_thread_pool (line 45) | def test_data_source_manager_in_thread_pool(): function test_multiple_threads (line 78) | def test_multiple_threads(): FILE: tests/test_baostock_fixed.py function test_baostock_query_all_stock_with_date (line 18) | def test_baostock_query_all_stock_with_date(): function test_baostock_adapter_fixed (line 85) | def test_baostock_adapter_fixed(): function test_data_source_manager_baostock (line 152) | def test_data_source_manager_baostock(): FILE: tests/test_baostock_quick.py function test_baostock_import (line 13) | def test_baostock_import(): function test_baostock_connection (line 25) | def test_baostock_connection(): function test_data_source_manager (line 76) | def test_data_source_manager(): function main (line 100) | def main(): FILE: tests/test_baostock_stock_filter.py function test_baostock_stock_types (line 18) | def test_baostock_stock_types(): function test_baostock_adapter_stock_filter (line 101) | def test_baostock_adapter_stock_filter(): FILE: tests/test_baostock_valuation.py function test_baostock_valuation_direct (line 18) | def test_baostock_valuation_direct(): function test_baostock_provider_valuation (line 88) | def test_baostock_provider_valuation(): function test_baostock_adapter_daily_basic (line 141) | def test_baostock_adapter_daily_basic(): function test_data_source_manager_with_baostock (line 193) | def test_data_source_manager_with_baostock(): FILE: tests/test_batch_analysis_planA.py function login (line 20) | def login(): function submit_batch (line 33) | def submit_batch(token: str): function poll_status (line 57) | def poll_status(token: str, task_id: str, timeout_sec: int = 300): function fetch_result (line 78) | def fetch_result(token: str, task_id: str): function main (line 87) | def main(): FILE: tests/test_cache_optimization.py function test_cache_manager (line 16) | def test_cache_manager(): function test_us_stock_cache (line 44) | def test_us_stock_cache(): function test_china_stock_cache (line 90) | def test_china_stock_cache(): function test_cache_ttl (line 151) | def test_cache_ttl(): function test_cache_cleanup (line 191) | def test_cache_cleanup(): function main (line 225) | def main(): FILE: tests/test_chinese_output.py function test_dashscope_chinese (line 18) | def test_dashscope_chinese(): function test_signal_processor_chinese (line 69) | def test_signal_processor_chinese(): function main (line 115) | def main(): FILE: tests/test_cli_fix.py function test_selections_dictionary_keys (line 20) | def test_selections_dictionary_keys(): function test_process_signal_call (line 86) | def test_process_signal_call(): function test_code_consistency (line 120) | def test_code_consistency(): function main (line 165) | def main(): FILE: tests/test_cli_hk.py function test_cli_market_selection (line 12) | def test_cli_market_selection(): function test_stock_analysis_flow (line 57) | def test_stock_analysis_flow(): function main (line 93) | def main(): FILE: tests/test_cli_logging_fix.py function test_cli_logging_setup (line 15) | def test_cli_logging_setup(): function test_console_output (line 63) | def test_console_output(): function test_log_file_writing (line 86) | def test_log_file_writing(): function test_cli_interface_preview (line 129) | def test_cli_interface_preview(): function main (line 170) | def main(): FILE: tests/test_cli_progress_display.py function test_cli_ui_manager (line 15) | def test_cli_ui_manager(): function test_analysis_flow_simulation (line 61) | def test_analysis_flow_simulation(): function test_progress_vs_logging (line 141) | def test_progress_vs_logging(): function test_user_experience (line 174) | def test_user_experience(): function main (line 220) | def main(): FILE: tests/test_cli_version.py function test_cli_imports (line 18) | def test_cli_imports(): function test_cli_config (line 44) | def test_cli_config(): function test_cli_graph_creation (line 82) | def test_cli_graph_creation(): function test_cli_cost_tracking (line 125) | def test_cli_cost_tracking(): function test_cli_help (line 172) | def test_cli_help(): function main (line 193) | def main(): FILE: tests/test_code_normalization.py function normalize_code_akshare_style (line 12) | def normalize_code_akshare_style(code_raw): function test_code_normalization (line 43) | def test_code_normalization(): function test_interface_compatibility (line 101) | def test_interface_compatibility(): FILE: tests/test_complete_tool_workflow.py function test_deepseek_complete_workflow (line 18) | def test_deepseek_complete_workflow(): function test_dashscope_react_agent (line 135) | def test_dashscope_react_agent(): function main (line 248) | def main(): FILE: tests/test_conditional_logic_config.py class TestConditionalLogicConfig (line 11) | class TestConditionalLogicConfig: method test_conditional_logic_default_params (line 14) | def test_conditional_logic_default_params(self): method test_conditional_logic_custom_params (line 21) | def test_conditional_logic_custom_params(self): method test_trading_graph_with_level_4_config (line 28) | def test_trading_graph_with_level_4_config(self): method test_trading_graph_with_level_5_config (line 46) | def test_trading_graph_with_level_5_config(self): method test_trading_graph_without_config (line 64) | def test_trading_graph_without_config(self): method test_trading_graph_with_partial_config (line 72) | def test_trading_graph_with_partial_config(self): class TestDebateRoundsProgression (line 86) | class TestDebateRoundsProgression: method test_debate_rounds_by_level (line 96) | def test_debate_rounds_by_level(self, level, debate_rounds, risk_rounds): FILE: tests/test_config_loading.py function test_pricing_config_loading (line 18) | def test_pricing_config_loading(): function test_cost_calculation (line 72) | def test_cost_calculation(): function main (line 118) | def main(): FILE: tests/test_config_management.py function test_config_manager (line 20) | def test_config_manager(): function test_token_tracker (line 114) | def test_token_tracker(): function test_pricing_accuracy (line 162) | def test_pricing_accuracy(): function test_usage_statistics (line 195) | def test_usage_statistics(): function main (line 242) | def main(): FILE: tests/test_config_system.py class TestStartupValidator (line 29) | class TestStartupValidator: method test_config_item_creation (line 32) | def test_config_item_creation(self): method test_validation_result_creation (line 46) | def test_validation_result_creation(self): method test_validate_missing_required_configs (line 61) | def test_validate_missing_required_configs(self): method test_validate_with_required_configs (line 83) | def test_validate_with_required_configs(self): method test_validate_invalid_port (line 99) | def test_validate_invalid_port(self): method test_validate_short_jwt_secret (line 115) | def test_validate_short_jwt_secret(self): method test_validate_default_jwt_secret_warning (line 131) | def test_validate_default_jwt_secret_warning(self): method test_validate_missing_recommended_configs (line 148) | def test_validate_missing_recommended_configs(self): method test_raise_if_failed (line 161) | def test_raise_if_failed(self): method test_raise_if_failed_success (line 177) | def test_raise_if_failed_success(self): class TestConfigCompat (line 186) | class TestConfigCompat: method test_config_manager_compat_creation (line 189) | def test_config_manager_compat_creation(self): method test_get_data_dir (line 196) | def test_get_data_dir(self): method test_get_data_dir_from_env (line 207) | def test_get_data_dir_from_env(self): method test_load_settings (line 216) | def test_load_settings(self): method test_token_tracker_compat_creation (line 227) | def test_token_tracker_compat_creation(self): method test_track_usage (line 234) | def test_track_usage(self): method test_reset_usage (line 253) | def test_reset_usage(self): class TestConfigPriority (line 266) | class TestConfigPriority: method test_env_priority (line 273) | def test_env_priority(self): method test_default_values (line 278) | def test_default_values(self): FILE: tests/test_conversion.py function test_markdown_content (line 12) | def test_markdown_content(): function save_test_content (line 77) | def save_test_content(): function test_word_conversion (line 88) | def test_word_conversion(md_content): function test_pdf_conversion (line 157) | def test_pdf_conversion(md_content): function main (line 220) | def main(): FILE: tests/test_correct_apis.py function test_google_news_tool (line 18) | def test_google_news_tool(): function test_reddit_tools (line 54) | def test_reddit_tools(): function test_toolkit_integration (line 128) | def test_toolkit_integration(): function main (line 175) | def main(): FILE: tests/test_dashscope_adapter_fix.py function test_enhanced_tool_binding (line 18) | def test_enhanced_tool_binding(): function test_tool_format_validation (line 79) | def test_tool_format_validation(): function test_backup_tool_creation (line 127) | def test_backup_tool_creation(): function test_tool_call_response_validation (line 166) | def test_tool_call_response_validation(): function test_comprehensive_tool_calling (line 217) | def test_comprehensive_tool_calling(): function main (line 277) | def main(): FILE: tests/test_dashscope_agent_friendly.py function flush_print (line 13) | def flush_print(msg): function main (line 19) | def main(): FILE: tests/test_dashscope_openai_fix.py function test_openai_adapter_import (line 16) | def test_openai_adapter_import(): function test_openai_adapter_connection (line 41) | def test_openai_adapter_connection(): function test_openai_adapter_function_calling (line 66) | def test_openai_adapter_function_calling(): function test_technical_analysis_with_new_adapter (line 91) | def test_technical_analysis_with_new_adapter(): function test_trading_graph_integration (line 191) | def test_trading_graph_integration(): function main (line 231) | def main(): FILE: tests/test_dashscope_quick_fix.py function test_adapter_creation (line 15) | def test_adapter_creation(): function test_tool_binding_basic (line 41) | def test_tool_binding_basic(): function test_vs_old_adapter (line 72) | def test_vs_old_adapter(): function test_import_completeness (line 100) | def test_import_completeness(): function test_api_key_detection (line 127) | def test_api_key_detection(): function test_technical_analysis_simulation (line 149) | def test_technical_analysis_simulation(): function main (line 196) | def main(): FILE: tests/test_dashscope_simple_fix.py function test_basic_functionality (line 15) | def test_basic_functionality(): function test_tool_binding (line 55) | def test_tool_binding(): function test_vs_old_adapter (line 110) | def test_vs_old_adapter(): function test_trading_graph_creation (line 165) | def test_trading_graph_creation(): function main (line 208) | def main(): FILE: tests/test_dashscope_token_tracking.py function test_dashscope_token_tracking (line 19) | def test_dashscope_token_tracking(): function test_mongodb_storage (line 113) | def test_mongodb_storage(): function main (line 143) | def main(): FILE: tests/test_dashscope_tool_call_fix.py function test_dashscope_tool_call_detection (line 19) | def test_dashscope_tool_call_detection(): FILE: tests/test_dashscope_tool_calling_fix.py function test_basic_tool_calling (line 16) | def test_basic_tool_calling(): function test_stock_analysis_tool_calling (line 86) | def test_stock_analysis_tool_calling(): function test_parameter_optimization (line 166) | def test_parameter_optimization(): function test_model_comparison (line 223) | def test_model_comparison(): function main (line 281) | def main(): FILE: tests/test_data_config_cli.py function test_data_dir_configuration (line 21) | def test_data_dir_configuration(): function test_cli_commands (line 102) | def test_cli_commands(): function main (line 127) | def main(): FILE: tests/test_data_consistency.py function test_data_consistency_checker (line 19) | def test_data_consistency_checker(): function test_mock_data_consistency (line 115) | def test_mock_data_consistency(): FILE: tests/test_data_depth_levels.py function test_data_depth_levels (line 15) | def test_data_depth_levels(): FILE: tests/test_data_sources_comprehensive.py function test_china_stock_data_sources (line 17) | def test_china_stock_data_sources(): function test_us_stock_data_sources (line 119) | def test_us_stock_data_sources(): function test_news_data_sources (line 198) | def test_news_data_sources(): function test_cache_system (line 269) | def test_cache_system(): function analyze_results (line 314) | def analyze_results(all_results: Dict): function print_recommendations (line 378) | def print_recommendations(all_results: Dict): function main (line 438) | def main(): FILE: tests/test_data_sources_simple.py function test_china_data_source (line 16) | def test_china_data_source(): function test_us_data_source (line 49) | def test_us_data_source(): function test_cache_system (line 83) | def test_cache_system(): function test_api_keys (line 122) | def test_api_keys(): function main (line 148) | def main(): FILE: tests/test_database_api.py function test_database_service (line 13) | async def test_database_service(): FILE: tests/test_dataframe_fix.py function test_safe_dataframe (line 15) | def test_safe_dataframe(): function test_comparison_data (line 60) | def test_comparison_data(): function test_timeline_data (line 105) | def test_timeline_data(): function test_arrow_conversion (line 139) | def test_arrow_conversion(): function main (line 172) | def main(): FILE: tests/test_db_requirements_fix.py function test_python_version_check (line 18) | def test_python_version_check(): function test_pickle_compatibility (line 31) | def test_pickle_compatibility(): function test_requirements_file_syntax (line 62) | def test_requirements_file_syntax(): function test_package_installation_simulation (line 106) | def test_package_installation_simulation(): function test_compatibility_checker_tool (line 141) | def test_compatibility_checker_tool(): function test_documentation_completeness (line 186) | def test_documentation_completeness(): function main (line 215) | def main(): FILE: tests/test_debate_flow_simulation.py class TestInvestmentDebateFlow (line 10) | class TestInvestmentDebateFlow: method test_level_4_investment_debate_2_rounds (line 13) | def test_level_4_investment_debate_2_rounds(self): method test_level_5_investment_debate_3_rounds (line 47) | def test_level_5_investment_debate_3_rounds(self): class TestRiskDebateFlow (line 77) | class TestRiskDebateFlow: method test_level_4_risk_debate_2_rounds (line 80) | def test_level_4_risk_debate_2_rounds(self): method test_level_5_risk_debate_3_rounds (line 124) | def test_level_5_risk_debate_3_rounds(self): class TestDebateRoundsCalculation (line 155) | class TestDebateRoundsCalculation: method test_investment_debate_total_count (line 164) | def test_investment_debate_total_count(self, max_debate_rounds, expect... method test_risk_debate_total_count (line 188) | def test_risk_debate_total_count(self, max_risk_discuss_rounds, expect... class TestDebateFlowSummary (line 207) | class TestDebateFlowSummary: method test_level_4_complete_flow (line 210) | def test_level_4_complete_flow(self): method test_level_5_complete_flow (line 231) | def test_level_5_complete_flow(self): FILE: tests/test_decision_data.py function test_decision_data (line 9) | def test_decision_data(): FILE: tests/test_deepseek_cost_calculation.py function test_deepseek_pricing_config (line 18) | def test_deepseek_pricing_config(): function test_deepseek_cost_calculation (line 54) | def test_deepseek_cost_calculation(): function test_token_tracker (line 107) | def test_token_tracker(): function test_deepseek_adapter_integration (line 154) | def test_deepseek_adapter_integration(): function main (line 192) | def main(): FILE: tests/test_deepseek_cost_debug.py function test_deepseek_cost_debug (line 18) | def test_deepseek_cost_debug(): function main (line 62) | def main(): FILE: tests/test_deepseek_cost_fix.py function test_deepseek_cost_calculation (line 18) | def test_deepseek_cost_calculation(): function test_cost_precision (line 104) | def test_cost_precision(): function main (line 125) | def main(): FILE: tests/test_deepseek_integration.py function test_deepseek_availability (line 18) | def test_deepseek_availability(): function test_deepseek_adapter (line 42) | def test_deepseek_adapter(): function test_deepseek_connection (line 68) | def test_deepseek_connection(): function test_deepseek_tools (line 94) | def test_deepseek_tools(): function test_deepseek_trading_graph (line 133) | def test_deepseek_trading_graph(): function test_deepseek_models (line 162) | def test_deepseek_models(): function main (line 185) | def main(): FILE: tests/test_deepseek_react_fix.py function test_deepseek_react_market_analyst (line 18) | def test_deepseek_react_market_analyst(): function test_graph_setup_logic (line 106) | def test_graph_setup_logic(): function main (line 142) | def main(): FILE: tests/test_deepseek_token_tracking.py function test_deepseek_adapter (line 19) | def test_deepseek_adapter(): function test_trading_graph_integration (line 83) | def test_trading_graph_integration(): function main (line 122) | def main(): FILE: tests/test_detailed_data_display.py function test_detailed_data_display (line 18) | def test_detailed_data_display(): FILE: tests/test_detailed_progress_display.py function test_complete_analysis_flow (line 15) | def test_complete_analysis_flow(): function test_problem_solving_effect (line 125) | def test_problem_solving_effect(): function test_analysis_stages (line 173) | def test_analysis_stages(): function main (line 238) | def main(): FILE: tests/test_documentation_consistency.py function test_redis_commander_port_consistency (line 21) | def test_redis_commander_port_consistency(): function test_cli_command_format_consistency (line 55) | def test_cli_command_format_consistency(): function test_cli_smart_suggestions (line 87) | def test_cli_smart_suggestions(): function test_documentation_structure (line 111) | def test_documentation_structure(): function main (line 141) | def main(): FILE: tests/test_duplicate_progress_fix.py function test_duplicate_prevention (line 14) | def test_duplicate_prevention(): function test_stream_chunk_simulation (line 67) | def test_stream_chunk_simulation(): function test_analyst_completion_order (line 120) | def test_analyst_completion_order(): function test_real_scenario_simulation (line 175) | def test_real_scenario_simulation(): function main (line 240) | def main(): FILE: tests/test_embedding_models.py function test_embedding_selection (line 18) | def test_embedding_selection(): function test_embedding_functionality (line 90) | def test_embedding_functionality(): function show_solutions (line 136) | def show_solutions(): function main (line 164) | def main(): FILE: tests/test_enhanced_analysis_history.py function test_load_analysis_results (line 16) | def test_load_analysis_results(): function test_comparison_functions (line 45) | def test_comparison_functions(): function test_chart_functions (line 79) | def test_chart_functions(): function create_test_data (line 119) | def create_test_data(): function main (line 149) | def main(): FILE: tests/test_enhanced_screening.py function test_enhanced_screening (line 18) | async def test_enhanced_screening(): FILE: tests/test_env_compatibility.py function test_env_loading (line 14) | def test_env_loading(): function test_model_config_merge (line 39) | def test_model_config_merge(): function test_settings_merge (line 73) | def test_settings_merge(): function test_backward_compatibility (line 109) | def test_backward_compatibility(): function main (line 139) | def main(): FILE: tests/test_env_config.py function test_env_config (line 10) | def test_env_config(): function main (line 145) | def main(): FILE: tests/test_existing_results.py function get_existing_task_ids (line 12) | def get_existing_task_ids(): function test_existing_result (line 69) | def test_existing_result(task_id, stock_symbol): function main (line 190) | def main(): FILE: tests/test_field_config_api.py function test_field_config_api (line 18) | async def test_field_config_api(): FILE: tests/test_file_loading_debug.py function test_file_loading (line 18) | def test_file_loading(): function main (line 57) | def main(): FILE: tests/test_final_config.py function test_final_config (line 9) | def test_final_config(): function main (line 131) | def main(): FILE: tests/test_final_integration.py function test_final_integration (line 14) | def test_final_integration(): FILE: tests/test_final_unified_architecture.py function test_complete_unified_architecture (line 14) | def test_complete_unified_architecture(): function test_llm_tool_calling_simulation (line 81) | def test_llm_tool_calling_simulation(): function test_unified_tools_functionality (line 170) | def test_unified_tools_functionality(): function main (line 218) | def main(): FILE: tests/test_final_verification.py function test_analysis_depth_differences (line 14) | def test_analysis_depth_differences(): FILE: tests/test_final_verification_with_config.py function test_analysis_depth_differences (line 14) | def test_analysis_depth_differences(): FILE: tests/test_financial_data_validation.py function test_financial_data_validation (line 17) | def test_financial_data_validation(): FILE: tests/test_financial_metrics_fix.py function test_financial_metrics (line 19) | def test_financial_metrics(): function test_tushare_connection (line 67) | def test_tushare_connection(): function main (line 96) | def main(): FILE: tests/test_finnhub_connection.py function test_finnhub_api (line 10) | def test_finnhub_api(): function test_china_stock_api (line 95) | def test_china_stock_api(): FILE: tests/test_finnhub_fundamentals.py function test_finnhub_api_key (line 14) | def test_finnhub_api_key(): function test_finnhub_fundamentals_with_cache (line 26) | def test_finnhub_fundamentals_with_cache(): function test_openai_fallback_with_cache (line 75) | def test_openai_fallback_with_cache(): function test_cache_management (line 141) | def test_cache_management(): function main (line 168) | def main(): FILE: tests/test_finnhub_hk.py function test_finnhub_connection (line 12) | def test_finnhub_connection(): function test_finnhub_hk_symbols (line 42) | def test_finnhub_hk_symbols(): function test_finnhub_hk_company_info (line 91) | def test_finnhub_hk_company_info(): function test_optimized_us_data_finnhub_hk (line 130) | def test_optimized_us_data_finnhub_hk(): function test_unified_interface_finnhub_priority (line 174) | def test_unified_interface_finnhub_priority(): function main (line 213) | def main(): FILE: tests/test_finnhub_news_fix.py function test_data_dir_config (line 24) | def test_data_dir_config(): function test_finnhub_news_path (line 45) | def test_finnhub_news_path(): function test_get_data_in_range (line 76) | def test_get_data_in_range(): function test_get_finnhub_news (line 100) | def test_get_finnhub_news(): function create_sample_data_structure (line 114) | def create_sample_data_structure(): function main (line 153) | def main(): FILE: tests/test_fix.py function test_analysis_fix (line 6) | def test_analysis_fix(): FILE: tests/test_fixed_analysis.py function test_fixed_analysis (line 11) | def test_fixed_analysis(): FILE: tests/test_format_fix.py function test_format_analysis_results (line 13) | def test_format_analysis_results(): function main (line 125) | def main(): FILE: tests/test_frontend_backend_integration.py function test_frontend_backend_integration (line 11) | def test_frontend_backend_integration(): FILE: tests/test_frontend_display.py function test_frontend_display (line 10) | def test_frontend_display(): FILE: tests/test_full_analysis_debug.py function test_full_stock_analysis (line 18) | def test_full_stock_analysis(): function main (line 99) | def main(): FILE: tests/test_full_fundamentals_flow.py function test_full_fundamentals_flow (line 13) | def test_full_fundamentals_flow(): FILE: tests/test_fundamentals_cache.py function test_cache_manager_fundamentals (line 16) | def test_cache_manager_fundamentals(): function test_fundamentals_with_cache (line 86) | def test_fundamentals_with_cache(): function test_cache_ttl (line 130) | def test_cache_ttl(): function main (line 171) | def main(): FILE: tests/test_fundamentals_debug.py function test_fundamentals_analyst_directly (line 9) | def test_fundamentals_analyst_directly(): function test_stock_utils_import (line 68) | def test_stock_utils_import(): function test_toolkit_hk_tools (line 97) | def test_toolkit_hk_tools(): function test_import_paths (line 132) | def test_import_paths(): function main (line 154) | def main(): FILE: tests/test_fundamentals_generation.py function test_fundamentals_generation (line 13) | def test_fundamentals_generation(): function test_industry_info (line 93) | def test_industry_info(): FILE: tests/test_fundamentals_no_duplicate.py function test_fundamentals_analyst (line 11) | def test_fundamentals_analyst(): FILE: tests/test_fundamentals_react_hk_fix.py function test_react_fundamentals_hk_config (line 12) | def test_react_fundamentals_hk_config(): function test_us_stock_separation (line 46) | def test_us_stock_separation(): function test_hk_query_format (line 73) | def test_hk_query_format(): function test_toolkit_method_usage (line 104) | def test_toolkit_method_usage(): function test_stock_type_detection (line 142) | def test_stock_type_detection(): function main (line 185) | def main(): FILE: tests/test_fundamentals_tracking.py function test_fundamentals_analyst (line 13) | def test_fundamentals_analyst(): function test_unified_tool_direct (line 87) | def test_unified_tool_direct(): FILE: tests/test_gemini_25_pro.py function test_gemini_25_pro_basic (line 18) | def test_gemini_25_pro_basic(): function test_gemini_25_pro_tradingagents (line 75) | def test_gemini_25_pro_tradingagents(): function test_gemini_25_pro_complex_reasoning (line 152) | def test_gemini_25_pro_complex_reasoning(): function main (line 211) | def main(): FILE: tests/test_gemini_final.py function test_gemini_tradingagents (line 18) | def test_gemini_tradingagents(): function test_gemini_basic (line 101) | def test_gemini_basic(): function main (line 136) | def main(): FILE: tests/test_gemini_simple.py function test_gemini_simple_analysis (line 18) | def test_gemini_simple_analysis(): function test_gemini_analyst_direct (line 101) | def test_gemini_analyst_direct(): function main (line 167) | def main(): FILE: tests/test_google_memory_fix.py function test_google_memory_fixed (line 18) | def test_google_memory_fixed(): function test_google_tradingagents_with_memory (line 95) | def test_google_tradingagents_with_memory(): function main (line 177) | def main(): FILE: tests/test_google_tool_handler_improvements.py function test_google_tool_handler_improvements (line 29) | def test_google_tool_handler_improvements(): FILE: tests/test_graph_routing.py function test_graph_routing (line 18) | def test_graph_routing(): function main (line 102) | def main(): FILE: tests/test_hk_apis_simple.py function test_stock_hk_spot (line 13) | def test_stock_hk_spot(): function test_stock_hk_daily (line 40) | def test_stock_hk_daily(): function test_stock_hk_spot_em (line 61) | def test_stock_hk_spot_em(): function test_stock_individual_info_hk (line 88) | def test_stock_individual_info_hk(): function main (line 109) | def main(): FILE: tests/test_hk_data_source_fix.py function test_toolkit_hk_method (line 12) | def test_toolkit_hk_method(): function test_market_analyst_tools (line 42) | def test_market_analyst_tools(): function test_akshare_hk_availability (line 84) | def test_akshare_hk_availability(): function test_data_source_priority (line 121) | def test_data_source_priority(): function test_market_analyst_modification (line 152) | def test_market_analyst_modification(): function main (line 179) | def main(): FILE: tests/test_hk_error_handling.py function test_hk_data_error_handling (line 10) | def test_hk_data_error_handling(): function test_akshare_error_recovery (line 81) | def test_akshare_error_recovery(): function test_hk_fallback_mechanisms (line 146) | def test_hk_fallback_mechanisms(): function main (line 209) | def main(): FILE: tests/test_hk_fundamentals_final.py function test_hk_fundamentals_complete (line 9) | def test_hk_fundamentals_complete(): function test_tool_selection_verification (line 90) | def test_tool_selection_verification(): function main (line 144) | def main(): FILE: tests/test_hk_fundamentals_fix.py function test_stock_type_detection (line 10) | def test_stock_type_detection(): function test_fundamentals_analyst_tool_selection (line 55) | def test_fundamentals_analyst_tool_selection(): function test_trader_currency_detection (line 109) | def test_trader_currency_detection(): function test_hk_data_source (line 145) | def test_hk_data_source(): function main (line 175) | def main(): FILE: tests/test_hk_improved.py function test_stock_recognition (line 12) | def test_stock_recognition(): function test_hk_data_unified (line 48) | def test_hk_data_unified(): function test_hk_info_unified (line 93) | def test_hk_info_unified(): function test_market_auto_selection (line 127) | def test_market_auto_selection(): function main (line 161) | def main(): FILE: tests/test_hk_priority.py function test_hk_data_source_priority (line 14) | def test_hk_data_source_priority(): function test_hk_data_priority (line 68) | def test_hk_data_priority(): function test_improved_hk_provider_priority (line 111) | def test_improved_hk_provider_priority(): function test_data_source_availability (line 162) | def test_data_source_availability(): function main (line 208) | def main(): FILE: tests/test_hk_simple.py function test_basic (line 12) | def test_basic(): FILE: tests/test_hk_simple_improved.py function test_hk_provider_direct (line 14) | def test_hk_provider_direct(): function test_cache_direct (line 64) | def test_cache_direct(): function test_normalization (line 131) | def test_normalization(): function main (line 167) | def main(): FILE: tests/test_hk_stock_functionality.py function test_stock_utils (line 15) | def test_stock_utils(): function test_hk_stock_provider (line 57) | def test_hk_stock_provider(): function test_hk_stock_info (line 91) | def test_hk_stock_info(): function test_hk_stock_data (line 130) | def test_hk_stock_data(): function test_optimized_us_data_hk_support (line 174) | def test_optimized_us_data_hk_support(): function main (line 221) | def main(): FILE: tests/test_import_fix.py function test_fundamentals_analyst_import (line 12) | def test_fundamentals_analyst_import(): function test_stock_utils_functions (line 40) | def test_stock_utils_functions(): function test_web_analysis_runner (line 87) | def test_web_analysis_runner(): function test_complete_analysis_flow (line 117) | def test_complete_analysis_flow(): function main (line 144) | def main(): FILE: tests/test_improved_hk_utils.py function test_improved_hk_provider (line 13) | def test_improved_hk_provider(): function test_analyst_integration (line 59) | def test_analyst_integration(): function test_cache_functionality (line 100) | def test_cache_functionality(): function main (line 168) | def main(): FILE: tests/test_industries_api.py function test_industries_api (line 12) | def test_industries_api(): FILE: tests/test_industry_screening_fix.py function test_industry_screening (line 16) | async def test_industry_screening(): function test_frontend_payload (line 124) | def test_frontend_payload(): FILE: tests/test_investment_advice_fix.py function test_web_components (line 14) | def test_web_components(): function test_analysis_runner (line 63) | def test_analysis_runner(): function test_demo_data (line 132) | def test_demo_data(): function main (line 171) | def main(): FILE: tests/test_level3_deadlock_debug.py function test_level3_deadlock (line 22) | def test_level3_deadlock(): FILE: tests/test_level3_fix.py function test_level3_analysis (line 15) | def test_level3_analysis(): FILE: tests/test_llm_technical_analysis_debug.py function test_dashscope_technical_analysis (line 16) | def test_dashscope_technical_analysis(): function test_deepseek_technical_analysis (line 86) | def test_deepseek_technical_analysis(): function test_message_sequence_handling (line 156) | def test_message_sequence_handling(): function test_max_tokens_impact (line 221) | def test_max_tokens_impact(): function main (line 270) | def main(): FILE: tests/test_llm_tool_call.py function test_function_exists (line 23) | def test_function_exists(): function test_direct_call (line 39) | def test_direct_call(): function test_toolkit_call (line 61) | def test_toolkit_call(): function test_toolkit_attributes (line 83) | def test_toolkit_attributes(): function simulate_llm_tool_call (line 101) | def simulate_llm_tool_call(): function main (line 142) | def main(): FILE: tests/test_llm_tool_calling_comparison.py function test_deepseek_tool_calling (line 19) | def test_deepseek_tool_calling(): function test_dashscope_tool_calling (line 105) | def test_dashscope_tool_calling(): function compare_results (line 188) | def compare_results(deepseek_result, dashscope_result): function main (line 239) | def main(): FILE: tests/test_logging_fix.py function test_logging_fix (line 18) | def test_logging_fix(): FILE: tests/test_login_api.py function test_login_api (line 5) | async def test_login_api(): FILE: tests/test_market_analyst_fix.py function test_deepseek_market_analyst (line 18) | def test_deepseek_market_analyst(): function test_dashscope_market_analyst (line 87) | def test_dashscope_market_analyst(): function main (line 161) | def main(): FILE: tests/test_market_analyst_lookback.py function test_config_loading (line 28) | def test_config_loading(): function test_date_range_calculation (line 58) | def test_date_range_calculation(lookback_days): function test_data_fetching (line 97) | def test_data_fetching(start_date, end_date): function test_technical_indicators_accuracy (line 161) | def test_technical_indicators_accuracy(lookback_days): function main (line 215) | def main(): FILE: tests/test_middleware.py function test_middleware (line 14) | async def test_middleware(): FILE: tests/test_model_config.py function login (line 17) | async def login(): function get_auth_headers (line 51) | def get_auth_headers(): function test_add_llm_config (line 60) | async def test_add_llm_config(): function test_get_llm_configs (line 107) | async def test_get_llm_configs(): function test_model_capability_service (line 149) | async def test_model_capability_service(): function test_delete_test_config (line 176) | async def test_delete_test_config(): function main (line 198) | async def main(): FILE: tests/test_mongodb_check.py function check_mongodb_connection (line 23) | def check_mongodb_connection(): function check_analysis_records (line 35) | def check_analysis_records(): function check_specific_stock (line 84) | def check_specific_stock(stock_symbol="000001"): function main (line 118) | def main(): FILE: tests/test_mongodb_save.py function check_mongodb_before_after (line 11) | def check_mongodb_before_after(): FILE: tests/test_news_analyst_fix.py function test_tool_parameters (line 16) | def test_tool_parameters(): FILE: tests/test_news_analyst_integration.py function test_news_analyst_integration (line 14) | def test_news_analyst_integration(): FILE: tests/test_news_filtering.py function test_basic_news_filter (line 14) | def test_basic_news_filter(): function test_enhanced_news_filter (line 78) | def test_enhanced_news_filter(): function test_real_news_filtering (line 138) | def test_real_news_filtering(): function test_news_filter_integration (line 199) | def test_news_filter_integration(): function main (line 237) | def main(): FILE: tests/test_news_timeout_fix.py class TestNewsTimeoutFix (line 25) | class TestNewsTimeoutFix(unittest.TestCase): method setUp (line 28) | def setUp(self): method test_make_request_timeout (line 33) | def test_make_request_timeout(self): method test_news_source_fallback (line 49) | def test_news_source_fallback(self): method test_all_news_sources_fail (line 83) | def test_all_news_sources_fail(self): FILE: tests/test_non_blocking.py function test_non_blocking_analysis (line 12) | async def test_non_blocking_analysis(): function test_concurrent_requests (line 107) | async def test_concurrent_requests(): FILE: tests/test_notification_removal.py function check_notification_code (line 9) | def check_notification_code(): function check_sync_control_component (line 72) | def check_sync_control_component(): function generate_test_instructions (line 139) | def generate_test_instructions(): FILE: tests/test_openai_config_fix.py function test_openai_config_detection (line 14) | def test_openai_config_detection(): function test_fundamentals_api_selection (line 82) | def test_fundamentals_api_selection(): function test_config_scenarios (line 138) | def test_config_scenarios(): function main (line 197) | def main(): FILE: tests/test_operation_logs.py function test_operation_logs (line 17) | async def test_operation_logs(): FILE: tests/test_optimized_data_depth.py function test_optimized_data_depth (line 14) | def test_optimized_data_depth(): FILE: tests/test_optimized_fundamentals.py function test_optimized_fundamentals (line 14) | def test_optimized_fundamentals(): FILE: tests/test_optimized_fundamentals_simple.py function test_optimized_fundamentals_logic (line 13) | def test_optimized_fundamentals_logic(): FILE: tests/test_optimized_prompts.py function test_company_name_extraction (line 14) | def test_company_name_extraction(): function test_market_analyst_prompt (line 58) | def test_market_analyst_prompt(): function test_fundamentals_analyst_prompt (line 143) | def test_fundamentals_analyst_prompt(): function main (line 183) | def main(): FILE: tests/test_pb_calculation_fix.py function test_pb_calculation_units (line 7) | def test_pb_calculation_units(): function test_pb_calculation_with_real_example (line 42) | def test_pb_calculation_with_real_example(): function test_pb_calculation_formula_equivalence (line 69) | def test_pb_calculation_formula_equivalence(): FILE: tests/test_performance_comparison.py function simulate_old_strategy (line 15) | def simulate_old_strategy(): function test_new_strategy (line 84) | def test_new_strategy(): function compare_performance (line 139) | def compare_performance(): FILE: tests/test_profitable_stock.py function test_profitable_stock (line 15) | def test_profitable_stock(): FILE: tests/test_progress.py function test_progress_callback (line 14) | def test_progress_callback(): function test_progress_tracker (line 47) | def test_progress_tracker(): function main (line 88) | def main(): FILE: tests/test_progress_steps.py function login (line 15) | async def login() -> str: function start_analysis (line 48) | async def start_analysis(token: str) -> str: function get_task_status (line 81) | async def get_task_status(token: str, task_id: str) -> dict: function print_progress_info (line 101) | def print_progress_info(status_data: dict, iteration: int): function monitor_task_progress (line 164) | async def monitor_task_progress(token: str, task_id: str, max_iterations... function main (line 201) | async def main(): FILE: tests/test_progress_time_calculation.py function test_progress_time_calculation_basic (line 17) | def test_progress_time_calculation_basic(): function test_progress_time_calculation_10_percent (line 49) | def test_progress_time_calculation_10_percent(): function test_progress_time_calculation_50_percent (line 81) | def test_progress_time_calculation_50_percent(): function test_progress_time_calculation_zero_progress (line 113) | def test_progress_time_calculation_zero_progress(): function test_progress_time_calculation_completed (line 143) | def test_progress_time_calculation_completed(): FILE: tests/test_prompt_optimization_effect.py function test_fundamentals_analyst_prompt (line 14) | def test_fundamentals_analyst_prompt(): function test_market_analyst_prompt (line 161) | def test_market_analyst_prompt(): function test_prompt_elements (line 273) | def test_prompt_elements(): function main (line 329) | def main(): FILE: tests/test_pypandoc_functionality.py function test_pypandoc_import (line 16) | def test_pypandoc_import(): function test_pandoc_version (line 27) | def test_pandoc_version(): function test_pandoc_download (line 39) | def test_pandoc_download(): function test_markdown_conversion (line 65) | def test_markdown_conversion(): function test_report_exporter (line 168) | def test_report_exporter(): function main (line 230) | def main(): FILE: tests/test_quick_async.py function test_api_non_blocking (line 11) | def test_api_non_blocking(): function test_multiple_concurrent_requests (line 136) | def test_multiple_concurrent_requests(): FILE: tests/test_quick_fix.py function quick_test (line 10) | def quick_test(): FILE: tests/test_quotes_ingestion.py function test_normalize_stock_code (line 17) | async def test_normalize_stock_code(): function test_market_quotes_status (line 56) | async def test_market_quotes_status(): function test_historical_data_import (line 115) | async def test_historical_data_import(): function test_akshare_realtime_quotes (line 196) | async def test_akshare_realtime_quotes(): function main (line 248) | async def main(): FILE: tests/test_quotes_sync_status.py function test_trading_time_logic (line 24) | def test_trading_time_logic(): function test_status_record_and_get (line 84) | async def test_status_record_and_get(): function test_error_status (line 146) | async def test_error_status(): function main (line 204) | async def main(): FILE: tests/test_raw_data_display.py function test_raw_data_display (line 16) | def test_raw_data_display(): FILE: tests/test_real_data_levels.py function analyze_data_content (line 19) | def analyze_data_content(data, level_name): function test_stock_with_all_levels (line 81) | def test_stock_with_all_levels(ticker, stock_name): function main (line 176) | def main(): FILE: tests/test_real_deepseek_cost.py function test_real_deepseek_analysis (line 18) | def test_real_deepseek_analysis(): function test_simple_deepseek_call (line 85) | def test_simple_deepseek_call(): function test_multiple_calls (line 127) | def test_multiple_calls(): function main (line 175) | def main(): FILE: tests/test_real_estate_api.py function test_real_estate_screening (line 12) | def test_real_estate_screening(): FILE: tests/test_real_volume_issue.py function test_real_tushare_volume_access (line 24) | def test_real_tushare_volume_access(): function test_tushare_adapter_direct (line 94) | def test_tushare_adapter_direct(): function test_column_mapping_in_real_data (line 163) | def test_column_mapping_in_real_data(): function main (line 232) | def main(): FILE: tests/test_redis_performance.py class RedisPerformanceTester (line 13) | class RedisPerformanceTester: method __init__ (line 16) | def __init__(self, host=None, port=None, password=None, db=None): method connect (line 24) | def connect(self): method test_connection_latency (line 47) | def test_connection_latency(self, iterations=100): method test_throughput (line 94) | def test_throughput(self, operations=1000, operation_type='set'): method test_concurrent_connections (line 154) | def test_concurrent_connections(self, num_threads=10, operations_per_t... method test_memory_usage (line 241) | def test_memory_usage(self): method run_full_test (line 267) | def run_full_test(self): function main (line 299) | def main(): FILE: tests/test_reports_api.py function login_and_get_token (line 10) | def login_and_get_token(base_url): function test_reports_api (line 37) | def test_reports_api(): function test_reports_with_filters (line 195) | def test_reports_with_filters(): FILE: tests/test_reports_fix.py function test_reports_and_analysts_fix (line 11) | def test_reports_and_analysts_fix(): FILE: tests/test_request_deduplication.py function test_concurrent_hk_quote_requests (line 12) | async def test_concurrent_hk_quote_requests(): function test_concurrent_us_quote_requests (line 74) | async def test_concurrent_us_quote_requests(): function test_different_stocks_no_blocking (line 128) | async def test_different_stocks_no_blocking(): FILE: tests/test_research_depth_5_levels.py class TestResearchDepth5Levels (line 8) | class TestResearchDepth5Levels: method test_depth_level_1_fast (line 11) | def test_depth_level_1_fast(self): method test_depth_level_2_basic (line 29) | def test_depth_level_2_basic(self): method test_depth_level_3_standard (line 47) | def test_depth_level_3_standard(self): method test_depth_level_4_deep (line 65) | def test_depth_level_4_deep(self): method test_depth_level_5_comprehensive (line 83) | def test_depth_level_5_comprehensive(self): method test_unknown_depth_defaults_to_standard (line 101) | def test_unknown_depth_defaults_to_standard(self): method test_all_depths_have_correct_progression (line 118) | def test_all_depths_have_correct_progression(self): class TestAnalysisParametersDefault (line 162) | class TestAnalysisParametersDefault: method test_default_research_depth_is_standard (line 165) | def test_default_research_depth_is_standard(self): method test_research_depth_accepts_all_5_levels (line 172) | def test_research_depth_accepts_all_5_levels(self): FILE: tests/test_research_depth_mapping.py class TestResearchDepthMapping (line 9) | class TestResearchDepthMapping: method test_level_1_fast (line 12) | def test_level_1_fast(self): method test_level_2_basic (line 28) | def test_level_2_basic(self): method test_level_3_standard (line 44) | def test_level_3_standard(self): method test_level_4_deep (line 60) | def test_level_4_deep(self): method test_level_5_comprehensive (line 77) | def test_level_5_comprehensive(self): method test_chinese_depth_fast (line 94) | def test_chinese_depth_fast(self): method test_chinese_depth_deep (line 109) | def test_chinese_depth_deep(self): method test_chinese_depth_comprehensive (line 124) | def test_chinese_depth_comprehensive(self): method test_string_number_depth (line 139) | def test_string_number_depth(self): method test_invalid_depth_fallback (line 154) | def test_invalid_depth_fallback(self): method test_debate_rounds_progression (line 170) | def test_debate_rounds_progression(self): FILE: tests/test_risk_assessment.py function test_risk_assessment_extraction (line 18) | def test_risk_assessment_extraction(): function test_web_interface_risk_display (line 118) | def test_web_interface_risk_display(): function test_risk_assessment_integration (line 151) | def test_risk_assessment_integration(): function main (line 241) | def main(): FILE: tests/test_sanitize_export.py function test_sanitize_simple_fields (line 8) | def test_sanitize_simple_fields(): function test_sanitize_max_tokens_preserved (line 29) | def test_sanitize_max_tokens_preserved(): function test_sanitize_nested_dict (line 50) | def test_sanitize_nested_dict(): function test_sanitize_list (line 75) | def test_sanitize_list(): function test_sanitize_case_insensitive (line 92) | def test_sanitize_case_insensitive(): function test_sanitize_all_keywords (line 109) | def test_sanitize_all_keywords(): function test_sanitize_complex_structure (line 136) | def test_sanitize_complex_structure(): FILE: tests/test_sanitize_real_data.py function test_sanitize_real_export_file (line 8) | def test_sanitize_real_export_file(): FILE: tests/test_screening_fields.py function test_screening_fields (line 17) | async def test_screening_fields(): FILE: tests/test_screening_fix.py function test_screening_api (line 16) | def test_screening_api(): FILE: tests/test_server_config.py function test_server_config (line 14) | def test_server_config(): FILE: tests/test_signal_processing_logging.py function test_signal_processing_logging (line 13) | def test_signal_processing_logging(): function test_logging_extraction (line 104) | def test_logging_extraction(): function main (line 169) | def main(): FILE: tests/test_signal_processor_debug.py function test_signal_processor (line 10) | def test_signal_processor(): function test_trading_graph (line 69) | def test_trading_graph(): FILE: tests/test_signal_processor_fix.py function test_signal_processor_currency_fix (line 17) | def test_signal_processor_currency_fix(): function test_web_currency_display (line 105) | def test_web_currency_display(): FILE: tests/test_simple_depth_check.py function test_depth_level (line 13) | def test_depth_level(depth): function main (line 59) | def main(): FILE: tests/test_simple_fundamentals.py function test_simple_fundamentals (line 13) | def test_simple_fundamentals(): FILE: tests/test_simple_tracking.py function test_data_flow (line 13) | def test_data_flow(): function test_tushare_direct (line 65) | def test_tushare_direct(): function test_tushare_provider (line 114) | def test_tushare_provider(): FILE: tests/test_smart_system.py function test_smart_config (line 10) | def test_smart_config(): function test_adaptive_cache (line 33) | def test_adaptive_cache(): function test_performance (line 93) | def test_performance(): function test_fallback_mechanism (line 161) | def test_fallback_mechanism(): function generate_test_report (line 195) | def generate_test_report(results): function main (line 231) | def main(): FILE: tests/test_sse_and_worker_config.py class FakePubSub (line 22) | class FakePubSub: method subscribe (line 23) | async def subscribe(self, channel: str): method get_message (line 25) | async def get_message(self, ignore_subscribe_messages: bool = True): method unsubscribe (line 28) | async def unsubscribe(self, *channels): method close (line 30) | async def close(self): class FakeRedis (line 33) | class FakeRedis: method pubsub (line 34) | def pubsub(self): class FakeQueueService (line 37) | class FakeQueueService: method get_task (line 38) | async def get_task(self, task_id: str): method get_batch (line 40) | async def get_batch(self, batch_id: str): function make_test_app (line 44) | def make_test_app(fake_queue_service: QueueService): function test_sse_task_connected_event (line 62) | def test_sse_task_connected_event(monkeypatch): function test_sse_batch_connected_event (line 79) | def test_sse_batch_connected_event(monkeypatch): function test_worker_intervals_env_and_dynamic_override (line 100) | def test_worker_intervals_env_and_dynamic_override(monkeypatch): FILE: tests/test_stock_code_tracking.py function test_stock_code_tracking (line 14) | def test_stock_code_tracking(): function test_individual_components (line 72) | def test_individual_components(): FILE: tests/test_stock_codes.py function test_get_stock_codes (line 13) | def test_get_stock_codes(): FILE: tests/test_stock_data_service.py class TestStockDataService (line 29) | class TestStockDataService(unittest.TestCase): method setUp (line 32) | def setUp(self): method test_service_initialization (line 39) | def test_service_initialization(self): method test_get_stock_basic_info_single (line 52) | def test_get_stock_basic_info_single(self): method test_get_stock_basic_info_all (line 78) | def test_get_stock_basic_info_all(self): method test_market_classification (line 103) | def test_market_classification(self): method test_fallback_data (line 125) | def test_fallback_data(self): class TestStockAPI (line 144) | class TestStockAPI(unittest.TestCase): method setUp (line 147) | def setUp(self): method test_service_status (line 152) | def test_service_status(self): method test_get_stock_info_api (line 167) | def test_get_stock_info_api(self): method test_search_stocks_api (line 189) | def test_search_stocks_api(self): method test_market_summary_api (line 213) | def test_market_summary_api(self): method test_stock_data_api (line 236) | def test_stock_data_api(self): class TestFallbackMechanism (line 259) | class TestFallbackMechanism(unittest.TestCase): method setUp (line 262) | def setUp(self): method test_mongodb_unavailable_fallback (line 268) | def test_mongodb_unavailable_fallback(self): method test_invalid_stock_code_fallback (line 292) | def test_invalid_stock_code_fallback(self): function run_comprehensive_test (line 317) | def run_comprehensive_test(): function run_manual_test (line 364) | def run_manual_test(): FILE: tests/test_stock_info_debug.py function test_stock_code_normalization (line 15) | def test_stock_code_normalization(): function test_tushare_api_direct (line 38) | def test_tushare_api_direct(): function test_stock_list_search (line 102) | def test_stock_list_search(): function test_alternative_stock_codes (line 153) | def test_alternative_stock_codes(): function main (line 193) | def main(): FILE: tests/test_stock_market_identification.py function test_stock_identification (line 14) | def test_stock_identification(): FILE: tests/test_summary_recommendation.py function test_summary_recommendation (line 8) | def test_summary_recommendation(): FILE: tests/test_symbol_field_fix.py function test_basics_sync_service_has_symbol_field (line 18) | def test_basics_sync_service_has_symbol_field(): function test_multi_source_sync_service_has_symbol_field (line 36) | def test_multi_source_sync_service_has_symbol_field(): function test_baostock_sync_service_has_symbol_field (line 54) | def test_baostock_sync_service_has_symbol_field(): function test_app_adapter_query_logic (line 72) | def test_app_adapter_query_logic(): function test_migration_script_exists (line 90) | def test_migration_script_exists(): function main (line 105) | def main(): FILE: tests/test_sync_control_functions.py function test_sync_control_functions (line 19) | async def test_sync_control_functions(): function test_api_endpoints (line 135) | async def test_api_endpoints(): FILE: tests/test_sync_history_api.py function test_sync_history_api (line 20) | async def test_sync_history_api(): function test_frontend_integration (line 153) | async def test_frontend_integration(): FILE: tests/test_sync_history_fix.py function test_multiple_sync_records (line 22) | async def test_multiple_sync_records(): function test_api_response (line 160) | async def test_api_response(): FILE: tests/test_sync_user_feedback.py function simulate_sync_with_feedback (line 20) | async def simulate_sync_with_feedback(): function test_status_polling_simulation (line 161) | async def test_status_polling_simulation(): FILE: tests/test_system_config_summary_sse_queue.py function app_client (line 11) | def app_client(): function test_config_summary_contains_new_settings_fields (line 25) | def test_config_summary_contains_new_settings_fields(app_client: TestCli... FILE: tests/test_system_simple.py function test_basic_system (line 10) | def test_basic_system(): function main (line 154) | def main(): FILE: tests/test_target_price.py function test_signal_processor (line 14) | def test_signal_processor(): function test_smart_price_estimation (line 58) | def test_smart_price_estimation(): function test_trader_prompt (line 84) | def test_trader_prompt(): function main (line 116) | def main(): FILE: tests/test_time_estimation_display.py function test_time_estimation_display (line 15) | def test_time_estimation_display(): function test_user_expectation_management (line 99) | def test_user_expectation_management(): function test_time_estimation_scenarios (line 134) | def test_time_estimation_scenarios(): function test_progress_communication (line 190) | def test_progress_communication(): function main (line 258) | def main(): FILE: tests/test_timezone_fix.py function test_timezone_fix (line 18) | async def test_timezone_fix(): FILE: tests/test_tool_binding_fix.py function test_tool_binding (line 10) | def test_tool_binding(): FILE: tests/test_tool_call_issue.py function test_tool_call_mechanism (line 28) | def test_tool_call_mechanism(): FILE: tests/test_tool_execution_flow.py function test_tool_execution_flow (line 15) | def test_tool_execution_flow(): FILE: tests/test_tool_interception.py function test_hk_fundamentals_with_interception (line 10) | def test_hk_fundamentals_with_interception(): function test_tool_selection_logic (line 106) | def test_tool_selection_logic(): function main (line 166) | def main(): FILE: tests/test_tool_removal.py function test_available_tools (line 7) | def test_available_tools(): function test_fundamentals_analyst_tool_selection (line 75) | def test_fundamentals_analyst_tool_selection(): function test_market_analyst_tool_selection (line 133) | def test_market_analyst_tool_selection(): function main (line 189) | def main(): FILE: tests/test_tool_selection_debug.py function test_llm_tool_binding (line 9) | def test_llm_tool_binding(): function test_tool_descriptions (line 57) | def test_tool_descriptions(): function test_fundamentals_analyst_tool_selection (line 97) | def test_fundamentals_analyst_tool_selection(): function main (line 156) | def main(): FILE: tests/test_toolkit_tools.py function test_toolkit_tools (line 18) | def test_toolkit_tools(): function test_social_news_analysts (line 95) | def test_social_news_analysts(): function check_data_requirements (line 121) | def check_data_requirements(): function main (line 163) | def main(): FILE: tests/test_trading_time_logic.py function test_trading_time_logic (line 20) | def test_trading_time_logic(): FILE: tests/test_tradingagents_runtime_settings.py function _admin_user (line 11) | def _admin_user(): function app_client_config (line 16) | def app_client_config(): function test_config_settings_contains_ta_keys (line 23) | def test_config_settings_contains_ta_keys(app_client_config: TestClient,... function test_runtime_settings_priority_db_env_default (line 44) | def test_runtime_settings_priority_db_env_default(monkeypatch): FILE: tests/test_tushare_integration.py function test_tushare_provider (line 17) | def test_tushare_provider(): function test_tushare_adapter (line 72) | def test_tushare_adapter(): function test_tushare_interface (line 131) | def test_tushare_interface(): function test_tushare_cache (line 191) | def test_tushare_cache(): function check_tushare_environment (line 241) | def check_tushare_environment(): function main (line 276) | def main(): FILE: tests/test_tushare_unified/test_tushare_provider.py class TestTushareProvider (line 13) | class TestTushareProvider: method provider (line 17) | def provider(self): method mock_tushare_api (line 22) | def mock_tushare_api(self): method test_connect_success (line 70) | async def test_connect_success(self, provider, mock_tushare_api): method test_connect_no_token (line 86) | async def test_connect_no_token(self, provider): method test_get_stock_list (line 97) | async def test_get_stock_list(self, provider, mock_tushare_api): method test_get_stock_basic_info_single (line 115) | async def test_get_stock_basic_info_single(self, provider, mock_tushar... method test_get_stock_quotes (line 134) | async def test_get_stock_quotes(self, provider, mock_tushare_api): method test_get_historical_data (line 158) | async def test_get_historical_data(self, provider, mock_tushare_api): method test_normalize_ts_code (line 173) | def test_normalize_ts_code(self, provider): method test_determine_market_info_from_ts_code (line 186) | def test_determine_market_info_from_ts_code(self, provider): method test_standardize_basic_info (line 206) | def test_standardize_basic_info(self, provider): method test_standardize_quotes (line 229) | def test_standardize_quotes(self, provider): method test_format_date_output (line 255) | def test_format_date_output(self, provider): method test_convert_to_float (line 269) | def test_convert_to_float(self, provider): FILE: tests/test_tushare_unified/test_tushare_sync_service.py class TestTushareSyncService (line 12) | class TestTushareSyncService: method sync_service (line 16) | def sync_service(self): method mock_stock_list (line 34) | def mock_stock_list(self): method test_initialize_success (line 60) | async def test_initialize_success(self, sync_service): method test_initialize_failure (line 69) | async def test_initialize_failure(self, sync_service): method test_sync_stock_basic_info_success (line 77) | async def test_sync_stock_basic_info_success(self, sync_service, mock_... method test_sync_stock_basic_info_no_data (line 99) | async def test_sync_stock_basic_info_no_data(self, sync_service): method test_process_basic_info_batch_success (line 110) | async def test_process_basic_info_batch_success(self, sync_service, mo... method test_process_basic_info_batch_skip_fresh_data (line 124) | async def test_process_basic_info_batch_skip_fresh_data(self, sync_ser... method test_sync_realtime_quotes_success (line 138) | async def test_sync_realtime_quotes_success(self, sync_service): method test_process_quotes_batch_success (line 162) | async def test_process_quotes_batch_success(self, sync_service): method test_get_and_save_quotes_success (line 176) | async def test_get_and_save_quotes_success(self, sync_service): method test_get_and_save_quotes_no_data (line 195) | async def test_get_and_save_quotes_no_data(self, sync_service): method test_sync_historical_data_success (line 204) | async def test_sync_historical_data_success(self, sync_service): method test_sync_financial_data_success (line 233) | async def test_sync_financial_data_success(self, sync_service): method test_is_data_fresh (line 259) | def test_is_data_fresh(self, sync_service): method test_get_sync_status_success (line 273) | async def test_get_sync_status_success(self, sync_service): FILE: tests/test_unified_architecture.py function test_unified_tools_availability (line 10) | def test_unified_tools_availability(): function test_market_analyst_unified (line 48) | def test_market_analyst_unified(): function test_fundamentals_analyst_unified (line 111) | def test_fundamentals_analyst_unified(): function test_stock_type_routing (line 174) | def test_stock_type_routing(): function main (line 240) | def main(): FILE: tests/test_unified_config.py function test_config_unification (line 18) | def test_config_unification(): function test_web_config_access (line 72) | def test_web_config_access(): function test_config_consistency (line 111) | def test_config_consistency(): function main (line 156) | def main(): FILE: tests/test_unified_fundamentals.py function test_unified_tool_directly (line 10) | def test_unified_tool_directly(): function test_fundamentals_analyst_with_unified_tool (line 72) | def test_fundamentals_analyst_with_unified_tool(): function test_stock_type_detection (line 150) | def test_stock_type_detection(): function main (line 189) | def main(): FILE: tests/test_unified_news_tool.py function test_unified_news_tool (line 18) | def test_unified_news_tool(): FILE: tests/test_us_stock_analysis.py function test_us_stock_market_analysis (line 10) | def test_us_stock_market_analysis(): function test_us_stock_fundamentals_analysis (line 70) | def test_us_stock_fundamentals_analysis(): FILE: tests/test_validation_fix.py function test_hk_validation (line 12) | def test_hk_validation(): function test_specific_case (line 72) | def test_specific_case(): function test_regex_patterns (line 103) | def test_regex_patterns(): function main (line 141) | def main(): FILE: tests/test_valuation_check.py function test_valuation_indicators (line 15) | def test_valuation_indicators(): FILE: tests/test_valuation_simple.py function test_valuation_simple (line 15) | def test_valuation_simple(): FILE: tests/test_volume_mapping_issue.py function test_tushare_adapter_volume_mapping (line 16) | def test_tushare_adapter_volume_mapping(): function test_data_source_manager_volume_access (line 76) | def test_data_source_manager_volume_access(): function test_real_tushare_data (line 123) | def test_real_tushare_data(): function test_column_mapping_logic (line 171) | def test_column_mapping_logic(): function main (line 246) | def main(): FILE: tests/test_vscode_config.py function test_python_environment (line 14) | def test_python_environment(): function test_vscode_settings (line 42) | def test_vscode_settings(): function test_virtual_env_path (line 86) | def test_virtual_env_path(): function test_package_imports (line 117) | def test_package_imports(): function test_project_structure (line 148) | def test_project_structure(): function test_environment_variables (line 185) | def test_environment_variables(): function test_simple_functionality (line 216) | def test_simple_functionality(): function main (line 241) | def main(): FILE: tests/test_web_api_akshare.py function test_akshare_web_api (line 19) | def test_akshare_web_api(): FILE: tests/test_web_config_page.py function test_config_page_import (line 13) | def test_config_page_import(): function test_config_manager_import (line 28) | def test_config_manager_import(): function test_streamlit_components (line 54) | def test_streamlit_components(): function main (line 74) | def main(): FILE: tests/test_web_fix.py function test_render_decision_summary (line 14) | def test_render_decision_summary(): function test_currency_detection (line 77) | def test_currency_detection(): FILE: tests/test_web_hk.py function test_analysis_form_hk_support (line 12) | def test_analysis_form_hk_support(): function test_analysis_runner_hk_support (line 32) | def test_analysis_runner_hk_support(): function test_stock_symbol_formatting (line 113) | def test_stock_symbol_formatting(): function test_market_type_integration (line 152) | def test_market_type_integration(): function main (line 198) | def main(): FILE: tests/test_web_interface.py function test_web_interface_config (line 18) | def test_web_interface_config(): function test_model_options (line 67) | def test_model_options(): function test_api_requirements (line 93) | def test_api_requirements(): function main (line 124) | def main(): FILE: tests/test_workflow_integration.py class MockLLM (line 10) | class MockLLM: method __init__ (line 12) | def __init__(self): method bind_tools (line 16) | def bind_tools(self, tools): method invoke (line 21) | def invoke(self, message): class MockToolkit (line 29) | class MockToolkit: method get_realtime_stock_news (line 31) | def get_realtime_stock_news(self, params): method get_google_news (line 33) | def get_google_news(self, params): method get_global_news_openai (line 35) | def get_global_news_openai(self, params): function test_news_analyst_integration (line 38) | def test_news_analyst_integration(): FILE: tests/tradingagents/test_app_cache_toggle.py class DummyDBManager (line 10) | class DummyDBManager: method __init__ (line 11) | def __init__(self, available: bool = True): method is_mongodb_available (line 14) | def is_mongodb_available(self) -> bool: method get_mongodb_client (line 17) | def get_mongodb_client(self): function clear_env_and_modules (line 22) | def clear_env_and_modules(monkeypatch): function test_basics_prefers_app_cache_when_enabled (line 34) | def test_basics_prefers_app_cache_when_enabled(monkeypatch): function test_basics_fallback_to_api_when_cache_miss (line 65) | def test_basics_fallback_to_api_when_cache_miss(monkeypatch): function test_basics_direct_first_when_disabled (line 97) | def test_basics_direct_first_when_disabled(monkeypatch): function test_realtime_quotes_prefers_app_market_quotes (line 130) | def test_realtime_quotes_prefers_app_market_quotes(monkeypatch): FILE: tests/unit/dataflows/test_unified_dataframe.py function test_unified_dataframe_prefers_tushare_then_akshare_then_baostock (line 7) | def test_unified_dataframe_prefers_tushare_then_akshare_then_baostock(): function test_unified_dataframe_fallback_to_baostock_when_others_fail (line 31) | def test_unified_dataframe_fallback_to_baostock_when_others_fail(): FILE: tests/unit/test_stocks_kline_news_api.py function create_test_app (line 11) | def create_test_app(): function client (line 25) | def client(): function test_kline_ok_source_and_adj (line 31) | def test_kline_ok_source_and_adj(client): function test_kline_invalid_period_returns_400 (line 51) | def test_kline_invalid_period_returns_400(client): function test_news_ok_with_announcements_and_source (line 59) | def test_news_ok_with_announcements_and_source(client): FILE: tests/unit/tools/analysis/test_indicators_uil.py function make_df (line 11) | def make_df(n=60, seed=42): function test_compute_many_basic_columns (line 23) | def test_compute_many_basic_columns(): function test_no_inplace_modification (line 46) | def test_no_inplace_modification(): FILE: tests/verify_mongodb_data.py function get_mongodb_config (line 25) | def get_mongodb_config() -> Dict[str, Any]: function connect_mongodb (line 36) | def connect_mongodb(): function verify_stock_data (line 69) | def verify_stock_data(db): function main (line 167) | def main(): FILE: tradingagents/agents/analysts/china_market_analyst.py function _get_company_name_for_china_market (line 13) | def _get_company_name_for_china_market(ticker: str, market_info: dict) -... function create_china_market_analyst (line 91) | def create_china_market_analyst(llm, toolkit): function create_china_stock_screener (line 212) | def create_china_stock_screener(llm, toolkit): FILE: tradingagents/agents/analysts/fundamentals_analyst.py function _get_company_name_for_fundamentals (line 20) | def _get_company_name_for_fundamentals(ticker: str, market_info: dict) -... function create_fundamentals_analyst (line 98) | def create_fundamentals_analyst(llm, toolkit): FILE: tradingagents/agents/analysts/market_analyst.py function _get_company_name (line 17) | def _get_company_name(ticker: str, market_info: dict) -> str: function create_market_analyst (line 95) | def create_market_analyst(llm, toolkit): FILE: tradingagents/agents/analysts/news_analyst.py function create_news_analyst (line 19) | def create_news_analyst(llm, toolkit): FILE: tradingagents/agents/analysts/social_media_analyst.py function _get_company_name_for_social_media (line 14) | def _get_company_name_for_social_media(ticker: str, market_info: dict) -... function create_social_media_analyst (line 92) | def create_social_media_analyst(llm, toolkit): FILE: tradingagents/agents/managers/research_manager.py function create_research_manager (line 9) | def create_research_manager(llm, memory): FILE: tradingagents/agents/managers/risk_manager.py function create_risk_manager (line 9) | def create_risk_manager(llm, memory): FILE: tradingagents/agents/researchers/bear_researcher.py function create_bear_researcher (line 10) | def create_bear_researcher(llm, memory): FILE: tradingagents/agents/researchers/bull_researcher.py function create_bull_researcher (line 10) | def create_bull_researcher(llm, memory): FILE: tradingagents/agents/risk_mgmt/aggresive_debator.py function create_risky_debator (line 9) | def create_risky_debator(llm): FILE: tradingagents/agents/risk_mgmt/conservative_debator.py function create_safe_debator (line 10) | def create_safe_debator(llm): FILE: tradingagents/agents/risk_mgmt/neutral_debator.py function create_neutral_debator (line 9) | def create_neutral_debator(llm): FILE: tradingagents/agents/trader/trader.py function create_trader (line 10) | def create_trader(llm, memory): FILE: tradingagents/agents/utils/agent_states.py class InvestDebateState (line 15) | class InvestDebateState(TypedDict): class RiskDebateState (line 29) | class RiskDebateState(TypedDict): class AgentState (line 54) | class AgentState(MessagesState): FILE: tradingagents/agents/utils/agent_utils.py function create_msg_delete (line 26) | def create_msg_delete(): class Toolkit (line 42) | class Toolkit: method update_config (line 46) | def update_config(cls, config): method config (line 51) | def config(self): method __init__ (line 55) | def __init__(self, config=None): method get_reddit_news (line 61) | def get_reddit_news( method get_finnhub_news (line 78) | def get_finnhub_news( method get_reddit_stock_info (line 110) | def get_reddit_stock_info( method get_chinese_social_sentiment (line 132) | def get_chinese_social_sentiment( method get_china_stock_data (line 155) | def get_china_stock_data( method get_china_market_overview (line 200) | def get_china_market_overview( method get_YFin_data (line 241) | def get_YFin_data( method get_YFin_data_online (line 262) | def get_YFin_data_online( method get_stockstats_indicators_report (line 283) | def get_stockstats_indicators_report( method get_stockstats_indicators_report_online (line 312) | def get_stockstats_indicators_report_online( method get_finnhub_company_insider_sentiment (line 341) | def get_finnhub_company_insider_sentiment( method get_finnhub_company_insider_transactions (line 365) | def get_finnhub_company_insider_transactions( method get_simfin_balance_sheet (line 389) | def get_simfin_balance_sheet( method get_simfin_cashflow (line 413) | def get_simfin_cashflow( method get_simfin_income_stmt (line 437) | def get_simfin_income_stmt( method get_google_news (line 463) | def get_google_news( method get_realtime_stock_news (line 483) | def get_realtime_stock_news( method get_stock_news_openai (line 504) | def get_stock_news_openai( method get_global_news_openai (line 523) | def get_global_news_openai( method get_fundamentals_openai (line 540) | def get_fundamentals_openai( method get_china_fundamentals (line 593) | def get_china_fundamentals( method get_hk_stock_data_unified (line 657) | def get_hk_stock_data_unified( method get_stock_fundamentals_unified (line 695) | def get_stock_fundamentals_unified( method get_stock_market_data_unified (line 1044) | def get_stock_market_data_unified( method get_stock_news_unified (line 1156) | def get_stock_news_unified( method get_stock_sentiment_unified (line 1290) | def get_stock_sentiment_unified( FILE: tradingagents/agents/utils/chromadb_config.py function is_windows_11 (line 11) | def is_windows_11() -> bool: function get_win10_chromadb_client (line 36) | def get_win10_chromadb_client(): function get_win11_chromadb_client (line 66) | def get_win11_chromadb_client(): function get_optimal_chromadb_client (line 97) | def get_optimal_chromadb_client(): FILE: tradingagents/agents/utils/google_tool_handler.py class GoogleToolCallHandler (line 17) | class GoogleToolCallHandler: method is_google_model (line 21) | def is_google_model(llm) -> bool: method handle_google_tool_calls (line 26) | def handle_google_tool_calls( method _get_tool_name (line 356) | def _get_tool_name(tool): method _validate_tool_call (line 366) | def _validate_tool_call(tool_call, index, analyst_name): method _fix_tool_call (line 406) | def _fix_tool_call(tool_call, index, analyst_name): method handle_simple_google_response (line 468) | def handle_simple_google_response( method generate_final_analysis_report (line 498) | def generate_final_analysis_report(llm, messages: List, analyst_name: ... method _optimize_message_sequence (line 630) | def _optimize_message_sequence(messages: List, analysis_prompt: str) -... method _generate_fallback_report (line 683) | def _generate_fallback_report(messages: List, analyst_name: str) -> str: method create_analysis_prompt (line 714) | def create_analysis_prompt( FILE: tradingagents/agents/utils/memory.py class ChromaDBManager (line 16) | class ChromaDBManager: method __new__ (line 24) | def __new__(cls): method __init__ (line 32) | def __init__(self): method get_or_create_collection (line 69) | def get_or_create_collection(self, name: str): class FinancialSituationMemory (line 99) | class FinancialSituationMemory: method __init__ (line 100) | def __init__(self, name, config): method _smart_text_truncation (line 313) | def _smart_text_truncation(self, text, max_length=8192): method get_embedding (line 351) | def get_embedding(self, text): method get_embedding_config_status (line 545) | def get_embedding_config_status(self): method get_last_text_info (line 555) | def get_last_text_info(self): method add_situations (line 559) | def add_situations(self, situations_and_advice): method get_memories (line 582) | def get_memories(self, current_situation, n_matches=1): method get_cache_info (line 642) | def get_cache_info(self): FILE: tradingagents/api/stock_api.py function get_stock_info (line 33) | def get_stock_info(stock_code: str) -> Dict[str, Any]: function get_all_stocks (line 66) | def get_all_stocks() -> List[Dict[str, Any]]: function get_stock_data (line 94) | def get_stock_data(stock_code: str, start_date: str = None, end_date: st... function search_stocks (line 123) | def search_stocks(keyword: str) -> List[Dict[str, Any]]: function get_market_summary (line 159) | def get_market_summary() -> Dict[str, Any]: function check_service_status (line 206) | def check_service_status() -> Dict[str, Any]: FILE: tradingagents/config/config_manager.py class ConfigManager (line 61) | class ConfigManager: method __init__ (line 64) | def __init__(self, config_dir: str = "config"): method _load_env_file (line 82) | def _load_env_file(self): method _get_env_api_key (line 98) | def _get_env_api_key(self, provider: str) -> str: method validate_openai_api_key_format (line 119) | def validate_openai_api_key_format(self, api_key: str) -> bool: method _init_mongodb_storage (line 152) | def _init_mongodb_storage(self): method _init_default_configs (line 197) | def _init_default_configs(self): method load_models (line 302) | def load_models(self) -> List[ModelConfig]: method save_models (line 338) | def save_models(self, models: List[ModelConfig]): method load_pricing (line 347) | def load_pricing(self) -> List[PricingConfig]: method save_pricing (line 357) | def save_pricing(self, pricing: List[PricingConfig]): method load_usage_records (line 366) | def load_usage_records(self) -> List[UsageRecord]: method save_usage_records (line 378) | def save_usage_records(self, records: List[UsageRecord]): method add_usage_record (line 387) | def add_usage_record(self, provider: str, model_name: str, input_token... method calculate_cost (line 441) | def calculate_cost(self, provider: str, model_name: str, input_tokens:... method load_settings (line 465) | def load_settings(self) -> Dict[str, Any]: method get_env_config_status (line 520) | def get_env_config_status(self) -> Dict[str, Any]: method save_settings (line 538) | def save_settings(self, settings: Dict[str, Any]): method get_enabled_models (line 546) | def get_enabled_models(self) -> List[ModelConfig]: method get_model_by_name (line 551) | def get_model_by_name(self, provider: str, model_name: str) -> Optiona... method get_usage_statistics (line 559) | def get_usage_statistics(self, days: int = 30) -> Dict[str, Any]: method get_data_dir (line 623) | def get_data_dir(self) -> str: method set_data_dir (line 632) | def set_data_dir(self, data_dir: str): method ensure_directories_exist (line 644) | def ensure_directories_exist(self): method set_openai_enabled (line 666) | def set_openai_enabled(self, enabled: bool): method is_openai_enabled (line 673) | def is_openai_enabled(self) -> bool: method get_openai_config_status (line 678) | def get_openai_config_status(self) -> Dict[str, Any]: class TokenTracker (line 692) | class TokenTracker: method __init__ (line 695) | def __init__(self, config_manager: ConfigManager): method track_usage (line 698) | def track_usage(self, provider: str, model_name: str, input_tokens: int, method _check_cost_alert (line 727) | def _check_cost_alert(self, current_cost: float): method get_session_cost (line 740) | def get_session_cost(self, session_id: str) -> float: method estimate_cost (line 746) | def estimate_cost(self, provider: str, model_name: str, estimated_inpu... function _get_project_config_dir (line 762) | def _get_project_config_dir(): FILE: tradingagents/config/database_config.py class DatabaseConfig (line 11) | class DatabaseConfig: method get_mongodb_config (line 15) | def get_mongodb_config() -> Dict[str, Any]: method get_redis_config (line 39) | def get_redis_config() -> Dict[str, Any]: method validate_config (line 76) | def validate_config() -> Dict[str, bool]: method get_config_status (line 103) | def get_config_status() -> str: FILE: tradingagents/config/database_manager.py class DatabaseManager (line 13) | class DatabaseManager: method __init__ (line 16) | def __init__(self): method _load_env_config (line 36) | def _load_env_config(self): method _detect_mongodb (line 85) | def _detect_mongodb(self) -> Tuple[bool, str]: method _detect_redis (line 125) | def _detect_redis(self) -> Tuple[bool, str]: method _detect_databases (line 159) | def _detect_databases(self): method _update_config_based_on_detection (line 184) | def _update_config_based_on_detection(self): method _initialize_connections (line 196) | def _initialize_connections(self): method get_mongodb_client (line 249) | def get_mongodb_client(self): method get_mongodb_db (line 255) | def get_mongodb_db(self): method get_redis_client (line 262) | def get_redis_client(self): method is_mongodb_available (line 268) | def is_mongodb_available(self) -> bool: method is_redis_available (line 272) | def is_redis_available(self) -> bool: method is_database_available (line 276) | def is_database_available(self) -> bool: method get_cache_backend (line 280) | def get_cache_backend(self) -> str: method get_config (line 284) | def get_config(self) -> Dict[str, Any]: method get_status_report (line 308) | def get_status_report(self) -> Dict[str, Any]: method get_cache_stats (line 326) | def get_cache_stats(self) -> Dict[str, Any]: method cache_clear_pattern (line 346) | def cache_clear_pattern(self, pattern: str) -> int: function get_database_manager (line 364) | def get_database_manager() -> DatabaseManager: function is_mongodb_available (line 371) | def is_mongodb_available() -> bool: function is_redis_available (line 375) | def is_redis_available() -> bool: function get_cache_backend (line 379) | def get_cache_backend() -> str: function get_mongodb_client (line 383) | def get_mongodb_client(): function get_redis_client (line 387) | def get_redis_client(): FILE: tradingagents/config/env_utils.py function parse_bool_env (line 11) | def parse_bool_env(env_var: str, default: bool = False) -> bool: function parse_int_env (line 67) | def parse_int_env(env_var: str, default: int = 0) -> int: function parse_float_env (line 90) | def parse_float_env(env_var: str, default: float = 0.0) -> float: function parse_str_env (line 113) | def parse_str_env(env_var: str, default: str = "") -> str: function parse_list_env (line 132) | def parse_list_env(env_var: str, separator: str = ",", default: Optional... function get_env_info (line 162) | def get_env_info(env_var: str) -> dict: function validate_required_env_vars (line 184) | def validate_required_env_vars(required_vars: list) -> dict: function get_bool_env (line 217) | def get_bool_env(env_var: str, default: bool = False) -> bool: function get_int_env (line 222) | def get_int_env(env_var: str, default: int = 0) -> int: function get_str_env (line 227) | def get_str_env(env_var: str, default: str = "") -> str: FILE: tradingagents/config/mongodb_storage.py class MongoDBStorage (line 28) | class MongoDBStorage: method __init__ (line 31) | def __init__(self, connection_string: str = None, database_name: str =... method _connect (line 56) | def _connect(self): method _create_indexes (line 91) | def _create_indexes(self): method is_connected (line 110) | def is_connected(self) -> bool: method save_usage_record (line 114) | def save_usage_record(self, record: UsageRecord) -> bool: method load_usage_records (line 147) | def load_usage_records(self, limit: int = 10000, days: int = None) -> ... method get_usage_statistics (line 183) | def get_usage_statistics(self, days: int = 30) -> Dict[str, Any]: method get_provider_statistics (line 234) | def get_provider_statistics(self, days: int = 30) -> Dict[str, Dict[st... method cleanup_old_records (line 279) | def cleanup_old_records(self, days: int = 90) -> int: method close (line 303) | def close(self): FILE: tradingagents/config/providers_config.py class DataSourceConfig (line 14) | class DataSourceConfig: method __init__ (line 17) | def __init__(self): method _load_configs (line 21) | def _load_configs(self): method get_provider_config (line 83) | def get_provider_config(self, provider_name: str) -> Dict[str, Any]: method is_provider_enabled (line 98) | def is_provider_enabled(self, provider_name: str) -> bool: method get_all_enabled_providers (line 103) | def get_all_enabled_providers(self) -> list: method _get_bool_env (line 111) | def _get_bool_env(self, key: str, default: bool) -> bool: method _get_int_env (line 116) | def _get_int_env(self, key: str, default: int) -> int: method _get_float_env (line 123) | def _get_float_env(self, key: str, default: float) -> float: function get_data_source_config (line 134) | def get_data_source_config() -> DataSourceConfig: function get_provider_config (line 141) | def get_provider_config(provider_name: str) -> Dict[str, Any]: FILE: tradingagents/config/runtime_settings.py function _get_event_loop_running (line 20) | def _get_event_loop_running() -> bool: function _get_system_settings_sync (line 33) | def _get_system_settings_sync() -> dict: function _coerce (line 91) | def _coerce(value: Any, caster: Callable[[Any], Any], default: Any) -> Any: function get_number (line 100) | def get_number(env_var: str, system_key: Optional[str], default: float |... function get_float (line 122) | def get_float(env_var: str, system_key: Optional[str], default: float) -... function get_int (line 126) | def get_int(env_var: str, system_key: Optional[str], default: int) -> int: function get_bool (line 132) | def get_bool(env_var: str, system_key: Optional[str], default: bool) -> ... function use_app_cache_enabled (line 153) | def use_app_cache_enabled(default: bool = False) -> bool: function get_timezone_name (line 184) | def get_timezone_name(default: str = "Asia/Shanghai") -> str: function get_zoneinfo (line 206) | def get_zoneinfo(default: str = "Asia/Shanghai") -> _ZoneInfo: FILE: tradingagents/config/tushare_config.py class TushareConfig (line 12) | class TushareConfig: method __init__ (line 15) | def __init__(self): method load_config (line 19) | def load_config(self): method _debug_config (line 40) | def _debug_config(self): method is_valid (line 48) | def is_valid(self) -> bool: method get_validation_result (line 62) | def get_validation_result(self) -> Dict[str, Any]: method get_env_debug_info (line 92) | def get_env_debug_info(self) -> Dict[str, Any]: method test_boolean_parsing (line 107) | def test_boolean_parsing(self) -> Dict[str, Any]: method fix_common_issues (line 148) | def fix_common_issues(self) -> Dict[str, str]: function get_tushare_config (line 160) | def get_tushare_config() -> TushareConfig: function check_tushare_compatibility (line 165) | def check_tushare_compatibility() -> Dict[str, Any]: function diagnose_tushare_issues (line 178) | def diagnose_tushare_issues(): FILE: tradingagents/config/usage_models.py class UsageRecord (line 12) | class UsageRecord: class ModelConfig (line 26) | class ModelConfig: class PricingConfig (line 38) | class PricingConfig: FILE: tradingagents/constants/data_sources.py class DataSourceCode (line 17) | class DataSourceCode(str, Enum): class DataSourceInfo (line 56) | class DataSourceInfo: method __post_init__ (line 70) | def __post_init__(self): function get_data_source_info (line 282) | def get_data_source_info(code: str) -> Optional[DataSourceInfo]: function list_all_data_sources (line 295) | def list_all_data_sources() -> List[DataSourceInfo]: function list_data_sources_by_market (line 305) | def list_data_sources_by_market(market: str) -> List[DataSourceInfo]: function list_free_data_sources (line 321) | def list_free_data_sources() -> List[DataSourceInfo]: function is_data_source_supported (line 334) | def is_data_source_supported(code: str) -> bool: FILE: tradingagents/dataflows/cache/__init__.py function get_cache (line 80) | def get_cache() -> Union[StockDataCache, IntegratedCacheManager]: FILE: tradingagents/dataflows/cache/adaptive.py class AdaptiveCacheSystem (line 19) | class AdaptiveCacheSystem: method __init__ (line 22) | def __init__(self, cache_dir: str = None): method _get_cache_key (line 45) | def _get_cache_key(self, symbol: str, start_date: str = "", end_date: ... method _get_ttl_seconds (line 51) | def _get_ttl_seconds(self, symbol: str, data_type: str = "stock_data")... method _is_cache_valid (line 64) | def _is_cache_valid(self, cache_time: datetime, ttl_seconds: int) -> b... method _save_to_file (line 72) | def _save_to_file(self, cache_key: str, data: Any, metadata: Dict) -> ... method _load_from_file (line 93) | def _load_from_file(self, cache_key: str) -> Optional[Dict]: method _save_to_redis (line 110) | def _save_to_redis(self, cache_key: str, data: Any, metadata: Dict, tt... method _load_from_redis (line 134) | def _load_from_redis(self, cache_key: str) -> Optional[Dict]: method _save_to_mongodb (line 158) | def _save_to_mongodb(self, cache_key: str, data: Any, metadata: Dict, ... method _load_from_mongodb (line 195) | def _load_from_mongodb(self, cache_key: str) -> Optional[Dict]: method save_data (line 234) | def save_data(self, symbol: str, data: Any, start_date: str = "", end_... method load_data (line 274) | def load_data(self, cache_key: str) -> Optional[Any]: method find_cached_data (line 306) | def find_cached_data(self, symbol: str, start_date: str = "", end_date... method get_cache_stats (line 317) | def get_cache_stats(self) -> Dict[str, Any]: method clear_expired_cache (line 404) | def clear_expired_cache(self): function get_cache_system (line 435) | def get_cache_system() -> AdaptiveCacheSystem: FILE: tradingagents/dataflows/cache/app_adapter.py function get_basics_from_cache (line 29) | def get_basics_from_cache(stock_code: Optional[str] = None) -> Optional[... function get_market_quote_dataframe (line 73) | def get_market_quote_dataframe(symbol: str) -> Optional[pd.DataFrame]: FILE: tradingagents/dataflows/cache/db_cache.py class DatabaseCacheManager (line 41) | class DatabaseCacheManager: method __init__ (line 44) | def __init__(self, method _init_mongodb (line 81) | def _init_mongodb(self): method _init_redis (line 114) | def _init_redis(self): method _create_mongodb_indexes (line 136) | def _create_mongodb_indexes(self): method _generate_cache_key (line 175) | def _generate_cache_key(self, data_type: str, symbol: str, **kwargs) -... method save_stock_data (line 184) | def save_stock_data(self, symbol: str, data: Union[pd.DataFrame, str], method load_stock_data (line 267) | def load_stock_data(self, cache_key: str) -> Optional[Union[pd.DataFra... method find_cached_stock_data (line 323) | def find_cached_stock_data(self, symbol: str, start_date: str = None, method save_news_data (line 370) | def save_news_data(self, symbol: str, news_data: str, method save_fundamentals_data (line 421) | def save_fundamentals_data(self, symbol: str, fundamentals_data: str, method get_cache_stats (line 473) | def get_cache_stats(self) -> Dict[str, Any]: method clear_old_cache (line 538) | def clear_old_cache(self, max_age_days: int = 7): method close (line 558) | def close(self): function get_db_cache (line 572) | def get_db_cache() -> DatabaseCacheManager: FILE: tradingagents/dataflows/cache/file_cache.py class StockDataCache (line 21) | class StockDataCache: method __init__ (line 24) | def __init__(self, cache_dir: str = None): method _determine_market_type (line 100) | def _determine_market_type(self, symbol: str) -> str: method _check_provider_availability (line 110) | def _check_provider_availability(self) -> List[str]: method should_skip_cache_for_content (line 138) | def should_skip_cache_for_content(self, content: str, data_type: str =... method _generate_cache_key (line 176) | def _generate_cache_key(self, data_type: str, symbol: str, **kwargs) -... method _get_cache_path (line 187) | def _get_cache_path(self, data_type: str, cache_key: str, file_format:... method _get_metadata_path (line 207) | def _get_metadata_path(self, cache_key: str) -> Path: method _save_metadata (line 211) | def _save_metadata(self, cache_key: str, metadata: Dict[str, Any]): method _load_metadata (line 220) | def _load_metadata(self, cache_key: str) -> Optional[Dict[str, Any]]: method is_cache_valid (line 233) | def is_cache_valid(self, cache_key: str, max_age_hours: int = None, sy... method save_stock_data (line 266) | def save_stock_data(self, symbol: str, data: Union[pd.DataFrame, str], method load_stock_data (line 334) | def load_stock_data(self, cache_key: str) -> Optional[Union[pd.DataFra... method find_cached_stock_data (line 354) | def find_cached_stock_data(self, symbol: str, start_date: str = None, method save_news_data (line 413) | def save_news_data(self, symbol: str, news_data: str, method save_fundamentals_data (line 453) | def save_fundamentals_data(self, symbol: str, fundamentals_data: str, method load_fundamentals_data (line 494) | def load_fundamentals_data(self, cache_key: str) -> Optional[str]: method find_cached_fundamentals_data (line 511) | def find_cached_fundamentals_data(self, symbol: str, data_source: str ... method clear_old_cache (line 554) | def clear_old_cache(self, max_age_days: int = 7): method get_cache_stats (line 580) | def get_cache_stats(self) -> Dict[str, Any]: method get_content_length_config_status (line 659) | def get_content_length_config_status(self) -> Dict[str, Any]: function get_cache (line 680) | def get_cache() -> StockDataCache: FILE: tradingagents/dataflows/cache/integrated.py class IntegratedCacheManager (line 30) | class IntegratedCacheManager: method __init__ (line 33) | def __init__(self, cache_dir: str = None): method _log_cache_status (line 58) | def _log_cache_status(self): method save_stock_data (line 73) | def save_stock_data(self, symbol: str, data: Any, start_date: str = None, method load_stock_data (line 108) | def load_stock_data(self, cache_key: str) -> Optional[Any]: method find_cached_stock_data (line 125) | def find_cached_stock_data(self, symbol: str, start_date: str = None, method save_news_data (line 157) | def save_news_data(self, symbol: str, data: Any, data_source: str = "d... method load_news_data (line 169) | def load_news_data(self, cache_key: str) -> Optional[Any]: method save_fundamentals_data (line 176) | def save_fundamentals_data(self, symbol: str, data: Any, data_source: ... method load_fundamentals_data (line 188) | def load_fundamentals_data(self, cache_key: str) -> Optional[Any]: method find_cached_fundamentals_data (line 195) | def find_cached_fundamentals_data(self, symbol: str, data_source: str ... method is_fundamentals_cache_valid (line 214) | def is_fundamentals_cache_valid(self, symbol: str, data_source: str = ... method get_cache_stats (line 230) | def get_cache_stats(self) -> Dict[str, Any]: method clear_expired_cache (line 265) | def clear_expired_cache(self): method clear_old_cache (line 273) | def clear_old_cache(self, max_age_days: int = 7): method get_cache_backend_info (line 339) | def get_cache_backend_info(self) -> Dict[str, Any]: method is_database_available (line 358) | def is_database_available(self) -> bool: method get_performance_mode (line 364) | def get_performance_mode(self) -> str: function get_cache (line 385) | def get_cache() -> IntegratedCacheManager: function get_stock_cache (line 393) | def get_stock_cache(): function create_cache_manager (line 397) | def create_cache_manager(cache_dir: str = None): FILE: tradingagents/dataflows/cache/mongodb_cache_adapter.py class MongoDBCacheAdapter (line 18) | class MongoDBCacheAdapter: method __init__ (line 21) | def __init__(self): method _init_mongodb_connection (line 32) | def _init_mongodb_connection(self): method get_stock_basic_info (line 47) | def get_stock_basic_info(self, symbol: str) -> Optional[Dict[str, Any]]: method _get_data_source_priority (line 81) | def _get_data_source_priority(self, symbol: str) -> list: method get_historical_data (line 160) | def get_historical_data(self, symbol: str, start_date: str = None, end... method get_financial_data (line 221) | def get_financial_data(self, symbol: str, report_period: str = None) -... method get_news_data (line 259) | def get_news_data(self, symbol: str = None, hours_back: int = 24, limi... method get_social_media_data (line 293) | def get_social_media_data(self, symbol: str = None, hours_back: int = ... method get_market_quotes (line 327) | def get_market_quotes(self, symbol: str) -> Optional[Dict[str, Any]]: function get_mongodb_cache_adapter (line 354) | def get_mongodb_cache_adapter() -> MongoDBCacheAdapter: function get_enhanced_data_adapter (line 362) | def get_enhanced_data_adapter() -> MongoDBCacheAdapter: function get_stock_data_with_fallback (line 367) | def get_stock_data_with_fallback(symbol: str, start_date: str = None, en... function get_financial_data_with_fallback (line 398) | def get_financial_data_with_fallback(symbol: str, fallback_func=None) ->... FILE: tradingagents/dataflows/data_completeness_checker.py class DataCompletenessChecker (line 15) | class DataCompletenessChecker: method __init__ (line 18) | def __init__(self): method check_data_completeness (line 21) | def check_data_completeness( method _parse_data_to_dataframe (line 153) | def _parse_data_to_dataframe(self, data: str) -> Optional[pd.DataFrame]: method _get_latest_trade_date (line 189) | def _get_latest_trade_date(self, market: str = "CN") -> Optional[str]: method _check_data_gaps (line 222) | def _check_data_gaps(self, df: pd.DataFrame, date_col: str) -> List[str]: function get_data_completeness_checker (line 250) | def get_data_completeness_checker() -> DataCompletenessChecker: FILE: tradingagents/dataflows/data_source_manager.py class ChinaDataSource (line 28) | class ChinaDataSource(Enum): class USDataSource (line 41) | class USDataSource(Enum): class DataSourceManager (line 57) | class DataSourceManager: method __init__ (line 60) | def __init__(self): method _check_mongodb_enabled (line 86) | def _check_mongodb_enabled(self) -> bool: method _get_data_source_priority_order (line 91) | def _get_data_source_priority_order(self, symbol: Optional[str] = None... method _identify_market_category (line 173) | def _identify_market_category(self, symbol: Optional[str]) -> Optional... method _get_default_source (line 206) | def _get_default_source(self) -> ChinaDataSource: method get_china_stock_data_tushare (line 226) | def get_china_stock_data_tushare(self, symbol: str, start_date: str, e... method get_fundamentals_data (line 249) | def get_fundamentals_data(self, symbol: str) -> str: method get_china_stock_fundamentals_tushare (line 316) | def get_china_stock_fundamentals_tushare(self, symbol: str) -> str: method get_news_data (line 329) | def get_news_data(self, symbol: str = None, hours_back: int = 24, limi... method _check_available_sources (line 402) | def _check_available_sources(self) -> List[ChinaDataSource]: method _get_datasource_configs_from_db (line 509) | def _get_datasource_configs_from_db(self) -> dict: method get_current_source (line 538) | def get_current_source(self) -> ChinaDataSource: method set_current_source (line 542) | def set_current_source(self, source: ChinaDataSource) -> bool: method get_data_adapter (line 552) | def get_data_adapter(self): method _get_mongodb_adapter (line 566) | def _get_mongodb_adapter(self): method _get_tushare_adapter (line 575) | def _get_tushare_adapter(self): method _get_akshare_adapter (line 584) | def _get_akshare_adapter(self): method _get_baostock_adapter (line 593) | def _get_baostock_adapter(self): method _get_cached_data (line 608) | def _get_cached_data(self, symbol: str, start_date: str = None, end_da... method _save_to_cache (line 642) | def _save_to_cache(self, symbol: str, data: pd.DataFrame, start_date: ... method _get_volume_safely (line 662) | def _get_volume_safely(self, data: pd.DataFrame) -> float: method _format_stock_data_response (line 682) | def _format_stock_data_response(self, data: pd.DataFrame, symbol: str,... method get_stock_dataframe (line 911) | def get_stock_dataframe(self, symbol: str, start_date: str = None, end... method _standardize_dataframe (line 987) | def _standardize_dataframe(self, df: pd.DataFrame) -> pd.DataFrame: method get_stock_data (line 1031) | def get_stock_data(self, symbol: str, start_date: str = None, end_date... method _get_mongodb_data (line 1143) | def _get_mongodb_data(self, symbol: str, start_date: str, end_date: st... method _get_tushare_data (line 1183) | def _get_tushare_data(self, symbol: str, start_date: str, end_date: st... method _get_akshare_data (line 1275) | def _get_akshare_data(self, symbol: str, start_date: str, end_date: st... method _get_baostock_data (line 1323) | def _get_baostock_data(self, symbol: str, start_date: str, end_date: s... method _get_volume_safely (line 1363) | def _get_volume_safely(self, data) -> float: method _try_fallback_sources (line 1382) | def _try_fallback_sources(self, symbol: str, start_date: str, end_date... method get_stock_info (line 1425) | def get_stock_info(self, symbol: str) -> Dict: method get_stock_basic_info (line 1535) | def get_stock_basic_info(self, stock_code: str = None) -> Optional[Dic... method get_stock_data_with_fallback (line 1575) | def get_stock_data_with_fallback(self, stock_code: str, start_date: st... method _try_fallback_stock_info (line 1596) | def _try_fallback_stock_info(self, symbol: str) -> Dict: method _get_akshare_stock_info (line 1649) | def _get_akshare_stock_info(self, symbol: str) -> Dict: method _get_baostock_stock_info (line 1708) | def _get_baostock_stock_info(self, symbol: str) -> Dict: method _parse_stock_info_string (line 1757) | def _parse_stock_info_string(self, info_str: str, symbol: str) -> Dict: method _get_mongodb_fundamentals (line 1788) | def _get_mongodb_fundamentals(self, symbol: str) -> str: method _get_tushare_fundamentals (line 1836) | def _get_tushare_fundamentals(self, symbol: str) -> str: method _get_akshare_fundamentals (line 1841) | def _get_akshare_fundamentals(self, symbol: str) -> str: method _get_valuation_indicators (line 1854) | def _get_valuation_indicators(self, symbol: str) -> Dict: method _format_financial_data (line 1882) | def _format_financial_data(self, symbol: str, financial_data: List[Dic... method _generate_fundamentals_analysis (line 1997) | def _generate_fundamentals_analysis(self, symbol: str) -> str: method _try_fallback_fundamentals (line 2019) | def _try_fallback_fundamentals(self, symbol: str) -> str: method _get_mongodb_news (line 2053) | def _get_mongodb_news(self, symbol: str, hours_back: int, limit: int) ... method _get_tushare_news (line 2073) | def _get_tushare_news(self, symbol: str, hours_back: int, limit: int) ... method _get_akshare_news (line 2084) | def _get_akshare_news(self, symbol: str, hours_back: int, limit: int) ... method _try_fallback_news (line 2095) | def _try_fallback_news(self, symbol: str, hours_back: int, limit: int)... function get_data_source_manager (line 2133) | def get_data_source_manager() -> DataSourceManager: function get_china_stock_data_unified (line 2141) | def get_china_stock_data_unified(symbol: str, start_date: str, end_date:... function get_china_stock_info_unified (line 2178) | def get_china_stock_info_unified(symbol: str) -> Dict: function get_data_source_manager (line 2195) | def get_data_source_manager() -> DataSourceManager: function get_stock_data_service (line 2205) | def get_stock_data_service() -> DataSourceManager: class USDataSourceManager (line 2217) | class USDataSourceManager: method __init__ (line 2228) | def __init__(self): method _check_mongodb_enabled (line 2245) | def _check_mongodb_enabled(self) -> bool: method _get_data_source_priority_order (line 2250) | def _get_data_source_priority_order(self, symbol: Optional[str] = None... method _get_default_source (line 2309) | def _get_default_source(self) -> USDataSource: method _check_available_sources (line 2327) | def _check_available_sources(self) -> List[USDataSource]: method _get_enabled_sources_from_db (line 2389) | def _get_enabled_sources_from_db(self) -> List[str]: method _get_datasource_configs_from_db (line 2422) | def _get_datasource_configs_from_db(self) -> dict: method get_current_source (line 2451) | def get_current_source(self) -> USDataSource: method set_current_source (line 2455) | def set_current_source(self, source: USDataSource) -> bool: function get_us_data_source_manager (line 2469) | def get_us_data_source_manager() -> USDataSourceManager: FILE: tradingagents/dataflows/interface.py function get_hk_stock_data_akshare (line 47) | def get_hk_stock_data_akshare(*args, **kwargs): function get_hk_stock_info_akshare (line 49) | def get_hk_stock_info_akshare(*args, **kwargs): function _get_enabled_hk_data_sources (line 55) | def _get_enabled_hk_data_sources() -> list: function _get_enabled_us_data_sources (line 115) | def _get_enabled_us_data_sources() -> list: function get_config (line 210) | def get_config(): function set_config (line 214) | def set_config(config): function get_finnhub_news (line 219) | def get_finnhub_news( function get_finnhub_company_insider_sentiment (line 268) | def get_finnhub_company_insider_sentiment( function get_finnhub_company_insider_transactions (line 309) | def get_finnhub_company_insider_transactions( function get_simfin_balance_sheet (line 351) | def get_simfin_balance_sheet( function get_simfin_cashflow (line 398) | def get_simfin_cashflow( function get_simfin_income_statements (line 445) | def get_simfin_income_statements( function get_google_news (line 492) | def get_google_news( function get_reddit_global_news (line 542) | def get_reddit_global_news( function get_reddit_company_news (line 594) | def get_reddit_company_news( function get_stock_stats_indicators_window (line 653) | def get_stock_stats_indicators_window( function get_stockstats_indicator (line 789) | def get_stockstats_indicator( function get_YFin_data_window (line 818) | def get_YFin_data_window( function get_YFin_data_online (line 859) | def get_YFin_data_online( function get_YFin_data (line 904) | def get_YFin_data( function get_stock_news_openai (line 939) | def get_stock_news_openai(ticker, curr_date): function get_global_news_openai (line 974) | def get_global_news_openai(curr_date): function get_fundamentals_finnhub (line 1009) | def get_fundamentals_finnhub(ticker, curr_date): function get_fundamentals_openai (line 1148) | def get_fundamentals_openai(ticker, curr_date): function _get_fundamentals_alpha_vantage (line 1242) | def _get_fundamentals_alpha_vantage(ticker, curr_date, cache): function _get_fundamentals_yfinance (line 1273) | def _get_fundamentals_yfinance(ticker, curr_date, cache): function _get_fundamentals_openai_impl (line 1347) | def _get_fundamentals_openai_impl(ticker, curr_date, config, cache): function get_china_stock_data_tushare (line 1409) | def get_china_stock_data_tushare( function get_china_stock_info_tushare (line 1443) | def get_china_stock_info_tushare( function get_china_stock_fundamentals_tushare (line 1484) | def get_china_stock_fundamentals_tushare( function get_china_stock_data_unified (line 1514) | def get_china_stock_data_unified( function get_china_stock_info_unified (line 1630) | def get_china_stock_info_unified( function switch_china_data_source (line 1682) | def switch_china_data_source( function get_current_china_data_source (line 1721) | def get_current_china_data_source() -> str: function get_hk_stock_data_unified (line 1748) | def get_hk_stock_data_unified(symbol: str, start_date: str = None, end_d... function get_hk_stock_info_unified (line 1847) | def get_hk_stock_info_unified(symbol: str) -> Dict: function get_stock_data_by_market (line 1909) | def get_stock_data_by_market(symbol: str, start_date: str = None, end_da... FILE: tradingagents/dataflows/news/chinese_finance.py class ChineseFinanceDataAggregator (line 18) | class ChineseFinanceDataAggregator: method __init__ (line 21) | def __init__(self): method get_stock_sentiment_summary (line 28) | def get_stock_sentiment_summary(self, ticker: str, days: int = 7) -> D... method _get_finance_news_sentiment (line 67) | def _get_finance_news_sentiment(self, ticker: str, days: int) -> Dict: method _get_stock_forum_sentiment (line 112) | def _get_stock_forum_sentiment(self, ticker: str, days: int) -> Dict: method _get_media_coverage_sentiment (line 125) | def _get_media_coverage_sentiment(self, ticker: str, days: int) -> Dict: method _search_finance_news (line 151) | def _search_finance_news(self, search_term: str, days: int) -> List[Di... method _get_media_coverage (line 167) | def _get_media_coverage(self, ticker: str, days: int) -> List[Dict]: method _analyze_text_sentiment (line 172) | def _analyze_text_sentiment(self, text: str) -> float: method _get_company_chinese_name (line 189) | def _get_company_chinese_name(self, ticker: str) -> Optional[str]: method _calculate_overall_sentiment (line 202) | def _calculate_overall_sentiment(self, news_sentiment: Dict, forum_sen... method _generate_sentiment_summary (line 238) | def _generate_sentiment_summary(self, overall_sentiment: Dict) -> str: function get_chinese_social_sentiment (line 258) | def get_chinese_social_sentiment(ticker: str, curr_date: str) -> str: FILE: tradingagents/dataflows/news/google_news.py function is_rate_limited (line 25) | def is_rate_limited(response): function make_request (line 35) | def make_request(url, headers): function getNewsData (line 44) | def getNewsData(query, start_date, end_date): FILE: tradingagents/dataflows/news/realtime_news.py class NewsItem (line 26) | class NewsItem: class RealtimeNewsAggregator (line 37) | class RealtimeNewsAggregator: method __init__ (line 40) | def __init__(self): method get_realtime_stock_news (line 50) | def get_realtime_stock_news(self, ticker: str, hours_back: int = 6, ma... method _get_finnhub_realtime_news (line 147) | def _get_finnhub_realtime_news(self, ticker: str, hours_back: int) -> ... method _get_alpha_vantage_news (line 197) | def _get_alpha_vantage_news(self, ticker: str, hours_back: int) -> Lis... method _get_newsapi_news (line 248) | def _get_newsapi_news(self, ticker: str, hours_back: int) -> List[News... method _get_chinese_finance_news (line 303) | def _get_chinese_finance_news(self, ticker: str, hours_back: int) -> L... method _parse_rss_feed (line 434) | def _parse_rss_feed(self, rss_url: str, ticker: str, hours_back: int) ... method _assess_news_urgency (line 505) | def _assess_news_urgency(self, title: str, content: str) -> str: method _calculate_relevance (line 536) | def _calculate_relevance(self, title: str, ticker: str) -> float: method _deduplicate_news (line 571) | def _deduplicate_news(self, news_items: List[NewsItem]) -> List[NewsIt... method format_news_report (line 608) | def format_news_report(self, news_items: List[NewsItem], ticker: str) ... function get_realtime_stock_news (line 683) | def get_realtime_stock_news(ticker: str, curr_date: str, hours_back: int... FILE: tradingagents/dataflows/news/reddit.py function fetch_top_from_category (line 52) | def fetch_top_from_category( FILE: tradingagents/dataflows/optimized_china_data.py class OptimizedChinaDataProvider (line 26) | class OptimizedChinaDataProvider: method __init__ (line 29) | def __init__(self): method _wait_for_rate_limit (line 37) | def _wait_for_rate_limit(self): method _format_financial_data_to_fundamentals (line 48) | def _format_financial_data_to_fundamentals(self, financial_data: Dict[... method get_stock_data (line 104) | def get_stock_data(self, symbol: str, start_date: str, end_date: str, method get_fundamentals_data (line 198) | def get_fundamentals_data(self, symbol: str, force_refresh: bool = Fal... method _get_stock_basic_info_only (line 270) | def _get_stock_basic_info_only(self, symbol: str) -> str: method _generate_fundamentals_report (line 317) | def _generate_fundamentals_report(self, symbol: str, stock_data: str, ... method _get_industry_info (line 681) | def _get_industry_info(self, symbol: str) -> dict: method _get_market_type_by_code (line 781) | def _get_market_type_by_code(self, symbol: str) -> str: method _get_special_stocks (line 791) | def _get_special_stocks(self) -> dict: method _estimate_financial_metrics (line 824) | def _estimate_financial_metrics(self, symbol: str, current_price: str)... method _get_real_financial_metrics (line 844) | def _get_real_financial_metrics(self, symbol: str, price_value: float)... method _parse_mongodb_financial_data (line 961) | def _parse_mongodb_financial_data(self, financial_data: dict, price_va... method _parse_akshare_financial_data (line 1345) | def _parse_akshare_financial_data(self, financial_data: dict, stock_in... method _parse_financial_data (line 1705) | def _parse_financial_data(self, financial_data: dict, stock_info: dict... method _calculate_fundamental_score (line 1879) | def _calculate_fundamental_score(self, metrics: dict, stock_info: dict... method _calculate_valuation_score (line 1911) | def _calculate_valuation_score(self, metrics: dict) -> float: method _calculate_growth_score (line 1945) | def _calculate_growth_score(self, metrics: dict, stock_info: dict) -> ... method _calculate_risk_level (line 1958) | def _calculate_risk_level(self, metrics: dict, stock_info: dict) -> str: method _analyze_valuation (line 1985) | def _analyze_valuation(self, financial_estimates: dict) -> str: method _analyze_growth_potential (line 1996) | def _analyze_growth_potential(self, symbol: str, industry_info: dict) ... method _analyze_risks (line 2005) | def _analyze_risks(self, symbol: str, financial_estimates: dict, indus... method _generate_investment_advice (line 2032) | def _generate_investment_advice(self, financial_estimates: dict, indus... method _try_get_old_cache (line 2056) | def _try_get_old_cache(self, symbol: str, start_date: str, end_date: s... method _generate_fallback_data (line 2082) | def _generate_fallback_data(self, symbol: str, start_date: str, end_da... method _generate_fallback_fundamentals (line 2103) | def _generate_fallback_fundamentals(self, symbol: str, error_msg: str)... function get_optimized_china_data_provider (line 2122) | def get_optimized_china_data_provider() -> OptimizedChinaDataProvider: function get_china_stock_data_cached (line 2130) | def get_china_stock_data_cached(symbol: str, start_date: str, end_date: ... function get_china_fundamentals_cached (line 2148) | def get_china_fundamentals_cached(symbol: str, force_refresh: bool = Fal... function _add_financial_cache_methods (line 2164) | def _add_financial_cache_methods(): FILE: tradingagents/dataflows/providers/base_provider.py class BaseStockDataProvider (line 11) | class BaseStockDataProvider(ABC): method __init__ (line 17) | def __init__(self, provider_name: str): method connect (line 31) | async def connect(self) -> bool: method disconnect (line 40) | async def disconnect(self): method is_available (line 45) | def is_available(self) -> bool: method get_stock_basic_info (line 52) | async def get_stock_basic_info(self, symbol: str = None) -> Optional[U... method get_stock_quotes (line 65) | async def get_stock_quotes(self, symbol: str) -> Optional[Dict[str, An... method get_historical_data (line 78) | async def get_historical_data( method get_stock_list (line 99) | async def get_stock_list(self, market: str = None) -> Optional[List[Di... method get_financial_data (line 111) | async def get_financial_data(self, symbol: str, report_type: str = "an... method standardize_basic_info (line 127) | def standardize_basic_info(self, raw_data: Dict[str, Any]) -> Dict[str... method standardize_quotes (line 158) | def standardize_quotes(self, raw_data: Dict[str, Any]) -> Dict[str, Any]: method _determine_market_info (line 205) | def _determine_market_info(self, raw_data: Dict[str, Any]) -> Dict[str... method _determine_market (line 216) | def _determine_market(self, raw_data: Dict[str, Any]) -> str: method _convert_to_float (line 221) | def _convert_to_float(self, value: Any) -> Optional[float]: method _format_date_output (line 230) | def _format_date_output(self, date_value: Any) -> Optional[str]: method __aenter__ (line 249) | async def __aenter__(self): method __aexit__ (line 254) | async def __aexit__(self, exc_type, exc_val, exc_tb): method __repr__ (line 258) | def __repr__(self): FILE: tradingagents/dataflows/providers/china/akshare.py class AKShareProvider (line 16) | class AKShareProvider(BaseStockDataProvider): method __init__ (line 28) | def __init__(self): method _initialize_akshare (line 36) | def _initialize_akshare(self): method _get_stock_news_direct (line 168) | def _get_stock_news_direct(self, symbol: str, limit: int = 10) -> Opti... method _configure_timeout (line 267) | def _configure_timeout(self): method connect (line 276) | async def connect(self) -> bool: method test_connection (line 280) | async def test_connection(self) -> bool: method get_stock_list_sync (line 291) | def get_stock_list_sync(self) -> Optional[pd.DataFrame]: method get_stock_list (line 311) | async def get_stock_list(self) -> List[Dict[str, Any]]: method get_stock_basic_info (line 350) | async def get_stock_basic_info(self, code: str) -> Optional[Dict[str, ... method _get_stock_list_cached (line 396) | async def _get_stock_list_cached(self): method _get_stock_info_detail (line 421) | async def _get_stock_info_detail(self, code: str) -> Dict[str, Any]: method _determine_market (line 481) | def _determine_market(self, code: str) -> str: method _get_full_symbol (line 492) | def _get_full_symbol(self, code: str) -> str: method _get_market_info (line 520) | def _get_market_info(self, code: str) -> Dict[str, Any]: method get_batch_stock_quotes (line 555) | async def get_batch_stock_quotes(self, codes: List[str]) -> Dict[str, ... method get_stock_quotes (line 702) | async def get_stock_quotes(self, code: str) -> Optional[Dict[str, Any]]: method _get_realtime_quotes_data (line 799) | async def _get_realtime_quotes_data(self, code: str) -> Dict[str, Any]: method _safe_float (line 869) | def _safe_float(self, value: Any) -> float: method _safe_int (line 878) | def _safe_int(self, value: Any) -> int: method _safe_str (line 887) | def _safe_str(self, value: Any) -> str: method get_historical_data (line 896) | async def get_historical_data( method _standardize_historical_columns (line 959) | def _standardize_historical_columns(self, df: pd.DataFrame, code: str)... method get_financial_data (line 1000) | async def get_financial_data(self, code: str) -> Dict[str, Any]: method get_market_status (line 1077) | async def get_market_status(self) -> Dict[str, Any]: method get_stock_news_sync (line 1110) | def get_stock_news_sync(self, symbol: str = None, limit: int = 10) -> ... method get_stock_news (line 1183) | async def get_stock_news(self, symbol: str = None, limit: int = 10) ->... method _parse_news_time (line 1364) | def _parse_news_time(self, time_str: str) -> Optional[datetime]: method _analyze_news_sentiment (line 1403) | def _analyze_news_sentiment(self, content: str, title: str) -> str: method _calculate_sentiment_score (line 1442) | def _calculate_sentiment_score(self, content: str, title: str) -> float: method _extract_keywords (line 1484) | def _extract_keywords(self, content: str, title: str) -> List[str]: method _assess_news_importance (line 1513) | def _assess_news_importance(self, content: str, title: str) -> str: method _classify_news (line 1550) | def _classify_news(self, content: str, title: str) -> str: function get_akshare_provider (line 1590) | def get_akshare_provider() -> AKShareProvider: FILE: tradingagents/dataflows/providers/china/baostock.py class BaoStockProvider (line 17) | class BaoStockProvider(BaseStockDataProvider): method __init__ (line 20) | def __init__(self): method _init_baostock (line 27) | def _init_baostock(self): method connect (line 41) | async def connect(self) -> bool: method test_connection (line 45) | async def test_connection(self) -> bool: method get_stock_list_sync (line 66) | def get_stock_list_sync(self) -> Optional[pd.DataFrame]: method get_stock_list (line 110) | async def get_stock_list(self) -> List[Dict[str, Any]]: method get_stock_basic_info (line 173) | async def get_stock_basic_info(self, code: str) -> Dict[str, Any]: method get_valuation_data (line 208) | async def get_valuation_data(self, code: str, trade_date: Optional[str... method _get_stock_info_detail (line 288) | async def _get_stock_info_detail(self, code: str) -> Dict[str, Any]: method get_stock_quotes (line 326) | async def get_stock_quotes(self, code: str) -> Dict[str, Any]: method _get_latest_kline_data (line 370) | async def _get_latest_kline_data(self, code: str) -> Dict[str, Any]: method _to_baostock_code (line 426) | def _to_baostock_code(self, symbol: str) -> str: method _determine_market (line 439) | def _determine_market(self, code: str) -> str: method _get_full_symbol (line 450) | def _get_full_symbol(self, code: str) -> str: method _get_market_info (line 478) | def _get_market_info(self, code: str) -> Dict[str, Any]: method _safe_float (line 513) | def _safe_float(self, value: Any) -> float: method _safe_int (line 522) | def _safe_int(self, value: Any) -> int: method _safe_str (line 531) | def _safe_str(self, value: Any) -> str: method get_historical_data (line 540) | async def get_historical_data(self, code: str, start_date: str, end_da... method get_financial_data (line 638) | async def get_financial_data(self, code: str, year: Optional[int] = None, method _get_profit_data (line 722) | async def _get_profit_data(self, code: str, year: int, quarter: int) -... method _get_operation_data (line 756) | async def _get_operation_data(self, code: str, year: int, quarter: int... method _get_growth_data (line 790) | async def _get_growth_data(self, code: str, year: int, quarter: int) -... method _get_balance_data (line 824) | async def _get_balance_data(self, code: str, year: int, quarter: int) ... method _get_cash_flow_data (line 858) | async def _get_cash_flow_data(self, code: str, year: int, quarter: int... function get_baostock_provider (line 897) | def get_baostock_provider() -> BaoStockProvider: FILE: tradingagents/dataflows/providers/china/fundamentals_snapshot.py function _safe_float (line 12) | def _safe_float(x) -> Optional[float]: function _get_tushare_snapshot (line 24) | def _get_tushare_snapshot(symbol: str) -> Dict[str, Optional[float]]: function get_cn_fund_snapshot (line 66) | def get_cn_fund_snapshot(symbol: str) -> Dict[str, Optional[float]]: FILE: tradingagents/dataflows/providers/china/tushare.py class TushareProvider (line 25) | class TushareProvider(BaseStockDataProvider): method __init__ (line 31) | def __init__(self): method _get_token_from_database (line 40) | def _get_token_from_database(self) -> Optional[str]: method connect_sync (line 88) | def connect_sync(self) -> bool: method connect (line 175) | async def connect(self) -> bool: method is_available (line 259) | def is_available(self) -> bool: method get_stock_list_sync (line 265) | def get_stock_list_sync(self, market: str = None) -> Optional[pd.DataF... method get_stock_list (line 285) | async def get_stock_list(self, market: str = None) -> Optional[List[Di... method get_stock_basic_info (line 325) | async def get_stock_basic_info(self, symbol: str = None) -> Optional[U... method get_stock_quotes (line 352) | async def get_stock_quotes(self, symbol: str) -> Optional[Dict[str, An... method get_realtime_quotes_batch (line 415) | async def get_realtime_quotes_batch(self) -> Optional[Dict[str, Dict[s... method _is_rate_limit_error (line 498) | def _is_rate_limit_error(self, error_msg: str) -> bool: method get_historical_data (line 511) | async def get_historical_data( method get_daily_basic (line 597) | async def get_daily_basic(self, trade_date: str) -> Optional[pd.DataFr... method find_latest_trade_date (line 620) | async def find_latest_trade_date(self) -> Optional[str]: method get_financial_data (line 652) | async def get_financial_data(self, symbol: str, report_type: str = "qu... method get_stock_news (line 768) | async def get_stock_news(self, symbol: str = None, limit: int = 10, method _process_tushare_news (line 874) | def _process_tushare_news(self, news_df: pd.DataFrame, source: str, method _get_source_name (line 908) | def _get_source_name(self, source_code: str) -> str: method _generate_summary (line 923) | def _generate_summary(self, content: str) -> str: method _is_news_relevant_to_symbol (line 935) | def _is_news_relevant_to_symbol(self, news_item: Dict[str, Any], symbo... method _deduplicate_news (line 951) | def _deduplicate_news(self, news_list: List[Dict[str, Any]]) -> List[D... method _analyze_news_sentiment (line 964) | def _analyze_news_sentiment(self, content: str, title: str) -> str: method _assess_news_importance (line 981) | def _assess_news_importance(self, content: str, title: str) -> str: method _extract_keywords (line 995) | def _extract_keywords(self, content: str, title: str) -> List[str]: method _parse_tushare_news_time (line 1009) | def _parse_tushare_news_time(self, time_str: str) -> Optional[datetime]: method _classify_tushare_news (line 1021) | def _classify_tushare_news(self, channels: str, content: str) -> str: method get_financial_data_by_period (line 1038) | async def get_financial_data_by_period(self, symbol: str, start_period... method get_financial_indicators_only (line 1103) | async def get_financial_indicators_only(self, symbol: str, limit: int ... method standardize_basic_info (line 1146) | def standardize_basic_info(self, raw_data: Dict[str, Any]) -> Dict[str... method standardize_quotes (line 1180) | def standardize_quotes(self, raw_data: Dict[str, Any]) -> Dict[str, Any]: method _normalize_ts_code (line 1229) | def _normalize_ts_code(self, symbol: str) -> str: method _determine_market_info_from_ts_code (line 1243) | def _determine_market_info_from_ts_code(self, ts_code: str) -> Dict[st... method _determine_market (line 1278) | def _determine_market(self, ts_code: str) -> str: method _format_date (line 1283) | def _format_date(self, date_value: Union[str, date]) -> str: method _standardize_historical_data (line 1292) | def _standardize_historical_data(self, df: pd.DataFrame) -> pd.DataFrame: method _standardize_tushare_financial_data (line 1311) | def _standardize_tushare_financial_data(self, financial_data: Dict[str... method _calculate_ttm_from_tushare (line 1430) | def _calculate_ttm_from_tushare(self, income_statements: list, field: ... method _determine_report_type (line 1532) | def _determine_report_type(self, report_period: str) -> str: method _safe_float (line 1547) | def _safe_float(self, value) -> Optional[float]: method _calculate_gross_profit (line 1574) | def _calculate_gross_profit(self, revenue, oper_cost) -> Optional[float]: method _safe_str (line 1583) | def _safe_str(self, value) -> Optional[str]: function get_tushare_provider (line 1596) | def get_tushare_provider() -> TushareProvider: FILE: tradingagents/dataflows/providers/examples/__init__.py function get_example_sdk_provider (line 14) | def get_example_sdk_provider(**kwargs): FILE: tradingagents/dataflows/providers/examples/example_sdk.py class ExampleSDKProvider (line 20) | class ExampleSDKProvider(BaseStockDataProvider): method __init__ (line 37) | def __init__(self, api_key: str = None, base_url: str = None, **kwargs): method connect (line 59) | async def connect(self) -> bool: method disconnect (line 92) | async def disconnect(self): method get_stock_basic_info (line 101) | async def get_stock_basic_info(self, symbol: str = None) -> Optional[U... method get_stock_list (line 132) | async def get_stock_list(self, market: str = None) -> Optional[List[Di... method get_stock_quotes (line 155) | async def get_stock_quotes(self, symbol: str) -> Optional[Dict[str, An... method get_historical_data (line 174) | async def get_historical_data( method get_financial_data (line 207) | async def get_financial_data(self, symbol: str, report_type: str = "an... method get_stock_news (line 228) | async def get_stock_news(self, symbol: str = None, limit: int = 10) ->... method standardize_basic_info (line 255) | def standardize_basic_info(self, raw_data: Dict[str, Any]) -> Dict[str... method standardize_quotes (line 273) | def standardize_quotes(self, raw_data: Dict[str, Any]) -> Dict[str, Any]: method _convert_to_dataframe (line 293) | def _convert_to_dataframe(self, history_data: List[Dict[str, Any]]) ->... method _standardize_financial_data (line 321) | def _standardize_financial_data(self, raw_data: Dict[str, Any]) -> Dic... method _standardize_news (line 336) | def _standardize_news(self, raw_data: Dict[str, Any]) -> Dict[str, Any]: method __aenter__ (line 352) | async def __aenter__(self): method __aexit__ (line 357) | async def __aexit__(self, exc_type, exc_val, exc_tb): function example_usage (line 364) | async def example_usage(): FILE: tradingagents/dataflows/providers/hk/hk_stock.py class HKStockProvider (line 24) | class HKStockProvider: method __init__ (line 27) | def __init__(self): method _wait_for_rate_limit (line 37) | def _wait_for_rate_limit(self): method get_stock_data (line 48) | def get_stock_data(self, symbol: str, start_date: str = None, end_date... method get_stock_info (line 118) | def get_stock_info(self, symbol: str) -> Dict[str, Any]: method get_real_time_price (line 169) | def get_real_time_price(self, symbol: str) -> Optional[Dict]: method _normalize_hk_symbol (line 208) | def _normalize_hk_symbol(self, symbol: str) -> str: method format_stock_data (line 239) | def format_stock_data(self, symbol: str, data: pd.DataFrame, start_dat... function get_hk_stock_provider (line 481) | def get_hk_stock_provider() -> HKStockProvider: function get_hk_stock_data (line 489) | def get_hk_stock_data(symbol: str, start_date: str = None, end_date: str... function get_hk_stock_info (line 506) | def get_hk_stock_info(symbol: str) -> Dict: FILE: tradingagents/dataflows/providers/hk/improved_hk.py function get_cache_dir (line 24) | def get_cache_dir(subdir: Optional[str] = None, create: bool = True): class ImprovedHKStockProvider (line 33) | class ImprovedHKStockProvider: method __init__ (line 36) | def __init__(self): method _load_cache (line 109) | def _load_cache(self): method _save_cache (line 121) | def _save_cache(self): method _is_cache_valid (line 131) | def _is_cache_valid(self, key: str) -> bool: method _rate_limit (line 139) | def _rate_limit(self): method _normalize_hk_symbol (line 151) | def _normalize_hk_symbol(self, symbol: str) -> str: method get_company_name (line 168) | def get_company_name(self, symbol: str) -> str: method get_financial_indicators (line 293) | def get_financial_indicators(self, symbol: str) -> Dict[str, Any]: method get_stock_info (line 389) | def get_stock_info(self, symbol: str) -> Dict[str, Any]: function get_improved_hk_provider (line 428) | def get_improved_hk_provider() -> ImprovedHKStockProvider: function get_hk_company_name_improved (line 436) | def get_hk_company_name_improved(symbol: str) -> str: function get_hk_stock_info_improved (line 450) | def get_hk_stock_info_improved(symbol: str) -> Dict[str, Any]: function get_hk_financial_indicators (line 464) | def get_hk_financial_indicators(symbol: str) -> Dict[str, Any]: function get_hk_stock_data_akshare (line 488) | def get_hk_stock_data_akshare(symbol: str, start_date: str = None, end_d... function get_hk_stock_info_akshare (line 669) | def get_hk_stock_info_akshare(symbol: str) -> Dict[str, Any]: FILE: tradingagents/dataflows/providers/us/alpha_vantage_common.py class AlphaVantageRateLimitError (line 25) | class AlphaVantageRateLimitError(Exception): class AlphaVantageAPIError (line 30) | class AlphaVantageAPIError(Exception): function _get_api_key_from_database (line 35) | def _get_api_key_from_database() -> Optional[str]: function get_api_key (line 85) | def get_api_key() -> str: function format_datetime_for_api (line 143) | def format_datetime_for_api(date_str: str) -> str: function _make_api_request (line 161) | def _make_api_request( function format_response_as_string (line 270) | def format_response_as_string(data: Dict[str, Any], title: str = "Alpha ... function check_api_key_valid (line 296) | def check_api_key_valid() -> bool: FILE: tradingagents/dataflows/providers/us/alpha_vantage_fundamentals.py function get_fundamentals (line 23) | def get_fundamentals( function get_balance_sheet (line 146) | def get_balance_sheet( function get_cashflow (line 175) | def get_cashflow( function get_income_statement (line 204) | def get_income_statement( FILE: tradingagents/dataflows/providers/us/alpha_vantage_news.py function get_news (line 20) | def get_news( function get_insider_transactions (line 111) | def get_insider_transactions( function get_market_news (line 174) | def get_market_news( FILE: tradingagents/dataflows/providers/us/finnhub.py function get_data_in_range (line 10) | def get_data_in_range(ticker, start_date, end_date, data_type, data_dir,... FILE: tradingagents/dataflows/providers/us/optimized.py function get_cache (line 20) | def get_cache(): function get_config (line 29) | def get_config(): class OptimizedUSDataProvider (line 38) | class OptimizedUSDataProvider: method __init__ (line 41) | def __init__(self): method _wait_for_rate_limit (line 58) | def _wait_for_rate_limit(self): method get_stock_data (line 70) | def get_stock_data(self, symbol: str, start_date: str, end_date: str, method _format_stock_data (line 252) | def _format_stock_data(self, symbol: str, data: pd.DataFrame, method _try_get_old_cache (line 323) | def _try_get_old_cache(self, symbol: str, start_date: str, end_date: s... method _get_data_from_finnhub (line 348) | def _get_data_from_finnhub(self, symbol: str, start_date: str, end_dat... method _get_data_from_yfinance (line 405) | def _get_data_from_yfinance(self, symbol: str, start_date: str, end_da... method _get_data_from_alpha_vantage (line 425) | def _get_data_from_alpha_vantage(self, symbol: str, start_date: str, e... method _generate_fallback_data (line 490) | def _generate_fallback_data(self, symbol: str, start_date: str, end_da... function get_optimized_us_data_provider (line 514) | def get_optimized_us_data_provider() -> OptimizedUSDataProvider: function get_us_stock_data_cached (line 522) | def get_us_stock_data_cached(symbol: str, start_date: str, end_date: str, FILE: tradingagents/dataflows/providers/us/yfinance.py function get_cache (line 22) | def get_cache(): function init_ticker (line 37) | def init_ticker(func: Callable) -> Callable: class YFinanceUtils (line 49) | class YFinanceUtils: method get_stock_data (line 51) | def get_stock_data( method get_stock_info (line 70) | def get_stock_info( method get_company_info (line 78) | def get_company_info( method get_stock_dividends (line 98) | def get_stock_dividends( method get_income_stmt (line 110) | def get_income_stmt(symbol: Annotated[str, "ticker symbol"]) -> DataFr... method get_balance_sheet (line 116) | def get_balance_sheet(symbol: Annotated[str, "ticker symbol"]) -> Data... method get_cash_flow (line 122) | def get_cash_flow(symbol: Annotated[str, "ticker symbol"]) -> DataFrame: method get_analyst_recommendations (line 128) | def get_analyst_recommendations(symbol: Annotated[str, "ticker symbol"... function get_stock_data_with_indicators (line 147) | def get_stock_data_with_indicators( function get_technical_indicator (line 197) | def get_technical_indicator( FILE: tradingagents/dataflows/realtime_metrics.py function calculate_realtime_pe_pb (line 12) | def calculate_realtime_pe_pb( function validate_pe_pb (line 299) | def validate_pe_pb(pe: Optional[float], pb: Optional[float]) -> bool: function get_pe_pb_with_fallback (line 323) | def get_pe_pb_with_fallback( FILE: tradingagents/dataflows/stock_api.py function get_stock_info (line 15) | def get_stock_info(stock_code: str) -> Optional[Dict[str, Any]]: function get_all_stocks (line 33) | def get_all_stocks() -> List[Dict[str, Any]]: function get_stock_data (line 55) | def get_stock_data(stock_code: str, start_date: str, end_date: str) -> str: function search_stocks_by_name (line 74) | def search_stocks_by_name(name: str) -> List[Dict[str, Any]]: function check_data_sources (line 98) | def check_data_sources() -> Dict[str, Any]: FILE: tradingagents/dataflows/stock_data_service.py class StockDataService (line 37) | class StockDataService: method __init__ (line 43) | def __init__(self): method _init_services (line 47) | def _init_services(self): method get_stock_basic_info (line 61) | def get_stock_basic_info(self, stock_code: str = None) -> Optional[Dic... method _get_from_mongodb (line 100) | def _get_from_mongodb(self, stock_code: str = None) -> Optional[Dict[s... method _get_from_enhanced_fetcher (line 124) | def _get_from_enhanced_fetcher(self, stock_code: str = None) -> Option... method _cache_to_mongodb (line 184) | def _cache_to_mongodb(self, data: Any) -> bool: method _get_fallback_data (line 216) | def _get_fallback_data(self, stock_code: str = None) -> Dict[str, Any]: method _get_market_name (line 234) | def _get_market_name(self, stock_code: str) -> str: method _get_stock_category (line 243) | def _get_stock_category(self, stock_code: str) -> str: method get_stock_data_with_fallback (line 258) | def get_stock_data_with_fallback(self, stock_code: str, start_date: st... function get_stock_data_service (line 281) | def get_stock_data_service() -> StockDataService: FILE: tradingagents/dataflows/technical/stockstats.py function get_config (line 8) | def get_config(): class StockstatsUtils (line 13) | class StockstatsUtils: method get_stock_stats (line 15) | def get_stock_stats( FILE: tradingagents/graph/conditional_logic.py class ConditionalLogic (line 10) | class ConditionalLogic: method __init__ (line 13) | def __init__(self, max_debate_rounds=1, max_risk_discuss_rounds=1): method should_continue_market (line 18) | def should_continue_market(self, state: AgentState): method should_continue_social (line 63) | def should_continue_social(self, state: AgentState): method should_continue_news (line 101) | def should_continue_news(self, state: AgentState): method should_continue_fundamentals (line 139) | def should_continue_fundamentals(self, state: AgentState): method should_continue_debate (line 201) | def should_continue_debate(self, state: AgentState) -> str: method should_continue_risk_analysis (line 219) | def should_continue_risk_analysis(self, state: AgentState) -> str: FILE: tradingagents/graph/propagation.py class Propagator (line 15) | class Propagator: method __init__ (line 18) | def __init__(self, max_recur_limit=100): method create_initial_state (line 22) | def create_initial_state( method get_graph_args (line 54) | def get_graph_args(self, use_progress_callback: bool = False) -> Dict[... FILE: tradingagents/graph/reflection.py class Reflector (line 11) | class Reflector: method __init__ (line 14) | def __init__(self, quick_thinking_llm: ChatOpenAI): method _get_reflection_prompt (line 19) | def _get_reflection_prompt(self) -> str: method _extract_current_situation (line 53) | def _extract_current_situation(self, current_state: Dict[str, Any]) ->... method _reflect_on_component (line 62) | def _reflect_on_component( method reflect_bull_researcher (line 77) | def reflect_bull_researcher(self, current_state, returns_losses, bull_... method reflect_bear_researcher (line 87) | def reflect_bear_researcher(self, current_state, returns_losses, bear_... method reflect_trader (line 97) | def reflect_trader(self, current_state, returns_losses, trader_memory): method reflect_invest_judge (line 107) | def reflect_invest_judge(self, current_state, returns_losses, invest_j... method reflect_risk_manager (line 117) | def reflect_risk_manager(self, current_state, returns_losses, risk_man... FILE: tradingagents/graph/setup.py class GraphSetup (line 19) | class GraphSetup: method __init__ (line 22) | def __init__( method setup_graph (line 51) | def setup_graph( FILE: tradingagents/graph/signal_processing.py class SignalProcessor (line 11) | class SignalProcessor: method __init__ (line 14) | def __init__(self, quick_thinking_llm: ChatOpenAI): method process_signal (line 19) | def process_signal(self, full_signal: str, stock_symbol: str = None) -... method _smart_price_estimation (line 216) | def _smart_price_estimation(self, text: str, action: str, is_china: bo... method _extract_simple_decision (line 281) | def _extract_simple_decision(self, text: str) -> dict: method _get_default_decision (line 328) | def _get_default_decision(self) -> dict: FILE: tradingagents/graph/trading_graph.py function create_llm_by_provider (line 41) | def create_llm_by_provider(provider: str, model: str, backend_url: str, ... class TradingAgentsGraph (line 193) | class TradingAgentsGraph: method __init__ (line 196) | def __init__( method _create_tool_nodes (line 814) | def _create_tool_nodes(self) -> Dict[str, ToolNode]: method propagate (line 872) | def propagate(self, company_name, trade_date, progress_callback=None, ... method _send_progress_update (line 1059) | def _send_progress_update(self, chunk, progress_callback): method _build_performance_data (line 1144) | def _build_performance_data(self, node_timings: Dict[str, float], tota... method _print_timing_summary (line 1249) | def _print_timing_summary(self, node_timings: Dict[str, float], total_... method _log_state (line 1335) | def _log_state(self, trade_date, final_state): method reflect_and_remember (line 1377) | def reflect_and_remember(self, returns_losses): method process_signal (line 1395) | def process_signal(self, full_signal, stock_symbol=None): FILE: tradingagents/llm_adapters/dashscope_openai_adapter.py class ChatDashScopeOpenAI (line 19) | class ChatDashScopeOpenAI(ChatOpenAI): method __init__ (line 26) | def __init__(self, **kwargs): method _generate (line 102) | def _generate(self, *args, **kwargs): function get_available_openai_models (line 181) | def get_available_openai_models() -> Dict[str, Dict[str, Any]]: function create_dashscope_openai_llm (line 186) | def create_dashscope_openai_llm( function test_dashscope_openai_connection (line 204) | def test_dashscope_openai_connection( function test_dashscope_openai_function_calling (line 237) | def test_dashscope_openai_function_calling( FILE: tradingagents/llm_adapters/deepseek_adapter.py class ChatDeepSeek (line 31) | class ChatDeepSeek(ChatOpenAI): method __init__ (line 38) | def __init__( method _generate (line 107) | def _generate( method _estimate_input_tokens (line 192) | def _estimate_input_tokens(self, messages: List[BaseMessage]) -> int: method _estimate_output_tokens (line 212) | def _estimate_output_tokens(self, result: ChatResult) -> int: method invoke (line 231) | def invoke( function create_deepseek_llm (line 265) | def create_deepseek_llm( FILE: tradingagents/llm_adapters/google_openai_adapter.py class ChatGoogleOpenAI (line 21) | class ChatGoogleOpenAI(ChatGoogleGenerativeAI): method __init__ (line 28) | def __init__(self, base_url: Optional[str] = None, **kwargs): method model_name (line 149) | def model_name(self) -> str: method _generate (line 159) | def _generate(self, messages: List[BaseMessage], stop: Optional[List[s... method _optimize_message_content (line 204) | def _optimize_message_content(self, message: BaseMessage): method _is_news_content (line 222) | def _is_news_content(self, content: str) -> bool: method _enhance_news_content (line 233) | def _enhance_news_content(self, content: str) -> str: method _track_token_usage (line 261) | def _track_token_usage(self, result: LLMResult, kwargs: Dict[str, Any]): function get_available_google_models (line 351) | def get_available_google_models() -> Dict[str, Dict[str, Any]]: function create_google_openai_llm (line 356) | def create_google_openai_llm( function test_google_openai_connection (line 389) | def test_google_openai_connection( function test_google_openai_function_calling (line 422) | def test_google_openai_function_calling( FILE: tradingagents/llm_adapters/openai_compatible_base.py class OpenAICompatibleBase (line 32) | class OpenAICompatibleBase(ChatOpenAI): method __init__ (line 38) | def __init__( method provider_name (line 149) | def provider_name(self) -> Optional[str]: method _generate (line 155) | def _generate( method _track_token_usage (line 177) | def _track_token_usage(self, result: ChatResult, kwargs: Dict, start_t... class ChatDeepSeekOpenAI (line 197) | class ChatDeepSeekOpenAI(OpenAICompatibleBase): method __init__ (line 200) | def __init__( class ChatDashScopeOpenAIUnified (line 220) | class ChatDashScopeOpenAIUnified(OpenAICompatibleBase): method __init__ (line 223) | def __init__( class ChatQianfanOpenAI (line 243) | class ChatQianfanOpenAI(OpenAICompatibleBase): method __init__ (line 246) | def __init__( method _estimate_tokens (line 305) | def _estimate_tokens(self, text: str) -> int: method _truncate_messages (line 311) | def _truncate_messages(self, messages: List[BaseMessage], max_tokens: ... method _generate (line 343) | def _generate( class ChatZhipuOpenAI (line 359) | class ChatZhipuOpenAI(OpenAICompatibleBase): method __init__ (line 362) | def __init__( method _estimate_tokens (line 390) | def _estimate_tokens(self, text: str) -> int: class ChatCustomOpenAI (line 397) | class ChatCustomOpenAI(OpenAICompatibleBase): method __init__ (line 400) | def __init__( function create_openai_compatible_llm (line 500) | def create_openai_compatible_llm( function test_openai_compatible_adapters (line 535) | def test_openai_compatible_adapters(): FILE: tradingagents/models/stock_data_models.py class MarketType (line 19) | class MarketType(str, Enum): class StockStatus (line 26) | class StockStatus(str, Enum): class ReportType (line 33) | class ReportType(str, Enum): class NewsCategory (line 39) | class NewsCategory(str, Enum): class SentimentType (line 47) | class SentimentType(str, Enum): class BaseStockModel (line 54) | class BaseStockModel(BaseModel): class Config (line 61) | class Config: class StockBasicInfo (line 70) | class StockBasicInfo(BaseStockModel): method validate_symbol (line 93) | def validate_symbol(cls, v): class StockDailyQuote (line 99) | class StockDailyQuote(BaseStockModel): class StockRealtimeQuote (line 124) | class StockRealtimeQuote(BaseStockModel): class BalanceSheetData (line 145) | class BalanceSheetData(BaseModel): class IncomeStatementData (line 157) | class IncomeStatementData(BaseModel): class CashflowStatementData (line 171) | class CashflowStatementData(BaseModel): class FinancialIndicators (line 180) | class FinancialIndicators(BaseModel): class StockFinancialData (line 196) | class StockFinancialData(BaseStockModel): class StockNews (line 209) | class StockNews(BaseStockModel): class MovingAverages (line 228) | class MovingAverages(BaseModel): class TechnicalIndicatorsData (line 236) | class TechnicalIndicatorsData(BaseModel): class StockTechnicalIndicators (line 255) | class StockTechnicalIndicators(BaseStockModel): class DataSourceConfig (line 264) | class DataSourceConfig(BaseStockModel): class DataSyncLog (line 276) | class DataSyncLog(BaseStockModel): FILE: tradingagents/tools/analysis/indicators.py class IndicatorSpec (line 11) | class IndicatorSpec: function _require_cols (line 19) | def _require_cols(df: pd.DataFrame, cols: Iterable[str]): function ma (line 25) | def ma(close: pd.Series, n: int, min_periods: int = None) -> pd.Series: function ema (line 42) | def ema(close: pd.Series, n: int) -> pd.Series: function macd (line 56) | def macd(close: pd.Series, fast: int = 12, slow: int = 26, signal: int =... function rsi (line 78) | def rsi(close: pd.Series, n: int = 14, method: str = 'ema') -> pd.Series: function boll (line 124) | def boll(close: pd.Series, n: int = 20, k: float = 2.0, min_periods: int... function atr (line 149) | def atr(high: pd.Series, low: pd.Series, close: pd.Series, n: int = 14) ... function kdj (line 159) | def kdj(high: pd.Series, low: pd.Series, close: pd.Series, n: int = 9, m... function compute_indicator (line 188) | def compute_indicator(df: pd.DataFrame, spec: IndicatorSpec) -> pd.DataF... function compute_many (line 249) | def compute_many(df: pd.DataFrame, specs: List[IndicatorSpec]) -> pd.Dat... function last_values (line 272) | def last_values(df: pd.DataFrame, columns: List[str]) -> Dict[str, Any]: function add_all_indicators (line 279) | def add_all_indicators(df: pd.DataFrame, close_col: str = 'close', FILE: tradingagents/tools/unified_news_tool.py class UnifiedNewsAnalyzer (line 14) | class UnifiedNewsAnalyzer: method __init__ (line 17) | def __init__(self, toolkit): method get_stock_news_unified (line 25) | def get_stock_news_unified(self, stock_code: str, max_news: int = 10, ... method _identify_stock_type (line 67) | def _identify_stock_type(self, stock_code: str) -> str: method _get_news_from_database (line 93) | def _get_news_from_database(self, stock_code: str, max_news: int = 10)... method _sync_news_from_akshare (line 187) | def _sync_news_from_akshare(self, stock_code: str, max_news: int = 10)... method _get_a_share_news (line 282) | def _get_a_share_news(self, stock_code: str, max_news: int, model_info... method _get_hk_share_news (line 367) | def _get_hk_share_news(self, stock_code: str, max_news: int, model_inf... method _get_us_share_news (line 413) | def _get_us_share_news(self, stock_code: str, max_news: int, model_inf... method _format_news_result (line 459) | def _format_news_result(self, news_content: str, source: str, model_in... function create_unified_news_tool (line 552) | def create_unified_news_tool(toolkit): FILE: tradingagents/utils/dataflow_utils.py function save_output (line 19) | def save_output(data: pd.DataFrame, tag: str, save_path: SavePathType = ... function get_current_date (line 33) | def get_current_date(): function decorate_all_methods (line 43) | def decorate_all_methods(decorator): function get_next_weekday (line 68) | def get_next_weekday(date_input): function get_trading_date_range (line 93) | def get_trading_date_range(target_date=None, lookback_days=10): FILE: tradingagents/utils/enhanced_news_filter.py class EnhancedNewsFilter (line 18) | class EnhancedNewsFilter(NewsRelevanceFilter): method __init__ (line 21) | def __init__(self, stock_code: str, company_name: str, use_semantic: b... method _init_semantic_model (line 49) | def _init_semantic_model(self): method _init_classification_model (line 83) | def _init_classification_model(self): method calculate_semantic_similarity (line 109) | def calculate_semantic_similarity(self, title: str, content: str) -> f... method classify_news_relevance (line 151) | def classify_news_relevance(self, title: str, content: str) -> float: method calculate_enhanced_relevance_score (line 205) | def calculate_enhanced_relevance_score(self, title: str, content: str)... method filter_news_enhanced (line 256) | def filter_news_enhanced(self, news_df: pd.DataFrame, min_score: float... function create_enhanced_news_filter (line 304) | def create_enhanced_news_filter(ticker: str, use_semantic: bool = True, ... FILE: tradingagents/utils/logging_init.py function init_logging (line 19) | def init_logging(config_override: Optional[dict] = None) -> None: function get_session_logger (line 47) | def get_session_logger(session_id: str, module_name: str = 'session') ->... function log_startup_info (line 89) | def log_startup_info(): function log_shutdown_info (line 115) | def log_shutdown_info(): function setup_web_logging (line 125) | def setup_web_logging(): function setup_analysis_logging (line 132) | def setup_analysis_logging(session_id: str): function setup_dataflow_logging (line 137) | def setup_dataflow_logging(): function setup_llm_logging (line 142) | def setup_llm_logging(): FILE: tradingagents/utils/logging_manager.py class ColoredFormatter (line 22) | class ColoredFormatter(logging.Formatter): method format (line 35) | def format(self, record): class StructuredFormatter (line 43) | class StructuredFormatter(logging.Formatter): method format (line 46) | def format(self, record): class TradingAgentsLogger (line 72) | class TradingAgentsLogger: method __init__ (line 75) | def __init__(self, config: Optional[Dict[str, Any]] = None): method _load_default_config (line 80) | def _load_default_config(self) -> Dict[str, Any]: method _load_config_file (line 139) | def _load_config_file(self) -> Optional[Dict[str, Any]]: method _convert_toml_config (line 162) | def _convert_toml_config(self, toml_config: Dict[str, Any]) -> Dict[st... method _setup_logging (line 186) | def _setup_logging(self): method _add_console_handler (line 212) | def _add_console_handler(self, logger: logging.Logger): method _add_file_handler (line 230) | def _add_file_handler(self, logger: logging.Logger): method _add_error_handler (line 256) | def _add_error_handler(self, logger: logging.Logger): method _add_structured_handler (line 285) | def _add_structured_handler(self, logger: logging.Logger): method _configure_specific_loggers (line 304) | def _configure_specific_loggers(self): method _parse_size (line 311) | def _parse_size(self, size_str: str) -> int: method get_logger (line 323) | def get_logger(self, name: str) -> logging.Logger: method log_analysis_start (line 329) | def log_analysis_start(self, logger: logging.Logger, stock_symbol: str... method log_analysis_complete (line 342) | def log_analysis_complete(self, logger: logging.Logger, stock_symbol: ... method log_module_start (line 358) | def log_module_start(self, logger: logging.Logger, module_name: str, s... method log_module_complete (line 373) | def log_module_complete(self, logger: logging.Logger, module_name: str... method log_module_error (line 393) | def log_module_error(self, logger: logging.Logger, module_name: str, s... method log_token_usage (line 411) | def log_token_usage(self, logger: logging.Logger, provider: str, model... function get_logger_manager (line 431) | def get_logger_manager() -> TradingAgentsLogger: function get_logger (line 439) | def get_logger(name: str) -> logging.Logger: function setup_logging (line 444) | def setup_logging(config: Optional[Dict[str, Any]] = None): FILE: tradingagents/utils/news_filter.py class NewsRelevanceFilter (line 14) | class NewsRelevanceFilter: method __init__ (line 17) | def __init__(self, stock_code: str, company_name: str): method calculate_relevance_score (line 51) | def calculate_relevance_score(self, title: str, content: str) -> float: method filter_news (line 134) | def filter_news(self, news_df: pd.DataFrame, min_score: float = 30) ->... method get_filter_statistics (line 181) | def get_filter_statistics(self, original_df: pd.DataFrame, filtered_df... function get_company_name (line 240) | def get_company_name(ticker: str) -> str: function create_news_filter (line 265) | def create_news_filter(ticker: str) -> NewsRelevanceFilter: FILE: tradingagents/utils/news_filter_integration.py function integrate_news_filtering (line 13) | def integrate_news_filtering(original_get_stock_news_em): function patch_akshare_utils (line 107) | def patch_akshare_utils(): function create_filtered_realtime_news_function (line 116) | def create_filtered_realtime_news_function(): function apply_news_filtering_patches (line 185) | def apply_news_filtering_patches(): FILE: tradingagents/utils/stock_utils.py class StockMarket (line 15) | class StockMarket(Enum): class StockUtils (line 23) | class StockUtils: method identify_stock_market (line 27) | def identify_stock_market(ticker: str) -> StockMarket: method is_china_stock (line 57) | def is_china_stock(ticker: str) -> bool: method is_hk_stock (line 70) | def is_hk_stock(ticker: str) -> bool: method is_us_stock (line 83) | def is_us_stock(ticker: str) -> bool: method get_currency_info (line 96) | def get_currency_info(ticker: str) -> Tuple[str, str]: method get_data_source (line 118) | def get_data_source(ticker: str) -> str: method normalize_hk_ticker (line 140) | def normalize_hk_ticker(ticker: str) -> str: method get_market_info (line 166) | def get_market_info(ticker: str) -> Dict: function is_china_stock (line 201) | def is_china_stock(ticker: str) -> bool: function is_hk_stock (line 206) | def is_hk_stock(ticker: str) -> bool: function is_us_stock (line 211) | def is_us_stock(ticker: str) -> bool: function get_stock_market_info (line 216) | def get_stock_market_info(ticker: str) -> Dict: FILE: tradingagents/utils/stock_validator.py class StockDataPreparationResult (line 16) | class StockDataPreparationResult: method __init__ (line 19) | def __init__(self, is_valid: bool, stock_code: str, market_type: str =... method to_dict (line 34) | def to_dict(self) -> Dict: class StockDataPreparer (line 54) | class StockDataPreparer: method __init__ (line 57) | def __init__(self, default_period_days: int = 30): method prepare_stock_data (line 61) | def prepare_stock_data(self, stock_code: str, market_type: str = "auto", method _validate_format (line 96) | def _validate_format(self, stock_code: str, market_type: str) -> Stock... method _detect_market_type (line 155) | def _detect_market_type(self, stock_code: str) -> str: method _get_hk_network_limitation_suggestion (line 173) | def _get_hk_network_limitation_suggestion(self) -> str: method _extract_hk_stock_name (line 194) | def _extract_hk_stock_name(self, stock_info, stock_code: str) -> str: method _prepare_data_by_market (line 262) | def _prepare_data_by_market(self, stock_code: str, market_type: str, method _prepare_data_by_market_async (line 292) | async def _prepare_data_by_market_async(self, stock_code: str, market_... method _prepare_china_stock_data (line 322) | def _prepare_china_stock_data(self, stock_code: str, period_days: int, method _prepare_china_stock_data_async (line 484) | async def _prepare_china_stock_data_async(self, stock_code: str, perio... method _check_database_data (line 608) | def _check_database_data(self, stock_code: str, start_date: str, end_d... method _trigger_data_sync_sync (line 701) | def _trigger_data_sync_sync(self, stock_code: str, start_date: str, en... method _trigger_data_sync_async (line 753) | async def _trigger_data_sync_async(self, stock_code: str, start_date: ... method _get_data_source_priority_for_sync (line 919) | def _get_data_source_priority_for_sync(self, stock_code: str) -> list: method _prepare_hk_stock_data (line 944) | def _prepare_hk_stock_data(self, stock_code: str, period_days: int, method _prepare_us_stock_data (line 1117) | def _prepare_us_stock_data(self, stock_code: str, period_days: int, function get_stock_preparer (line 1226) | def get_stock_preparer(default_period_days: int = 30) -> StockDataPreparer: function prepare_stock_data (line 1234) | def prepare_stock_data(stock_code: str, market_type: str = "auto", function is_stock_data_ready (line 1252) | def is_stock_data_ready(stock_code: str, market_type: str = "auto", function get_stock_preparation_message (line 1270) | def get_stock_preparation_message(stock_code: str, market_type: str = "a... function prepare_stock_data_async (line 1292) | async def prepare_stock_data_async(stock_code: str, market_type: str = "... FILE: tradingagents/utils/tool_logging.py function log_tool_call (line 25) | def log_tool_call(tool_name: Optional[str] = None, log_args: bool = True... function log_data_source_call (line 119) | def log_data_source_call(source_name: str): function log_llm_call (line 200) | def log_llm_call(provider: str, model: str): function log_tool_usage (line 264) | def log_tool_usage(tool_name: str, symbol: str = None, **extra_data): function log_analysis_step (line 286) | def log_analysis_step(step_name: str, symbol: str, **extra_data): function log_analysis_module (line 306) | def log_analysis_module(module_name: str, session_id: str = None): function log_analyst_module (line 399) | def log_analyst_module(analyst_type: str): function log_graph_module (line 409) | def log_graph_module(graph_type: str): function log_dataflow_module (line 419) | def log_dataflow_module(dataflow_type: str): FILE: utils/check_version_consistency.py function get_target_version (line 16) | def get_target_version(): function normalize_version (line 26) | def normalize_version(v: str) -> str: function check_special_files (line 37) | def check_special_files(file_path: Path, content: str, target_version: s... function check_file_versions (line 76) | def check_file_versions(file_path: Path, target_version: str): function main (line 96) | def main(): FILE: utils/cleanup_unnecessary_dirs.py function cleanup_directories (line 16) | def cleanup_directories(): function update_gitignore (line 66) | def update_gitignore(): function analyze_upstream_contribution (line 129) | def analyze_upstream_contribution(): function main (line 159) | def main(): FILE: utils/data_config.py function get_data_path (line 22) | def get_data_path(key: str, create: bool = True) -> Path: function get_cache_dir (line 47) | def get_cache_dir(subdir: Optional[str] = None, create: bool = True) -> ... function get_results_dir (line 66) | def get_results_dir(subdir: Optional[str] = None, create: bool = True) -... function get_sessions_dir (line 85) | def get_sessions_dir(subdir: Optional[str] = None, create: bool = True) ... function get_logs_dir (line 104) | def get_logs_dir(subdir: Optional[str] = None, create: bool = True) -> P... function get_config_dir (line 123) | def get_config_dir(subdir: Optional[str] = None, create: bool = True) ->... function get_temp_dir (line 142) | def get_temp_dir(subdir: Optional[str] = None, create: bool = True) -> P... function get_analysis_results_dir (line 162) | def get_analysis_results_dir() -> Path: function get_stock_data_cache_dir (line 167) | def get_stock_data_cache_dir() -> Path: function get_news_data_cache_dir (line 172) | def get_news_data_cache_dir() -> Path: function get_fundamentals_cache_dir (line 177) | def get_fundamentals_cache_dir() -> Path: function get_metadata_cache_dir (line 182) | def get_metadata_cache_dir() -> Path: function get_web_sessions_dir (line 187) | def get_web_sessions_dir() -> Path: function get_cli_sessions_dir (line 192) | def get_cli_sessions_dir() -> Path: function get_application_logs_dir (line 197) | def get_application_logs_dir() -> Path: function get_operations_logs_dir (line 202) | def get_operations_logs_dir() -> Path: function get_user_activities_logs_dir (line 207) | def get_user_activities_logs_dir() -> Path: function check_data_directory_config (line 213) | def check_data_directory_config() -> dict: function print_data_directory_status (line 242) | def print_data_directory_status(): FILE: utils/update_data_source_references.py function update_file_content (line 16) | def update_file_content(file_path: Path, replacements: list): function main (line 39) | def main(): FILE: web/app.py function initialize_session_state (line 319) | def initialize_session_state(): function check_frontend_auth_cache (line 417) | def check_frontend_auth_cache(): function inject_frontend_cache_check (line 489) | def inject_frontend_cache_check(): function main (line 594) | def main(): FILE: web/components/analysis_form.py function render_analysis_form (line 20) | def render_analysis_form(): FILE: web/components/analysis_results.py function safe_timestamp_to_datetime (line 30) | def safe_timestamp_to_datetime(timestamp_value): function get_analysis_results_dir (line 46) | def get_analysis_results_dir(): function get_favorites_file (line 52) | def get_favorites_file(): function get_tags_file (line 56) | def get_tags_file(): function load_favorites (line 60) | def load_favorites(): function save_favorites (line 71) | def save_favorites(favorites): function load_tags (line 81) | def load_tags(): function save_tags (line 92) | def save_tags(tags): function add_tag_to_analysis (line 102) | def add_tag_to_analysis(analysis_id, tag): function remove_tag_from_analysis (line 111) | def remove_tag_from_analysis(analysis_id, tag): function get_analysis_tags (line 120) | def get_analysis_tags(analysis_id): function load_analysis_results (line 125) | def load_analysis_results(start_date=None, end_date=None, stock_symbol=N... function render_analysis_results (line 333) | def render_analysis_results(): function render_results_list (line 452) | def render_results_list(results: List[Dict[str, Any]]): function render_results_table (line 477) | def render_results_table(results: List[Dict[str, Any]]): function render_results_cards (line 497) | def render_results_cards(results: List[Dict[str, Any]]): function toggle_favorite (line 591) | def toggle_favorite(analysis_id): function render_results_comparison (line 600) | def render_results_comparison(results: List[Dict[str, Any]]): function render_results_charts (line 695) | def render_results_charts(results: List[Dict[str, Any]]): function render_tags_management (line 813) | def render_tags_management(results: List[Dict[str, Any]]): function render_results_export (line 890) | def render_results_export(results: List[Dict[str, Any]]): function render_results_comparison (line 974) | def render_results_comparison(results: List[Dict[str, Any]]): function render_detailed_analysis (line 1173) | def render_detailed_analysis(results: List[Dict[str, Any]]): function render_detailed_analysis_content (line 1240) | def render_detailed_analysis_content(selected_result): function render_investment_debate_content (line 1561) | def render_investment_debate_content(content): function render_risk_debate_content (line 1575) | def render_risk_debate_content(content): function save_analysis_result (line 1593) | def save_analysis_result(analysis_id: str, stock_symbol: str, analysts: ... function show_expanded_detail (line 1695) | def show_expanded_detail(result): FILE: web/components/async_progress_display.py class AsyncProgressDisplay (line 16) | class AsyncProgressDisplay: method __init__ (line 19) | def __init__(self, container, analysis_id: str, refresh_interval: floa... method update_display (line 38) | def update_display(self) -> bool: method _render_progress (line 63) | def _render_progress(self, progress_data: Dict[str, Any]): function create_async_progress_display (line 148) | def create_async_progress_display(container, analysis_id: str, refresh_i... function auto_refresh_progress (line 152) | def auto_refresh_progress(display: AsyncProgressDisplay, max_duration: f... function streamlit_auto_refresh_progress (line 179) | def streamlit_auto_refresh_progress(analysis_id: str, refresh_interval: ... function display_static_progress (line 278) | def display_static_progress(analysis_id: str) -> bool: function display_unified_progress (line 413) | def display_unified_progress(analysis_id: str, show_refresh_controls: bo... function display_static_progress_with_controls (line 425) | def display_static_progress_with_controls(analysis_id: str, show_refresh... FILE: web/components/header.py function render_header (line 7) | def render_header(): FILE: web/components/login.py class SimpleAuthManager (line 45) | class SimpleAuthManager: method __init__ (line 46) | def __init__(self): method is_authenticated (line 50) | def is_authenticated(self): method authenticate (line 53) | def authenticate(self, username, password): method logout (line 61) | def logout(self): method get_current_user (line 65) | def get_current_user(self): method require_permission (line 68) | def require_permission(self, permission): function get_base64_image (line 73) | def get_base64_image(image_path): function render_login_form (line 81) | def render_login_form(): function render_sidebar_user_info (line 294) | def render_sidebar_user_info(): function render_sidebar_logout (line 388) | def render_sidebar_logout(): function render_user_info (line 433) | def render_user_info(): function check_authentication (line 545) | def check_authentication(): function require_permission (line 552) | def require_permission(permission: str): FILE: web/components/operation_logs.py function get_operation_logs_dir (line 20) | def get_operation_logs_dir(): function get_user_activities_dir (line 26) | def get_user_activities_dir(): function load_operation_logs (line 31) | def load_operation_logs(start_date=None, end_date=None, username=None, a... function render_operation_logs (line 150) | def render_operation_logs(): function render_logs_charts (line 263) | def render_logs_charts(logs: List[Dict[str, Any]]): function render_logs_list (line 346) | def render_logs_list(logs: List[Dict[str, Any]]): function render_logs_export (line 409) | def render_logs_export(logs: List[Dict[str, Any]]): function log_operation (line 535) | def log_operation(username: str, action_type: str, action: str, details:... FILE: web/components/results_display.py function render_results (line 18) | def render_results(results): function render_analysis_info (line 77) | def render_analysis_info(results): function render_decision_summary (line 142) | def render_decision_summary(decision, stock_symbol=None): function render_detailed_analysis (line 278) | def render_detailed_analysis(state): function render_investment_debate_content (line 476) | def render_investment_debate_content(content): function render_risk_debate_content (line 492) | def render_risk_debate_content(content): function render_analysis_placeholder (line 513) | def render_analysis_placeholder(): function render_risk_warning (line 557) | def render_risk_warning(): function create_price_chart (line 576) | def create_price_chart(price_data): function create_sentiment_gauge (line 604) | def create_sentiment_gauge(sentiment_score): FILE: web/components/sidebar.py function get_version (line 20) | def get_version(): function render_sidebar (line 32) | def render_sidebar(): FILE: web/components/user_activity_dashboard.py function render_user_activity_dashboard (line 22) | def render_user_activity_dashboard(): function render_activity_charts (line 116) | def render_activity_charts(activities: List[Dict[str, Any]]): function render_activity_list (line 183) | def render_activity_list(activities: List[Dict[str, Any]]): function render_user_analysis (line 227) | def render_user_analysis(activities: List[Dict[str, Any]]): function render_export_options (line 277) | def render_export_options(activities: List[Dict[str, Any]]): function render_activity_summary_widget (line 354) | def render_activity_summary_widget(): FILE: web/modules/cache_management.py function main (line 42) | def main(): FILE: web/modules/config_management.py function render_config_management (line 28) | def render_config_management(): function render_model_config (line 55) | def render_model_config(): function render_pricing_config (line 173) | def render_pricing_config(): function render_usage_statistics (line 273) | def render_usage_statistics(): function render_system_settings (line 385) | def render_system_settings(): function render_env_status (line 503) | def render_env_status(): function main (line 563) | def main(): FILE: web/modules/database_management.py function main (line 29) | def main(): FILE: web/modules/token_statistics.py function render_token_statistics (line 31) | def render_token_statistics(): function render_overview_metrics (line 106) | def render_overview_metrics(stats: Dict[str, Any], time_range: str): function render_detailed_charts (line 160) | def render_detailed_charts(records: List[UsageRecord], stats: Dict[str, ... function render_provider_statistics (line 211) | def render_provider_statistics(stats: Dict[str, Any]): function render_cost_trends (line 265) | def render_cost_trends(records: List[UsageRecord]): function render_detailed_records_table (line 328) | def render_detailed_records_table(records: List[UsageRecord]): function load_detailed_records (line 367) | def load_detailed_records(days: int) -> List[UsageRecord]: function export_statistics_data (line 389) | def export_statistics_data(days: int): function main (line 430) | def main(): FILE: web/run_web.py function check_dependencies (line 19) | def check_dependencies(): function clean_cache_files (line 43) | def clean_cache_files(force_clean=False): function check_api_keys (line 158) | def check_api_keys(): function main (line 190) | def main(): FILE: web/utils/analysis_runner.py function translate_analyst_labels (line 36) | def translate_analyst_labels(text): function extract_risk_assessment (line 60) | def extract_risk_assessment(state): function run_stock_analysis (line 100) | def run_stock_analysis(stock_symbol, analysis_date, analysts, research_d... function format_analysis_results (line 625) | def format_analysis_results(results): function validate_analysis_params (line 772) | def validate_analysis_params(stock_symbol, analysis_date, analysts, rese... function get_supported_stocks (line 829) | def get_supported_stocks(): function generate_demo_results_deprecated (line 850) | def generate_demo_results_deprecated(stock_symbol, analysis_date, analys... FILE: web/utils/api_checker.py function check_api_keys (line 7) | def check_api_keys(): function get_api_key_status_message (line 83) | def get_api_key_status_message(): function validate_api_key_format (line 96) | def validate_api_key_format(key_type, api_key): function test_api_connection (line 119) | def test_api_connection(key_type, api_key): FILE: web/utils/async_progress_tracker.py function safe_serialize (line 19) | def safe_serialize(obj): class AsyncProgressTracker (line 72) | class AsyncProgressTracker: method __init__ (line 75) | def __init__(self, analysis_id: str, analysts: List[str], research_dep... method _init_redis (line 145) | def _init_redis(self) -> bool: method _generate_dynamic_steps (line 190) | def _generate_dynamic_steps(self) -> List[Dict]: method _get_analyst_display_name (line 244) | def _get_analyst_display_name(self, analyst: str) -> str: method _get_analyst_step_info (line 255) | def _get_analyst_step_info(self, analyst: str) -> Dict[str, str]: method _estimate_total_duration (line 293) | def _estimate_total_duration(self) -> float: method update_progress (line 324) | def update_progress(self, message: str, step: Optional[int] = None): method _detect_step_from_message (line 389) | def _detect_step_from_message(self, message: str) -> Optional[int]: method _find_step_by_keyword (line 454) | def _find_step_by_keyword(self, keywords) -> Optional[int]: method _get_next_step (line 465) | def _get_next_step(self, keyword: str) -> Optional[int]: method _calculate_weighted_progress (line 472) | def _calculate_weighted_progress(self) -> float: method _estimate_remaining_time (line 486) | def _estimate_remaining_time(self, progress: float, elapsed_time: floa... method _save_progress (line 498) | def _save_progress(self): method get_progress (line 553) | def get_progress(self) -> Dict[str, Any]: method mark_completed (line 557) | def mark_completed(self, message: str = "分析完成", results: Any = None): method mark_failed (line 583) | def mark_failed(self, error_message: str): function get_progress_by_id (line 598) | def get_progress_by_id(analysis_id: str) -> Optional[Dict[str, Any]]: function format_time (line 650) | def format_time(seconds: float) -> str: function get_latest_analysis_id (line 662) | def get_latest_analysis_id() -> Optional[str]: FILE: web/utils/auth_manager.py class AuthManager (line 26) | class AuthManager: method __init__ (line 29) | def __init__(self): method _ensure_users_file (line 34) | def _ensure_users_file(self): method _inject_auth_cache_js (line 61) | def _inject_auth_cache_js(self): method _hash_password (line 151) | def _hash_password(self, password: str) -> str: method _load_users (line 155) | def _load_users(self) -> Dict: method authenticate (line 164) | def authenticate(self, username: str, password: str) -> Tuple[bool, Op... method check_permission (line 204) | def check_permission(self, permission: str) -> bool: method is_authenticated (line 222) | def is_authenticated(self) -> bool: method login (line 247) | def login(self, username: str, password: str) -> bool: method logout (line 295) | def logout(self): method restore_from_cache (line 323) | def restore_from_cache(self, user_info: Dict, login_time: float = None... method get_current_user (line 362) | def get_current_user(self) -> Optional[Dict]: method require_permission (line 368) | def require_permission(self, permission: str) -> bool: FILE: web/utils/cookie_manager.py class CookieManager (line 18) | class CookieManager: method __init__ (line 21) | def __init__(self): method set_analysis_state (line 45) | def set_analysis_state(self, analysis_id: str, status: str = "running", method get_analysis_state (line 72) | def get_analysis_state(self) -> Optional[Dict[str, Any]]: method clear_analysis_state (line 102) | def clear_analysis_state(self): method get_debug_info (line 117) | def get_debug_info(self) -> Dict[str, Any]: function get_persistent_analysis_id (line 140) | def get_persistent_analysis_id() -> Optional[str]: function set_persistent_analysis_id (line 170) | def set_persistent_analysis_id(analysis_id: str, status: str = "running", FILE: web/utils/docker_pdf_adapter.py function is_docker_environment (line 16) | def is_docker_environment() -> bool: function setup_xvfb_display (line 34) | def setup_xvfb_display(): function get_docker_wkhtmltopdf_args (line 68) | def get_docker_wkhtmltopdf_args(): function test_docker_pdf_generation (line 82) | def test_docker_pdf_generation() -> bool: function get_docker_pdf_extra_args (line 140) | def get_docker_pdf_extra_args(): function check_docker_pdf_dependencies (line 162) | def check_docker_pdf_dependencies(): function get_docker_status_info (line 203) | def get_docker_status_info(): FILE: web/utils/file_session_manager.py class FileSessionManager (line 15) | class FileSessionManager: method __init__ (line 18) | def __init__(self): method _get_browser_fingerprint (line 23) | def _get_browser_fingerprint(self) -> str: method _get_session_file_path (line 64) | def _get_session_file_path(self, fingerprint: str) -> Path: method _cleanup_old_sessions (line 68) | def _cleanup_old_sessions(self): method save_analysis_state (line 86) | def save_analysis_state(self, analysis_id: str, status: str = "running", method load_analysis_state (line 128) | def load_analysis_state(self) -> Optional[Dict[str, Any]]: method clear_analysis_state (line 155) | def clear_analysis_state(self): method get_debug_info (line 174) | def get_debug_info(self) -> Dict[str, Any]: function get_persistent_analysis_id (line 210) | def get_persistent_analysis_id() -> Optional[str]: function set_persistent_analysis_id (line 251) | def set_persistent_analysis_id(analysis_id: str, status: str = "running", FILE: web/utils/mongodb_report_manager.py class MongoDBReportManager (line 24) | class MongoDBReportManager: method __init__ (line 27) | def __init__(self): method _connect (line 36) | def _connect(self): method _create_indexes (line 90) | def _create_indexes(self): method save_analysis_report (line 109) | def save_analysis_report(self, stock_symbol: str, analysis_results: Di... method get_analysis_reports (line 207) | def get_analysis_reports(self, limit: int = 100, stock_symbol: str = N... method get_report_by_id (line 270) | def get_report_by_id(self, analysis_id: str) -> Optional[Dict[str, Any]]: method delete_report (line 302) | def delete_report(self, analysis_id: str) -> bool: method get_all_reports (line 321) | def get_all_reports(self, limit: int = 1000) -> List[Dict[str, Any]]: method fix_inconsistent_reports (line 343) | def fix_inconsistent_reports(self) -> bool: method save_report (line 398) | def save_report(self, report_data: Dict[str, Any]) -> bool: FILE: web/utils/persistence.py class ModelPersistence (line 13) | class ModelPersistence: method __init__ (line 16) | def __init__(self): method save_config (line 19) | def save_config(self, provider, category, model): method load_config (line 41) | def load_config(self): method clear_config (line 72) | def clear_config(self): function save_model_selection (line 86) | def save_model_selection(provider, category="", model=""): function load_model_selection (line 90) | def load_model_selection(): function clear_model_selection (line 94) | def clear_model_selection(): FILE: web/utils/progress_log_handler.py class ProgressLogHandler (line 11) | class ProgressLogHandler(logging.Handler): method register_tracker (line 21) | def register_tracker(cls, analysis_id: str, tracker): method unregister_tracker (line 32) | def unregister_tracker(cls, analysis_id: str): method emit (line 46) | def emit(self, record): method _extract_stock_symbol (line 76) | def _extract_stock_symbol(self, message: str) -> Optional[str]: function setup_progress_log_integration (line 90) | def setup_progress_log_integration(): function register_analysis_tracker (line 106) | def register_analysis_tracker(analysis_id: str, tracker): function unregister_analysis_tracker (line 111) | def unregister_analysis_tracker(analysis_id: str): FILE: web/utils/progress_tracker.py class SmartAnalysisProgressTracker (line 14) | class SmartAnalysisProgressTracker: method __init__ (line 17) | def __init__(self, analysts: List[str], research_depth: int, llm_provi... method _generate_dynamic_steps (line 30) | def _generate_dynamic_steps(self) -> List[Dict]: method _get_analyst_display_name (line 55) | def _get_analyst_display_name(self, analyst: str) -> str: method _estimate_total_duration (line 66) | def _estimate_total_duration(self) -> float: method update (line 97) | def update(self, message: str, step: Optional[int] = None, total_steps... method _calculate_weighted_progress (line 138) | def _calculate_weighted_progress(self) -> float: method _estimate_remaining_time (line 152) | def _estimate_remaining_time(self, progress: float, elapsed_time: floa... method _detect_step_from_message (line 161) | def _detect_step_from_message(self, message: str) -> Optional[int]: method get_current_step_info (line 240) | def get_current_step_info(self) -> Dict: method get_progress_percentage (line 246) | def get_progress_percentage(self) -> float: method get_elapsed_time (line 250) | def get_elapsed_time(self) -> float: method get_estimated_total_time (line 254) | def get_estimated_total_time(self) -> float: method format_time (line 258) | def format_time(self, seconds: float) -> str: class SmartStreamlitProgressDisplay (line 269) | class SmartStreamlitProgressDisplay: method __init__ (line 272) | def __init__(self, container): method setup_display (line 280) | def setup_display(self): method update (line 289) | def update(self, message: str, current_step: int, total_steps: int, pr... method _format_time (line 308) | def _format_time(self, seconds: float) -> str: method clear (line 319) | def clear(self): function create_smart_progress_callback (line 323) | def create_smart_progress_callback(display: SmartStreamlitProgressDispla... function create_progress_callback (line 349) | def create_progress_callback(display, analysts=None, research_depth=2, l... FILE: web/utils/redis_session_manager.py class RedisSessionManager (line 12) | class RedisSessionManager: method __init__ (line 15) | def __init__(self): method _init_redis (line 21) | def _init_redis(self) -> bool: method _get_session_key (line 59) | def _get_session_key(self) -> str: method save_analysis_state (line 86) | def save_analysis_state(self, analysis_id: str, status: str = "running", method load_analysis_state (line 129) | def load_analysis_state(self) -> Optional[Dict[str, Any]]: method clear_analysis_state (line 149) | def clear_analysis_state(self): method _save_to_file (line 170) | def _save_to_file(self, session_key: str, session_data: Dict[str, Any]): method _load_from_file (line 183) | def _load_from_file(self, session_key: str) -> Optional[Dict[str, Any]]: method _delete_file (line 205) | def _delete_file(self, session_key: str): method get_debug_info (line 215) | def get_debug_info(self) -> Dict[str, Any]: function get_persistent_analysis_id (line 255) | def get_persistent_analysis_id() -> Optional[str]: function set_persistent_analysis_id (line 287) | def set_persistent_analysis_id(analysis_id: str, status: str = "running", FILE: web/utils/report_exporter.py class ReportExporter (line 86) | class ReportExporter: method __init__ (line 89) | def __init__(self): method _clean_text_for_markdown (line 107) | def _clean_text_for_markdown(self, text: str) -> str: method _clean_markdown_for_pandoc (line 128) | def _clean_markdown_for_pandoc(self, content: str) -> str: method generate_markdown_report (line 166) | def generate_markdown_report(self, results: Dict[str, Any]) -> str: method _add_team_decision_reports (line 267) | def _add_team_decision_reports(self, md_content: str, state: Dict[str,... method _format_team_decision_content (line 333) | def _format_team_decision_content(self, content: Dict[str, Any], modul... method generate_docx_report (line 371) | def generate_docx_report(self, results: Dict[str, Any]) -> bytes: method generate_pdf_report (line 445) | def generate_pdf_report(self, results: Dict[str, Any]) -> bytes: method export_report (line 544) | def export_report(self, results: Dict[str, Any], format_type: str) -> ... function _format_team_decision_content (line 602) | def _format_team_decision_content(content: Dict[str, Any], module_key: s... function save_modular_reports_to_results_dir (line 641) | def save_modular_reports_to_results_dir(results: Dict[str, Any], stock_s... function save_report_to_results_dir (line 854) | def save_report_to_results_dir(content: bytes, filename: str, stock_symb... function render_export_buttons (line 900) | def render_export_buttons(results: Dict[str, Any]): function save_analysis_report (line 1165) | def save_analysis_report(stock_symbol: str, analysis_results: Dict[str, ... FILE: web/utils/session_persistence.py class SessionPersistenceManager (line 14) | class SessionPersistenceManager: method __init__ (line 17) | def __init__(self): method _get_browser_fingerprint (line 21) | def _get_browser_fingerprint(self) -> str: method _get_session_file_path (line 37) | def _get_session_file_path(self, fingerprint: str) -> str: method save_analysis_state (line 41) | def save_analysis_state(self, analysis_id: str, status: str = "running", method load_analysis_state (line 77) | def load_analysis_state(self) -> Optional[Dict[str, Any]]: method clear_analysis_state (line 104) | def clear_analysis_state(self): method get_debug_info (line 123) | def get_debug_info(self) -> Dict[str, Any]: function get_persistent_analysis_id (line 153) | def get_persistent_analysis_id() -> Optional[str]: function set_persistent_analysis_id (line 185) | def set_persistent_analysis_id(analysis_id: str, status: str = "running", FILE: web/utils/smart_session_manager.py class SmartSessionManager (line 10) | class SmartSessionManager: method __init__ (line 13) | def __init__(self): method _init_redis_manager (line 19) | def _init_redis_manager(self) -> bool: method _init_file_manager (line 34) | def _init_file_manager(self): method save_analysis_state (line 42) | def save_analysis_state(self, analysis_id: str, status: str = "running", method load_analysis_state (line 69) | def load_analysis_state(self) -> Optional[Dict[str, Any]]: method clear_analysis_state (line 91) | def clear_analysis_state(self): method get_debug_info (line 107) | def get_debug_info(self) -> Dict[str, Any]: function get_persistent_analysis_id (line 136) | def get_persistent_analysis_id() -> Optional[str]: function set_persistent_analysis_id (line 171) | def set_persistent_analysis_id(analysis_id: str, status: str = "running", function get_session_debug_info (line 192) | def get_session_debug_info() -> Dict[str, Any]: FILE: web/utils/thread_tracker.py class ThreadTracker (line 13) | class ThreadTracker: method __init__ (line 16) | def __init__(self): method register_thread (line 20) | def register_thread(self, analysis_id: str, thread: threading.Thread): method unregister_thread (line 26) | def unregister_thread(self, analysis_id: str): method is_thread_alive (line 33) | def is_thread_alive(self, analysis_id: str) -> bool: method get_alive_threads (line 48) | def get_alive_threads(self) -> Dict[str, threading.Thread]: method cleanup_dead_threads (line 67) | def cleanup_dead_threads(self): method get_thread_info (line 71) | def get_thread_info(self, analysis_id: str) -> Optional[Dict]: method get_all_thread_info (line 86) | def get_all_thread_info(self) -> Dict[str, Dict]: function register_analysis_thread (line 103) | def register_analysis_thread(analysis_id: str, thread: threading.Thread): function unregister_analysis_thread (line 107) | def unregister_analysis_thread(analysis_id: str): function is_analysis_thread_alive (line 111) | def is_analysis_thread_alive(analysis_id: str) -> bool: function get_analysis_thread_info (line 115) | def get_analysis_thread_info(analysis_id: str) -> Optional[Dict]: function cleanup_dead_analysis_threads (line 119) | def cleanup_dead_analysis_threads(): function get_all_analysis_threads (line 123) | def get_all_analysis_threads() -> Dict[str, Dict]: function check_analysis_status (line 127) | def check_analysis_status(analysis_id: str) -> str: FILE: web/utils/ui_utils.py function apply_hide_deploy_button_css (line 9) | def apply_hide_deploy_button_css(): function apply_common_styles (line 80) | def apply_common_styles(): FILE: web/utils/user_activity_logger.py class UserActivity (line 21) | class UserActivity: class UserActivityLogger (line 37) | class UserActivityLogger: method __init__ (line 40) | def __init__(self): method _get_activity_file_path (line 61) | def _get_activity_file_path(self, date: str = None) -> Path: method _get_session_id (line 67) | def _get_session_id(self) -> str: method _get_user_info (line 73) | def _get_user_info(self) -> Dict[str, str]: method _get_request_info (line 83) | def _get_request_info(self) -> Dict[str, Optional[str]]: method log_activity (line 100) | def log_activity(self, method _write_activity (line 143) | def _write_activity(self, activity: UserActivity) -> None: method log_login (line 160) | def log_login(self, username: str, success: bool, error_message: str =... method log_logout (line 170) | def log_logout(self, username: str) -> None: method log_analysis_request (line 178) | def log_analysis_request(self, stock_code: str, analysis_type: str, su... method log_page_visit (line 193) | def log_page_visit(self, page_name: str, page_params: Dict[str, Any] =... method log_config_change (line 204) | def log_config_change(self, config_type: str, changes: Dict[str, Any])... method log_data_export (line 215) | def log_data_export(self, export_type: str, data_info: Dict[str, Any], method log_user_management (line 229) | def log_user_management(self, operation: str, target_user: str, method get_user_activities (line 240) | def get_user_activities(self, username: str = None, method _read_activities_from_file (line 292) | def _read_activities_from_file(self, file_path: Path, username: str = ... method get_activity_statistics (line 324) | def get_activity_statistics(self, days: int = 7) -> Dict[str, Any]: method cleanup_old_activities (line 379) | def cleanup_old_activities(self, days_to_keep: int = 90) -> int: