How Can We Quantify What a New Observation Tells Us About an Uncertain Outcome? Define a probability model for the possible target labels, then measure the average remaining uncertainty after observing a candidate feature. Information gain is the difference between the initial entropy and the conditional entropy averaged over feature outcomes. A feature that perfectly resolves one small subgroup need not remove uncertainty from the whole collection.
This international lab extends Total Expectation and Variance, Logarithmic Scale, Conditional Independence and Precision, Recall and Threshold through original fictional card registers. Vocabulary Coding and Engineering (VCE) and EnDist are proposed frameworks, not validated interventions. The mathematical examples do not assess actual learners or deployed AI models; future superintelligence remains hypothetical.
- Declare a finite target distribution and logarithm base.
- Calculate binary entropy and handle zero-probability terms.
- Reconstruct feature-conditioned distributions from counts.
- Weight conditional entropies by group probabilities.
- Compare information gain without equating it with causal value or test accuracy.
- Independently solve a fresh unequal-group example.
Choose your reading route
Coursework series: Total Expectation and Variance Lab · Logarithmic Scale Lab · Conditional Independence Lab · Precision, Recall and Threshold Lab · Vocabulary Coding and Engineering
Continue this coursework series: Discrete Fourier and Frequency Components Lab · Deadlock and Resource Ordering Lab · Entropy and Information Gain Lab (this article) · Relative Clauses and Restriction Studio
Full chapter index
Chapters 1–5
Chapters 6–10
Chapters 11–15
Chapters 16–20
Chapters 21–25
Chapter 26
CHAPTER 1 OF 26 · Understand the capability
1. The capability: measure uncertainty relative to a defined question
A fictional archive draws one labelled card from a small collection. Before the card is revealed, we know the distribution of target labels. A feature question may reduce uncertainty about that target, but not every question is equally useful. Learners need to compare the complete conditional distributions, not the attractiveness of the feature name.
The deliverables are a source register, entropy calculations, weighted conditional comparisons, a changed-model test and an independent transfer. The numbers describe a stipulated probability experiment. They do not measure the intelligence of a learner or the benefit of a real institutional decision.
CHAPTER 2 OF 26 · Understand the capability
2. Define Shannon entropy in bits
For a finite random variable Y, write H(Y)=−Σ p(y)log₂ p(y), with a zero-probability term defined as zero. The logarithm base two makes the numerical unit bits. For a binary distribution with probabilities p and 1−p, call this function h(p).
A certain binary outcome has entropy zero; two equally likely outcomes have entropy one bit. For p=3/4 the binary entropy is approximately 0.811278 bits. The University of Toronto notes provide background on this measure and its use in decision-tree comparisons. Entropy is an average property of a distribution, not a count of questions asked.
Background reading: University of Toronto CSC311: Information Theory for Decision Trees · scikit-learn: decision-tree classification criteria.
CHAPTER 3 OF 26 · Understand the capability
3. Vocabulary Coding and Engineering for information gain
Distinguish outcome, target, feature, probability, surprisal, entropy, conditional entropy and information gain. For an outcome with positive probability p, its surprisal is −log₂ p; entropy is the probability-weighted average of such surprisals.
Under proposed VCE, attach the target variable, feature definition, logarithm base and probability model to each numerical result. A claim that a feature has more information is incomplete unless the question and comparison are specified. Another reader should be able to reconstruct the conditional table.
Related framework: Vocabulary Coding and Engineering.
CHAPTER 4 OF 26 · Work through the example
4. Read the fictional eight-card register
The invented Hazel archive has eight distinct cards P1–P4 and N1–N4. P and N are merely two target labels. Choose one card uniformly, with each ID having probability 1/8. Three known binary features are recorded: X, Z and W. Their values are fully specified in the table.
The table is an entire fictional finite population for the exercise, not a training sample from actual people. The target Y has four P and four N outcomes. We will compare one observation of X, Z or W with respect to uncertainty about Y, while keeping all selection probabilities fixed.
| Card | Target Y | Feature X | Feature Z | Feature W |
|---|---|---|---|---|
| P1 | P | 1 | 1 | 1 |
| P2 | P | 1 | 0 | 1 |
| P3 | P | 1 | 0 | 0 |
| P4 | P | 0 | 1 | 0 |
| N1 | N | 1 | 1 | 0 |
| N2 | N | 0 | 1 | 0 |
| N3 | N | 0 | 0 | 0 |
| N4 | N | 0 | 0 | 0 |
CHAPTER 5 OF 26 · Work through the example
5. Calculate the initial target entropy
Because P and N each have probability one half, H(Y)=−(1/2)log₂(1/2)−(1/2)log₂(1/2)=1 bit. The count of eight cards does not make this label entropy three bits.
Three bits would instead be the entropy of the uniformly selected card identity, since eight distinct identities are equally likely. Distinguish the target label from the identity of the item. The same collection can support different entropy calculations depending on which random variable is being considered.
CHAPTER 6 OF 26 · Work through the example
6. Inspect a partially informative feature
For X=1, the possible cards are P1,P2,P3,N1. Their label probabilities are 3/4 and 1/4. For X=0, the possible cards are P4,N2,N3,N4, so label probabilities are 1/4 and 3/4.
Both groups have four cards and probability 1/2. Both conditional entropies equal h(3/4), approximately 0.811278 bits. Weighting them gives H(Y given X)=0.811278 bits. The average information gain is H(Y)−H(Y given X), approximately 0.188722 bits.
CHAPTER 7 OF 26 · Work through the example
7. Inspect a feature that leaves the target distribution unchanged
For Z=1, the cards P1,P4,N1,N2 include two P and two N. For Z=0, the cards P2,P3,N3,N4 also include two of each label. Every conditioned distribution is balanced.
Each conditional entropy is one bit. The weighted conditional entropy is also one bit, so the information gain is zero. In this stipulated distribution, Z and Y are independent. Z could still be useful for another task; its zero gain is specific to this target and probability model.
CHAPTER 8 OF 26 · Work through the example
8. Inspect an unequal-size feature split
Feature W=1 selects only P1 and P2, so the target is certain in that group and its conditional entropy is zero. Feature W=0 selects the remaining six cards: two P and four N. Its conditional entropy is h(1/3), approximately 0.918296 bits.
The group probabilities are 1/4 and 3/4. Thus H(Y given W)=(1/4)0+(3/4)h(1/3), approximately 0.688722 bits. The gain is approximately 0.311278 bits. The pure small group is not the entire population, so its zero entropy must not replace the weighted result.
CHAPTER 9 OF 26 · Work through the example
9. Compare the three candidate observations
The gains for X, Z and W are approximately 0.188722, zero and 0.311278 bits respectively. Under the declared one-feature information-gain objective, W gives the greatest reduction in average label uncertainty among these three choices.
This result is conditional on the entire fictional register and the specified objective. It does not establish the cheapest question, the best multi-step decision tree, a causal mechanism or predictive performance in a new collection. Those tasks require additional definitions and evidence.
| Feature | Groups (P,N) | Conditional entropy (bits) | Gain (bits) |
|---|---|---|---|
| X | (3,1); (1,3) | 0.811278 | 0.188722 |
| Z | (2,2); (2,2) | 1 | 0 |
| W | (2,0); (2,4) | 0.688722 | 0.311278 |
CHAPTER 10 OF 26 · Identify failure modes
10. Detect an unweighted-child error
A generated report averages the two W-group entropies equally and obtains about 0.459148 bits of conditional entropy. That calculation assigns half the probability to a two-card group and half to a six-card group, contrary to the uniform card-selection model.
Repair the weights to 2/8 and 6/8. The correct conditional entropy is about 0.688722 bits. An unweighted average would be legitimate for a different experiment that chose the groups equally before choosing a card within each group. Do not silently change the experiment.
CHAPTER 11 OF 26 · Identify failure modes
11. Handle a zero term and an absent conditioning event
Within W=1, the negative-label probability is zero, so its contribution to entropy is zero by the specified limiting convention. We never evaluate log₂(0) as an ordinary real number.
If a new feature is constant, one of its binary groups may have probability zero. The conditional distribution in that absent group is not determined by the experiment, and it contributes no weight to conditional entropy. Report the absent group instead of inventing a class balance for it.
CHAPTER 12 OF 26 · Identify failure modes
12. Check a perfect split as a boundary
Imagine a separate candidate feature R which simply reproduces the target label. Observing R determines whether Y is P or N. Every positive-probability group has zero entropy, giving H(Y given R)=0 and information gain one bit.
This is the largest possible gain about the initially balanced binary target. A feature equal to the answer would be inappropriate as an input for predicting an unknown label if that feature were unavailable at decision time. This example connects with the Evaluation Leakage Lab without treating all informative features as leaks.
CHAPTER 13 OF 26 · Identify failure modes
13. Check information gain against a decision objective
If the task were to predict Y using one observed feature and zero-one loss, the best prediction within each group would be its more probable label, with a declared tie rule. On the toy distribution, X allows 6/8 correct; Z allows 4/8; W allows 6/8.
W and X have different information gains but the same best one-feature classification accuracy in this example. Information gain and expected accuracy answer different questions. A costly or inaccessible feature may also be inappropriate even if it gives greater gain. State the objective before ranking.
CHAPTER 14 OF 26 · Identify failure modes
14. Show why an individual observation may increase uncertainty
In a different ten-card model, two cards are P and eight are N, with uniform selection. The initial entropy is h(1/5), approximately 0.721928 bits. One feature outcome selects four cards containing two P and two N. Within that group the entropy is one bit, higher than the initial value.
The remaining six cards are all N. Averaging over both groups gives conditional entropy (4/10)×1+(6/10)×0=0.4 bits, less than the starting entropy. Thus the average reduction does not mean every specific observation lowers entropy. Preserve the difference between an observed branch and the weighted average across branches.
CHAPTER 15 OF 26 · Identify failure modes
15. Do not equate association with causal influence
Our original feature W is informative about Y in the stipulated distribution. That does not mean that changing the feature would change the target. A label and feature can be associated for many reasons. Information gain is a statistical relationship between defined variables.
For a real observational dataset, a causal question needs a suitable design and assumptions beyond entropy. The calculations here rank fictional questions by one mathematical criterion. Do not use them to assign real people to categories or infer personal characteristics.
CHAPTER 16 OF 26 · Identify failure modes
16. Separate the complete toy distribution from estimated quantities
In the original exercise, the eight cards define the distribution exactly because the selection rule is uniform over that complete collection. In a real study, a frequency table may instead estimate probabilities in a broader population.
Small samples, missing labels, changes in collection conditions and selecting many candidate features can distort apparent generalisation. A split chosen with training data needs separate evaluation under a defensible protocol. Our toy gain is exact for the stipulated collection and does not establish future performance.
CHAPTER 17 OF 26 · Identify failure modes
17. Audit an AI-generated feature comparison
Ask an assistant to return a target count, feature-group counts, probability weights, each entropy and the gain. Independently check the W groups and confirm the counts sum to eight. Do not accept a table that gives only a preferred feature name.
Test the constant-feature and perfect-feature cases to see whether the calculation respects its boundaries. If the assistant treats the most informative feature as an established cause, require it to separate the mathematical relationship from the unsupported causal claim.
CHAPTER 18 OF 26 · Identify failure modes
18. A prompt for reproducible entropy reasoning
Try: Choose uniformly from the eight specified cards. Compute target entropy in bits. Group by X, Z and W separately, calculate the conditional label distribution for each positive-probability group and weight each entropy by its group probability. Compare gains using the declared objective.
Continue: explain the error from weighting W’s groups equally; compare the best one-feature classification accuracy; and state what a perfect feature would imply. Keep group-specific and average uncertainty distinct. Reconstruct one entropy calculation independently using the logarithm rule.
CHAPTER 19 OF 26 · Identify failure modes
19. A proposed assessment rubric
Score five dimensions zero to three: faithful target and distribution definition; correct entropy formula and boundary handling; reproducible group counts and weights; accurate interpretation of gain and decision limits; independent transfer. Zero indicates absent evidence, one major error, two mostly correct with a gap, three independently reproducible.
Keep assisted computation, independent learner reasoning and receiver reconstruction separate. Permit ordinary accessibility supports and agreed calculator access. The fifteen-point rubric is a proposed classroom tool, not a validated intelligence or statistical-proficiency measure. Feedback should identify the incorrect probability, term or inference.
CHAPTER 20 OF 26 · Test independent transfer
20. Independent transfer: six cards and two groups
Use a fresh six-card register: two P and four N, uniformly sampled. Feature group A contains two P and two N, and group B contains two N. Compute initial entropy, both conditional entropies, weighted conditional entropy and gain before reviewing the check.
Worked check: initial entropy h(1/3)≈0.918296; A has entropy one and probability 2/3; B has entropy zero and probability 1/3. The weighted conditional entropy is 2/3. The gain is approximately 0.251629 bits. Explain why branch A increased uncertainty while the average decreased. Check that the group counts account for all six cards.
| Observed feature | Positive | Negative | Probability of group |
|---|---|---|---|
| A | 2 | 2 | 2/3 |
| B | 0 | 2 | 1/3 |
CHAPTER 21 OF 26 · Test independent transfer
21. Primary learning: ask a useful question
Use adult-prepared cards with an accessible target label and other visible attributes. Ask which simple question helps identify the target and which tells the learner nothing about it. Show that a question may resolve some cards but leave others uncertain.
Formal logarithms are not necessary at this level. Offer tactile symbols or spoken labels and small collections. Adults can prepare checked examples with AI without requiring direct child access. The foundation is recognising what an observation distinguishes, rather than memorising a feature name.
CHAPTER 22 OF 26 · Test independent transfer
22. Secondary learning: connect fractions and weighted uncertainty
Students can construct feature-group count tables and compare how balanced each group is. Introduce binary entropy when logarithms are appropriate. Derive the weighted conditional calculation and compare the equal-size X groups with the unequal W groups.
Give the fresh six-card case before its answer. Ask learners to test an unweighted calculation and explain why it uses the wrong selection model. Accessible tables or spoken derivations can demonstrate the reasoning without a specific software package.
CHAPTER 23 OF 26 · Test independent transfer
23. University, institutions and EnDist
Advanced study may examine conditional entropy, mutual information, decision trees and evaluation under distribution shift. Real data analysis requires defensible feature availability, label definitions, sampling and independent evaluation. The toy example is not a basis for consequential classification of individuals.
Under proposed EnDist, a useful handover carries the target, features, counts, probability model, logarithm convention and comparison objective. Another team can reproduce the calculation or test a changed question. This distributed capability is distinct from generating a polished feature-ranking report.
CHAPTER 24 OF 26 · Four-week coursework plan
24. A four-week coursework sequence
Week one: define the eight-card experiment, compare identity with label entropy and calculate binary cases. Week two: build all feature groups and reproduce their conditional entropies and weighted gains. Keep the full register with the report.
Week three: inspect zero terms, unequal weights, leakage and the accuracy comparison. Week four: release the six-card transfer and ask a receiver to reconstruct the result independently. Adapt pace, notation and access supports. This is a proposed sequence, not validated instruction.
CHAPTER 25 OF 26 · Four-week coursework plan
25. Questions about information gain
Does a pure subgroup guarantee zero conditional entropy overall? No; all positive-probability groups contribute. Does zero gain for a feature mean it is useless for every task? No; the conclusion concerns the defined target and distribution. Does information gain measure causal influence? No.
Does every observed branch reduce entropy? No; a specific branch may be more uncertain than the initial distribution. Can an assistant choose a feature without a stated objective? It can propose choices, but the learner must identify what is being optimised and what the evidence permits.
CHAPTER 26 OF 26 · Four-week coursework plan
26. Sources, boundaries and next steps
The University of Toronto notes explain entropy, conditional entropy and information gain; scikit-learn’s decision-tree guide provides technical context for entropy-based splits. The registers, comparisons, transfers and rubric here are original fictional classroom constructions, not real AI evaluation results.
Construct a new eight-card population in which two features tie on gain but differ in the sizes of their groups. Give the exact register to a receiver and ask for independent checks and a stated decision criterion. The enduring capability is quantifying information about a defined question without making a broader unsupported claim.
References: University of Toronto CSC311: Information Theory for Decision Trees · scikit-learn: decision-tree classification criteria.
Related coursework: Total Expectation and Variance Lab · Logarithmic Scale Lab · Conditional Independence Lab · Precision, Recall and Threshold Lab.