The more relevant doc describing the chain spec format is here: https://paritytech.github.io/polkadot-sdk/master/sc_chain_spec/index.html#
The RuntimeGenesisConfig within a chain-spec can be provided in two formats - full json representation of RuntimeGenesisConfig struct, and patch representation applied to the default value of RuntimeGenesisConfig.
The main purpose of genesis config patch:
- minimize the maintenance effort when
RuntimeGenesisConfigis changed in future (e.g. new pallets added to runtime or pallet's genesis config changed), - increase readability - it only contains relevant fields,
- allows to apply numerous changes in distinct domains (e.g. for zombienet).
Patch is intended for development/testing configurations.
(link to relevant discussion: https://github.com/paritytech/polkadot-sdk/issues/62#issuecomment-1763992444)