r/probabilitytheory • u/CourseSome8119 • 9h ago
[Applied] Does this simple model of how errors might spread between agents make sense?
I've made a simple model of how one error might spread through a group of agents. In my case the agents are AI models passing work to each other, but it could be any process. I'm not sure the probability parts are right, and I'd appreciate any feedback.
How the model is set up: - Each agent takes n steps. - With clean input, each step has a chance p of an error. - If an agent gets work from an agent that made an error, its chance per step becomes r = min(1, p·c). Here c is how much bad input raises the error rate. - Each agent passes work to d other agents, picked at random. Each handoff carries an error with chance g. - The full model also has a checking step. I left it out here to keep it simple.
ε = 1 − (1 − p)\^n share of agents that err on their own
Δ = (1 − p)\^n − (1 − r)\^n extra chance of erring caused by bad input
R = d·g·Δ spread number
z = ε + Δ·(1 − e\^(−d·g·z)) share of agents that err (largest root)
x = 1 − e\^(−d·g·z) share that received bad input
Each error is serious with chance q. Expected serious errors across N agents: E = q·n·N·[p + x·(r − p)], and the chance of at least one is 1 − e^(−E).
What the model says, if I've set it up right: - With d = 1 (a straight line of agents), R stays below 1, so passed-on errors fade out. - With d above 1, R can go above 1. - Because some agents err on their own (ε above 0), z changes smoothly around R = 1 rather than jumping.
What I've checked so far: some property tests, and a simulation of the same rules (48 setups, 2,000 runs each). - With random handoffs, the formula and the simulation were within 1 point of each other. That's inside the simulation's noise, so I can only say they roughly agree. - With fixed setups (trees, or handoffs in a set order) and a high c, the formula came out higher than the simulation, by up to 12.5 points. For a straight pipeline it came out lower, by up to 4 points. - The simulation checks the math, not how real agents behave. Nothing here has been tested on real AI agents.
My questions: 1. Is the equation for z a reasonable shortcut here? Is there a better standard way to handle trees and set-order handoffs? 2. The Poisson step for "at least one serious error" was within 1.8 points of the simulation. Is there a known limit on how far off that step can be? 3. Does it make sense to count only the extra errors caused by bad input (Δ) in R?
The full write-up and code are free here: https://doi.org/10.5281/zenodo.23491077