The realizable mistake-bound model #
This file sets up the realizable mistake-bound model of online classification for concept classes
C : ConceptClass α β with arbitrary label type β [Littlestone1988, §3;
ShalevShwartzBenDavid2014, §21.1; DanielySabatoBenDavidShalevShwartz2015]. Learning proceeds in
rounds. In each round an adversary presents an instance x : α, the learner predicts a label in
β, and then the adversary reveals the true label y : β. The learner errs when its prediction
differs from y. The labels must stay consistent with some target concept c ∈ C. The quantity of
interest is the worst-case number of mistakes.
A deterministic learner is a function OnlineLearner α β := List (α × β) → α → β. It sees the
labelled history of the previous rounds and the current instance. mistakes A S counts the rounds
of the labelled sequence S on which A errs.
S is realizable by C when its version space versionSpace C S, the set of concepts of C
that agree with every example of S, is nonempty. The mistake bound of A on C is the supremum
of mistakes A S over all finite realizable S, in ℕ∞. The optimal mistake bound of C is the
infimum of the mistake bounds over all deterministic learners (M_A(C) and opt(C) in
[Littlestone1988, §3, Definition 1]). Littlestone sets M_A(∅) = -1; here the empty class has no
realizable sequence, so its mistake bound is 0 (mistakeBound_empty).
Since the learner is deterministic, adaptivity gives the adversary nothing more. An Adversary α β
chooses each instance and each label as a function of the history and of the learner's prediction.
mistakeBound_eq_iSup_adversary shows that the mistake bound is also the supremum over adversaries
and horizons of the mistakes on the realizable transcripts. mistakeBound_eq_iSup_concept restates
the bound with a fixed target concept c ∈ C and adversarially chosen instances.
Main definitions #
Cslib.MachineLearning.OnlineLearning.MistakeBound.OnlineLearner: deterministic online learners.Cslib.MachineLearning.OnlineLearning.MistakeBound.mistakes: the number of mistakes on a labelled sequence.Cslib.MachineLearning.OnlineLearning.MistakeBound.versionSpace: the concepts consistent with a labelled sequence.Cslib.MachineLearning.OnlineLearning.MistakeBound.Realizable: realizability by a concept class.Cslib.MachineLearning.OnlineLearning.MistakeBound.mistakeBound: the worst-case number of mistakes,M_A(C).Cslib.MachineLearning.OnlineLearning.MistakeBound.optimalMistakeBound: the optimal mistake bound,opt(C).Cslib.MachineLearning.OnlineLearning.MistakeBound.Adversary: adaptive adversaries and their transcripts.
Main results #
Cslib.MachineLearning.OnlineLearning.MistakeBound.mistakes_eq_card: the mistake count as the number of roundston which the prediction from the firsttexamples is wrong.Cslib.MachineLearning.OnlineLearning.MistakeBound.mistakeBound_eq_iSup_concept: the mistake bound with a fixed target concept and chosen instances.Cslib.MachineLearning.OnlineLearning.MistakeBound.mistakeBound_eq_iSup_adversary: adaptive adversaries achieve the same worst-case mistake bound as realizable sequences.
References #
A deterministic online learner: from the labelled history of the previous rounds and the
current instance, it predicts a label in β.
mistakesFrom A h S: the number of mistakes of A on the rounds S, after the history h.
Each round predicts from the history so far and then appends its example to it.
The number of mistakes of the learner A on the labelled sequence S, started from the empty
history.
The version space: the concepts of C that agree with every example of S.
A labelled sequence is realizable by C if some concept of C agrees with all of it.
The mistake bound M_A(C) of the learner A on the class C [Littlestone1988, §3]: the
supremum of the mistakes of A over all finite sequences realizable by C. For the empty class
this is 0, where Littlestone sets M_A(∅) = -1.
The optimal mistake bound opt(C) [Littlestone1988, §3, Definition 1]: the least mistake
bound of a deterministic learner on C.
Mistake counts #
The mistakes on S ++ S' are those on S, then those on S' after the history h ++ S.
The mistakes of a fixed classifier c, as a learner that ignores its history, are the
examples it labels wrongly.
After the history h, the mistakes on S are the rounds t on which the prediction from
h and the first t examples of S is wrong.
The mistakes of A on S are the rounds t on which the prediction from the first t
examples is wrong.
Version spaces #
Realizability #
A sequence labelled by a concept of C is realizable by C.
Mistake bounds #
The empty class has no realizable sequence, so every learner has mistake bound 0 on it.
Littlestone's convention M_A(∅) = -1 is not used.
When no OnlineLearner α β exists (for instance, Nonempty α and IsEmpty β), the optimal
mistake bound is ⊤.
The mistake bound in Littlestone's form [Littlestone1988, §3]: the target c ∈ C is fixed and
the adversary chooses the instances, each labelled by c.
Adaptive adversaries #
An adaptive adversary. From the labelled history it chooses the next instance (next), and
from the history and the learner's prediction it chooses the label (label).
The next instance, as a function of the history.
The label, as a function of the history and of the learner's prediction.
The labelled history after t rounds of the learner A against the adversary B.
Adaptive adversaries are no stronger than realizable sequences: the mistake bound of a
deterministic learner is the supremum, over adversaries B and horizons t, of its mistakes on
the transcripts that are realizable by C.