Overview
Add feedback ratings to requests to track user satisfaction and quality of LLM responses. Feedback can be used to identify problematic requests, improve prompts, and train evaluation models.Endpoint
string
required
POST
string
required
/v1/request//feedback
Authentication
Requires API key authentication via theAuthorization header:
Path Parameters
string
required
The unique identifier of the request to add feedback to
Request Body
boolean
required
The feedback rating for the request
true- Positive feedback (thumbs up)false- Negative feedback (thumbs down)
Response
Returns a success or error response.null
Always
null on successstring
Error message if the request failed, otherwise
nullExamples
Positive Feedback
Add a positive (thumbs up) rating:Negative Feedback
Add a negative (thumbs down) rating:Using in Code
Response Examples
Success Response
Error Response
Integration Examples
React Component
Implement feedback buttons in your UI:CLI Tool
Add feedback from the command line:Use Cases
User Feedback Collection
Collect end-user feedback on AI responses:A/B Testing
Compare different prompts or models:Quality Monitoring
Automatically flag low-quality responses:Training Data Generation
Use feedback to create training datasets:Query Requests by Feedback
You can filter requests by feedback using the query endpoint:Notes
- Feedback can be updated by sending another request with a different rating
- Only one feedback rating per request is stored (most recent wins)
- Feedback is immediately reflected in query results and analytics
- Use feedback in combination with custom properties for more detailed tracking
- Feedback data is available in exports and webhooks
- Consider implementing a feedback collection UI thatโs easy for users to access
Best Practices
- Make feedback easy: Place feedback buttons prominently in your UI
- Explain context: Tell users what the feedback is for and how it helps
- Donโt overdo it: Only ask for feedback on important interactions
- Act on feedback: Regularly review negative feedback and improve prompts
- Track trends: Monitor feedback rates over time to measure improvements
- Combine signals: Use feedback alongside evaluation scores for better insights