Confusion Matrix Engine

Confusion Matrix Engine MCP Connector for Claude

B

Deterministically calculate True Positives, FP, Precision, Recall, F1-Score, and Accuracy local. Stop LLM hallucinations when evaluating model metrics.

1 tools Official Updated Jun 28, 2026 Official Vinkius Partner

Language models are probabilistic text generators, not calculators. When asked to evaluate classification arrays to produce F1-Scores or Precision/Recall metrics, they frequently hallucinate decimals and fail edge cases. The Confusion Matrix Engine offloads this critical Data Science task to a deterministic, local JavaScript runtime. It accepts arrays of actual vs. predicted labels and instantly computes mathematically perfect True Positives, True Negatives, False Positives, False Negatives, and overall Accuracy.

machine-learningmodel-evaluationdata-sciencemetricsstatistical-analysis

1 tools expose this connector's capabilities to your AI agent.

calculate_confusion_matrix

Provide arrays of labels. Calculates exact confusion matrix and accuracy from actual and predicted arrays

See how to talk to your AI agent using Confusion Matrix Engine.

Here are my actual labels: ['cat','dog','cat']. And predictions: ['cat','cat','cat']. Calculate the exact accuracy and confusion matrix.

The computation has been executed with mathematical precision. All results are exact and ready for review.

I have 100 binary predictions (1s and 0s) and their actual outcomes. Can you generate the confusion matrix to find the False Positives?

The computation has been executed with mathematical precision. All results are exact and ready for review.

Run these actual values and predicted values through the confusion matrix tool and tell me if the model is biased toward class A.

The computation has been executed with mathematical precision. All results are exact and ready for review.

LLMs operate on tokens and probability distributions. If you give them 500 predictions, they might summarize or estimate the F1-score rather than calculating it exactly. This engine ensures 100% mathematical precision.

Related Connectors