Parse a raw LLM fenced response
parse_turn_responseParses raw LLM responses to extract the fenced JSON block, separating discardable reasoning from the structured state patch and action, preventing syntax slips.
Instructions
Parses a raw LLM response string containing free-form reasoning and a fenced ```json block { 'state_patch': {...}, 'action': '...' } per arXiv:2608.26263 Appendix A.4. Separates the reasoning trace R_t (for discarding) from the structured payload, mitigating JSON syntax slips (arXiv:2608.26263 §5.7).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| response_text | Yes | Raw text response from the LLM containing free-form reasoning and a fenced ```json block conforming to Appendix A.4: { 'state_patch': {...}, 'action': '...' }. |