This is a quite easy function, finally just doing a WMI trigger for a ConfigMgr baseline. This also offers a possiblity to trigger a baseline via ScheduledTask
What could be the usecase for such a script?
Think about a baseline evaluating pending reboots. If this evaluation happens at 11:00 and the device is rebooted at 11:01 the next evaluation will be approx at 11:00 24h later. In the meanwhile the compliance state remains on non-compliant even the performed reboot already happend.