February 2025
The Development of Predictive Language Models
16-hour invited mini-course at the Institute of Mathematical Stochastics of TU Braunschweig, for researchers in mathematics from six German universities.
Available now · based in the Paris area, open to relocation
Statistician, PhD in applied mathematics. I study statistics in high and infinite dimension, and I put it to the test on very concrete ground: sentences, DNA sequences, curves and signals.
My work is about inference when the number of variables is large compared with the number of observations, or when the data are only observed through a filter and noise. These questions arise for a covariance matrix, a sentence, a DNA strand, a curve or a signal.
When the number of variables is of the same order as the number of observations , or larger, the sample covariance matrix is ill-conditioned, then singular as soon as : Hotelling's test, which checks whether a mean is zero, no longer applies as such. We penalize it with a parameter . This is also daily life in finance, where the covariance of hundreds of assets is estimated from a few years of returns: the Ledoit–Wolf penalty, offered in the figure, is a classic there.
I prove non-asymptotic exponential bounds for this penalized : an explicit threshold, valid for all and , which depends on the data through effective dimensions. The figure draws many samples from the chosen distribution and compares the histogram of with the bound.
Let be independent and identically distributed random vectors in . We test with
If the distribution of is symmetric, with probability at least ,
where the effective dimensions are computed from the eigenvalues of , in decreasing order, (the others are zero):
In the figure, . The Θ depend on the data: each draw has its own bound. The vertical line marks their median, the box on the axis their spread. With the Ledoit–Wolf box ticked, is replaced on each draw by the estimated optimal Ledoit–Wolf (2004) penalty, , as in the paper.
Try it yourself: change the distribution, the dimension, the sample size, the penalty, and watch the distribution of over the Monte Carlo draws take shape against the bound
With 1,000, the computation is long in the browser: the button at the bottom of the panel announces its duration before running it. The Python notebook of this figure is faster.
100 400 4.00MC = 499
against , at level 5%
, with . We test , that is , against , at level 5%
, with Pareto II with index . We test against , at level 5%
Centred symmetric distribution: we are under , the theorem applies.
: alternative hypothesis, should exceed the bound.
Under , : we recentre by this value. Non-symmetric distribution, outside the scope of the theorem.
Non-symmetric, heavy-tailed distribution: depends on and becomes infinite if .
As in the paper, we plot : plays the role of the mean and that of the variance. The curve is the normal distribution with the same mean and variance as the simulated values. The bound becomes .
A mistake, an idea, a simpler way to say it? Nothing replaces the eye of a careful reader: write to me.
Simplifying a text means rewriting it so that it is easier to read and understand, without changing its meaning. This takes several steps, and one of the most important is to recognize the part of speech of each word: noun, verb, determiner… This is called POS tagging.
The catch: the same word can change its part of speech. In French, « donne » is a verb in « elle donne » (she gives) and a noun in « la donne a changé » (the deal has changed). To decide, the computer looks at the context, that is, the surrounding words. Hover over or tap a word of the French sentence below: you will see the probability of each part of speech, without and then with the context.
On language models themselves, I gave a 16-hour invited mini-course at TU Braunschweig in 2025, and the code accompanying my course on predictive language models is on GitHub.
In my thesis, then in a paper submitted with Patrice Bertail, Thierry Dumont and Mélanie Zetlaoui, I build these classifiers from penalized generalized empirical likelihood and -divergences. They generalize maximum entropy, a classical method of natural language processing.
The context of a word is described by thousands of features: the word itself, the two words before and the two words after, capitalization, the beginning or end of the sentence, the suffix… There are often more of them than examples: this is high dimension. Penalization gives a closed-form expression for the probability of each tag given the context: no optimization algorithm, and a much shorter computing time. Maximum entropy is only a special case of these empirical likelihoods. On the Penn Treebank, the reference English corpus, the error rate stays below 5% with a deliberately small feature set: this is a method, which can be enriched to gain accuracy.
Hover over or tap a word · elsewhere, a tap starts or stops the scrolling
Without context
With the context
part of speech: the grammatical class of the word, its “tag”.
Without context: how often each part of speech occurs for the word in the Brown corpus, about a million words of American English (1961), with the universal tagset of Petrov, Das and McDonald. With context: illustrative values, whatever the context size chosen (±1 to ±4).
These percentages change from one corpus to another. The larger and more varied the corpus, the more precise the estimate; it also depends on the domain. In the Brown corpus, “to” is a particle 57% of the time (“to know”) and a preposition 43% of the time; “show” is a verb 70% of the time, but in television listings the noun (“a quiz show”) would probably come first.
A mistake, an idea, a simpler way to say it? Nothing replaces the eye of a careful reader: write to me.
An aptamer is a short DNA strand that binds to a specific target, like an antibody. At LMAC, with the biologists of the GEC laboratory*, I worked on designing aptamers for the diagnosis of Lyme disease, combining experiments (in vitro) and numerical models (in silico).
A sequence reads like a sentence. We turn it into a vector by counting its k-mers, or with a generative model, a restricted Boltzmann machine (RBM), which learns a continuous representation and can propose new sequences. For words of k letters, the space has 4k dimensions: high dimension comes back quickly. Once they are vectors, sequences have a geometry: we see how they spread out, and we measure distances between them, such as the cosine of the figure.
A restricted Boltzmann machine has two layers: the visible layer receives a sequence, one letter per node, and the hidden layer sums up the dependencies between its letters. Like Di Gioacchino et al. (PLOS Computational Biology, 2022), we train it on the sequences of the last SELEX round, then draw new ones from it: the selection, replayed in silico.
The hidden layer also serves as a representation: its mean, given a sequence, is a dense continuous vector. Sequences then sit in a space where distances can be measured; the k-mers and the cosine of the figure give a second, sparse view of it. Among the generated sequences, we keep those closest to the three laboratory candidates, then test them in vitro: several bind the target as well as the reference aptamers, sometimes better.
With Hugo Da Ponte, Mickael Guerin, Séverine Padiolleau-Lefèvre and Irene Maffucci (GEC), Miraine Dávila Felipe and Ghislaine Gayraud (LMAC), Université de technologie de Compiègne.
Two DNA strands, their k-mers counted in colours, and the angle between the two vectors: the smaller it is, the more alike the strands.
ATGCGTACCTGAAGCTTGCATCGGATACGTTAGCCATGGA
S2k = 2dimension 16cos = 1.000angle = 0.0°
k = 1 to 4dimension 340cos = 1.000angle = 0.0°
equals 1 when the k-mers of the two sequences are in the same proportions. First line: the chosen k. Second line: the counts for k = 1, 2, 3 and 4 put end to end, 4 + 16 + 64 + 256 = 340 cells.
A mistake, an idea, a simpler way to say it? Nothing replaces the eye of a careful reader: write to me.
Follow the traffic of a computer network over a day: it draws a curve. A curve is a value at every instant, hence infinitely many values; we measure it at points, but nothing stops from growing. Comparing hundreds of such days to spot an attack is statistics in infinite dimension, and it is precisely one of the applications of our paper with Patrice Bertail and Nataliia Lysenko.
There we extend the penalized to Hilbert spaces: the same exponential bounds hold, with the same effective dimensions, whatever . The resulting test is valid for every , with a closed-form threshold: it is computed in one go, whereas the sign-flip test recomputes the statistic hundreds of times. And a formula lends itself to analysis, which opens the way to a theoretical study of its power.
In the figure, choose a model of curves. At the top, a few drawn curves, then the eigenvalues of their covariance operator, which tell how many directions really matter. At the bottom, the histogram of against the bound, and the power of the two tests as the mean moves away from zero.
Let be independent curves with the same distribution in , symmetric about their mean . We test with
Here is the norm of , , and the associated inner product; is the operator , the identity and the penalty. is positive, so is invertible and its inverse square root is well defined.
The operator is computed under , without recentring. The effective dimensions are those of the top figure, on its eigenvalues; the test rejects when , with , and its level is at most for every , with no moment condition.
The sign-flip test draws signs times, recomputes on the with the same , and rejects when the p-value is at most . In the figure, as in the paper's code, the curves are measured on the grid and the inner product is that of the grid values.
Try it yourself: choose a model, then tap a setting under a chart
Fourier: a random sum of sines and cosines, plus a little noise, observed at points; the eigenvalues drop fast.
Brownian motion, generated by the first terms of its Karhunen-Loève expansion, then observed at points: eigenvalues of order , dominated by the first.
Ornstein–Uhlenbeck with scale : same decay in , less dominated by the first.
Flat spectrum: orthonormal vectors of a discrete Fourier basis, with the same variance ; no direction dominates.
beyond the median bound: – rejected
With 1,000, the computation is long in the browser: the button announces its duration before running it, and the paper's Python code, at the bottom of the panel, is faster.
bound signs (199) 5%
11 values of , 99 draws each; the vertical line marks the chosen .
: the constant curve ( equals 1 everywhere), plus a centred, symmetric noise . The shift is thus the true mean that generated the curves, . We always test against , at level 5%.
The settings are shared by the four charts.
A mistake, an idea, a simpler way to say it? Nothing replaces the eye of a careful reader: write to me.
Picture a message sent by an antenna: a sequence of symbols taken from a small alphabet, like the points of a Wi-Fi or 4G radio constellation. On the way, the channel distorts it. Each symbol spills over onto the next ones, like a voice echoing in an empty room, then noise is added. We receive , knowing neither the echo nor the noise level .
Blind deconvolution means recovering the message all the same: the filter that cancels the echo, the noise level, and the alphabet itself with the frequency of each symbol. With Emmanuelle Gautherat and Ghislaine Gayraud, we propose a procedure that is simple to program and uses only the moments of . In the figure, top left is what the antenna receives, on the right what the estimation recovers, and at the bottom the error as a function of the signal lengthfirst what the antenna receives, then what the estimation recovers, and finally the error as a function of the signal length.
We filter by a of length and correct the moments of for the effect of noise, for a given level . As long as is below the true level, the matrix of corrected moments stays positive definite; it becomes singular exactly when reaches it and is the right inverse filter.
Hence the algorithm: a grid in , then a bisection, which look for the smallest at which the smallest eigenvalue can vanish; at each , we minimize over the unit sphere of the , from several starting points. The symbols are then the roots of a polynomial, and their frequencies the solution of a Vandermonde system.
Work in progress, being written up.
Try it yourself: choose the channel and the alphabet, then tap a setting under a chart
| Re | Im | mass | to redo |
|---|
Tick a setting to fine-tune it; unticked, it goes back to the value in the paper's code.
true symbols estimated estimated noise size according to mass
| true | 1st draw | last | MC mean |
|---|
A mistake, an idea, a simpler way to say it? Nothing replaces the eye of a careful reader: write to me.
Up-to-date list on HAL, Google Scholar and ORCID.
Journal of Multivariate Analysis, vol. 203, 105342
Submitted to Econometrics and Statistics
Preprint, bioRxiv
Submitted to Electronic Journal of Statistics; HAL preprint
Université Paris Nanterre, defended on 23 June 2023
February 2025
16-hour invited mini-course at the Institute of Mathematical Stochastics of TU Braunschweig, for researchers in mathematics from six German universities.
I taught at Université Paris Nanterre from 2017 to 2023: during my PhD, then for two years as a full-time teaching and research fellow (ATER, 2020–2022), at 192 tutorial-equivalent hours per year. In all, 621 hours, from first year to second-year master's.
I designed and taught the master's course Semantic Analysis of Textual Data: lectures, tutorials and computer labs.
See the detailed teaching record (.ods file, in French)The code of the papers and courses is on GitHub: simulations, figures and notebooks, one repository per project. The code of the five figures on this page is right here, one Python notebook per figure.
Preparatory classes in Reims, the ISEFAR master's at Paris Nanterre, a spell in actuarial work and project management, then research: a PhD at MODAL'X and a postdoc at LMAC.
Outside mathematics: twenty years of guitar, seven of piano, a half-marathon and a year of theatre.
Hosted by the MODAL'X laboratory, Université Paris Nanterre; available now.
LMAC, Université de technologie de Compiègne. Num4Lyme project, funded by ISCD (Sorbonne Université), supervised by Ghislaine Gayraud and Miraine Dávila Felipe.
Monthly seminar of the PhD students and postdocs of LMAC; local committee of the conference Non-stationarity, cyclostationarity and applications.
MODAL'X, Université Paris Nanterre. Thesis supervised by Patrice Bertail, co-supervised by Mélanie Zetlaoui and Thierry Dumont.
Actuarial analyst at La Mutuelle Générale, then project manager at Dalink Conseil.
Preparatory classes MPSI and MP* in Reims, bachelor's in applied mathematics and ISEFAR master's at Université Paris Nanterre.
For a position, a collaboration, a seminar invitation or a question about a paper, the simplest is to write.