"Bullshit article generator" summit GitHub hot list, write thousands of words every minute masterpiece formalism

First, the introduction of garbage text generator

View GitHub recently, I found such a bone Qing Qi's ridiculous project, but also particularly high heat.

  • Project Chinese name: bullshit article generator
  • Project English name: BullshitGenerator

According to its author, he occasionally takes some time for the Chinese text test text rendering GUI development, and therefore developed this nonsense generator. However, due to the formation of nonsense it is too philosophical, it has recently been small partners to play bad.

His style might look like this:

imgClick and drag to move

You find, citing the scheme of things, that good shit unreasonable Where is it?

There are something like this:

imgClick and drag to move

Moreover, the same theme, each click is generated, there will be a completely different character.

Second, the origins of spam text generator

Garbage text generator is also very interesting history, according to the authors, from the very beginning he was known almost shopping, I found someone in the exit when the student union, need to write 6000 words withdraw the application. Because of the previously very good at writing this kind of "bullshit" article. The results write a few words, suddenly thought or write a program to generate it. So, shit unreasonable character generator was born.

At present, because the project is too hot, one student, the generator ported to the telegram, received a full philosophizing robots.

When asked "What for lunch today" Such a century-old problem when the robot replied to a full two-screen information:

imgClick and drag to move

There are also some students, it is committed to bringing this project to the world. So, in English and Japanese version was born.

imgClick and drag to move

Some students also developed a handwritten version:

imgClick and drag to move

Third, shit unreasonable article generator is how to achieve?

Simply rolled over the source really is particularly simple, is simple nonsense corpus, a little string concatenation statement generates a gorgeous thousands of words, we have to appreciate Source:

Famous celebrity nonsense corpus, 167 lines of code, this just add more nonsense, you will be able to generate more content:

imgClick and drag to move

js version generation algorithm:

function 生成文章(){
    主题 = $('input').value
    let 文章 = []
    for(let 空 in 主题){
        let 章节 = "";
        let 章节长度 = 0;
        while( 章节长度 < 6000 ){
            let 随机数 = 随便取一个数();
            if(随机数 < 5 && 章节.length > 200){
                章节 = 增加段落(章节);
                文章.push(章节); 
                章节 = "";
            }else if(随机数 < 20){
                let 句子 = 来点名人名言();
                章节长度 = 章节长度 + 句子.length;
                章节 = 章节 + 句子;
            }else{
                let 句子 = 来点论述();
                章节长度 = 章节长度 + 句子.length;
                章节 = 章节 + 句子;
            }
        }
        章节 = 增加段落(章节);
        文章.push(章节);
    }
    let 排版 = "<div>" + 文章.join("</div><div>") + "</div>";
    $("#论文").innerHTML = 排版;
}

Click and drag to move

py Version:

if __name__ == "__main__":
    xx = input("请输入文章主题:")
    for x in xx:
        tmp = str()
        while ( len(tmp) < 6000 ) :
            分支 = random.randint(0,100)
            if 分支 < 5:
                tmp += 另起一段()
            elif 分支 < 20 :
                tmp += 来点名人名言()
            else:
                tmp += next(下一句废话)
        tmp = tmp.replace("x",xx)
        print(tmp)

Click and drag to move

As can be seen, did not use any advanced technology, no tricks, the authors state the following:

I Caishuxueqian not related to any natural language processing algorithms and is currently prefer a simple and effective way to achieve the purpose of way. Unless hit the ceiling, otherwise we will not introduce any neural network algorithm, but anyone is welcome to open another branch more complex , better algorithms, but unless critical nonetheless, otherwise I will not temporarily integration.

The text read carefully, still quite philosophical.

Amount, in fact, in all seriousness say that feeling nonsense. You know. . .

Fourth, and finally, put links

Bullshit article Builder:
https://github.com/menzi11/BullshitGenerator

Web version:
https://suulnnka.github.io/BullshitGenerator/index.html


My micro-channel public number: architecture Scriptures (id: gentoo666), shared Java dry, high concurrency programming, popular technical tutorials, and distributed micro-services technology, architecture, design, block chain technology, artificial intelligence, big data, Java interview questions, as well as cutting-edge information and so popular. Updated daily Oh!

imgClick and drag to move

Guess you like

Origin www.cnblogs.com/anymk/p/11991803.html