Fix Base#hookFor() method and cleanup invoke fix

Add Environment#duplicate() to create performant copy of a complete
environment.
Use composeWith on hooked generators