Which is the right time to execute the automation test scripts and what is the time interval you run those test scripts ?

Automation test script obviously need to execute when the application becomes stable only. So, at the initial phase of the development lifecycle better use the manual testing and unit testing block to ensure the stability of the system.

And in the later part of the software development life cycle, when the system becomes comparatively stable then only the automation test script can be used. So sanity and regression suite can be executed using the automation suite. And for smoke testing, only use the automation scripts when the systm becomes stable only.

And time interval depends on the defect lifecycle. suppose, currently sprint 2 is ongoing. Now sprint 1 delivery becomes stable. So start to execute the regression suite of sprint1 and continue the smoke testing at first for sprint 2. So, for stable release the frequency of the regression suite can be weekly depending upon the impact area of the sprint 2 release. And for sanity test suite, the frequency for the current release should be daily overnight and smoke test suite execution should only be done when new code changes has been pushed.