Skip to content

Fix ticker extraction, swarm timeouts, and region warnings in finance assistant#247

Merged
manoj-selvakumar5 merged 3 commits intostrands-agents:mainfrom
mmiakashs:fix/finance-swarm-ticker-and-timeout
Apr 13, 2026
Merged

Fix ticker extraction, swarm timeouts, and region warnings in finance assistant#247
manoj-selvakumar5 merged 3 commits intostrands-agents:mainfrom
mmiakashs:fix/finance-swarm-ticker-and-timeout

Conversation

@mmiakashs
Copy link
Copy Markdown
Contributor

@mmiakashs mmiakashs commented Apr 8, 2026

Summary

  • Fix ticker defaulting to AMZN when orchestrator passes full sentences by adding _extract_ticker() helper
  • Include ticker in all swarm agent system prompts so each agent knows which company to analyze
  • Increase node_timeout (30s → 90s) and execution_timeout (120s → 300s) to prevent timeout errors
  • Remove deprecated region parameter from BedrockModel calls
  • Update model to Opus 4.6 via configurable constants
  • Update orchestrator prompt to instruct passing ticker symbols only

Test plan

  • Run uv run finance_assistant_swarm.py with ticker ALK
  • Verify 0 occurrences of AMZN in output
  • Verify 0 Invalid configuration parameters: ['region'] warnings
  • Verify 0 timeout errors — all swarm runs complete with Status.COMPLETED

… assistant

- Fix ticker defaulting to AMZN when orchestrator passes full sentences
  by adding _extract_ticker() helper with regex-based extraction
- Include ticker in all swarm agent system prompts so financial_analyst
  and market_analyst know which company to analyze
- Increase node_timeout from 30s to 90s and execution_timeout from 120s
  to 300s to prevent premature timeout errors
- Remove deprecated `region` parameter from BedrockModel calls
- Update model to Opus 4.6 via configurable constants
- Update orchestrator prompt to instruct passing ticker symbols only
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 12, 2026

Latest scan for commit: 664f584 | Updated: 2026-04-13 17:41:33 UTC

✅ Security Scan Report (PR Files Only)

Scanned Files

  • python/04-industry-use-cases/finance/finance-assistant-swarm-agent/README.md
  • python/04-industry-use-cases/finance/finance-assistant-swarm-agent/company_analysis_agent.py
  • python/04-industry-use-cases/finance/finance-assistant-swarm-agent/finance_assistant_swarm.py
  • python/04-industry-use-cases/finance/finance-assistant-swarm-agent/financial_metrics_agent.py
  • python/04-industry-use-cases/finance/finance-assistant-swarm-agent/stock_price_agent.py

Security Scan Results

Critical High Medium Low Info
0 0 0 0 0

Threshold: High

No security issues detected in your changes. Great job!

This scan only covers files changed in this PR.

Update swarm model comment to accurately reflect Opus usage instead of
claiming "use a fast model". Remove no-op region="us-east-1" from
BedrockModel calls in standalone agents (BedrockModel accepts region_name,
not region).
@manoj-selvakumar5 manoj-selvakumar5 merged commit de27509 into strands-agents:main Apr 13, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants