Open Thinkering

Menu

Month: July 2022

Some thoughts on programmatic Open Badge image creation using AI models

Towards the end of yesterday’s meeting of the Open Recognition working group of the Open Skills Network we got on to talking about how it might be possible to programatically create the images for Open Badges when aligning with Rich Skill Descriptors (RSDs).

Creating lots of badges manually is quite the task, and gets in the way of Open Recognition and Keeping Badges Weird. So the first step would be to speed up the process by creating a style guide. Sharing SVG templates that are editable in a wide range of image-editing applications can speed up the process.

For example, for the upcoming Badge Summit, we’re issuing a badge which we want others to be able to issue for their own events. So we asked Bryan Mathers to create an image where the outside would remain the same, but the middle bit could be swapped out easily. Here’s the result:

I Kept Badge Weird at The Badge Summit 2022 badge

The next step would be to have a style guide which makes it faster to create unique badges. That involves a colour palette, font choices, shapes, etc. You can see this in action for our Keep Badges Weird community badges:

Selection of badges available to earn in the Keep Badges Weird community.

Lovely as they are, this is still labour-intensive and time-consuming. So how about we create them programatically? My former Mozilla colleague Andrew Hayward did a great job of this years ago, and the Badge Studio site (code) is still online at the time of posting.

The advantage of programmatically creating badge images is that it (helpfully) constrains what you can do to be in alignment with a style guide. Creating good looking badges can take seconds rather than hours!

An example of a badge image created using Badge Stuudio

However, what if we want to create badge images quickly, and programatically based on certain inputs? There are libraries that can create unique shapes and images based on email address and are used sometimes as the default avatar for platforms. Here, for example, is RoboHash which can be used to create good-looking unique ‘robots’:

Selection of unique robots created using RoboHash

It’s not a huge leap to think about how this could be used to create badge images based on a unique reference from an RSD.

But, if we’re getting a computer to generate something, why not something crazy and unique? Lately, there’s been a lot of noise about different AI models that can be used to generate images based on text input. One of the best-known of these, the images from which have been circulating my corner of social media quite frequently is Craiyon (formerly DALL-E mini). Here’s a really basic attempt:

Nine images created via the Craiyon AI model showing recognition badges

They’re quite… uninspiring and generic? However, they didn’t take any thought or effort on my part.

There are more advanced models than Craiyon, such as Midjourney. This can create stunning images, such as the one featured in Albert Wenger’s post about machine creativity. In fact, it was that post that got me thinking about all this!

You can create up to 25 images using the Midjourney Discord account before paying, so I created this one as quickly as possible using the same prompt as above. You can create variations and upscales, so I asked it to create variations of one of four images created, and the upscaled it to the max. I ended up with the following:

Round patch-style badge (black/yellow with orange shapes)

This is also quite boring, to be fair, but the awesome and weird thing about doing this in Discord is that you see the prompts that other people are entering to create image — e.g. ‘huge potato chip eating a bag of humans’ or ‘rainbow slushy trippy wallpaper’. I noticed that there were certain prompts that led to amazing outputs, so I tried ‘rainbow waterfall in a hexagon,bright,trippy’ and got these options:

rainbows and hexagons, AI created art

The bottom-left image looked potentially interesting, so I asked for variations and then upscaled one of them. I then just cropped it into a 12-sided shape and ended up with the following. I guarantee it’s one of the most unique badge images you’ll have seen recently!

12-sided rainbow hexagon images

The point is that there’s almost infinite variations here. And, as I found, getting the words right, and then doing variations and upscaling is actually quite a creative process!

As ever, I don’t have the technical skills to stitch all of this together, but I guess my job is to encourage those who do in particularly fruitful directions. The workflow would go something like:

  1. Community decides new RSDs
  2. Organisation or individual creates badge metadata aligning with one or more RSD
  3. AI model generates badge image

I should imagine a lot of this could be automated so that badges that align with a particular RSD could have visual similarity.

This could be amazing. Anyone want to give it a try? 🤩

Enjoy things while they last (or hope for the best, prepare for the worst)

Note: it’s hot, this post might be be more ramble-y than usual…


Next to my bed I have one of these:

Glass paperweight with image of waves within it

It’s a glass paperweight that serves as a memento mori, a reminder that one day I will die. That might seem a bit morbid, but it reminds me to carpe diem (“seize the day”, to use another Latin phrase) and that things won’t be this way forever.

My kids will grow up and leave home.

My current state of calm will dissipate.

My possessions will stop working, get lost, or be stolen.

The list is long, for good and bad.


But my reason for writing this post is not a personal one, but a professional one. Right now, I’m more interested in talking about projects and initiatives ‘dying’ than me kicking the bucket. There have been multiple reasons over the past week where I’ve noticed that people expect things that start off great to continue to be so.

An OER repository was sold off to a company whose website is blacklisted by many educational institutions. A popular Android launcher was sold to an analytics company that’s often blacklisted by network blocking software. A project I’ve been involved with looks like it could be in danger of betraying its radical roots.

This is all very predictable, and is the reason for the popular phrase “hope for the best, prepare for the worst”. Especially in the kind of work I do at the intersection of learning, technology, and community, there are some amazing people collaborating on some fantastic things. It just takes a few bad actors (or people with ‘misaligned incentives’ shall we say) to spoil things.

