Small refactoring to ChainBuilderType and some proofs

3 jobs for master in 6 minutes and 18 seconds (queued for 1 second)