The way it may have been written is not as upfront as scientific text is nowadays. Gelatin was used in ancient Egypt and agar (rather than agarose) was reportedly used as far back as the 1600s including for food.
https://en.m.wikipedia.org/wiki/Agar https://thecookingfacts.com/how-was-gelatin-invented/
I would also mention jams and jellies are in a similar fashion and the first known recipe for jam was written in the 4th century AD and it probably existed before then.