Skip to content

Fix scanner memory typing in deal pipeline#2

Open
sasmita016 wants to merge 3 commits intoed-donner:mainfrom
sasmita016:feature-2026
Open

Fix scanner memory typing in deal pipeline#2
sasmita016 wants to merge 3 commits intoed-donner:mainfrom
sasmita016:feature-2026

Conversation

@sasmita016
Copy link
Copy Markdown

@sasmita016 sasmita016 commented Mar 15, 2026

What this PR does

  • Aligns ScannerAgent, PlanningAgent, and AutonomousPlanningAgent to consistently treat memory as List[Opportunity].
  • Updates docstrings to reflect the correct memory type.\n\n## Why this change is needed
  • The scanner currently expects URLs (List[str]) in type hints but actually accesses opp.deal.url, which is an Opportunity.
  • This mismatch can lead to runtime errors and confusion when integrating or extending the pipeline.
  • Fixing the types makes the contract explicit and safer without changing behavior.

Notes
No logic changes; only type alignment and doc updates.\n- Smoke-checked by exercising ScannerAgent.test_scan() and fetch_deals() with Opportunity memory.

Subrata Mohapatra and others added 3 commits March 14, 2026 23:37
Title
Fix scanner memory typing in deal pipeline

What this PR does

Aligns the scanner, planner, and autonomous planner to use List[Opportunity] consistently for memory.
Updates related docstrings to reflect the correct memory type.
Why this change is needed

The scanner previously typed memory as List[str] (URLs) but used it as List[Opportunity] (opp.deal.url), which could break at runtime and confused the pipeline contract.
This change ensures the scanner pipeline matches actual usage and avoids type-driven runtime errors.
Notes

This is a behavior‑preserving change focused on type consistency; no workflow logic changes.
Verified with a targeted smoke test of ScannerAgent.test_scan() and fetch_deals() using Opportunity objects.
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.

1 participant