Why I created this project?

I really enjoy using my Echo Dot. It's conveniently placed in the corner of my room and it allows me to set timers, alarms and add quick reminders using my voice. Ever since I got it, I realized just how powerful voice is in human-computer interaction.

I use a habit tracker on my phone and have found it very useful but I wanted to try using it on my Echo device. In my mind, I wanted to be able to track a habit simply by telling Alexa, "I worked out today" or "I ate only healthy food today". When I tried the habit trackers on the skill store, I did not like them very much. The experience felt constraint and I felt as though I was not speaking in natural language (which is how it should be).

This is when I decided to build my own habit tracking skill.

What it does

The Habit Tracker allows you to begin tracking any habit of your choice, be it swimming, eating healthy or working out. Once you begin tracking a habit you can log it each day you complete it and the skill will remember how long you have been consistently performing this habit. It can also tell you what your longest streak has been for that particular habit.

You can even ask for a progress report and the skill will communicate to you your progress in natural language, even congratulating you if you're doing well on your habits and motivating you if you are not.

You can even un-log a habit that you accidentally logged, delete a habit you are no longer interested in tracking and get a list of all your habits.

How I built it

I spent a significant amount of time reading up on Voice User Interfaces and the important design principles that go into building them efficiently. I paid a lot of attention to the conversation flow and drew up flowcharts that encompass almost all the paths the conversation might take. I programmed the lambda function in Node.js and used MongoDB hosted on Atlas for my database.

My friend is an excellent designer and helped design the logo.

Challenges I ran into

Debugging was especially challenging while hosting the lambda function on AWS. Coding the different paths the conversation could take and the handlers for these paths was also quite time consuming.

Accomplishments that I'm proud of

This is the first project that I have successfully completed all by myself. This project went from the concept stage to the design stage and has finally taken shape and this makes me very happy. I really wish people find some value in what I have built.

What I learned

A TON of things. I've learnt how to adopt coding best practices (still learning). I've also learnt how to write unit tests, communicate with a NoSQL database and more importantly how to design and code beautifully simple conversation flows for voice enabled devices.

What's next for Habit Tracker

Lots of things,

  • Improve the user interface, add buttons to log and un-log habits using the touch screen
  • Add multiple responses so that the conversation feels much more natural
  • Add more advanced features like choosing how many days a week should a habit be performed

Built With

Share this project:
×

Updates