This guide shows how to use the Humanloop SDK to record user feedback on datapoints. This works equivalently for both the completion and chat APIs.
humanloop.chat() or humanloop.complete() to log generations with the Python or TypeScript SDKs. If not, follow our guide to integrating the SDK.Extract the data ID from the humanloop.complete_deployed() response.
Call humanloop.feedback() referencing the saved datapoint ID to record user feedback.
You can also include the source of the feedback when recording it.
The feedback recorded for each datapoint can be viewed in the Logs tab of your project.
Different use cases and user interfaces may require different kinds of feedback that need to be mapped to the appropriate end user interaction. There are broadly 3 important kinds of feedback:
It can also be useful to allow your users to correct the outputs of your model. This is strong feedback signal and can also be considered as ground truth data for finetuning later.
This feedback will also show up within Humanloop, where your internal users can also provide feedback and corrections on logged data to help with evaluation.