Best way to detect if there is exit/hole

So my question is what would be the best way to detect if there is a hole/exit that smoke could exit through
example:


how would I know if there is exit/hole from this box and where it is

You could Raycast upwards from wherever the smoke is sourcing from, and if the Raycast doesn’t find a part then it knows there’s a hole there