How I ended up making MachineLearningForKids

I write a lot about what I’m doing with machine learning for kids, but in this post, I want to share a little about how I ended up doing it and why.

I tend to write about *what* I’ve done. I rarely write how things happened though, or what made me do them. I just assume that people would be less interested in that.

But, if I think about what I find interesting, it tends to be the backstory to projects. To use Nick as an example, I’ve seen him give loads of talks about Node-RED. And I’ve enjoyed the ones where he talks about how Node-RED happened more than where he gives demos of what Node-RED is.

Inspired by that, I thought I should at least try to capture a few breadcrumbs for how I ended up where I am now with machinelearningforkids.co.uk.

Timeline

I’ve tried to find a few checkpoints. As I only just thought to do this, it’s a little biased towards this year, but I think there’s enough background here to give an idea.

2014 – 2015
I was a mentor for a couple of universities in the UK that were on the Watson Academic Programme we were running. This was before Watson tech was generally available as cloud APIs, so this involved giving Uni students special access to Watson tech and helping them do projects with them. But more importantly, it meant I was working with University students to help introduce them to machine learning.

April 29 2015
I spoke at an education conference (aimed at education, government and industry) about the need to teach the ideas and implications of artificial intelligence to school kids. It was mostly theoretical at this point – I was essentially saying “I think we should be doing this” because I only saw us making an effort to engage with Uni students on anything to do with AI.

I got an enthusiastic reaction from teachers at the event, and at similar events throughout that year. But I didn’t find the time to do much more than talk and think about it.

February 18 2016
In a few half-term afternoons, I built a machine learning-powered Guess Who game with my kids – getting them to train a text classifier to recognise Guess Who questions and an image classifier to recognise attributes in photos of faces.

They loved it, and more importantly – seemed to learn a lot from it. I ended up tidying it up a bit and running it as an activity with a couple of local schools. I was convinced it should be totally possible to give kids hands-on experience with machine learning that would help them to learn the fundamental principes.

June 26 2016
I made another educational game – this time, Rock Paper Scissors. Again, I started by testing it on my kids, getting them to train an image classifier to recognise photos of hand shapes.

It also went really well. It was less fiddly and complicated than Guess Who. It was also a lot quicker to do – running Guess Who with school kids in Code Clubs was taking several weeks (with an hour each week) because it had a few moving parts. I wanted something that the kids could do in one session, while still learning a few interesting ML concepts.

Again, I managed to tweak and refine the game based on the feedback I got from the local schools who gave it a try.

October 1 2016
Another educational ML game – this time, Top Trumps. This one started life as a hack-day project. The idea was that kids could train a bot to play Top Trumps by playing against it – with a simple classifier learning from the outcomes of each hand.

It was even simpler to setup and run than the last two projects. That was the consistent feedback on everything I was taking into schools. A project to do at home with your own kids is a different thing to something you want to try and run with a whole class at once. I was starting to learn how to make that work.

This one was used as an activity at the XploreIT STEM event ran for local schools at IBM Hursley. The feedback from that was also super enthusiastic.

February 22 2017
I had two main challenges with my approach in 2016.

First, each new activity involved a ton of work building a whole new UI to train and test each new project. Every activity was a new, standalone thing. This meant new activities took time to create.

Second, the activities were hugely prescriptive. “Now, you’re going to train a computer to play Guess Who. That’s all you can do. The UI is hard-coded to run a Guess Who game. That’s what we’re doing.”
I wanted kids to be able to be more creative. To make more open-ended activities, where the students would be able to make whatever they can think of with the ML models they trained.

To that end, I started kicking around the idea of using Scratch as the basis for educational ML projects. In February, I made a small proof-of-concept showing how to extend Scratch by adding Watson services to the blocks available in the Scratch palette.

April 17 2017
I felt like I had the different pieces I needed.

My projects in 2016 made me think that you could make games that would enable kids to train machine learning systems, in a way that they would enjoy and learn from.

And the Scratch prototype showed me that it could be delivered in an open-ended way, without me having to build a massive new UI (or teach kids how to use it).

I bought the machinelearningforkids.co.uk domain name, mostly as an incentive to get me to do something about it, and started idea-storming.

May 2017
I started building a new ML training tool that could dynamically generate Scratch extensions.

That first month was a bit like an extended hack-day. Looking back over the commits, I can see that I wrote about 5000 lines of code in the evenings and weekends across a few weeks.

