Refactor bottle internals
Update bottle toolchain to use new internals