Project
Investment commentary
written every week
Every Monday morning, the same ritual: pull the net asset values, recompute contributions, and rewrite the same paragraph for each fund.
python deterministic attribution llm agents scheduled publishing
Repetitive, but not mechanical
Investment commentary is not a text you can produce loosely. It has to say what drove performance over the period, what held it back, and why, with exact figures. The form repeats, but every edition means going back to the data and interpreting it.
That is precisely the kind of task automation handles well, provided you do not hand the model the part it is bad at.
The rule everything else is built on
Numbers are never produced by the model. Performance attribution, per-holding contributions and the gap to benchmark are computed by deterministic code from positions and net asset values. The model receives those settled results, and its only job is to turn them into prose.
A language model asked to compute a contribution will produce a plausible number. In investment commentary, plausible and wrong is the worst possible outcome, because nobody checks it.
Framing the period
One detail carries more weight than it looks: the period is not derived from the calendar but from the data actually available. The pipeline fetches the latest published net asset value and builds the period from it, which rules out a whole class of silent error in weeks with a public holiday.
The full pipeline
- Fetch net asset values, positions and cash at both ends of the period.
- Deterministic computation of contributions and the gap to benchmark.
- Market context research to explain the notable moves.
- Writing, framed by tone and format rules specific to each product.
- Human review, then publication.
The outcome
Weekly time drops from several hours to a review pass. The less visible gain sits elsewhere: the format stops drifting, the same indicators are computed the same way from one edition to the next, and a question about a figure from six months ago still has an answer.