I don't believe the agent does much on it's own. It does run a job every 2 minutes ( configurable ) to update its current list of gateways that it should be talking through.
In most cases, what happens is that that the core sends a notification ( called a 'poke' in SA nomenclature ) to the agent telling it to wake up and grab a command. The agent then calls back up to the core and asks for the command it was told was waiting. Agent downloads the necessary items to run the command and then pushes the results back up to core.
There may be a occasional job ( software discovery ) that runs, but that's about it. The core is always the one who initiates the connection when there is actual work to do though, via the 'poke'.
This is described in the Way documentation, btw, which you can reach via https://<yourcore>:1018, if you've installed the spin-developer cert into your browser.