Transforming Primary Care: a Case Study in Evolving from Start-Up to Scale-Up

Mike's Notes

A useful shared experience by Leander Vanderbijl at an InfoQ conference. The original InfoQ video presentation includes the slides. and is well worth watching (52:26).

Resources

References

  • Reference

Repository

  • Home > Ajabbi Research > Library > Subscriptions > InfoQ
  • Home > Handbook > 

Last Updated

29/01/2026

Transforming Primary Care: a Case Study in Evolving from Start-Up to Scale-Up

By: Leander Vanderbijl
InfoQ: 22/10/2025

Leander Vanderbijl is an engineer and architect that has worked across the entire stack and has been working at Kry/Livi for the past number of years. He has developed large enterprise applications, migrated cloud platforms, designed data query frameworks, architected integration systems and built lots and lots of APIs. Having worked in large enterprises, small companies and, most recently, in healthcare, he has built the monolith, torn it apart and then rebuilt it again.

Transcript

Leander Vanderbijl: Have you ever built the perfect application? Beautifully crafted your models so that everything fits the real-world objects that you think you're going to have in your system? Only to wake up one morning and your PM comes to you and says, yes, that's great, but what if it just did this a little bit differently? With that one sentence, your entire premise is thrown out the window. All of your assumptions are proven false and your beautiful system is impossible to work with. What about that perfect architecture you've developed? Very clean, you've got onions and layers and all of that fun stuff, and it works perfectly. You don't know when and you don't know why particularly, but over time you suddenly come back to it and this beautiful application has become a spiderweb's nest of impossible dependencies. I've been there. We've had that problem.

In this talk, we're going to talk about how our company, Kry, has evolved through startup and scaleup phases, and particularly how our systems have evolved while we were trying to find our product market fit, and how our systems became that spaghetti spiderweb's nest of dependencies.

Particularly, we'll look at how we're now applying domain-driven principles to gain back control of our architecture, to try to make sense of the mess that we built. Again, not intentionally did we build that mess. We're also going to look at how we're changing our mindset from looking at the product and taking a feature endpoint. Our frontend needs this so I'm going to build one endpoint for that. Instead of doing that, we're starting to think about, what functionality do we need to provide for any client or for any other part of the system? We're going to look at how we're moving from an organic approach to our software evolution where people just do what they need to, when they need to, to a much more deliberate and targeted approach to our evolution where everybody knows where we're going.

Marshall Goldsmith says, what got you here, won't get you there. Which is a great quote as long as you know where there is. Throughout this talk I'd like you to remember my golden rule, my guiding principle, working software is better than the promise of working software. We're not Google or Microsoft. I can't go and tell a team to rewrite the OS every four years. We have to find some other way of making our systems better in situ.

Roadmap

For the structure of this talk I'm going to borrow heavily from Simon Brown's C4 model. We're going to look at this problem at four different levels. We're going to start at the company profile. We'll talk a little bit about what our company does and what its purpose is. Then we'll move on to go a little bit deeper to the container level and look at our product history and our requirements and how those have evolved over time. Then we'll get a bit deeper still and get to that component layer and look at how our architecture and our services have grown and adapted over time. Lastly, we'll look at domain modeling, sort of a code level. We won't look at code but that code level of the C4 model. We'll look at how our domain modeling has changed over time and how it's evolved when we started to realize that our initial attempts at it weren't fitting the bill.

Tech in Hardware

Did you know that in the UK there are 353 million GP patient appointments every year? There are 28,000 full-time GPs. Is anybody good at math? I do that for you. That average is somewhere in the neighborhood of 30 patients a day, or 3 to 4 patients an hour. At Kry, we've found that by applying technological solutions in a process that we call digital offloading that we can increase this throughput from 3 to 4 meetings an hour to somewhere in the neighborhood of 7 or 8 meetings an hour, so nearly double, and still provide the same levels of clinical excellence. We do this through a series of things.

A large part of that is moving the meetings online, and that has proven that we can improve throughput just by doing that alone. A lot of it is really around all the rest of the provision of services that go around meeting a patient. That's things like being able to get data in a timely and efficient manner to the GP before they look at a patient. That's mastering the workflows after the patient has been seen by the GP. All the data input, we can standardize that. We also can vastly improve the workflows for continuing care, things like prescriptions or providing referrals and things like that. With all of that that's how we can really drastically improve the speed and the quality in which our GPs can manage the patients.

Company Profile (Context)

We were started in 2015 in Sweden. As we grew, we started to expand into other parts of Europe. Primarily, our biggest markets are France and the UK. We've also recently gone into Norway as well. Again, our focus is the digital transformation of primary care.

Product History (Containers)

Let's go into how our products have evolved over time. When we started in 2015 it was simple. All we wanted to do was hold meetings digitally online. The requirements were again pretty straightforward. Obviously, I'm simplifying this a little bit. Really all we had to do was we had to allow clinicians to be able to meet with patients. We had to be able to get reimbursed, that's the important part, from the national healthcare system particularly in Sweden. We had to be able to share data with the national healthcare services. That's both getting data and being able to write data back to them.

As we grew, we added more requirements and more functionality. Things became naturally more complicated. We added prescriptions. When we moved into other parts of Europe we started having to deal with more complexity. We had to deal with regional differences. Things like in the UK the reimbursement model is based on a fee per action, so we get paid for every patient appointment we have. Whereas when we built the system in Sweden the Swedish model is based on capitation, which means that the patient has to be registered with your clinic in order for us to be reimbursed. They were very different models of getting reimbursed. We also had to deal with a lot of different security and regulatory differences.

Things like age of consent, dealing with children and things like that. We started adding new clinical types, so new health services. Things like mental health, nursing services. These services had very different workflows to the original GP workflows. We started opening our own physical branches and we started having to deal with different scheduling models.

Particularly, we started to have to deal with separated schedule books. Each physical practice would have their own separated schedule that had to be maintained and managed differently from all the other schedules. This was something that was a big difference because originally when we were just digitally online, we just had one big pool of doctors who would serve us a queue. Most recently, we've added insurance companies and private companies who want to provide our services to their employees as a benefit. This has added more workflows that we had to manage. With insurance workflows we have to be able to make decisions on the fly as to whether or not we can see that patient. That means we have to be talking in real time to insurance third-party APIs and be able to make complex decisions on the go. We also came across issues with data sharing.

In the UK, for example, if we see a patient through an NHS contract, we're allowed to use NHS APIs and NHS data. If we see that same patient through an insurance workflow, we're not allowed to use any of the APIs. We're not allowed to use that data either. Suddenly, we had to start understanding, who is paying for this appointment, and be able to make decisions rapidly as to what data we could use, what APIs we could use and the like. That's a plotted history of our product.

Architecture and Services (Components)

When we started, life was simple. We made this ourselves, maybe you can tell. Again, life was easy. We had clinicians and we had users, and they could have meetings. We could store their data in what we called, and I still don't understand this joke, the fax machine. It was ok. It worked. In fact, it worked really well. We could scale quite easily with this service in terms of the volume, and life was good. We started having patients and we started increasing the number of patients we were seeing. We started adding more functionality. We added the ability to manage prescriptions. As we grew, sometimes it was quite easy for us to add new services because you could fit it in or you could do things. Sometimes, for example, when we had to add new payment models when we moved into the rest of Europe, things became more complicated. We had made assumptions about our payment systems and our payment models when we started in Sweden.

Suddenly, when those models changed, we had to work out how to fit them in. Sometimes we could fit that in just beside the code we'd already written. Other times that would be too difficult and so we'd have to create a new service. The same thing happened across the board when we added mental health services, for example. Mental health services are a very different workflow. They don't necessarily revolve around one meeting with a patient like we had with a GP. You might have a dozen meetings or more meetings, all part of one service as you were. We had to build another service to manage that, and the trend continued. When we moved into physical, we started dealing with queues and scheduling. We already could do queues and scheduling in our meeting service, but we couldn't separate them nicely so we had to refactor parts of that. We had to build a service to go with it to manage some of that complexity.

It was at this time that we really started to see that maybe what we had initially thought, wasn't as perfect as we had initially thought. Things were starting to change. When we started having physical meetings we realized, yes, we've got patients as well. When we started, users were patients and patients were users, and it was simple. Who's a user in a physical sense? We also at this stage started being able to see children. Somebody worked out that children might have parents, we didn't really think about that.

