Skip to content

fix: prevent group_data override in MAS and add missing replanner_agent_name#133

Merged
JDOxygen merged 1 commit intojd-opensource:mainfrom
Takki-cd:fix/bugfix-0331
Mar 31, 2026
Merged

fix: prevent group_data override in MAS and add missing replanner_agent_name#133
JDOxygen merged 1 commit intojd-opensource:mainfrom
Takki-cd:fix/bugfix-0331

Conversation

@Takki-cd
Copy link
Copy Markdown
Contributor

Summary

Fix two bugs in OxyGent framework: group_data being unexpectedly overwritten in MAS and missing replanner_agent_name field in PlanAndSolve flow.

Changes

  1. MAS (mas.py) - Fix group_data override issue
  • Problem: When from_trace_id is provided, the framework correctly merges historical group_data from ES with current group_data. However, a subsequent loop overwrites the merged result with the raw payload value, This causes historical context to be lost when other agents or
    frontend pass their own group_data.
  • Solution: Reorder the code to set all payload fields first, then perform the special group_data merge logic. This ensures the merged result is the final value.
  1. PlanAndSolve (plan_and_solve.py) - Add missing replanner_agent_name
  • Problem: replanner_agent_name is used in the code when enable_replanner=True, but the field was never defined, causing AttributeError.
  • Solution: Add the missing field definition with default value "replanner_agent".

Impact

  • Users can now safely pass group_data in multi-agent scenarios without losing historical context
  • enable_replanner feature in PlanAndSolve will work correctly

@JDOxygen JDOxygen merged commit 6eaf5d4 into jd-opensource:main Mar 31, 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