I would probably use the FFI on top of pgsql. Not so much because of the `robustness' of the FFI, but because the actual underlying wire protocol is probably more likely to change than the interface that psql gives you.