Then, some really clever guy, real person, realized that actually a child might have two parents and they might have two separate accounts. How do we deal with those relationships? We made this work but it wasn't pretty. Remember, this is all through our startup phase. We didn't have the luxury of stopping, pausing everything, and refactoring a bunch of code, refactoring some of our main assumptions. Our primary goal was to get customers in the door. Our primary goal was to try to get profitable, and so we were doing everything we could to make that happen. I must stress this, that wasn't the wrong decision. We absolutely had to do that. If we hadn't have done that, I probably wouldn't be here today. These are decisions that are made because of the situation that you're in, and that's fine.

At some stage, you are going to have to deal with the technical debt you've built. Our insurance workflows were so drastically different to what we had built before that we actually built pretty much a stand-beside service to handle a good chunk of our insurance workflow. We started having duplicate code because we couldn't make it work otherwise. We started complicating the systems that we had.

This was a very organic approach. When we started, we didn't really know where we were going to go. People just did what they needed to do. At the beginning, again, remember this was easy. Our dependencies were very straightforward. You could see which service needed to talk to which service and how things should go. Over time, as we added more services and we added more complexity, those dependencies grew. We didn't have any rules about who could talk to what or when.

Basically, if you needed it, you could build it. We started to realize that our services were no longer really fit for purpose. Many of them grew so bloated through just constant addition of different functionality that they hardly resembled the purpose for which they'd been started in the first place. We had also the opposite problem where people couldn't be bothered or didn't want to wreck what was already there, so they'd create a standalone service often for a very tiny bit of functionality. What was even better was that people didn't necessarily talk as well as perhaps we should have, and so we started to duplicate. Sometimes we had multiple services doing very similar things, but one very similar thing. Again, this is natural. You've got a company that's growing very quickly and we're trying to get as many customers through the door. We lived with it and it worked. We did get customers through the door. Our architecture grew very flat.

Everything could talk to everything else and there were no rules around it. We knew that our services were no longer becoming a cohesive API that anybody could use. Instead, they just became really a big collection of endpoints. Things were starting to become problematic. It was difficult for us to extend. It was difficult for us to change anything. We spent probably two years knowing that this was a problem. It's very easy to identify that you've got a problem. It's a lot harder to actually work out how to fix it. We tried all sorts of things. We went to the bosses and said, can we just stop doing everything for a couple of years and rewrite this? You can guess what their response was. We thought, what if we just decided to do a version 2 of our APIs? Maybe we can just fix the problems with that API.

That failed too, not because they didn't do good work but because we didn't really know what we were building. We were just trying to fix our perceived problems with a very small part of the API without taking the entire picture into view. Remember my golden rule, working systems are better than the promise of working systems. We knew we weren't going to start from scratch, and we knew we had to do it in situ. We realized, the most important thing we had to do was we had to agree on where we were going. We had to stop all pulling in different directions and work out what it was that we wanted to do, and then move in that direction all together. It didn't matter if people took little deviations here and there, as long as they weren't going backwards or southwest.

This is where domain-driven design came to the rescue. We had all of these services and all of these systems that we knew about and we listed them. There's some of them here. This is where we took the decision to flip what we were doing from looking at the product down and look from the functionality up instead. We'd gotten to a stage now that we were mature enough that we did start to understand our systems reasonably well or at least what the functionality needed to be. We didn't have to kowtow to the product team and build a brand-new thing every time because by this stage we'd built most of the functionality. We could start thinking about it in the opposite way. We sat down and we started to think about, what is it that we actually do? What's our core business? We didn't do this in a big team. We tried to do it in big teams. We tried to crowdsource this, and we just had too much whataboutery. There was just too much, what about this edge case? That's not going to fit that. It became counterproductive.

In the end, we had to make a decision. We had to try to decide where to go. We just made a small team and said, we're going to make this broad and we're going to start somewhere so that we can get going in one direction. We sat together and we said, what is it that we do? We do healthcare. That hasn't really gotten us that far, has it? At least we know we don't do bananas. This is what we have now, one big domain of healthcare. We knew we had to dig deeper, and this is where we actually got really pleasantly surprised because actually when we looked at our services it wasn't that hard to start grouping things in big buckets.

In fact, we went right back to the beginning and said, what were we trying to do? We were trying to have meetings online. We looked and we saw we had meetings, we had users, we had a queue service, schedule. That's a bucket. That's really easy. I don't need a PhD in rocket science to work that one out. We put that into a bucket and that became our first domain. Again, things seemed very simple. We looked at what was left, and again we started to realize that actually some of this was quite straightforward. We had patients. We had prescriptions. We had different service types. We were storing their data. We had ways to do referrals. We had all of these services that were really around providing that medical service to a patient. That became a domain called medical. We had two great pillars there ready to go, and that felt really good.

Then we went, we're forgetting probably the most important part of this, how do we get paid? We realized that the payment systems and our reimbursement models and all of that stuff, our contracts, that those things were definitely a domain on their own because they changed for all sorts of reasons, a new government, a new payment model. That became a third domain where we could isolate all of that, let's call it crazy, on its own.

We had three brilliant pillars and that felt right, but we still had a bunch of services left over. We had no idea where these would fit. We had a bunch of services around messaging. Messaging was used by parts of systems in all of those domains. It was used to communicate with patients. It was used to communicate with our contract with the NHS or with GP surgeries. It was used between clinicians to communicate. Where does that go? We also had a bunch of services around EMRs, medical record systems. That's where your patient data is stored. We had a bunch of services that were connecting to different medical record systems.

Again, these were used by all of the domains. What were we going to do with those? We didn't really know. We didn't want to have a handful of separate domains standing on their own, so we did what any sane person would do and we fudged it. We created a domain that isn't a domain, really. We created something that we just called support systems, and whatever didn't really fit or was used by multiple domains we put into that. We were left with a very simple model of what we did. This reduced our cognitive load when we had to start dealing with new functionality or new systems. It meant that our developers didn't have to worry about 50 services when they were adding functionality, but they could just deal with the one or two that were relevant to their domain.

We got here. We know what we're going to do. How do we go from there? Domain-driven design to me is a journey, it is not a destination. I never expect us to get to what that domain looked like. We might but I doubt it. As we go, as we develop, as we work towards that domain, things will inevitably change. Requirements change. Our understanding of the problem changes. We have to expect that that's going to happen. The beauty of that was that it wasn't super specific. It wasn't like anything was going to trip us up, but it all gave us a unified idea of where we wanted to go. It was something that everybody could get behind. What got you here, won't get you there. At least we now know where there is. Let's take a look at a few of the approaches that we used, not to get us to domain driven, but to move us in that direction.

The first one I call the take that approach. The take that approach is where we have a bunch of singers who are all right on their own, but we put them together and they become greater than the sum of their parts. You remember I was talking about those medical record systems. We had a good dozen or so different services that managed our connections to medical record systems. They were used in different ways by different parts of the code at different times. We started to have a couple of duplications. We'd have code in two different areas calling the same EMR in a different way because they needed a slightly different outcome or a slightly different result. All of the different connections to those EMRs were implemented totally differently. All of the code that used those systems couldn't just talk to a different EMR if we wanted to change, they had to rewrite or reorder how they were using them.

One thing about all of these EMRs is that they weren't consistent at all. The way that you had to get data from each of them was different. They all had different models for the data. They all had different ways of connecting to them. For some of the systems, or a lot of the systems even, you could connect over HTTP. There are some systems that you can only connect to locally through a TCP port. We actually had to have a VPN into some of these systems. That complexity, coupled with the fact that we were just duplicating all of this logic all over the place, seemed ripe for simplification.

Again, nothing fantastic here, but this was perfect for an adapter proxy pattern. We created a single proxy at the top where all of our clients could connect to if they wanted medical record data. They could connect to a single consistent API and get a single set of domain models back. If they wanted to connect to a different medical record system, they'd just call the same one and just say, I want it from a different system. In one swoop, it standardized all of this complexity. We hid all of that complexity in the EMR connectors. The EMR connectors would be responsible for translating from the medical record system to our domain models, and we'd have one connector for every external EMR. It became very easy for us to now just talk to a different medical record system, because all we had to do was add another connector. We didn't have to rewrite all of the code from top to bottom. That was the take that approach.

