Version 0.4 rewrite