fix: preserve exchange-qualified tickers across agent prompts

This commit is contained in:
CadeYu
2026-03-21 13:10:09 +08:00
parent f362a160c3
commit 08bfe70a69
11 changed files with 91 additions and 24 deletions
@@ -1,9 +1,13 @@
import time
import json
from tradingagents.agents.utils.agent_utils import build_instrument_context
def create_research_manager(llm, memory):
def research_manager_node(state) -> dict:
ticker = state["company_of_interest"]
instrument_context = build_instrument_context(ticker)
history = state["investment_debate_state"].get("history", "")
market_research_report = state["market_report"]
sentiment_report = state["sentiment_report"]
@@ -33,6 +37,8 @@ Take into account your past mistakes on similar situations. Use these insights t
Here are your past reflections on mistakes:
\"{past_memory_str}\"
{instrument_context}
Here is the debate:
Debate History:
{history}"""