mirror of
https://github.com/langgenius/dify-official-plugins.git
synced 2026-07-21 17:45:23 -04:00
[PR #2333] [MERGED] feat(cot_agent): refactor ReAct output parser and enhance json parsing #2407
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/langgenius/dify-official-plugins/pull/2333
Author: @whhe
Created: 12/25/2025
Status: ✅ Merged
Merged: 12/28/2025
Merged by: @crazywoola
Base:
main← Head:enhance-react-parsing📝 Commits (3)
be3a6b8feat(cot_agent): refactor ReAct output parser and enhance json parsing65b8bb4update version1a8c7eaUpdate agent-strategies/cot_agent/output_parser/cot_output_parser.py📊 Changes
3 files changed (+117 additions, -117 deletions)
View changed files
📝
agent-strategies/cot_agent/manifest.yaml(+1 -1)📝
agent-strategies/cot_agent/output_parser/cot_output_parser.py(+114 -114)📝
agent-strategies/cot_agent/prompt/template.py(+2 -2)📄 Description
Related Issues or Context
Major changes:
Change the response prefix from "Answer" to "FinalAnswer" to avoid mismatches due to the same first letter as “Action”.
Extracted the matching logic into the utility class
PrefixMatcher.Added support for complex JSON types.
This PR contains Changes to Non-Plugin
This PR contains Changes to Non-LLM Models Plugin
This PR contains Changes to LLM Models Plugin
Version Control (Any Changes to the Plugin Will Require Bumping the Version)
VersionField, Not in Meta Section)Dify Plugin SDK Version
dify_plugin>=0.3.0,<0.6.0is in requirements.txt (SDK docs)Environment Verification (If Any Code Changes)
Local Deployment Environment
SaaS Environment
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.