structure generator internals logically