Updates to Gem#state for revised workflow

Work in progress, there are still some TODO's that have to be
flushed out