mirror of
https://github.com/simonlin1212/TradingAgents-astock.git
synced 2026-08-31 01:23:38 +00:00
- 适配A股数据源(mootdx+腾讯财经+akshare),全免费无积分墙 - 新增3个A股特化分析师(政策/游资/解禁),共7位AI分析师 - A股交易规则约束(T+1/涨跌停/最小手数/ST标识) - 内置Streamlit Web UI + PDF报告导出 - 支持MiniMax/DeepSeek/智谱/通义/OpenAI/Anthropic等多家LLM - 沪深300基准替代SPY
12 lines
637 B
Python
12 lines
637 B
Python
import time
|
|
from tradingagents.dataflows.y_finance import get_YFin_data_online, get_stock_stats_indicators_window, get_balance_sheet as get_yfinance_balance_sheet, get_cashflow as get_yfinance_cashflow, get_income_statement as get_yfinance_income_statement, get_insider_transactions as get_yfinance_insider_transactions
|
|
|
|
print("Testing optimized implementation with 30-day lookback:")
|
|
start_time = time.time()
|
|
result = get_stock_stats_indicators_window("AAPL", "macd", "2024-11-01", 30)
|
|
end_time = time.time()
|
|
|
|
print(f"Execution time: {end_time - start_time:.2f} seconds")
|
|
print(f"Result length: {len(result)} characters")
|
|
print(result)
|