AAmit’s LibraryLEARN · PRACTISE · REFLECT

Quality and reliability × AI, language tools and decision assistance

Business lens: Quality and reliability · Technology lens: AI, language tools and decision assistance

Reading scope: Original synthetic teaching; selected primary background and same-author checks are not independent validation.

Quality is a decision requirement

A fictional distributor uses an AI score to flag damaged deliveries before customers receive them. Quality means supporting an appropriate decision under specified conditions, not merely producing an impressive score. Define the unit as one delivery and the target as damage confirmed through a documented inspection. A model trained on earlier inspections may perform differently when packaging, suppliers or inspection practices change. The manager must decide what the flag triggers: additional inspection, a temporary hold or a conversation with a supplier. Automatically rejecting an order would create a different consequence and require different evidence. Start with that consequence before choosing a model metric.

Build a shared evaluation ledger

Operations records inspected deliveries, Customer Service explains the cost of an overlooked problem and Finance estimates inspection effort. The data team aligns predictions with independently recorded outcomes. Do not let the predicted class overwrite the outcome field, because that makes evaluation circular. Keep model version, observation date and review status. An unresolved inspection remains unresolved rather than becoming an assumed success. Consultation establishes whether a false alarm merely creates extra work or delays an essential delivery. Different departments may reasonably prefer different thresholds; their disagreement should become an explicit decision about cost and service rather than a hidden configuration choice.

Worked classification case

In a synthetic set of 100 inspected deliveries, 20 are damaged and 80 are sound. The system flags 30 deliveries: 15 damaged and 15 sound. Among the 70 unflagged deliveries, five are damaged and 65 are sound. Precision is 15/30, or 50%; recall is 15/20, or 75%; accuracy is (15+65)/100, or 80%. A rule that always predicts sound also obtains 80% accuracy while finding no damage. Therefore accuracy alone does not show operational usefulness. If extra inspections cost an invented ₹40 each, inspecting all 30 flags costs ₹1,200. That cost is a teaching assumption, not a market price.

Compare a bounded alternative

Suppose a second synthetic threshold flags 40 deliveries, containing 18 damaged and 22 sound. Its precision is 18/40, or 45%, and recall is 18/20, or 90%. The additional ten inspections cost ₹400 under the same assumption and identify three additional damaged deliveries. Whether that is worthwhile depends on consequences that the dataset does not supply, including inconvenience, avoided complaints and capacity. Keep threshold comparison on the same evaluation set so changing the denominator does not masquerade as improvement. A later evaluation on genuinely new observations is needed before inferring that the selected threshold will generalise.

Practice with human review

Extend the existing classification-evaluation lesson by creating both confusion matrices and writing a threshold decision memo. Use invented delivery identifiers and inspect the lesson's actual output separately from the case figures. Include an abstention state for a missing packaging observation, with an owner and deadline for review. The assistant should provide evidence to an inspector rather than invent a reason after the fact. Document who can correct the recorded outcome and how disputed labels are resolved. This worksheet does not execute a new production model or establish compliance. A confident explanation is not proof that a classifier has correctly identified damage.

Question-word examination

Who inspects the delivery and Whom does a delay affect? Whose evidence establishes the outcome? What counts as damage, Where is the inspection recorded and When is the evaluation window closed? Why is accuracy insufficient for this decision? Which threshold fits the available inspection capacity? How will staff resolve uncertain cases and challenge a mistaken flag? Use these questions to distinguish model performance from service quality. The customer experiences the completed delivery process, including explanations and corrections, rather than the confusion matrix itself. Improvement must therefore connect measurement, managerial involvement and the people responsible for resolving errors.

Four levels of study

Foundation learners explain the four cells of the confusion matrix with delivery stories. Undergraduate learners reproduce precision, recall and inspection costs for both thresholds. Postgraduate learners critique label selection, capacity constraints and the difference between a controlled evaluation and field performance. Research learners propose a prospective study of threshold changes, recording uncertainty and checking whether additional inspection improves customer outcomes. A DBA contribution would need more than a dashboard: it should explain the organisational mechanism, comparison and limitations. Retain negative findings, because learning that a model adds cost without useful detection is itself valuable evidence.

Study questions and answers

Why does 80% accuracy not establish useful damage detection?

Always predicting sound scores 80% on this dataset while detecting zero damaged deliveries. The operational task requires examining damaged-delivery recall and error consequences.

Marking guide: Explain always-sound baseline 80% accuracy with zero damaged recall; assess errors relevant to the task.

What changes under the second threshold?

Recall rises from 75% to 90%; precision falls from 50% to 45%. Ten more inspections cost ₹400 under the invented ₹40 assumption and find three more damaged deliveries.

Marking guide: Credit recall 75% to 90%, precision 50% to 45%, ten extra inspections costing 400 and three extra damaged findings under assumptions.

What is the human-review boundary?

Missing or disputed observations need an explicit review state, owner and correction process. A score does not by itself authorise rejection or establish the true inspection outcome.

Marking guide: Require explicit disputed/missing review state, owner and correction process; score alone cannot authorise rejection.

Practice task

Build two confusion matrices, a review-state ledger and a threshold memo with capacity and error consequences.

Practice bridge

  1. Build two confusion matrices, a review-state ledger and a threshold memo with capacity and error consequences.
  2. Reproduce the stated arithmetic, change one valid assumption and distinguish actual lesson observations from the invented case.

Open connected lab

Boundary: Original synthetic teaching connected to an existing bounded or guided lesson. No new executable fixture, catalogue lab or external platform execution claimed.

Sources and further reading

  • scikit-learn: classification metrics and scoring
    Scope: Precision, recall, accuracy and confusion-matrix background only; exercise labels and business consequence judgments remain synthetic.
    Access: Selected free official documentation; no model training or fixture execution claimed.

Related chapters

Interactive practice

Open workshop · Open runnable practice · Open lab lab-33

Open interactive matrix reading