A single user 👍/👎 on an AI output, tagged to the LangSmith run that produced it.
Durability: feedback is an INDEPENDENT record. Every domain reference (patient_id,
patient_session_id, audit_run_id, audit_response_id, audit_question_id, entity_id) is
ON DELETE SET NULL — deleting a patient / session / audit run must never cascade into or delete
feedback. The durable target_ref / langsmith_run_id / langsmith_thread_id and the snapshotted
prompt_version/model keep the row meaningful after its domain parent is gone.
A single user 👍/👎 on an AI output, tagged to the LangSmith run that produced it.
Durability: feedback is an INDEPENDENT record. Every domain reference (
patient_id,patient_session_id,audit_run_id,audit_response_id,audit_question_id,entity_id) isON DELETE SET NULL— deleting a patient / session / audit run must never cascade into or delete feedback. The durabletarget_ref/langsmith_run_id/langsmith_thread_idand the snapshottedprompt_version/modelkeep the row meaningful after its domain parent is gone.