dankenstein Markov Chain Twitter Bot generator开源项目

我要开发同款
匿名用户2021年11月08日
137阅读

技术信息

开源地址
https://github.com/esl/elarm
授权协议
BSD-3-Clause License

作品详情

Dakestei

DakesteiisaMarkovChaiTwitterBotgeerator,basedomakigamashupofdifferetcorpora.

Itisdescribedithisblogpost.

Depedecies

ThesoftwareitselfisimplemetedusigBash,Make,adPytho.

You'lleedaTwitterAccoutadaTwitterapplicatio.Fromthelatter,you'lleedacosumerkey,acosumersecret,aaccesstokeadaaccesstokesecret.

EtertheseitotwitterCredetials.sh

Togeeratethesupporteddatasetsyou'lleed:

PopplerbrewistallpoppleromacOSsudoapt-getistall-ypoppler-utilsoUbutu

Afterthat,youcarutheimportEv.shscriptithedev-folder.ThiswillcreateaPythovirtualeviromet(codaifyouhaveit,virtualevotherwise)calleddakestei,adistallallpytho-depedecies.

Ifyou'dratheristallthemseparately,theyare:Tweepy,darklyrics,wikiquote,markovify;(optioallyltk)

Usage

UsageisbasedaroudMake.Thefollowigoptiosareavailable:

makecorpora:Buildsallcorporamakelist:Listsallavailablecorporamakecombiatios:Pritsallpossiblecombiatiosoftwocadidates-mayicludeduplicates(withswitchedpositios)makemodelARGS="corpus1corpus2[(scale1scale2)stateSizeoverlapTotaloverlapRatiotriessetecesmodelComplexity]":Geeratesamodelbasedotwocorpora(theolyrequiredargs).Ifyoudefiescale1,youmustdefiescale2.Alloptiosisidethesquarebracketsareoptioal.ARGS:corpus1strig-theameofthefirstcorpusodefaultcorpus2strig-theameofthesecodcorpusodefaultscale1float/it-scaleofcorpus1relativetocorpus2defaultsto1scale2float/it-scaleofcorpus2relativetocorpus1defaultsto1stateSizeit-statesizeoftheMarkovchaidefaultsto2overlapTotalit-maximumsequetialwordsthatoverlapwithasetecefromthecorporadefaultsto15overlapRatioit-maximumpercetageofoverlapwithasetecefromthecorporadefaultsto70triesit-attemptstomakeaorigialsetecedefaultsto10setecesit-umberofsetecesdefaultsto5modelComplexitystrig-aive|expertdefaultsto"aive"EXAMPLE:makemodelARGS="tcmjobs21215301025expert"&&makesetecesmakesetece:Outputsoesetecebasedoaavailable(previouslytraied)model.makeseteces:Outputstheamoutofsetecesgiveasaargumetdurigmodelgeeratio.makeclea:Deletesallcorpora.maketweet:Postsatweet.

Itispossibletoseallcombiatiosforagivecadidate,e.g.makecombiatios|grep"picard+".

Deploymet:

Twittersecretsaresetviaevirometvariables,e.g.

exportCONSUMER_KEY="cosumer_key"exportCONSUMER_SECRET="cosumer_secret"exportACCESS_KEY="access_toke"exportACCESS_SECRET="access_toke_secret"

Aexampledeploymetisdescribedithebottomofthisblogpost.

功能介绍

Dankenstein Dankenstein is a Markov Chain Twitter Bot generator, based on making a mashup of diff...

声明:本文仅代表作者观点,不代表本站立场。如果侵犯到您的合法权益,请联系我们删除侵权资源!如果遇到资源链接失效,请您通过评论或工单的方式通知管理员。未经允许,不得转载,本站所有资源文章禁止商业使用运营!
下载安装【程序员客栈】APP
实时对接需求、及时收发消息、丰富的开放项目需求、随时随地查看项目状态

评论