Spatial regulation of a common precursor from two distinct genes generates metabolite diversity