Confusion Matrix — 3-class (JSON)
The same 3-class confusion matrix as JSON — a labels array plus a nested counts matrix. The structured twin of the CSV, for testing evaluation tooling.
{
"labels": [
"person",
"car",
"tree"
],
"matrix": [
[
48,
3,
1
],
[
4,
51,
2
],
[
2,
1,
44
]
],
"layout": "rows=actual, cols=predicted"
}
Specifications
- Classes
- 3
- Labels
- person, car, tree
- Layout
- rows = actual, columns = predicted
What is a .json file?
JSON (JavaScript Object Notation) is a lightweight, text-based data-interchange format representing objects, arrays, strings, numbers, booleans, and null. It is language-independent, human-readable, and the dominant format for web APIs and configuration. It requires a single well-formed root value.
How to use this file
Use an example JSON file to test parsers and serializers, schema validation, Unicode and number-precision handling, and API request or response processing.
Code examples
import json
with open("confusion-matrix.json") as f:
data = json.load(f)
print(type(data), len(data))Related files
- jsonClassification Report (JSON)A per-class classification report in the scikit-learn structure — precision, recall, F1, and support for each class plus accuracy and macro/weighted averages. A fixture for testing metric parsers and report renderers.

- jsonModel Benchmark Results (JSON)A model-evaluation summary in JSON — per-task scores for a fictional model across sentiment, NER, summarization, translation, and QA, each with its metric and sample size. A fixture for testing eval dashboards and leaderboard importers.

- jsonDetection Annotations — COCO (JSON)Object-detection annotations for the scene in the COCO JSON format — images, categories, and per-object bounding boxes as [x, y, width, height]. Grouped with YOLO and Pascal-VOC twins for testing annotation-format conversion.

- jsonText Embeddings — 16-dim (JSON)A set of 24 L2-normalised 16-dimensional text embeddings as JSON — each record pairs an id and its source text with a float vector. A fixture for testing vector stores, similarity search, and embedding loaders. Parquet and .npy twins included.

- ipynbJupyter Notebook (IPYNB)A valid Jupyter notebook (nbformat 4.5) with markdown cells, code cells, and real outputs (stdout stream and an execute result) — for testing notebook parsers, nbconvert, and JSON tooling.

- csvSurvey Responses — Likert + NPS (CSV, 60 rows)A customer-survey response set — 60 respondents rating five statements on a 1–5 Likert scale plus a 0–10 NPS score and a segment. A fixture for testing survey analysis, aggregation, and NPS/CSAT calculations.

Generated by generation/ai_datasets.py. Free for any use, no attribution required — license.