POST
/
evaluation
/
metrics
/
alignment
PINECONE_API_KEY="YOUR_API_KEY"

curl https://prod-1-data.ke.pinecone.io/assistant/evaluation/metrics/alignment \
  -H "Api-Key: $PINECONE_API_KEY" \
  -H "Content-Type: application/json" \
  -H "X-Pinecone-Api-Version: 2025-10" \
  -d '{
    "question": "What are the capital cities of France, England and Spain?",
    "answer": "Paris is the capital city of France and Barcelona of Spain",
    "ground_truth_answer": "Paris is the capital city of France, London of England and Madrid of Spain"
}'
{
  "metrics": {
    "correctness": 123,
    "completeness": 123,
    "alignment": 123
  },
  "reasoning": {
    "evaluated_facts": [
      {
        "fact": {
          "content": "<string>"
        },
        "entailment": "entailed"
      }
    ]
  },
  "usage": {
    "prompt_tokens": 123,
    "completion_tokens": 123,
    "total_tokens": 123
  }
}
PINECONE_API_KEY="YOUR_API_KEY"

curl https://prod-1-data.ke.pinecone.io/assistant/evaluation/metrics/alignment \
  -H "Api-Key: $PINECONE_API_KEY" \
  -H "Content-Type: application/json" \
  -H "X-Pinecone-Api-Version: 2025-10" \
  -d '{
    "question": "What are the capital cities of France, England and Spain?",
    "answer": "Paris is the capital city of France and Barcelona of Spain",
    "ground_truth_answer": "Paris is the capital city of France, London of England and Madrid of Spain"
}'

Authorizations

Api-Key
string
header
required

An API Key is required to call Pinecone APIs. Get yours from the console.

Body

application/json

The request body for the alignment evaluation.

The request for the alignment evaluation.

Response

200
application/json

The evaluation metrics and reasoning for the generated answer.

The response for the alignment evaluation.