The next approach is the opposite of the take that approach, the Robbie Williams. The Robbie Williams approach is where you take the one singer in the band who's actually any good, and you get rid of the rest. I apologize to all of you take that fans. We had a REST Entity called care facility, and there were over 40 endpoints dealing with a care facility. Thirty-one, I think, when we counted last, of those endpoints, were just one variation or another of getting a care facility. You can see we got creative with the naming. We've got with a hyphen, without a hyphen. We've got a plural. We've put physical in there. We had a second version. Again, this is obvious, but we came to this and went, that's a bit mad, isn't it? Most of these endpoints, the only difference between them was they would call by a different column, they'd filter by a different column. We had all these endpoints. We had two versions of our APIs.

In behind all of that, in our code, we had 15 different service classes, all basically just querying a care facility. We had five different data access objects, all for a care facility. We realized we could just take this and make this simple. We could just have one query endpoint. The way we did this, we'd already tried this, and you can see that with the V2. We didn't want to go down that road again. What we decided to do was that we'd start off with our brand-new single query endpoint, we'd go through each of those 31 endpoints one at a time, and we'd make sure that we could match the functionality in our new query endpoint. We'd go from top to bottom on our systems and get all the calling code, point it to the new endpoint, and then we deleted the old endpoint, so that every time we went through a new endpoint, we knew we'd gotten rid of it. It was never going to stay around anymore. That allowed us to take our 40 endpoints and get one endpoint, one version, one service, and one data access object.

Domain Modelling (Code)

Let's move on to our domain modeling. This was what we started with. Again, it was simple. We designed this ourselves, and it matched what we knew about the world when we started. We had users who could have a meeting. We had clinicians who could join that meeting. We knew who was paying for it. We would store some data. The way that we were able to really dramatically speed up the way that clinicians would handle our meetings was that we standardized using forms, and that made it really quick and easy for clinicians to go through a meeting, fill out the information they had, and move on. It was also great for us to be able to review those meetings to ensure that we were still providing the same levels of clinical excellence because we were standardized. The forms were hugely important for us, but when we stored the data, we stored the data in the format of that form because that's what made sense at the time.

As we grew, that started to show its age. Forms would change over time. If we want to look at an old meeting that was written in an old form, and we've got the data, how do we render that form again? We had to be able to match those things, and that became difficult, especially with more iterations. We had to support UX that was old and things like that. Because the data wasn't stored semantically, we had no way of being able to ask the kinds of questions you would expect to be able to ask of a system like this. How many people have we seen for COVID-19? We could answer those questions, but it was really difficult.

One of the other aspects we had was that you can see that everything was revolving around the meeting object. The meeting was really our central pillar for understanding our system. As we started adding new workflows, that assumption started to become invalid. When we had mental health services, we had to be able to manage a service over multiple meetings, and so things were starting to get strained. We talked about users being patients, and patients being users, and them not being the same thing. Again, we realized that our model was starting to strain at the seams. It was starting to become difficult to use. It was starting to show some of the frailties.

We had a look, and this was different from our approach to services. We decided here, this is a healthcare model. This is a popular industry in the world, I think. Maybe somebody has done this before. Turns out they have. FHIR stands for Fast Healthcare Interoperability Resources. It is a full schema and model for healthcare objects. It's used around the globe. We were like, "I don't know why we didn't find this a couple of years ago, but excellent. We've got it now. This will solve all of our problems". No, that was bad timing. It's great. It is fantastic. It's a beautiful set of resources and models that have been really well thought out. Anything you could possibly want in the healthcare space is catered for.

The fact that they've been able to manage all of the complexity that occurs around the world with a model like this is amazing. Some of the things you might notice here is that in order to support all of that variability, they've had to make it fairly abstract. Things like the patient name isn't a name, it's a human name. Inside the human name, object, or a bunch of smaller objects. If you look in the contact relationship, you've got a codable concept. You'll see that codable concept in the communication language. You'll see it in the marital status. Codable concept is basically a namespace key-value pair. That's fantastic because it allows us to model all of these things or allows them to model all these things without being too specific. Can you imagine your frontend developer who wants to get the first name on a screen shouting at you when he's like, what do you mean I have to go through eight different objects to get the first name?

It was great for telling us how things should look, but it wasn't necessarily great for every implementation that we would need. When we took this model into our medical domain, it was like the lights came on. It made sense because everything was specific to the much more narrow domain in which we were working. We had patients. We don't have users. We had appointments instead of meetings. We had clinicians. Clinicians are clinicians. Instead of this random set of forms and data that we had, we had observations which were strongly typed, so we could now start asking questions like, how many people have we seen for COVID-19? What was fantastic about doing this exercise was that when we started looking at the other domains that we had, it started to make a lot of sense. We could see where the objects in the different domains met. We could see how they related to each other. We could also see why they weren't the same thing anymore. This was a massive step forward for us.

Let's move to my last approach that we used around how we dealt with domain models. That's the approach formerly known as Prince. This is where we take a system that works and that is useful and that we quite like, but we realized that there was actually another service, a hidden service that we hadn't identified at first that would better suit part of our requirements. That we'd had one service that was actually trying to do multiple things, and it did both of them badly. It would be better to leave the service as-is for the things that it was useful for, but to build a new service for the things that it didn't do well.

This is what we did for our medical data. We took the FHIR model and we built a new data service from it using FHIR, not directly, but as an inspiration. We did think about using it directly, but then we got to that, how are we going to tell the frontend developer that he's got to learn FHIR and learn these complex models? We didn't. We used it for what it was good for. We took the best bits, particularly the objects and the relationships between the objects, and then we modeled the properties as made sense for us and for our systems. Now we can very easily query our data. We've got a given name there, so our frontend developer is happy.

This drastically improved our understanding of the system because we no longer were tightly coupling our patient data to how it was inputted. It allowed us to be able to make changes in the input forms without having to worry about the backend. Things become simple in small doses. There are three approaches, the take that, where we can get a bunch of things that seem similar, maybe they're not rockstars in their own, but we can put them together and they'll be greater than the sum of their parts. We can have the Robbie Williams approach, where we take the one good thing that you have and then delete all the rest. We have the approach formerly known as Prince, where we rebrand or rework some of the functionality that we've discovered we needed at the time, but we still can use the old stuff because the old stuff is still good.

Summary

Remember, you are never going to be in a situation where things don't change. People are always going to be coming to you and asking you to make new things, to build new things, to change how they work. You have to lean into it and you have to accept it. We've used domain-driven design very successfully to reorganize how we think about our systems, even the ones that are already running. Lastly, I'd really recommend that you organize around the functionality that you have, not around what the product says they need, because, remember, domain-driven design is a journey, not a destination.

Questions and Answers

Dr. Kreindler: How do you think larger health systems can get to 11 out of 10 in terms of their whole architectural strategy? Because right now it feels like most of us are at 1 or 2 out of 10 in large health systems.

Leander Vanderbijl: There's a lot at play. There's a lot of perceived complexity, I think, in the healthcare industry. I think a lot of that complexity isn't necessarily complexity, but it's just different ways of working. Trying to convince people to move towards a standardized approach to things, which isn't necessarily a be-all and end-all in and of itself, but has proven very successful for us, can be difficult. We go to practices and we say, if you do things this way, we can really improve your throughput, we can really improve your services.

A lot of people go, yes, but I can't do it that way because we use a fax machine or whatever. A lot of that is changing people's minds. There's a lot of vested interests in terms of how systems work, and maybe not even necessarily vested interests, but medical data is very protected, rightly so. That makes it very difficult if you want to start doing novel things with it. It makes it very hard to get around some of those hurdles and to be able to convince large organizations like the NHS or other things to be able to allow you to get into data, to do things that maybe are slightly off the beaten track.

Dr. Kreindler: You talked about domain-driven design. By that, I'm assuming you're talking about the different components of the business, are you, or domain as in the healthcare domain?

Leander Vanderbijl: It's more in a software perspective. It's how we group our functionality together to be able to make it easier to understand and to develop.

Participant 1: With the increasing role of tech companies in the government sphere, do you think we'd ever get to a point where governments themselves are agreeing on data models or other interfaces, like the FHIR one, that could make just business on the international scale easier?

Leander Vanderbijl: Yes. In fact, the NHS has adopted this wholesale. In fact, their latest set of GP Connect APIs are all FHIR-based and they are brilliant. There's a lot that people complain about the NHS, but their GP Connect APIs are absolutely brilliant. They're very well thought out, they're very well modeled. If you can get access to them, they're amazing. It is difficult because they're under a lot of pressure. There is a lot of governance you need to go through to be able to get access to them, but they are fantastic. It would be nice if the private companies that had medical record systems would support FHIR as beautifully as the NHS does, and that's actually been almost more of a problem than the national healthcare systems.

