An agency is usually strongest when you need ongoing execution in a defined specialism such as PPC, SEO, creative or development. A consultant is more useful when you need someone to look across those specialisms and ask whether they are solving the right problem. The two are not mutually exclusive. I often think the best setup is strong specialist partners with somebody independent connecting their activity to the wider commercial objective.
Related service
Fractional Ecommerce Leadership