If my wife is considered a real estate professional, and she buys a house to flip, can the gain be used to fund a tax retirement account i.e. SEPP or a 401(k)?
Can the rental income from rental houses that are in her LLC be used to fund a retirement account?
The income reported on Schedule C, Schedule K-1, W2 or 1099-MISC as earned income can be used to fund retirement accounts. Basically, the rule of thumb is whether you pay FICA and ordinary income taxes on it. If you pay Social Security - you can also use it to contribute to retirement. If you pay capital gains rates and not paying FICA taxes - then no.
Passive income, even if considered ordinary income (like rental) is not earned income and is not subject to SE/FICA taxes. It can also not be used as a source for retirement accounts (well, the money itself can, but you need to have a corresponding earned income to back the amounts you deposit).
So #1 is probably yes, depending on how it is actually booked and reported.
The #2 is definitely no.