June 6 2017
I had something sort of working, so I needed to get some feedback. In June, there was a three-day Summer School for teachers held at Hursley. I managed to get a slot in there to show a room full of teachers from across Hampshire what I was up to, and ask them what they thought of it.

June 7 2017
I shared a two-minute video showing an end-to-end overview of what the prototype could do. Only a couple of dozen people watched it, but a few that did gave me some really helpful pointers on how I could make the tool make more sense.

June 20 2017
I had a stand at our internal innovation showcase event “TechConnect”, which meant I got to show the prototype to a variety of IBM technical leaders. I got some lovely supportive comments, some super useful pointers and feedback, and managed to win the overall judge’s prize.

July 4 2017
Another Summer School for teachers, this time in London. By this time I had not just a working prototype that was starting to look like a usable tool, but also a couple of examples of what I thought project worksheets could look like. I showed the worksheets and gave a live demo to a room full of teachers from schools across London and asked them what they thought.

July 18 2017
Getting a lot of feedback from a lot of people at an early stage of a project is super useful, so I was grabbing any opportunity I could get to put the prototype in front of teachers. I gave another live demo – this time at a continuing-professional-development session for teachers in Warwick.

August 2 2017
I guess this was sort of when I released the tool. But it’s not like I’ve stopped working on it since, so any date is fairly arbitrary. But if you have to pick a date when I stopped calling it a prototype, and started calling it an actual thing, then start of August would be it.

August 8 2017
I also shared the tool with colleagues within IBM. A lot of IBMers are regular volunteers at their local schools or run Code Clubs, so I invited them to use machinelearningforkids.co.uk as part of that. This quickly got me a bunch of new users, and a couple of weeks full of bug reports and feature requests!

August 29 2017
I found a few opportunities to test the tool and the worksheets at work. When we had a bunch of work experience students in, I’d borrow them for an afternoon to get them to try out a few machinelearningforkids.co.uk projects.

But on August 29, I ran my own event – a half-day event for school kids held at Hursley that was entirely made up of using machinelearningforkids.co.uk.

September 14 2017
One of the local primary schools that ran my Guess Who project over several months in the last school year agreed to use machinelearningforkids.co.uk with their Year 5 class this term.

Not just as an after-school club, but for the whole class as a part of their normal school day. And not just as a one-off activity, but in a regular class every week for twelve weeks.

This was very exciting, and a great vote of confidence.

September 21 2017
There was a small piece in the Telegraph about what I’ve been up to, but the interview for this was back in May before I could share what I was doing with machinelearningforkids.co.uk so it’s about what I was doing last year.

October 2 2017
Over 100 kids used machinelearningforkids.co.uk at this year’s XploreIT (a STEM event for local primary schools held at Hursley).

October 17 2017
90 school kids at IET’s EngFest event in London used machinelearningforkids.co.uk to train machine learning models to do sentiment analysis and recognise handwriting.

I’ve got a couple more of these sorts of events lined up this year: workshops for large numbers of kids to give them an educational taster session in AI using machinelearningforkids.co.uk. The next one is November at the Festival of Innovation.

October 29 2017
Until now, I’ve been cautious about user growth. Class accounts for schools and code clubs could only be created by me. All new classes started by the teacher or group leader emailing me to ask me to set them up on the tool.

That was also an MVP consideration. One of the things I was able to avoid until now was building APIs and UI for creating class accounts. I did it manually. But as I try and scale it up a little, that means removing the last few manual steps and automating everything. As of today, schools can sign themselves up through machinelearningforkids.co.uk without needing me to get involved.

And that brings me to today.

The main takeaway from pulling together this timeline was just how slow it’s been. I’ve been thinking, talking about, and evolving this idea for two-and-a-half years now.

Adoption

Schools and coding groups are now using machinelearningforkids.co.uk in Singapore, Egypt, Israel, Brazil, Philippines, Ireland, Spain, and the Netherlands.

The takeup closer to home has been slower. There are only about ten schools in England and Scotland that have signed up. And I only know of one of them using it regularly (e.g. every week instead of for one-off activities).

However, all of this has been with essentially zero marketing or promotion. In fact, I’m amazed that the schools and groups that are using it managed to hear of it. It’s been word of mouth, I guess?

That said, there are now thirty IBM employees using it. I haven’t really chased people to ask what they’re doing with it. I’m sure some will just be trying it out for themselves, or with their own kids. But from the limited analytics I have, I can tell that at least some of them are using it for something like Code Club or school sessions. Either that, or they have over twenty kids each.

