Make agent optional

Signed-off-by: Gawain Lynch <gawain.lynch@gmail.com>