Fix write bug on booleans.

  - Add start of core library.