Code Monkey home page Code Monkey logo

blabber's Introduction

bird-singing2




Simple CLI server for all your blabbing needs.

It packs two simple but powerful functionalities:

  1. You can give the server text, and it will process and learn its ngrams (n configurable when starting the server).
  2. You can ask the server to generate random text based on the ngrams it's learnt from the input text it's been fed since starting.
Usage of ./blabber:
  -maxWords uint
    	max number of words on output when using generate (default 100)
  -ngram uint
    	size of the ngrams to be processed when using learn (default 3)
  -port uint
    	port for the server to listen on (default 8080)

Example of use:

$ curl -X POST http://localhost:8080/learn -H "Content-Type: text/plain --data-binary @pride-prejudice.txt 
$ curl -X GET http://localhost:8080/generate
To think it more than commonly anxious to get round to the preference of one, and offended by the other as politely and more cheerfully. Their visit afforded was produced by the lady with whom she almost looked up to the stables. They were to set out with such a woman.

The possibilities are endless!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.