TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Show HN: Convert English to Cron Expressions

108 pointsby jacobpeddalmost 3 years ago

23 comments

txutxualmost 3 years ago
So nice!<p>For prior art (not GPT-3 based) in debian&#x2F;ubuntu based distributions:<p><pre><code> &#x2F;usr&#x2F;share&#x2F;doc&#x2F;cron&#x2F;examples&#x2F;crontab2english.pl </code></pre> I use to use it like:<p><pre><code> perl &#x2F;usr&#x2F;share&#x2F;doc&#x2F;cron&#x2F;examples&#x2F;crontab2english.pl &#x2F;etc&#x2F;cron.d&#x2F;myfile </code></pre> Also prior to crontab.guru:<p><pre><code> $ head -2 &#x2F;usr&#x2F;share&#x2F;doc&#x2F;cron&#x2F;examples&#x2F;crontab2english.pl #!&#x2F;usr&#x2F;bin&#x2F;perl #Time-stamp: &quot;2001-07-29 16:07:28 MDT&quot; </code></pre> 21 years ago, more people did prefer english to cron :)
评论 #32364044 未加载
Chico75almost 3 years ago
This is incredible. While there is still a decent rate of false-positives or errors, it&#x27;s such a nicer user interface than the powerful yet hard-to-read cron syntax.<p>Any chance it could be made into a library&#x2F;api?
评论 #32361638 未加载
评论 #32359435 未加载
taudealmost 3 years ago
A different take on the same idea: Cron tab Guru [1]. I use this tool all the time.<p>I&#x27;d love a CLI version of this tool, where I pass in the cron expression and it tells me the english translation.<p>[1] <a href="https:&#x2F;&#x2F;crontab.guru&#x2F;" rel="nofollow">https:&#x2F;&#x2F;crontab.guru&#x2F;</a>
评论 #32359348 未加载
jacobpeddalmost 3 years ago
This was inspired by previous work using GPT-3 to generate regex. It uses the new codex model and works surprisingly well.<p>Let me know if you get any interesting results!
评论 #32366968 未加载
nicoburnsalmost 3 years ago
I feel like AI is a poor fit for this domain, because the whole point of using a tool like this would be to check&#x2F;ensure correctness. Perhaps it should at least also offer a precise translation back the other way?<p>Scheduled tasks are hard enough to debug as it is. The last thing I want to do is add more indeterminism!
评论 #32362921 未加载
评论 #32362875 未加载
SnooSuxalmost 3 years ago
Really cool project, but I <i>may</i> have found a mistake. Typing &quot;21st night september&quot; returns “At 12:00 AM, on day 21 of the month, only in September”. And I would expect it to be maybe 9-11:59pm, not midnight that morning. But maybe &#x27;night&#x27; is just not very well defined?
评论 #32359462 未加载
coding123almost 3 years ago
It nailed &quot;every hour on Fridays&quot; damn, must be ai backed.
folkhackalmost 3 years ago
&gt; &quot;every third thursday&quot;<p>... nice. Other folks are beating ya up based on their first try but mine was exactly correct!<p>Adding to my cron tools bookmarks - cool stuff.
gfasteralmost 3 years ago
This is pretty great. It would be nice if it were able to handle exceptions, for example:<p>&quot;The second Sunday of every month except in December&quot;
评论 #32359381 未加载
Davieyalmost 3 years ago
Really liked, &quot;Last Monday of every month except August&quot;.<p>I tried other hard ones and got rate limited :(
评论 #32365252 未加载
apugoneappualmost 3 years ago
This is so cool! Don&#x27;t use cron jobs often but in love with the UI!<p>I made a similar tool [1] to convert English to Excel formulas but would def take a page out of your super clean look!<p>[1] <a href="https:&#x2F;&#x2F;www.tersho.com" rel="nofollow">https:&#x2F;&#x2F;www.tersho.com</a>
JLCarvethalmost 3 years ago
This looks incredibly cool. One thing, the &lt;title&gt; has a typo: Chon Prompt
评论 #32359061 未加载
seifertericalmost 3 years ago
It&#x27;s erroring out on me but I wanted to try one of my stackoverflow questions from long ago that still gets frequent votes:<p>Every 15 minutes except at 3AM?<p>Stackoverflow responses say it can&#x27;t be done in one line.
评论 #32361232 未加载
评论 #32359689 未加载
zufallsheldalmost 3 years ago
Great, using &quot;never&quot; as prompt results in:<p>&quot;At 12:00 AM, on day 31 of the month, only in February&quot;
评论 #32359688 未加载
评论 #32362222 未加载
评论 #32359813 未加载
zeropalmost 3 years ago
Good tool . I Tried: &quot;On alternate Saturday at noon&quot;<p>Not sure if it gave right results. but i think this is amazing stuff. Thanks for building it.
foxbeealmost 3 years ago
This is great. CRON presets are great, but this is perfect for allowing users to define their own CRON expressions. Nice work!
throwfh80h82almost 3 years ago
Cool tool, I&#x27;d use this.<p>&quot;When the stock market closes and opens&quot; - I think the stock market opens at 9:30 though, not 9.
mrlonglongalmost 3 years ago
I gave it &quot;every full moon&quot; and it gave me 0 0 * * * *<p>Still some more work, methinks.
YourCupOTeaalmost 3 years ago
I keep getting the too many requests error even though I&#x27;ve never tried it before.
评论 #32359580 未加载
jmprspretalmost 3 years ago
A fun game is to put an emoji or two in the prompt and see what comes out :)
iamandrasalmost 3 years ago
Oh, this is just cool. Nice work.
tejtmalmost 3 years ago
not finding an acceptable way to describe<p>&quot;first and third Tuesday at noon each month &quot;
owow123almost 3 years ago
&gt; 2 hours after 3 5 and 7<p>&gt; 0 2 3,5,7 * *<p>Not great
评论 #32364113 未加载