‘Legal AI can’t do judgment’, some have said, as if this were a sacrosanct area of legal work. But, AI can capture and leverage judgment at a firmwide level and then deploy it for new matters. Aloi, based in Sweden, is doing it. Ultimately this is all about tapping large data sets that sit inside law firms – and turning them into meaningful insights.
Artificial Lawyer spoke to Johan Häger, CEO of Aloi, about their approach. We look at: where the judgment layer sits in relation to the DMS and the final work product; how much past data is needed to accomplish this; how this connects to client preferences; and how building a judgment layer with AI supports how associate work will evolve, i.e. less process-level work in the future and the need to do higher value tasks which are supported by this crystallised firmwide knowledge.
The judgment layer approach also connects to other areas of legal AI development that AL has explored, such as startups offering to create digital twins of lawyers, as well as some law firms and tech companies seeking to build out open weights AI models that rely on their own data, i.e. this also connects to legal AI sovereignty. All this and more we explore below.
To watch / listen to the video inside the page, please press Play, or you can go direct to the AL TV Channel.
— Advertisement —

—
AI Transcript
Hey everybody, Richard Tromans here again, Artificial Lawyer TV. Today, doing a special interview, all about judgment and AI with Swedish legal tech company, Aloi, which has been around for some months, but it’s really going to town now. I hope I pronounced that correctly. To tell us more about it is the CEO, Johan. Good to have you with us.
Johan Häger (00:37.652)
Hi, Richard Great to be here. Thanks.
Richard Tromans (00:39.726)
Well, it’s a pleasure to have you, because now, just put a bit of context around this. A lot of people have said, well, yeah, AI can do this. It can do that. It can read a document. It can drag up information. It can even write you a contract, maybe. But it can’t handle judgment. This is the sacrosanct thing. You can’t do it. It’s far too complicated. But Aloi as far as I understand it, is designed to capture and crystallize the judgment within a law firm and to then leverage it for the benefit.
Johan Häger (00:58.26)
Yes.
Richard Tromans (01:08.608)
of those law firms and their clients. So talk us through what Aloi is and how it works and how it captures that judgment.
Johan Häger (01:17.854)
Yes, thank you so much for that. And this is of course, this is the closest thing to my heart and has been for quite some time. And this is sort of the main point, pain point, I think for the legal industry, actually. We are getting great support now from many products on workflows and drafting and also the chat interfaces, all of those things are great support. But there’s been one thing that has been problematic and that’s really utilizing your larger data sets.
and larger unstructured data sets that sits in all law firms. And this is, if you approach this, the first step has been really to find precedents, find clauses in these systems. If you think of a law firm with a hundred million documents, finding particular clauses, for example, you need a specific merger clause for a deal. Then finding merger clauses throughout the system has been quite easy. That was sort of the first step. But then when the data sets grew bigger,
and for larger law firms that got more more complicated, then the precision in that has not been that good. So getting to the next step has been to get precision into what we can actually find in those data sets. And that comes into sort of what we call first the model spec, that we get a specification of how these documents actually are structured. So we have invested a lot of legal engineering time is actually learning.
or teaching Aloi how to recognize the structures, the rules in these documents, the dependencies, all of these things. And that’s done in different ways. First, it’s in the model spec, and then with metadata. A lot of metadata is applied to these documents. Could be hundreds of metadata fields. And these metadata fields together with the model spec, that is providing the first step of how we actually, how we process the documentation, how we actually…
how a lawyer learns what is most relevant for the customer. Then we apply something that we call a judgment graph, learning the context of the deal. That is also really, really important. If you think about a particular draft of a document that is not sort of isolated in a transaction, it’s really dependent on so many other things. In an M&A transaction today, you perhaps have 50, 100 different documents.
Johan Häger (03:42.111)
You have a due diligence process. You have so many things going on. And Aloi needs to look at all of these different ancillary processes and documents to actually interpret that particular clause or document that you are drafting. And that’s done through a traditional graph that also is that we also teach the legal process of the legal structure of documents and structure of processes. So this is much more data processing.
learning unstructured data, putting the legal context into it. Then there are certain things that we approach that are also relevant to these judgment or intelligence decisions. It’s version handling for lawyers. Now we go into some details. Version handling is really important. For example, if you have a transaction regarding a share purchase agreement, can be 20, 30 different versions processed on
both sides of that transaction. That’s really important to learn from those versions what has actually happened, how have a particular risk or particular clause been approached by the lawyers before, how the identified risk, how that has been mitigated, what routes have been taken in that. So there’s many different steps in actually approaching what we then ultimately say is the legal judgment.
And the legal judgment is a combination of what we learned from the model specs, the metadata fields, the lineage process, and the judgment graph. And all of this together comes to a conclusion and a recommendation for the lawyer. It’s sort of in a way that we see the decision patterns throughout the data. Thank you.
Richard Tromans (05:28.238)
Gotcha, okay, you throw it, so that’s, might say, your raw materials, right? So let’s say we’ve got a new matter, comes into XLawFirm.
Johan Häger (05:34.644)
Hmm. Yeah. Hmm?
Richard Tromans (05:41.079)
and lands on the desk of a particular senior lawyer and they begin the process. They start to get into the very first documents for this matter. How does all of this raw material that you’ve processed and organized and found shape and meaning within, how does all of this get applied to what this new lawyer is doing on this new matter?
—
Come and join us in London this November 4th + 5th at Legal Innovators! The conference at the intersection of legal AI and the business of law. Day One: law firms, Day Two: inhouse.
Legal Innovators UK – London, Nov 4 and 5

