Underneath, Alfred stores each Key Map on an append-only file.
The file is homogeneous, i.e., each document is written one after the other.
On a file, each document starts with a header with 14 bytes.
The first two bytes are UTF-invalid magic tracker (0xDC80). It can be used, in case there is a corruption detected, to trace the start of the next document.
The remaining four bytes have the length of the document (ASCII).
Each document ends with a 40 byte trailer.
It starts with a 12-byte ASCII-encoded length.
Then comes a CRC32 checksum of the document.
In between, the document is serialized in JSON serialized form.