The Cognitive Distortion Journal (CDJ) is a smart journaling tool that helps remedy distorted thinking. It can feel impossible to follow the CBT technique of labeling and reframing distorted thinking when you've been thinking this way your whole life. The CDJ can help with that 🧠✨ -- v2 is in development!
Currently the CdGpt response is getting unpacked as a JSON string in Message.content. This isn't fully capturing what the LLM returns, which appears to more closely match the FormatInstructions interface. More validation needs to happen with the LLM response as well as it is non-deterministic.
Figure out an appropriate type for the LLM response and implement validation for it.
Currently the CdGpt response is getting unpacked as a JSON string in
Message.content
. This isn't fully capturing what the LLM returns, which appears to more closely match theFormatInstructions
interface. More validation needs to happen with the LLM response as well as it is non-deterministic.Figure out an appropriate type for the LLM response and implement validation for it.
Accomplish TODO below from commit in backend/src/models/entry/entryAnalysis.ts of #169 and remove ESLint disable comments.
Line: 16 Message: // TODO: any should be replaced with return type from cdgpt response Commit: 6007601