Efficiently typed serialization format (in the spirit of msgpack)