Algorithmia

How to Solve FizzBuzz Using Machine Learning and Scikit-Learn

Using machine learning to solve FizzBuzzThis is a guest post by Daniël Heres, a software engineer & Computing Science student. Want to contribute your own how-to post? Let us know.

FizzBuzz is a programming exercise some interviewers use to test a developer’s skills. To solve FizzBuzz, count from 1 to 100 and replace numbers divisible by 3 with “fizz”, and numbers divisible by 5 with “buzz.” For numbers divisible by both 3 and 5, we replace them with “fizzbuzz”.

Sounds straight-forward, right?

Instead of programming a bunch of if statements and checking whether each number can be divided by 3 or 5, we’re going to use machine learning. In this tutorial I’ll show you how can create your own AI FizzBuzz model, and host it on Algorithmia. Try the final result here. Read More…

Web Scraping with Python: How To Crawl, Scrape, and Analyze URLs

Web Scraping 101: How to crawl, scrape, and analyze websites in Python

How do you convert an entire website into JSON when an API isn’t available? For many, they’d write a web crawler to first discover every URL on a domain. Then, write a web scraper for each type of page to transform it into structured data. After that, they’d have to de-dupe, strip HTML, and more just to get their data in a structured state. That sounds like a lot of work.
Read More…

Use LDA to Classify Text Documents

LDA Topic TagsThe LDA microservice is a quick and useful implementation of MALLET, a machine learning language toolkit for Java. This topic modeling package automatically finds the relevant topics in unstructured text data.

The Algorithmia implementation makes LDA available as a REST API, and removes the need to install multiple packages, manage servers, or deal with dependencies. This microservice accepts strings, files, and URLs, as well as the ability to include a stop word list as an argument. Read More…

Build a Sentiment Analysis Slack Chatbot in Python

slack-chatbot-appThis is a guest post by Chris Hannam, a professional Python and Java developer. Want to contribute your own how-to post? Let us know here.

As companies adopt chat tools like Slack to manage internal communication, they’re learning that a lot can get lost when communicating over text.

With this in mind, I built a Slack chatbot to keep an eye on messages, and flag negative ones to give the commenter a little nudge to be nicer in the future. Read More…