That’s why setting up projects the right way from the beginning is so important. With MoodleNet, for example, we used the AGPL license, which meant that after I and the team resigned due to some internal drama, the Open Source code could form the basis of the project which has turned into Bonfire.

Even without specific licensing, just working openly can have the same effect. For example, there’s an archive of the work I did with a community that I helped grow at Mozilla around the Web Literacy Map. There’s no reference to it any more on the Mozilla site, but I can still reference it myself.

I’m not bitter about these things. (Well, not any more.) My point is rather than you should set up projects and initiatives in open ways, providing ways for awesome, talented people to get involved. But don’t be naive while doing so. Use defensive licenses, like the AGPL, and the wonderful Creative Commons Attribution-Sharealike (CC BY-SA) license which forces derivative works to be shared under the same license.

The same is true of legal structure and governance. WAO is set up as a co-operative with a flat structure and Sociocratic decision-making. It’s not possible for one person to sell out our company from underneath us because of the legal structure we created, after taking advice from more senior members of the co-operative community. And we’ve learned that consent-based decision making allows us to make decisions in line with our values.

Processes (especially around decision-making) work… until they don’t. You have to be intentional about these things. Remember that contracts are for when things go wrong, so cover your back. Imagine the worst thing that could happen, and put in place safeguards. Come up with ways to make decisions in productive ways with other people. Share your work far and wide, but protect it using an appropriate license.

Remember that our time on this planet is short, so let’s be awesome to each other.


In case you’re wondering, I bought my memento mori from The School of Life, and while you can’t get this particular one any more, there are others which are great — if not quite as awesome.

Weeknote 28/2022

It’s 16 degrees C and raining where I am as I sit down to write this. I’ve just been for a gentle run. It’ll get warm here later today, but not dangerously hot like further south in England is predicted to be. Stay safe out there!

A couple of months ago I listened to a podcast episode entitled Run Like a Pro (Even If You’re Slow). In it, someone was interviewed who had some great advice on running: increase the overall volume of running that you do, while mixing up low intensity and high intensity workouts. So this week, I’ve alternated 10k runs with shorter runs, running every day other than Saturday (my rest day). It’s worked really well, and has felt fantastic starting each day with a run!

  • Monday: 10k
  • Tuesday: 4k
  • Wednesday: 10k
  • Thursday: 2.5k
  • Friday: 10k
  • Saturday: (off)
  • Sunday: 5k

Saturday was an important day for Team Belshaw. My wife, Hannah, completed a 26.2 mile / 42 kilometre (i.e. marathon-length) Mighty Hike with some friends to raise money for MacMillan Cancer Support. Meanwhile, I was with the kids: our daughter made her debut in a friendly for her new football team, scoring one and making two assists in a 5-0 victory; our son participated in a 3-on-3 basketball tournament where he played well against kids older (and much taller!) than him.


After literally weeks of agonising, I’ve finally purchased a new laptop. It’s a refurbished Lenovo ThinkPad X1 Titanium Yoga and should be arriving today. As far as I can gather from my extensive research, it should be a fantastic replacement for the Google Pixelbook on which I’m composing this. In other words, it’s got a 3:2 form factor touchscreen and can be turned into a tablet. I’m planning to run Linux on it (obviously) so will be testing out various distributions. I’ll probably try Fedora Silverblue first and then my go-to distro of Pop!_OS.

This does mean it’s the end of the line for my Mac Mini on which I’ve been experimenting with Asahi Linux. While it’s been amazing to see the progress the team behind the project have made in such a short amount of time, it’s realistically going to be another few months before I could use it as a daily driver. So I think it’s better to use the sale of the Mac Mini towards the new laptop.


Work-wise this week I spent about 40% of my time on LocalGov Drupal community stuff. I’m really pleased with the progress that’s being made in a short amount of time, and it’s a fun project to work on with Aaron, Laura, and the core LGD team. The plan is to experiment with Open Badges soon, after an enthusiastic response to a quick overview in the Product Group meeting.

Some of the rest of my time was spent working on WAO‘s collaboration with Participate on the Keep Badges Weird community project. I’m heading to the US in a couple of weeks’ time to The Badge Summit, so we’ve just been making sure we’re ready for that. We also ran a Badge Wiki barn-raising session with KBW community members, which is something I always enjoy.

Other than that, I worked with Laura and Anne on the Sport England open working programme, getting the slimmed-down and contextualised version of our What We Talk About When We Talk About Open email-based course ready to be delivered over the summer. We also worked on planning out the third module on Open Access to be ready for September. A bit of business development, marketing, and a tiny bit of work on a Greenpeace project, and that was that.


I published two blog posts here:

…one on the WAO blog:

…and a few on Thought Shrapnel:


I’m really enjoying watching the UEFA Women’s Euro tournament. The standard of football is pretty high, and it’s so inspiring for my daughter to see the England team play so well and with so much confidence. She genuinely could be playing for them in a decade’s time. We’ll see.

Next week, it’s the last week at school for our kids. So everything is nice and relaxed. Everything is under control work-wise, so I’ll have plenty of time to set up my new laptop and make sure we’re ready for the kids being off for six weeks. I’m taking most of August off, which will help, but going from Colorado, to Devon, to France might not feel so relaxing…


Photo of the Jasmine in our garden after a bit of remedial work and lots of watering yesterday!

css.php