“Is this your job?”

I keep getting asked this.

From 2011 to December 2016, I was a developer on IBM’s AI services. And a big part of that was in enabling IBM’s clients and business partners to be able to train and use machine learning systems. You could argue that enabling school kids to do and understand this is just a broadening of that same role.

Since January, I’ve been working in a different bit of IBM, on something unrelated to AI or IBM’s Watson work. And in some ways, that’s made it easier for me to work on Machine Learning for Kids as I’ve had more free time than I used to as a Watson developer.

Either way, nope. This isn’t my job. It’s very much a personal project.

As part of this reflecting-on-what-it’s-been-like-building-MLforKids that I’m doing, I grabbed a few screenshots from Github.

Most of them are fairly typical for a personal project.

For example, the code is written in evenings and weekends. (Although possibly earlier in the morning than is healthy)

github-punchcard

The amount of code I’ve written for it tailed off over the summer (as I focused on writing worksheets rather than adding a lot of new function to the tool itself).

The recent blip is mostly the new functionality I’ve added to allow schools to sign themselves up that I mentioned before.

github-contributions

github-codefrequency

“Why are you doing this?”

This is the other question I keep getting asked.

Interestingly, not by geeks. Geeks seem to instinctively get it. “You thought of something cool you could build. So you built it. Of course you did”

Others (teachers, managers, journalists, etc.) seem to ask this one a lot.

It’s not a question I’ve been very good at answering. The best I’ve come up with is because I thought it needed doing. (I’ve tried to explain why before and after I started doing this). And, as far as I could see, noone seemed to be doing it.

I’m still on the look-out. The closest I’ve found was the research paper “Child-friendly Programming Interfaces to AI Cloud Services” (published last month), when one of the authors got in touch with me in August to give machinelearningforkids.co.uk a try and kindly give me some feedback on it.

The aim of that work is similar to what I’m doing (making it easier for kids to use AI services, albeit from Snap! instead of Scratch). Their focus is in helping kids use pre-trained AI services as-is so that the children can learn what these technologies can do. I’m more interested in making sure the kids train the machine learning models themselves.

But different emphases aside, it’s fantastic to know that I’m not the only one that thinks this is an area that’s worth time and effort.

“What next?”

Obviously, as with any code project, there’s a backlog of technical issues that need addressing.

I want to expand the range of project worksheets I’ve written. And the ones I’ve already written could really do with improving. Writing words is hard.

More importantly, I guess increasing adoption and usage should be a goal.

Partly, that’s something I can do in the tool by making it easier. Signing up, in particular setting up the Bluemix bits, is still harder than it should be. I’m not sure what I can do about that, but I know I need to do something.

Perhaps I should do something to spread the word about some of this, outside of the people who already listen to me endlessly go on about it on Twitter and in person. 🙂

How I built it

Finally, I need to put something geeky in here to offset all the rambling.

Still under the banner of how I built the current tool…

The back-end code is all written in TypeScript.
The front-end is all Angular.

The app is running in Node.js, developed with a typical tool set for a Node.js app – gulp, mocha, sinon, istanbul, etc.

I’m storing training data in a hosted database from Compose.io.

Machine learning models for text projects are trained using the API from Watson Conversation. Machine learning models for images projects are trained using the API from Watson Visual Recognition.

The overall app is hosted on IBM Bluemix.

The SSL cert came from Let’s Encrypt.

The user management and auth services is provided by Auth0.

I’m using Google Analytics, but not particularly intelligently. It’s interesting to see where my users are in the world, and what browsers they’re using.

I’m using cfbot and a private Slack channel to alert me to any back-end errors.

And I’m using Sentry.io to alert me to any front-end errors.

And obviously the project builder that the kids use is ScratchX, with a few extensions based on this sample.

Tags: , , ,

3 Responses to “How I ended up making MachineLearningForKids”

  1. GaleaWong says:

    Dale Lane, hello. I’m from China’s FabLab XH. I’m a student. I’m very interested in the children’s mechanical learning website you’ve made. Could you bring it into our FabLab XH lab? Looking forward to your reply, thank you.?????

  2. dale says:

    Hello – Happy to help if I can. What did you mean by bringing it into the lab?

  3. GaleaWong says:

    Hello, you are so nice, sorry. I mean, can I get your support to promote this website in China so that more children and even adults can learn machine learning?