Skip to main content
POST
/
batches
/
{batch_id}
/
feedback
{
  "batch_id": "<string>",
  "feedback_session_id": "<string>",
  "submitted_count": 123,
  "failed_count": 123,
  "processing_status": "<string>",
  "validation_results": [
    {
      "evaluation_id": "<string>",
      "status": "<string>",
      "message": "<string>",
      "feedback_id": "<string>"
    }
  ],
  "impact_analysis": {
    "significant_corrections": 123,
    "approval_rate": 123,
    "average_rating": 123,
    "retraining_recommended": true
  },
  "submitted_at": {}
}

Overview

Submits feedback for multiple evaluations within a batch. This endpoint allows you to provide corrections, ratings, and comments for batch processing results, which helps improve judge performance through machine learning.

Path Parameters

batch_id
string
required
Unique identifier of the batch

Request Body

feedback_entries
array
required
List of feedback entries for evaluations in the batch
feedback_options
object
Global feedback options for the batch

Response

batch_id
string
required
ID of the batch feedback was submitted for
feedback_session_id
string
required
Unique identifier for this feedback submission session
submitted_count
integer
required
Number of feedback entries successfully submitted
failed_count
integer
required
Number of feedback entries that failed validation
processing_status
string
required
Status of feedback processing
  • submitted - Feedback submitted successfully
  • processing - Feedback being processed
  • processed - Feedback processing completed
  • failed - Feedback processing failed
validation_results
array
Results of feedback validation
impact_analysis
object
Analysis of feedback impact
submitted_at
datetime
required
Timestamp when feedback was submitted

Examples

curl -X POST https://api.judge.example.com/batches/batch_abc123/feedback \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "feedback_entries": [
      {
        "evaluation_id": "eval_001",
        "type": "correction",
        "content": {
          "corrected_scores": {
            "crit_quality": 85,
            "crit_relevance": 90
          },
          "corrected_overall_score": 87,
          "explanation": "The content quality was underestimated"
        },
        "criterion_specific": true,
        "target_criteria": ["crit_quality", "crit_relevance"],
        "severity": "high"
      },
      {
        "evaluation_id": "eval_002",
        "type": "approval",
        "content": {
          "approved": true,
          "comment": "Accurate evaluation"
        },
        "severity": "low"
      },
      {
        "evaluation_id": "eval_003",
        "type": "rating",
        "content": {
          "rating": 8,
          "comment": "Good evaluation with minor issues"
        },
        "severity": "medium"
      }
    ],
    "feedback_options": {
      "auto_trigger_retraining": true,
      "notification_preferences": {
        "email": true,
        "webhook_url": "https://your-app.com/webhooks/feedback"
      }
    }
  }'
curl -X POST https://api.judge.example.com/batches/batch_abc123/feedback \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "feedback_entries": [
      {
        "evaluation_id": "eval_invalid",
        "type": "rating",
        "content": {
          "rating": 8
        }
      }
    ]
  }'
curl -X POST https://api.judge.example.com/batches/invalid_batch/feedback \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "feedback_entries": [
      {
        "evaluation_id": "eval_001",
        "type": "rating",
        "content": {"rating": 8}
      }
    ]
  }'