It would seem that the ID entered into options block of gnuradio companion is used as the class name of the generated python script. (defaults to top_block)
But there is one source of trouble with that.
What if I put into ID field some name which could be same as some imported module.
This could happen if your working on OOT module, and put into ID of options block the same name as your OOT module. It gives you the error: AttributeError: 'module' object has no attribute 'foobar'
Perhaps some little check should be put into gnuradio-companion to prevent the name conflict.