<commit_before># The following script will send a quote to a Log and Speech service every minute.

speech = Runtime.createAndStart("speech","Speech")
cron   =  Runtime.createAndStart("cron", "Cron")
log   =  Runtime.createAndStart("log", "Log")
cron.addScheduledEvent("* * * * *","speech","speak", "hello sir, time for your coffee")
cron.addScheduledEvent("* * * * *","log","log", "hello sir, time for your coffee")<commit_msg>Update Cron.py<commit_after># The following script will send a quote to a Log and Python every minute

cron   =  Runtime.createAndStart('cron', 'Cron')
log   =  Runtime.createAndStart('log', 'Log')

# add a task which sends text to the log service Log.log(string) every minute
cron.addTask('* * * * *','log','log', 'hello sir, time for your coffee')
# add a task to send text to a python function every minute
cron.addTask('* * * * *','python','doThisEveryMinute', 'hello sir, time for your coffee')

def doThisEveryMinute(text):
	print (str(datetime.datetime.now().time()), text)

listOfTasks = cron.getCronTasks()
for i in listOfTasks:
	print(i.name, i.cronPattern, i.method)
{'fraction_non_alphanumeric': 0.151268115942029, 'fraction_numerical': 0.0, 'mean_word_length': 5.350574712643678, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '297978', 'n_tokens_mistral': 357, 'n_tokens_neox': 351, 'n_words': 116}