FlexKnot as a generalized model of the sky-averaged 21-cm signal at z ∼ 6–30 in the presence of systematics | Synapse