Skip to content

Add JSON repair and structured response handling#54

Merged
hackall360 merged 2 commits intomainfrom
codex/fix-image-generation-and-json-formatting
Sep 14, 2025
Merged

Add JSON repair and structured response handling#54
hackall360 merged 2 commits intomainfrom
codex/fix-image-generation-and-json-formatting

Conversation

@hackall360
Copy link
Contributor

Summary

  • add JSON repair utility to normalize AI output
  • expand chat-core to parse repaired JSON for images, audio, and UI commands
  • document allowed JSON fields for responses and wire up repair script
  • add json-repair unit test and include in test suite

Testing

  • npm test (fails: fetch failed in PolliLib smoke tests)
  • node tests/markdown-sanitization.mjs (fails: Cannot find module '/workspace/Chat/js/chat/markdown-sanitizer.js')
  • node tests/ai-response.mjs (fails: Cannot find module '/workspace/Chat/js/chat/markdown-sanitizer.js')
  • node tests/json-tools.mjs
  • node tests/json-repair.mjs

https://chatgpt.com/codex/tasks/task_b_68c71690bcf8832fb20e6cae5acf141f

@hackall360 hackall360 merged commit f69daf1 into main Sep 14, 2025
1 check failed
@hackall360 hackall360 deleted the codex/fix-image-generation-and-json-formatting branch September 14, 2025 19:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant