I can't imagine a way to quantitate formic acid in ants without murdering a few of them. Actually, you should get several ants (in order to get an average) and extract the formic acid - with water, as suggested. In this process, you will have casualties. Then, filter the extract in order to prevent ant bodies to reach your equipment - and save the dead bodies so their relatives can claim them. Inject the filtered extract in a suitable liquid chromatograph. Any old Antek might do.
Maybe with a nanoLC you could avoid killing an ant
Jokes aside, Consumer Products Guy gave you a nice starting point for a chromatographer.
Take several ants, crush them in order to break the exoskeleton and internal organs into tiny pieces (or even better, almost homogeneous), add a little (known) amount of water, mix thoroughly, filter in a .45 micron filter (maybe syringeless like Uni-Prep) and inject in a liquid chromatograph with a conductivity detector and a specialty column as Consumer Products Guy suggested. If it doesn't work, then you can start tweaking.
You could distill ant bodies as it used to be done to get formic acid, but I guess it would take a lot more ants.