Participant 2: Domain-driven design is obviously very good for informing your software, but to what extent, when you've drawn your models, you've mapped out domain, you understand what your software currently does. Can those models maybe inform back on the product side of things, go, actually, what you're suggesting here, we're moving into a new domain? Are we losing the purity of the focus? Are we maybe changing direction a bit? Can it shake back and affect the product as much as it affects the software that comes out of it?

Leander Vanderbijl: Absolutely, it can. The way you model things can absolutely impact how well you can do certain things. We had the instance with the way that our data was stored, we couldn't answer a lot of the questions that we wanted to ask. Once we started storing it in a model that made sense, in a domain that made sense, we suddenly could ask those questions, but we could also ask a lot more that came up, because they were like, "You can do this. Yes, I hadn't thought about that kind of question". Absolutely, it's a two-way street there. Definitely.

Participant 3: To paraphrase, "We drive down costs and increase efficiency by standardizing the business workflow of medical care, domain-driven design being a great way of standardizing IT systems". I totally agree. I'm a big fan. Have you thought about the next step, so, for example, 4C analysis in the business workflow to further drive optimization? Given the data you now have or the personnel you have, how you could use something more like 4C to drive the actual outcomes in the medical business, because it's a different approach to try to drive different medical outcomes through process change.

Leander Vanderbijl: Absolutely. The trick there is around governance. How long can you keep data like this? Are you allowed to use it for other purposes, like training data models or that sort of thing? That's a bit of a minefield at the moment. I think there are still a lot of people trying to work out the ins and outs of that. We are starting to do things like automated triage, so being able to say, given a set of complaints, do they need to be seen tomorrow, yesterday, or whatever?

Participant 3: After domain-driven design, have you thought about what would be the next thing that you would implement, like a 4C analysis or something else?

Leander Vanderbijl: No is probably the shortest answer. Again, this is a journey. What we want to do is see where it takes us, really, and try not to be too prescriptive of where we're going to go. Once we start getting the initial domains starting to make sense, then we have the time to start looking deeper and fixing some of the other problems. At the first hurdles, we're really fixing the top layer of problems. We do need to go deeper into some of the way that some of our other code is written and some of the problems that are there. That's natural.

The AI advertising wars

Mike's Notes

This is an extract from a recent thoughtful SubStack post by Gennaro Cuofano, in The Business Engineer. The post discusses the AI advertising wars. This extract is about recent changes at the newly formed Agentic AI Foundation, a Linux Foundation initiative.

"What we’re witnessing is the emergence of a complete protocol stack for agentic commerce. Understanding how these pieces fit together reveals both the competitive dynamics and the cascading implications for the digital ecosystem." - Gennaro Cuafano

Note to self

  • Create a Pipi MCP Engine.
  • Look into the open-source protocols at the Agentic AI Foundation.
The post also discusses the war around payment protocols.

Resources

References

  • Reference

Repository

  • Home > Ajabbi Research > Library > Subscriptions > The Business Engineer
  • Home > Handbook > 

Last Updated

28/01/2026

The AI advertising wars

By: Gennaro Cuofano
The Business Engineer: 27/01/2026

Creator of The Business Engineer, the deep-tech research hub, spun off from FourWeekMBA, the leading blog on business model strategy. Gennaro has over 10 years of experience as a deep tech executive.

...

The Protocol Stack: Five Layers of the New Commerce Architecture

What we’re witnessing is the emergence of a complete protocol stack for agentic commerce. Understanding how these pieces fit together reveals both the competitive dynamics and the cascading implications for the digital ecosystem.

Layer 1: Foundation Infrastructure

The foundation layer has effectively been won by the Model Context Protocol. MCP, launched by Anthropic in November 2024, has achieved what few technology standards accomplish in a single year: industry-wide adoption backed by competing giants. The numbers tell the story:

  • 97 million monthly SDK downloads
  • 10,000+ active servers
  • ~2,000 entries in the MCP Registry (407% growth since September)
  • First-class client support across ChatGPT, Gemini, Microsoft Copilot, Cursor, and VS Code

In December 2025, Anthropic donated MCP to the newly formed Agentic AI Foundation under the Linux Foundation. This wasn’t an act of charity but strategic positioning—by making MCP vendor-neutral, Anthropic ensured its protocol would become critical infrastructure rather than a competitive weapon that might be forked or abandoned. As Mike Krieger, Anthropic’s Chief Product Officer, put it:

"A year later, it’s become the industry standard for connecting AI systems to data and tools.”

MCP now sits alongside two other founding projects under the AAIF:

  • AGENTS.md (OpenAI): Adopted by 60,000+ open-source projects for providing AI coding agents with project-specific instructions
  • goose (Block): An open-source, local-first agent framework
  • Agent2Agent / A2A (Google): Enables communication between autonomous agents, supported by 150+ organizations

The significance of this consolidation under the Linux Foundation cannot be overstated. These protocols are becoming the TCP/IP of the agentic economy—essential infrastructure that no single company controls but upon which all higher-value services depend.

Layer 2: Payment Infrastructure

The payment layer remains more fragmented. Google’s Agent Payments Protocol (AP2), co-developed with PayPal and backed by over 60 merchants and financial institutions, provides secure payment tokenization for agent-initiated transactions. It’s designed to work seamlessly with Google Pay and the broader Google commerce ecosystem.

The payment processor alignment is telling:

  • Stripe → OpenAI’s commerce stack (Shared Payment Token, Agentic Commerce Suite)
  • PayPal → Google’s AP2 + Perplexity’s commerce features

This isn’t neutral infrastructure—the payment processors are choosing sides in the protocol wars, betting on which business model will dominate.

Layer 3: Commerce Infrastructure—The Battlefield

This is where the war is actually being fought. Two competing protocols with fundamentally different architectures and business models are vying to become the standard for agentic commerce.

Google’s Universal Commerce Protocol (UCP), announced at the National Retail Federation conference on January 11, 2026, was co-developed with Shopify, Etsy, Wayfair, Target, and Walmart, with endorsement from over 20 partners including Visa, Mastercard, American Express, Stripe, Best Buy, and Zalando.

UCP is a full-journey protocol covering:

  • Product discovery
  • Cart management
  • Checkout
  • Post-purchase support
  • Loyalty programs and returns (roadmap)

The architectural philosophy is revealing: UCP establishes a common language through which agents can discover merchant capabilities, negotiate supported features, and execute transactions. Merchants publish their capabilities via a .well-known/ucp file, agents discover what’s available, and transactions proceed through standardized primitives.

OpenAI’s Agentic Commerce Protocol (ACP), launched in September 2025 in partnership with Stripe, takes a narrower approach. ACP is checkout-focused—it solves the “last mile” of completing a purchase rather than the entire shopping journey. The protocol is Apache 2.0 licensed and explicitly designed to work across payment processors and AI platforms.

ACP’s architecture reflects OpenAI’s strategic position: they don’t need to own discovery (ChatGPT’s conversational interface handles that) or post-purchase (merchants handle fulfillment). They need to capture value at the moment of conversion. For merchants already on Stripe, enabling agentic payments requires as little as one line of code.

The scope difference is intentional. UCP gives Google a reason to keep merchants within its ecosystem across the entire customer journey. ACP lets OpenAI capture transaction value wherever discovery happens.

...

Potential uses of OpenTofu

Mike's Notes

Thoughts on Terraform and OpenTofu in the wake of the HCP Terraform Free Tier being discontinued by IBM.

Alex asked Gemini about OpenTofu. The output was not verified and is appended below. (I used Google Translate to English)

Resources

References

  • Reference

Repository

  • Home > Ajabbi Research > Library >
  • Home > Handbook > 

Last Updated

27/01/2026

Potential uses of OpenTofu

By: Mike Peters
On a Sandy Beach: 27/01/2026

Mike is the inventor and architect of Pipi and the founder of Ajabbi.

Background

The original plan was for Pipi to use Terraform as Infrastructure-as-Code (IaC) to deploy cloud infrastructure across AWS, Azure, GCP, IBM, Oracle, and more. Then IBM announced that the Terraform Free Tier is being discontinued. There is now an open-source fork called OpenTofu, which is part of the Cloud Native Computing Foundation (CNCF). OpenTofu has strong community support. Pipi will now use OpenTofu.

Pipi as a code generator

