Big bulk commit. Close to final minimalistic version.