Repository navigation
Commit da1a383
committed
fix(semantic-consistency): keep a usable reason when the model omits one
SemanticConsistencyNode#buildValidationResult passed the model's reason
straight into SqlRetryDto.semantic(). A response of {"passed":false}
without a "reason" field therefore stored a null reason, which then
reaches SqlGenerationDTO.exceptionMessage and is rendered into the
{error_message} section of the sql-error-fixer prompt — leaving the
repair model with an empty "错误信息" block and nothing to act on.
Fall back to a generic notice when the reason is blank so the retry
prompt always carries an explanation. Behaviour is unchanged whenever
the model supplies a reason.
Add a regression test asserting the stored reason is never null while
the failure verdict and retry routing are preserved.1 parent 27e7baa commit da1a383
2 files changed
Lines changed: 26 additions & 1 deletion
File tree
- data-agent-management/src
- main/java/com/alibaba/cloud/ai/dataagent/workflow/node
- test/java/com/alibaba/cloud/ai/dataagent/workflow/node
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| 32 | + | |
32 | 33 | | |
33 | 34 | | |
34 | 35 | | |
| |||
109 | 110 | | |
110 | 111 | | |
111 | 112 | | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
112 | 118 | | |
113 | 119 | | |
114 | 120 | | |
115 | 121 | | |
116 | 122 | | |
117 | 123 | | |
118 | 124 | | |
119 | | - | |
| 125 | + | |
| 126 | + | |
120 | 127 | | |
121 | 128 | | |
122 | 129 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
125 | 125 | | |
126 | 126 | | |
127 | 127 | | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
128 | 146 | | |
129 | 147 | | |
130 | 148 | | |
| |||
0 commit comments