A Pipi Agent could easily generate the highly structured Terraform/OpenTofu code.

Potential Uses

  • The Pipi messaging system could use OpenTofu syntax as the message format for internal messaging between Pipi Agents. The needs are relatively simple compared to what is available. But more capacity is available if needed.

    Message examples
    • Tell the Namespace Engine (nsp) to shut down.
    • Tell the Factory Engine (fac) to make more Workflow Engines (wfl) and where to deploy them.
    • Tell the Ontology Engine (ont) to import the latest version of SNOMED.
    • The updated SNOMED Ontology availability would then trigger many other engines to run updates to Workspace for Health and User Documentation.
    • Tell the Workspace Engine (wsp) to build a Hebrew-language/script generic model of the Workspace for Screen.
    • Tell the Google Cloud Engine (GCE) to deploy a Vietnamese-language/script customised Health System Workspace for a Hospital in Vietnam to GCP.
    • Tell the Physical Law Engine (pyw) to update with the latest definitions from the Particle Data Group.
  • Dedicated Pipi Agents would use OpenTofu to deploy cloud infrastructure to each cloud platform.
    • Apple Engine (ale)
    • AWS Engine (aws)
    • AZURE Engine (azu)
    • Digital Ocean Engine (dgo)
    • Google Cloud Engine (ggc)
    • IBM Engine (ibm)
    • Meta Engine (met)
    • Oracle Engine (ora)
    • (More will be added later; all are welcome)

OpenTofu Example

This code sample is from the OpenTofu Docs.

terraform {
  required_providers {
    aws = {
      source  = "hashicorp/aws"
      version = "~> 1.0.4"
    }
  }
}

variable "aws_region" {}

variable "base_cidr_block" {
  description = "A /16 CIDR range definition, such as 10.1.0.0/16, that the VPC will use"
  default = "10.1.0.0/16"
}

variable "availability_zones" {
  description = "A list of availability zones in which to create subnets"
  type = list(string)
}

provider "aws" {
  region = var.aws_region
}

resource "aws_vpc" "main" {
  # Referencing the base_cidr_block variable allows the network address
  # to be changed without modifying the configuration.
  cidr_block = var.base_cidr_block
}

resource "aws_subnet" "az" {
  # Create one subnet for each given availability zone.
  count = length(var.availability_zones)

  # For each subnet, use one of the specified availability zones.
  availability_zone = var.availability_zones[count.index]

  # By referencing the aws_vpc.main object, OpenTofu knows that the subnet
  # must be created only after the VPC is created.
  vpc_id = aws_vpc.main.id

  # Built-in functions and operators can be used for simple transformations of
  # values, such as computing a subnet address. Here we create a /20 prefix for
  # each subnet, using consecutive addresses for each availability zone,
  # such as 10.1.16.0/20 .
  cidr_block = cidrsubnet(aws_vpc.main.cidr_block, 4, count.index+1)
}

Yes, Mike! It's cool!

I talked a little bit with Gemini [1]. OpenTofu is a great tool

Alex

[1] https://gemini.google.com/share/4c550e83a230

OpenTofu: Features and Benefits

Some responses below were generated according to the creator's saved info and preferences. Learn moreOpens in a new window 27 January 2026 at 21:22

Published on 27 January 2026 at 21:37

Prompt

What features does OpenTofu provide?

Output