—
Johan Häger (06:03.452)
Yeah, you mean from a technical perspective how it’s actually how it works.
Richard Tromans (06:07.554)
Yeah, yeah, without getting too technical, but just generally, I’m sure people watching this will be thinking, okay, so you found all this information about our past deals, you’ve seen the context, you’ve seen how different clauses were argued, okay, wonderful. How are you then going to apply that meaningfully to this new piece of work that I’m going to do?
Johan Häger (06:24.778)
Yeah, the spot on best question really, the more context and intent you provide from a prompting perspective or workflow perspective. For example, if you think of something very practical, you’re a lawyer, you’re drafting an SPHA share purchase agreement, you have some terms from the clients and perhaps you have a heads of terms and a term sheet that you can of course apply that you know, that’s a baseline, right?
Then what you can go further and then you can ask the system, the platform, how have we approached this in the past? How have we drafted these particular clauses and what this particular client’s wishes? And that is a call done in Aloi or through another platform to Aloi. And then Aloi does the retrieval on that information. It retrieves the ingested information through all those systems that I mentioned before.
Richard Tromans (07:20.866)
But how does it, how does, I I guess many lawyers would ask this as well, which would be, okay, again, that sounds very cool, but how does it know what to apply? So I’m in, I’m in this, you know, I’m in like the, you know, the 25th clause down, I’m working my way through the contract and I’m like, I want to this one. How does it know to apply that information to that clause?
Johan Häger (07:40.896)
Yeah, it’s a combination of those different systems, but mainly it’s how we actually work with the model spec and metadata fields. So the model specs where we define the structure of the document through the legal knowledge of how, for example, an SPA works. And for example, the knowledge in the system regarding how this particular client wants to see that information being or that clause being drafted. So this
Richard Tromans (08:05.295)
And so that will then surface itself as you’re working on a new contract.
Johan Häger (08:07.841)
It will. you provide the context, the intent, you prompt. For example, you ask, this is a particular, this is a merger provision. I want to draft for this particular client, Blue. How have we done that in the past? All that information of how we’ve done that in the past will surface. If I give it more context, for example, I say, how for client Blue, how have we approached deals where they have acquired IP heavy businesses in the past? That will also be retrieved with that.
precision with that context then you approach the system and say that my intent in this this particular transaction is to do a little bit be a bit more aggressive with the terms more seller-friendly than I’ve been in the past then I’ll always retrieve that kind of information so it knows what’s seller-friendly it knows what IP heavy businesses it knows what the private equity deal is it knows what a stock exchange deal is that is sort of in the system
Richard Tromans (09:06.816)
Okay, I meant it’s being effectively customized by past transactions. So it’s probably fair to say that this is only really gonna be, at least in the short term, immediate value to people who have done past transactions with the clients.
Johan Häger (09:22.761)
Yeah, I would say there’s a sort of a marginal effect impact of our effect on data also, right? So the difference between having 10 facilities agreements and 100, it’s a quite big difference. But between 100 and 1000, there’s less variations and between 1000 and 10,000, even less variations. So even smaller clients of us, smaller customers with just around 30, 40 lawyers, they have a great experience of the product. Larger customers with thousands of lawyers, they approach this in a completely different thing. They add us to their tech stack for just ingestion and retrieval and combine us with different other products surfacing the workflows. it’s different ways to approach it depending on how much data you have really.
Richard Tromans (10:08.557)
you
Richard Tromans (10:15.214)
So I mean playing devil’s advocate, the owner of a DMS company might say, this sounds just like a DMS with a few fancy AI things added on. mean, how is it different to that?
Johan Häger (10:25.697)
It’s quite a difference. DMS is what it’s called, a document handling system. Then some of the DMSs have a sort of built search systems to it where you can search for a president. I have a client below that I’ve worked for before. Can you bring me those deals back? And it will do that with some precision. It will also bring a clause back, perhaps.
that what merger clauses have we used for this particular client. But it will not see decisions patterns in the data. It will not have that sophistication level that you actually need for sophisticated drafting, sophisticated negotiation, to see how you’re actually taking a decision in the past. That’s where the real value comes. Law is so much, yeah, sorry. Law is so much about, to me, the legal profession has always been so much about
Richard Tromans (11:11.968)
you got you.
Johan Häger (11:19.443)
risk identification and mitigation is protecting the downside in most cases. seeing how risk have been approached in the past is hugely valuable. And that’s only possible through a system like this.
Richard Tromans (11:36.526)
And as you say, yeah, mean, obviously you want to ameliorate the risk, but then of course there’s the more positive things in that you want to put in positions that are beneficial to the clients. Their own secret source, as it were.
Johan Häger (11:46.655)
Yes.
And I think this would be hugely important now for the whole industry when we see this is a clear shift in the market, right? The firms that will really leverage that data will get closer ties to their clients. It will be more sticky with the clients. They will learn more over time in an optimized way regarding their clients and the clients’ preferences and risk handling.
So if you leverage your data, you leverage your knowledge of the client, you get more sticky with the client and you will have a more robust business model going forward. And so that’s highly important. And also I think it’s so interesting to see now the legal industry going from something that has been very, when I was still in private practice, my clients called me and they sort of, they were under the perception that I knew everything that we have ever done in the law firm. That was of course not the case.
Now we take that very individually dependent legal industry that was dependent on the knowledge of a particular individual to something that is much more data driven, utilizes the whole experience of an institution to back that advice. And that’s something that will be a clear shift in the market.
Richard Tromans (13:00.672)
Interesting. mean, this connects to many different things. It connects to some degree to what’s happening with digital twins, which some people are developing. It connects also to this idea of AI sovereignty within a law firm where it practice groups are saying, well, you know, we want to try and crystallize our own knowledge, our own judgment layer. We want to keep it inside the building as it were. Some are even going out and working with Palantir and other companies, you know.
Johan Häger (13:21.919)
Yeah.
Johan Häger (13:26.881)
Yes.
Richard Tromans (13:29.55)
There’s all kinds of things like that going on. then some of the some other legal tech companies are sort of saying, we’ll help you to do this. It’s I where do you fit into this sort of quite rapidly evolving ecosystem?
Johan Häger (13:44.459)
I sort of see the market as you have the DMA. If you start from the bottom right, you have the DMSs sitting there. They are document handling system sorting the data you file with them. You file all your data and sort it, sort of structure it in that way. And then, but it’s not structured from an intelligence perspective, structured from a document handling system perspective. Then above that sits the data processing companies that are good at retrieving with high sophistication, retrieving on that data.
Those are all, of course, like companies like Aloi. We need to work together with the DMS companies, of course, to provide value to the end user, the lawyers and the lawyers clients. Then on top of that, you have the application layers where you have some rather large players already. And they are fronting the customers with great workflows and great processes. you combine all of this, you combine those application layers with those workflows.
with the data processing companies like Alois sitting in the middle where the DMS is, then you get a really good user experience for the lawyers. And by leveraging data there, you get a really high value back to the customers. So to your question, we sit in the middle, but we are very much a data handling company that supports our customers with a lot of structuring of the data, which is a quite complicated process.
Richard Tromans (14:57.08)
Gotcha.
Johan Häger (15:10.314)
It’s not only optimized through a platform. It’s also something that you discuss closely with these clients. Data is one of the most valuable resources, of course, for knowledge companies going forward and for major DAW firms. And to really structure that data in the most clever manner will be key for the future.
Richard Tromans (15:29.068)
Yeah, absolutely. It’s very interesting as well. mean, in terms of, mean, for example, you know, do you work in a very sort of customized way with each law firm? I mean, you have that kind of forward deployed engineers and that kind of thing, or is it a kind of like everybody can just jump on and they can just use it themselves? I mean, how, how do you get where you need to get to with each law firm?
Johan Häger (15:42.028)
Yeah
Johan Häger (15:54.883)
Yeah, we have both ways to do it really. We have a baseline product that we can deploy right away, really, when we start onboarding the product. It just takes us a couple of hours to do the technical onboarding. And then the ingestion process depends on how much data we ingest. But a number of million documents over a few days is normally what it takes. And then you’re up and running with the baseline product.
Richard Tromans (16:22.382)
And do you have to kind of customize? So say you’ve got to get all the documents in, but then do you then sort of customize and tweak it for specific clients? I mean, like a law firm says, well, initially we’re going to focus on these clients. We want you to really attune it particularly to these types of work or how does that go?
Johan Häger (16:30.124)
Yes.
Johan Häger (16:40.674)
I would say that the tuning, you wish, that it’s more tuning the larger the institution gets. Larger law firms want more tuning and more tailoring to their needs. And it’s that it should fit very well with their other products in their stack. And that’s something we work very closely with them. So we have teams going out to the law firms. So yesterday we had a team go into Norwegian.
law firm to do the MCP connection for them to integrate with another product. So that’s it. Then we’re sending a team of five engineers and then working throughout a couple of days and then it’s to set up that MCP connection. we do. No, So to answer your question, we do both. have a standard application layer also, which many of our customers use, of course.
Richard Tromans (17:23.32)
Got you, got you. And just last, sorry, no, go on, please go on.
Richard Tromans (17:35.385)
Gotcha. So just around after a couple of philosophical questions. So, and it’s a question that I think everyone needs to ask themselves in the age of AI is, what is, is that actually judgment? Is looking past decision patterns, the end result of negotiations and so forth, is that really tapping judgment? I mean, from your perspective, have you, if you were working with ex-BIC law firm, and you’ve done that, have you actually captured their judgement for them?
Johan Häger (18:10.371)
Yes, I believe we have actually. We have. if you visit our event tomorrow in Stockholm, you will see that when we launch a new negotiation platform, which is the best way to showcase that really, that we can see the decision pattern in the law firm. Then if you want to be a little bit more philosophical to that, I want to see what the law is doing, the sophisticated data retrieval and the processing of the structured data that we do closely together with our customers.
I would like to see, even if you get the judgment from a lawyer, you get a clear proposal on what decision to take. I will still see that as a recommendation to the lawyer. And the lawyer is taking the final call together with the client. But you get so much more intelligence behind that decision, so much more data-driven approach, so much more data-driven approach regarding that decision. So if I, you, in my practice at Roche before,
If I was sort of taking my decision based on my recognition of or knowledge about a number of deals that I could sort of remember and the number of different situations I could remember, this is multiplied by a hundred, thousand now. And so it gets much more data driven, much more support for that decision.
Richard Tromans (19:28.226)
Yeah, absolutely. And very, very last question. I mean, how does that change the law firm model? I mean, we haven’t even talked about in-house and maybe we can talk about the in-house world another day, but just, just briefly. So we’ve got this pyramid of most experienced lawyers at the top, naturally the least experienced at bottom. Does this enable the more junior lawyers to get up the chain faster? They may of course not have performed some of that work themselves that’s being referred to, but they can tap it more rapidly that they can. So you could say to a first year associate, look, I know you didn’t do one of these financing agreements before, but this is pretty much how you do it. This is because Aloi will flow into your desktop and show you what we did and how we do it. Is that possible?
Johan Häger (20:06.733)
Yeah.
You put it in a perfect way, really. A lawyer will flow into your desktop. It’s sort of the experience of all the senior partners that you have available at your fingertips every day, right? So if you just use a product like this with this sophisticated data access, you get really good, really fast. I think the learning curve will become really steep for lawyers using a product like this.
The learning curve regarding legal issues, regarding drafting, regarding negotiation, regarding the particular client and counterparty, that would be really steep. So I think we’re entering into something that is of tremendous value for law firms and ultimately for their clients.
Richard Tromans (20:50.294)
Interesting, yeah, and I think this connects to legal education, ongoing training, you know.
Johan Häger (20:54.603)
Yes, absolutely. And I think actually we touched on that at a meeting earlier today, legal education can be based on products like this. You actually draw on the data support from products like this when you do your in-house trainings, for example. Then when it comes to, I think you mentioned the business model. I think this is highly relevant. How do we see the low-end work for law firms? We will more or less stop charging for that, I think.
in the legal industry. will be very difficult to start charged for a simple documentation and that sort of things.
Richard Tromans (21:31.544)
And even, I mean, even, know, so X law firm is a very respected law firm. And you’ve crystallized, you know, the decisions and judgment that they would normally apply to this relatively simple document. The client is just like, well, we use this system as well. You know, let’s say this is in a few years time, everybody’s using systems like Aloi or, you know, something similar. And they’re just simply like, we know that you can do this in like five seconds. We trust the way that this
Johan Häger (21:36.557)
Hmm.
Johan Häger (21:51.563)
Yeah.
Richard Tromans (22:01.07)
data has been crystallized, all you need to do is apply it to this particular document. We would do it ourselves, except we don’t have the data set that you have because you’re a big law firm. Frankly, do this for $5 and you’ll get our next M&A deal. You know, and it’s which you will get a hundred thousand, well, which whatever, you know, it’s, mean, it’s, going to get like that, isn’t it? Cause there’s going to be this commodification of it.
Johan Häger (22:09.524)
Exactly.
Johan Häger (22:21.185)
Yeah, but I think, yeah, but the key point is actually what exactly what you said. You can do it yourself with generic AI today. You can ask it to drop the merger clause that is quite looks quite good, but it’s not data supported. It’s not supported with all that intelligence that the law firm today sits on. That sits in the DMS. And that’s really the key thing, right?
Richard Tromans (22:46.369)
It is, is, it is, it is. Well, look, I’ve got to end it there. Really, really interesting talking to you. Thank you very much.
Discover more from Artificial Lawyer
Subscribe to get the latest posts sent to your email.