A plausible setup:
There are two equal-sized groups of large numbers:
... such that you can't be expected to distinguish them in the allowed time.
The lottery works by picking at one of the numbers at random.
Omega's algorithm: for each number in those groups, predict whether you would two-box (given the already-determined lottery number). In the set of prime numbers for which you one-box, and composite numbers for which you two-box, pick a number at random and show it to you (so if it predicts you always two-box, it's sure to pick a composite number, etc.).
In that setup, if your algorithm is "if the number ends in 3, two-box, else one-box", then Omega will just pick a random number among the composites ending in 3 and the primes ending in 1, 3, 7, or 9.
And if your algorithm is "If the number is the same as the lottery, two-box, else, one-box", then yeah the chosen number will not be completely independent of the lottery number (Omega can only pick the lottery number if it's composite, or if it makes a prediction error), but that looks independent enough for the spirit of the post.
You see two boxes and you can either take both boxes, or take only box B. Box A is transparent and contains $1000. Box B contains a visible number, say 1033. The Bank of Omega, which operates by very clear and transparent mechanisms, will pay you $1M if this number is prime, and $0 if it is composite. Omega is known to select prime numbers for Box B whenever Omega predicts that you will take only Box B; and conversely select composite numbers if Omega predicts that you will take both boxes. Omega has previously predicted correctly in 99.9% of cases.
Separately, the Numerical Lottery has randomly selected 1033 and is displaying this number on a screen nearby. The Lottery Bank, likewise operating by a clear known mechanism, will pay you $2 million if it has selected a composite number, and otherwise pay you $0. (This event will take place regardless of whether you take only B or both boxes, and both the Bank of Omega and the Lottery Bank will carry out their payment processes - you don't have to choose one game or the other.)
You previously played the game with Omega and the Numerical Lottery a few thousand times before you ran across this case where Omega's number and the Lottery number were the same, so this event is not suspicious.
Omega also knew the Lottery number before you saw it, and while making its prediction, and Omega likewise predicts correctly in 99.9% of the cases where the Lottery number happens to match Omega's number. (Omega's number is chosen independently of the lottery number, however.)
You have two minutes to make a decision, you don't have a calculator, and if you try to factor the number you will be run over by the trolley from the Ultimate Trolley Problem.
Do you take only box B, or both boxes?