its crazy to think that this technology could have been used in the roman empire or any prior civilization that had a written language. personally i would use large billboard with a black/white pattern and a mask that slides back and forth to change the color of the billboard from white to black very suddenly and repeatedly. it could be seen for miles without a telescope.
The ancient Greeks had a "hydraulic telegraph", in which to posts within eyesight of one another could communicate by fire.
The length of the fire was measured by water spilling out of a reservoir, and the message indicated by the level to which the water fell during that period.
Limited number of signals which could be sent, and limited range and hours of operation, but an option.
Note that the Chappe Telegraph benefited by availability of optics and telescopes, which the Greeks lacked.
A British hydraulic telegraph was developed in 1838 which relied on pressure transmitted through pipes, though it was never fully developed. This could operate at distances of up to a mile and had a vocabulary of 12,000 words.
In the 9th century the Byzantines operated an optical beacon system also based on hydraulic telegraphs.
Other long-distance signalling methods include drumming (particularly prevalent in Africa, and characterised by "drum languages": <https://en.wikipedia.org/wiki/Talking_drum>), signal fires, and mirrors, though I'm not aware of the latter being used in ancient times.