OpenTofu is an open-source fork of Terraform (created after HashiCorp's license was changed to BSL), developed under the auspices of the Linux Foundation. In 2026, it became a full-fledged competitor to Terraform, offering a number of unique features while maintaining backward compatibility.

Here are the main features that OpenTofu provides:

1. Full compatibility with the Terraform ecosystem

OpenTofu is designed as a drop-in replacement. This means:

  • HCL support: The same configuration file syntax is used.
  • Working with providers and modules: OpenTofu uses its own registry ( OpenTofu Registry ), which mirrors most popular providers (AWS, Azure, GCP, etc.) and modules.
  • Migration: You can migrate from Terraform (versions up to and including 1.6 and many later) with virtually one command without rewriting any code.

2. Advanced Security (State Encryption)

One of the main "killer features" introduced in OpenTofu (starting with version 1.7) is native encryption of state files .

  • Unlike standard Terraform, where sensitive data terraform.tfstate is often stored in cleartext, OpenTofu allows you to encrypt it at rest.
  • Various key management methods are supported: AWS KMS, GCP KMS, HashiCorp Vault (OpenBao), as well as environment variables and files.

3. Improvements in code management

OpenTofu is actively implementing features that the community has been requesting for years:

  • Dynamic Provider Functions: Ability to use functions defined directly in providers within your HCL code.
  • Improved loops in import blocks: Can now be used for_each inside count blocks import, making it much easier to bulk import existing resources into your code.
  • Early Variable Evaluation: Allows you to use variables in parts of the configuration where they were previously unavailable (for example, in backend settings).

4. Openness and community

  • MPL v2.0 License: Ensures that the tool will always remain free and open for use for any commercial purposes without legal risks.
  • Community-driven Roadmap: The development plan is formed based on RFCs (Request for Comments) from the community, and not on the commercial interests of a single corporation.

Comparison of key aspects

Characteristic OpenTofu Terraform
License Open Source (MPL 2.0) Business Source License (BSL)
State encryption Native (client) Depends on the backend (SaaS/Enterprise)
Management Linux Foundation HashiCorp
Registry opentofu.org registry.terraform.io

Is it worth switching? 

If your organization values ​​open source and vendor lock-in, or client-side encryption of state files is critical to you, OpenTofu is an excellent choice.

Would you like me to help you create a migration plan or a sample configuration for encrypting the state file?

Prompt

What is it intended for? Let's say I'm creating a multi-agent system.

OpenTofu is designed for managing infrastructure as code (IaC). Simply put, instead of manually clicking through the cloud provider's console (creating servers, databases, and networks), you describe the desired architecture in text files, and OpenTofu automatically "builds" and connects these components.

If you're building a multi-agent system (MAS), OpenTofu will be responsible for the "foundation" on which those agents will live and communicate.


The Role of OpenTofu in Creating a Multi-Agent System

When agents become numerous, they require computing resources and a communication environment. Here's how OpenTofu helps in this scenario:

1. Deployment of computing nodes

You can describe a cluster (e.g. Kubernetes or a group of virtual machines) where your agents will run.

  • Example: You need 10 isolated containers for different agent types (scheduler agent, executor agent, etc.). OpenTofu will create them with a single command.

2. Setting up the communication environment (Message Brokers)

Agents must exchange messages.

  • OpenTofu will automatically deploy and configure RabbitMQ , Kafka , or Redis Pub/Sub to serve as the "bus" for your agents to communicate.

3. Database Management (Vector and Regular)

Agents often need memory (Long-term memory).

  • You can use code to set up a vector database (such as Pinecone , Weaviate , or Milvus ) and a regular one (PostgreSQL) to store conversation history and logs.

4. Scaling

If your system needs 500 agents instead of 5 tomorrow, you don't need to manually configure each server. Simply change one number in the configuration: count = 500, and OpenTofu will build the missing infrastructure.


Example of a logical diagram of work:

  1. Code (HCL): You describe: "I need a 3-node cluster and a database."
  2. OpenTofu (Execution): Compares your code with what's already in the cloud.
  3. Infrastructure: Creates servers -> Installs the runtime environment (Docker/K8s) on them -> Sets up the network between them.
  4. Agents: Now your Python scripts (agents) can run in this ready-to-use and stable environment.


Why choose OpenTofu over just scripts?

  • Idempotency: If you run the server creation script twice, it can create two servers. OpenTofu will recognize that one already exists and won't do anything extra.
  • Dependency Management: It knows that it needs to create a network first, and only then a server on that network.
  • Collaboration: The state file ( state) allows an entire team of engineers to work on the same infrastructure without chaos.

Can you suggest which cloud resources or providers would be best suited to host your multi-agent system?

Prompt

I'm interested in how to organize the exchange of messages between agents that exchange commands and data.

To organize communication between agents for exchanging commands and data, you typically use one of three architectural models. The choice depends on how autonomous your agents are and how critical delivery speed is.

Below is a breakdown of the main approaches you can implement and automate using OpenTofu.

1. Message Bus (Pub/Sub) — The Most Flexible Approach

This is a classic model where agents do not communicate directly. Instead, they send messages to "topics" or "exchanges."

  • How it works: Agent A sends a command to the topic commands. Agent B is subscribed to this topic, receives the command, executes it, and sends the result to the data topic.
  • Tools: RabbitMQ, Apache Kafka, NATS, or Redis.
  • Advantage: Agents are fully decoupled. If one agent goes offline, messages accumulate in the queue and are processed once it restarts.

2. Centralized Orchestrator (Shared Space)

In this model, there is a central "knowledge base" or dispatcher that distributes tasks and maintains state.

  • How it works: Agents write data to a shared database (e.g., a vector database or Redis) and check the status of tasks in a central table.
  • Tools: Redis (using Streams or Lists), PostgreSQL with queues (Listen/Notify).
  • Advantage: It is easy to track the state of the entire system and the history of all commands in one place.

3. Direct Interaction (gRPC / HTTP)

Agents contact each other directly via their network addresses.

  • How it works: Each agent has its own API endpoint.
  • Tools: gRPC (high speed, strict data typing) or FastAPI/Flask (simplicity).
  • Advantage: Minimal latency because there are no intermediate layers.
  • Disadvantage: Harder to scale. If an agent's IP address changes, others must be notified (requires Service Discovery).

Technical Implementation: The Role of OpenTofu

Once you decide on the architecture, you need to "spin up" the infrastructure for this communication. OpenTofu automates this process:

  1. Broker Deployment: OpenTofu code deploys a RabbitMQ or NATS cluster.
  2. Queue Configuration: It immediately creates the necessary queues (e.g., task_queue, results_queue).
  3. Security: It generates unique credentials for each agent type, ensuring an "executor" agent cannot accidentally delete messages from the "planner" queue.
  4. Service Discovery: If using gRPC, OpenTofu can configure Consul or internal DNS in Kubernetes so agents find each other by name (e.g., agent-alpha.local) rather than static IPs.

Where to start?

If you are just starting to design your system, I recommend the Redis + Python (using libraries like Celery or TaskIQ) or NATS combination. This provides a great balance between simplicity and performance.

Would you like me to provide a sample OpenTofu configuration to deploy a message broker (like Redis or RabbitMQ) in Docker or a cloud provider?

This Is a Fight Worth Having: The Case for Open Source AI | Raffi Krikorian, Mozilla CTO

Mike's Notes

Another wonderful video interview by Kesnia Se from Turing Solutions with Raffi Krikorian, CTO of MozillaAn excellent newsletter worth subscribing to.

I learn a great deal from every issue of this newsletter. Once Ajabbi becomes financially stable, this newsletter will be one of those generously supported by the future foundation.

Resources

References

  • Reference

Repository

  • Home > Ajabbi Research > Library > Subscriptions > Turing Solutions
  • Home > Handbook > 

Last Updated

26/01/2026

This Is a Fight Worth Having: The Case for Open Source AI | Raffi Krikorian, Mozilla CTO

By: Kesnia Se
Turing Solutions: 24/01/2026

Dreamt about Turing Post since 2019, founded it in 2023, after a successful launch of TheSequence (co-founded with Jesus Rodriguez). Board member at Track Two: An Institute for Citizen Diplomacy, currently writing a book about them. Previously: guest lecturer at HSE (Moscow, Russia); Middlebury Institute of International Studies (Monterey, USA). Ex editor-in-chief of TheQuestion, ex NY chief editor of Snob Magazine. Contributor to Stratfor, Towards Data Science, The Startup, and others. Writer.

Note: We planned to publish Week 2 of our Open Source AI series, “The Real Math – when open source saves money, when it doesn’t”, but the flu took over our house. We did manage to publish this interview though, which aligns with the series. Watch it, it’s very interesting and gives you a great sense of where open source AI is right now. Next week, we’ll publish the real math. Let’s use this moment to learn what will be most useful to you →

Which angle of open source AI economics matters most to you?

  • Enterprise only – real cost math, infra traps, and why most companies miscalculate self-hosting
  • Personal use only – when local models beat subscriptions, and when they absolutely don’t
  • Both – side-by-side breakeven logic for companies vs individuals
  • Myth-busting – where open source is oversold and proprietary APIs still win
Login or Subscribe to participate in polls.

Now to the show: In the first episode of Inference’s quarterly series on Open Source AI, we talk to Raffi Krikorian, CTO of Mozilla, about when open source AI stops being aspirational and becomes an operational choice.

We explore why stories like Pinterest saving $10 million by moving to open models are real, but often misunderstood, and why timing and maturity matter more than ideology. Raffi lays out his view of a missing “LAMP stack for AI” and explains why the hardest problem to solve isn’t models or data, but the connective glue that makes it easier for developers to use open source.

Along the way, he shares how Mozilla is navigating these tradeoffs in practice, why even open-source-first organizations still rely on closed tools during experimentation, and what the browser era taught Mozilla about defaults, user choice, and long-term control.

Raffi is passionate about open source, but grounded in its real economics. In this episode, he shares practical recommendations that apply even if you are still experimenting. Listen closely.

In this episode of Inference, we get into:

  • Why experimentation favors closed APIs and production favors open systems
  • How company maturity matters more than company size for cost savings
  • What a real “LAMP stack for AI” could look like, layer by layer
  • Why choice and portability matter more than model loyalty
  • Mozilla’s bet on small, specialized models over one giant model
  • Why data ownership and user context are the real long-term battleground
  • Concrete steps companies can take today to keep an exit door open

This is a conversation about choice, cost, and control in the AI stack. Watch it!

This is a free edition. Upgrade if you want to receive our deep dives directly in your inbox.

We prepared a transcript for your convenience. But as always – watch the full video, subscribe, like and leave your feedback. It helps us grow on YouTube and bring you more insights ⬇️

Ksenia Se: Hello, everyone. We're doing something different with Inference by Turing Post this year. Starting with this episode, we're dedicating each quarter to one topic explored through multiple conversations. And this quarter's topic is open source AI. I'm starting with someone who is reorganizing his whole company around this bet: Raffi Krikorian, CTO at Mozilla. Welcome, Raffi.

Raffi Krikorian: It is such a pleasure. Thanks for having me.

When Values Meet Economics

Ksenia: Absolutely. But let me be honest with you about open source. I had one problem recently with it. All the conversations sound very aspirational. It's about freedom, it's about transparency, it's about ownership – but that's not how companies do business, right? So from what you are seeing, when does open source AI become an operational choice rather than an ideological one?

Raffi: Well, on one hand, I'm actually kind of glad that you only have one problem with it, because I think there are a billion problems in the grand scheme of things. But no, I mean, I think you're exactly right. I think it is an unfair thing to assume that open source wins because of values. It needs to be this combination of values and economics that really work out in order for it to make sense.

I mean, one shining hope right now – well, there are many shining hopes – but one concrete example is at the end of last year, Pinterest put out a report that they've saved $10 million by moving to open source rather than relying on closed-source providers. And we're starting to see a bunch of people have very similar comments. They've passed through the prototyping stage and gotten into the steady-state utilization phase. Therefore, they now know how to provision properly. They've figured out which models actually perform quite well. So they're no longer paying a per-token cost and instead absorbing that into the infrastructure.

If I were to make a prediction for 2026, we're going to start to see a lot more of those types of stories starting to show up – that the economics and the values are starting to align, or maybe just even the economics are starting to align. And therefore these big companies are starting to make that choice.

You know, another thing I've been thinking a lot about is this notion of how to enable that choice to happen in the future in the first place. Things like what we're building at Mozilla on the Mozilla AI team – for example, this thing we call the Choice Suite (aka any-suite) – how things like the Choice Suite can actually enable enterprises to be more flexible in how they even negotiate.

I remember the days when everyone built directly on AWS. No one does that anymore, right? They build on Terraform and all the other things. And what that provides them is negotiating opportunities. When AWS says, "Well, it's now going to cost $50,000," you can be like, "Well, Azure says it's only going to cost me $30,000, and I have a Terraform script. I can just move over very quickly."

I think those types of moments are going to start to show up this year. The economics are going to start to work out.

The Maturity Threshold

Ksenia: I heard this case of Pinterest. But if you think about Pinterest, it's a huge company with a lot of ML engineers that can be dedicated to the switch. So when do you think it makes sense to switch – does company size matter? Technical capabilities? Spend level? When is open source cheaper for them, not just a principle again?

Raffi: Before we have the dollar sign or euro sign conversation, I think it really goes to how fast can people move?

In the Pinterest case, when you read between the lines, what you implicitly see is that they went past experimentation. They actually now know what their use case looks like. They now know exactly the kind of application they want to build and deploy. And now they can actually codify it and fine-tune – fine-tune is overloaded – but build the exact infrastructure they need in order to achieve their goals.

I think a version of that does play out on every single level. The reason why it's about more than just a dollar sign is: when you go to a small company, small companies by definition are still in the iteration phase. They're still trying to experiment to see what works best for them. What's the actual application they're trying to build?

And right now, I can't with an honest face say that they should be experimenting with open source AI. The OpenAI API is kind of lovely, right? It's one API call and it abstracts away all the stuff behind the scenes. Whereas if you try to use open source software, you're cobbling together all these different pieces, trying to figure out which evaluation provider, which traceability provider...

So once they get past experimenting on what they want to build, and then they want to get into production or they want to get into some form of cost optimization or cost savings, then I think open source is positioned to be a valid part of that conversation. So I don't think it's a dollar sign. I actually think it's the maturity of the application that you want to build.

Ksenia: When did it happen at Mozilla? I'm sure you were iterating and experimenting a lot with both closed and open source tools and models. When was this moment?

Raffi: I mean, we're actually still going through this moment right now. I'm not sure I would say that Firefox is fully locked into exactly what their AI-powered user experience really looks like. And I would also say that things like the Mozilla AI team and other teams are still very deep into using things like OpenAI API, Claude Code, et cetera.

Only a few of them have even started switching to things like Codex or open alternatives. So we are actually still as part of this journey, trying to figure out what we're going to do.

But I would say – you know, part of my job at Mozilla is to think about the broader AI ecosystem. How can we do for the AI ecosystem what Mozilla did for the web? How can we actually bring user choice? How can we actually give credible alternatives that force openness in different parts of the stack?

So my goal and the work that I'm trying to do is try to make it so that the open source choice can happen earlier and earlier in that experimentation process. For me, I think about Mozilla as a testing ground of the different things we can be experimenting with as early as possible, even while we're still trying to figure out what we want to do.

So we're not quite there yet, but that's maybe our North Star of what we're trying to get done this year.

The Open Source Stack: A LAMP Moment

Ksenia: Let's talk more about the open source stack then, because – again, another problem with open source – it's kind of one thing in theory. In practice, it's multilayered. First of all, even the understanding of what open source is is multilayered. So what is the stack? What are we looking at?

Raffi: The thing that we need is a sort of LAMP stack definition. Right now there isn't a good definition of what that looks like. But what I would propose is that we should look at it on four different layers:

  • The compute layer
  • The model layer
  • The data layer (maybe we can argue which is lower – data or models)
  • The developer experience layer

And I think this replicates itself both on training and on the inference side.

The conversation we need to have is: What do APIs look like? Or what do standards look like between those layers so that we as an open source ecosystem can start coalescing around this LAMP-like stack metaphor that can make it really easy to deploy?

I'll note that one of the things we're trying to do with our Choice Suite is provide maybe that top-of-the-stack opening. If you use the Choice Suite, you get one API call that abstracts away a lot of things below it. So if you use AnyLLM, which is one part of the Choice Suite, you call the AnyLLM API, and then you can rapidly switch between different LLM providers – both local, both remote, open, closed, et cetera.

So we're trying to embed choice into that conversation. And we think that can apply for almost everything inside that developer tool suite layer, that developer experience layer on the top of that LAMP-like stack. But we need to do this over and over and over again across all the different parts of the stack.

I want to live in a world where we have interchangeable components that people can really choose what their LAMP stack looks like, and they can assemble it rapidly. Maybe there's a set of blueprints that make it really easy for small businesses to do it. Maybe there's a different set of blueprints for enterprises, a different set for governments even. But I want to figure out how to make that LAMP stack coalesce.

Ksenia: Is anyone building something like this?

Raffi: Lots of people are building parts of it. I think OpenRouter is a good example. Things like MCP (Model Context Protocol), which allows calling from the model layer, is part of this conversation.

I'm not saying that Mozilla needs to go build this all ourselves. My real goal is to try to articulate: What are the things that developers are looking for when you think about it as a full-stack component? And how do we motivate and drive the community toward what are the standardization opportunities?

Mozilla probably will only show up in that developer experience layer, maybe in the data layer. But I want that ethos. I dream of a time when that ethos goes through that entire stack.

The Vibrant Ecosystem

Ksenia: What are the companies that serve your ideal currently?

Raffi: There's a bunch of them. I think OpenRouter and Mozilla AI are good examples when it comes to that top of the stack.

But I'm really excited about the work that people like AI2 (Allen Institute for AI) are doing at the model layer, or ETH Zurich is doing at the model layer, and others to try to figure out what really open models look like.

I also think that there's going to be a lot of innovation in that model layer, especially as we're coming to grips with the fact that it's impossible for anyone to play in it. The Transformer architecture makes it literally computationally and financially impossible. But at the same time, there's a lot of evidence that these smaller language models or smaller fine-tuned models from the pre-Transformer days might actually be the path forward.

I'm intrigued by a lot of companies who are starting to build the infrastructure for faster fine-tuning or model composability or things like that on that layer.

On the data side, I'm of course really interested in things like what Databricks is up to. Mozilla has a play with the Mozilla Data Collective where we're creating a two-sided marketplace to make it really easy to have provenance-related data that you can then license to any model trainer out there in the world.

The Mozilla Data Collective folks are literally in conversation with every radio station on the planet. They're like, "How do we license audio data from every single language with a transcription of it?" And how do we scrub it just good enough that model trainers can then use it?

So I'm intrigued by the people playing in that data licensing space and others. And of course, that top of the stack – there are just so many companies doing interesting work there. I'm really a big fan of what the LangChain folks are doing. I'm a really big fan of what all the orchestration layers are doing, the deepset people are doing on the RAG layer.

I think there's so much – if there's anything people should take away, it's that there's actually a lot of vibrancy in the open source ecosystem. I think what's missing is a connective glue layer to just make it easier for developers.

I want to live in a world where a developer finds it just as easy to use an open stack as it is to use the OpenAI API. That's the world I want to live in.

The one thing I didn't mention is that compute layer – that's going to be the hardest for us to make a dent in. There are companies like Flower AI that I'm intrigued by for federated learning across heterogeneous data sets, heterogeneous hardware. That could be a way. Imagine a world where compute was not a scarcity mindset, but it was an abundance mindset. That would be a really interesting AI world for us to live in. So I'm intrigued by what that federated space might be able to do there.

Specialization and the Twitter Analogy

Ksenia: I'm a big fan of federated learning. I think we still haven't yet seen what it's capable of. And if we think about small models again, and when they go to all the devices, how cool would that be if it all can be connected and we're not dependent on GPUs or whatever big compute we need?

Raffi: Exactly.

Ksenia: But if we talk about small language models, which I read in your blog post you're betting on them as well – and that's what I noticed about open source models when I was writing about it last week – is that we are moving to specialization. It's not one big model for everything, but you know, one for coding, one for this, one for that.

Again, if you talk about companies adopting it, when does it make sense to connect three models, or again, use one big one? Because specialization is great, but also it adds complexity. I'm just trying to build this decision-making process for companies to be able to use open source.

Raffi: I look at it almost in the exact same way that I look at it from my previous jobs. You know, when I was at Twitter a decade and a half ago at this point, Twitter was written in Ruby on Rails. And then once we fully understood what the application stack looked like, we started moving parts of it to the JVM to harden it, to make it more efficient, to make it faster, more performant, et cetera.

I think the exact same thing is playing out in this space right now. Like, you know, I have a rack full of computers next to me right now that I hack on on the weekends. And even I use the OpenAI API to do a lot of my work, just to help me form an idea, to rapidly prototype, et cetera.

But then when I get to a place that I want to deploy it, I start looking at it and think, "Oh, should I do this part in Qwen? Should I do this part in something else?" So I think it's part of that maturity curve of ideas right now.

You start in a place where you don't exactly know what you're doing. So you need a general-purpose tool to help you sort that out. And as you start to get more solidification in the kinds of things you want to build, that's when you can start to really optimize and find the right model at the right time.

Now there are also different constraints that you might want to take into account, right? I might want to run things in a disconnected environment. I might want to run things on-device versus not. I do a lot of work with open source in an African context where the connectivity is not so great and you actually want it to run on-device.

But again, you might build that experimental application in a really good Wi-Fi environment. And then once you're actually ready to deploy it, then you start either fine-tuning or you figure out what's the right model you can run on-device so you can go into a disconnected environment.

Another example might be autocomplete on a web browser. You can imagine a world – there's no reason for us to be sending all that information to a large model remotely. Then you've added latency, you've added all these things. You want to do that kind of work as close to the user as possible so you can be really, really sensitive to keystrokes, really sensitive to timing, really sensitive to battery power. If you're running it locally, why hit the network for every single keystroke?

So I think those constraints might be part of the driving factor. But I think the overall thing is still: as you go from experimentation to production, somewhere along that line is the right time to think about making those transitions. And my job is to move that line as close as I can to experimentation.

Why Data Matters

Ksenia: Why does Mozilla focus so much on data?

Raffi: In the sense of user data and user privacy and things like that? Well, I feel that data, especially in the AI world, is one of the biggest tipping points. Besides the paradigm that most of the AI providers are thinking about right now – which is "data is free, we just scraped it from the web" – that might also just be last year's battle.

But I do think two things. One is there are a bunch of data sets that haven't been on the web that could be really useful. And if we can change the dynamics around them – whether it be indigenous languages or whether it be genetic data of different communities, things like that – people might deserve some form of either recognition or compensation for it. I find those to be the human-centered version of data collection.

And so how can Mozilla enable that? I think it's a very important thing. I'm excited by the work the Mozilla Data Collective is doing on making those really easy to license, having one-click licensing mechanisms, one-click purchasing mechanisms. We as Mozilla don't intend to make a lot of money off that. We want to enable people to do it. We'll just maybe do a small transaction cost, but we want to enable more interesting experiences to happen on the web. But I want to do it in such a way that actually truly respects the people that were part of that value chain to get you to that experience.

But then there's the other question, which is: I really care – I feel that if these big model providers have already treated data on the web as free for them to use, they're coming after yours and my data next. They're going to try to get to my private data and stuff that's near and dear to me.

So I'm really interested in data in the sense of: How do we start thinking about protections for user context? How do we make user context portable across different sets of model providers so that we can invert that ownership paradigm? It's not that the model provider owns my context – I own my context and I can make it portable and I can expose different aspects of it depending on what we're trying to do at any given moment.

So that's the thing that I find interesting. I think it's very compatible with how Mozilla thinks about the user agent. Right now, the web browser is my agent. It's supposed to protect me. It gives me privacy. It protects me from ads, et cetera.

But now in this new agentic world, this Layer 8 world where intelligence is starting to mediate, that mediation is starting to not be my user agent anymore. So I think that having my data be secure and private in that interaction is going to be incredibly important.

Ksenia: This is a race so hard to win, considering that you can just push a button and everything in your iPhone becomes connected to Google services and then it's personalized AI, but also your data is out there in the air. So I don't know how to win this race for open source.

Raffi: Yeah, I mean, I don't know the answer either, but I think this is a fight worth having. And I think it starts with having some credible experiences that we can really talk about and how we want to show up to users.

So my canonical example here is Signal. Signal showed up in the sense that it drove privacy as part of the communications conversation. It wasn't even needed for every single user to use Signal. But the fact that Signal existed forces people like WhatsApp, Telegram, iMessage – now RCS is starting to think about having to have encryption on it because it's being driven by that conversation.

So if Mozilla or people aligned with the Mozilla Manifesto and our values can start building what these interfaces could look like where my context stays with me and doesn't move and can still be useful in a lot of ways, I think that could be something that could just drag the ecosystem a little more toward user privacy than where we are today.

Ksenia: Conversations matter.

Raffi: Correct. Conversations matter.

The Firefox Lesson

Ksenia: Here's a little tricky question. Mozilla has a fascinating history. What you're saying is that what you did with the web, you want to do with AI. At one point, Firefox indeed challenged Microsoft, brought it down to 55%. But then Chrome came and brought Firefox to 5%. So how can we make sure that the world of AI, even if we disrupt it first, will not be consolidated again?

Raffi: I think these are all pendulum swings. And so I would note that even though Firefox's usage has gone down, Google had to release an open source browser. We had to still maintain web standards. We still had to do all the things.

So the battle that we were trying to win by releasing Firefox – we won it. We might not be that big pillar that everyone's using anymore, but it's because of us that the web is open. It's distributed, et cetera.

And so yes, there's some consolidation that occurred, but the important thing is web standards. The important thing was open source as part of the conversation. The important thing is that anyone can still participate in the web.

That's not the direction AI is going in right now. And so that's why I'm trying to drag Mozilla into that fight. Because if we can start to drive the conversation through credible alternatives, web standards, more people using it because of open source – I think that exact same playbook might work again in this space.

And sure, we're not going to be the model provider. There's not enough money in the world for us to compete on the model side. But I think if we can just get the other pieces in place, we can get an entire ecosystem speaking the same language. And I think it's kind of like a rebel alliance, almost, that we can start to give credible alternatives and drive the conversation. We're all part of the rebel alliance for different reasons.

But in the end, if it means that user data is secure, context is ours not someone else's, there's choice in the ecosystem, I can trust the outputs of the LLMs and trust the outputs of the chatbots, if I can surf the web without being worried – then Mozilla will have won that fight. And that's the fight that I'm trying to take.

Practical Steps for Companies

Ksenia: It's a very important fight. I'm just trying to see from a company's perspective how to showcase to them that they should try. And if you can give advice to a company that is still in the experimentation mode, what will be your one, two, three steps for them to start thinking about it? How to implement open source for their company?

Raffi: What I would say for a company is: Try to instrument choice into your engineering stack as early as you can.

This is the reason why we built things at Mozilla AI like the Choice Suite. It's really easy to do. It's just a small shim. Put those things into your application as early as you can. You don't know when you might want to switch to open source. You don't know when you're going to exit your experimentation stage. But give yourself the exit door as early as you can so that you can then do it later when the time is right.

Don't make it a massive Herculean engineering effort later. Make it super small. It's like an NPM install or a UV install and you just do one line of code or five lines of code. You just do that at the beginning, and that investment gives you the exit door later.

So try to do those types of things as early as you can. Just like any good engineer would – engineers are usually thinking about: How can I refactor this later? How can I test this later? How can I do all those things later? So just think about those things as early as you can in the process.

And Cursor and others also take those prompts really quite well. You'd just be like, "I want to integrate AnyLLM into this," and it just happens. It might not even be five lines of code. It might just be one prompt you do at the beginning of your project that gives you that flexibility later. So that's, I think, the biggest piece of advice.

And then the second one is: Just be open and see what's going on in the ecosystem. Like I said before, the vibrancy in the open source ecosystem is quite amazing. It's quite lovely. So go read your favorite blogs. Listen to people like you to understand what's going on out there. Because maybe one of those things you'll be like, "Oh, I should swap that for that," and it could show up as part of that conversation.

Making It Simple

Ksenia: I would like to have a clear understanding: How can a child or a non-technical person just install an open source model and just use it for whatever, for their phone? That should be easier.

Raffi: I would love to get to that world! That world is not the world we live in yet, but I think we can get there.

Ksenia: This year, right?

Raffi: 100% this year! I mean, like right now, any person on a Mac who can pull up a terminal can install a local open source model with just brew install ollama, right? It's already a one-liner, but you need to know how to use a terminal.

So we can just eliminate that this year. That would be amazing, right? I feel like we can get there. I feel like this is a slam dunk. We just got to do it.

Einstein's Dreams

Ksenia: Well, that's been a very fascinating conversation. And I like to finish all my conversations with a question about a book. A book that recently or long ago influenced how you think about life and how you think about your work, your values. What was that book?

Raffi: Oh, that's such a great question. And I'm not prepared for this question.

I would say that one of the books that probably has most impacted me is a book by Alan Lightman called Einstein's Dreams. And so what it is is a set of vignettes – I want to say it's 20, I could be wrong on the number – which are all different versions of how time could flow differently.

What if we lived in a world where time moved slower the higher altitude you were? Or what if we lived in a world where time went in a circle over and over and over again? And what would that mean as implications to life, love, friendship, et cetera?

And so that was literally the first book I ever gave the woman I was dating, who then became my wife. So if you were looking for one book that changed my life, that was probably the book.

Ksenia: That's amazing. I would love to read this book. It sounds very interesting. Thank you so much. Thank you for this conversation. Let's hope this year will make a lot of progress in open source.

Raffi: Thank you for having me. This was such a pleasure.