Thismastodonbotwilltootwordsfromalistyouprovide.
Theoriginalbot,@wordbot@botsin.space,usesalistofwordscreatedbyaneuralnetwork.Youmayusewhateverwordsyouwant,butit'syourjobtosupplythewords.Thisrepositoryincludesanexamplewordfile.
BONUS:Ifyouhavealistofnewandunusualwords,andwanttomakesurethey'renotinthedictionary,I'veprovidedaperlscriptcalledcheck.plthatyoucanmanuallyrunonyourwordfile.Itcomparesthenewwordstoanincludeddictionaryfile.Feelfreetoreplacethedictionaryandrepurposethescriptasyoulike.
Ifallyouwanttodoistootitemsfromalist,youjustneedtootbot.py,toot_secrets.py,andwords.txt.
Dependson:pawopyThepythonmodulepawopyisrequiredfortooting.
Ifyouwouldprefertomakeatwitterbot,youcanedittootbot.pytousetweepyinstead.
HowtotootCreateamastodonaccountforyourbot(recommended:https://botsin.space)
Inthesettingsofthataccount:a.GotoDevelopmentb.Createanappc.Clickontheappyoujustcreatedd.Copythekey,secret,andaccesstoken
Addthekey,secret,andaccesstokentothetoot_secrets.pyfileincludedhere.
Runthetootbot.pyscriptfromthecommandlinetomakesureitdoestherightthing.(Thisprovidessomecommandlinefeedbackandalsomakesittootitsfirsttoot!)
Setupacronjobtoruntootbot.pyonyourdesiredinterval.
评论