How do you know when you have to do it? The sensor tells you how many oxygen molecules you consumed, as a proportion of the current flowing. So just let oxygen flow into the tank at the same rate as you're consuming it. Which you know because the device literally measures how much oxygen it is consuming.
I think the real issue is that the explanation in the tweet is from a physics perspective rather than an engineering one, which means it reads like it was implemented with impossible magic.