What's the diff? Sutta comparison tool 🛠

Have you ever struggled to see exactly what the difference was between two suttas? Struggle no more!

For example:

Or for something much longer (which may take a while to load depending on your device)


@Snowbird This is just amazing!!
:pray:t5: :pray:t5:

1 Like

Well, it’s just putting together existing technology. In the readMe I link to the library I used to do the diffing. And, of course, the suttas themselves are coming from the SuttaCentral API.

Much appreciation as always to Bhante @Sujato and his team for all their hard work. And to @Khemarato.bhikkhu for his help and patience with the coding.


That’s awesome. I :heartpulse: diff… :rofl:

I guess it was a bit too tricky to align the columns? That would be perfection…


The diffing library I’m using doesn’t provide for that (as far as I can tell). But anything is possible with code.

My thinking was that either the suttas would be so similar that it wouldn’t matter (assuming simple manual checking [aka eyeballing it] was not turning up the difference) or that they would be so different that aligning the line wouldn’t work.

1 Like

If you could code liberation from suffering, that would be great Bhante. I’m looking forward to ‘Arahant v 1.0’ :wink:


Sorry. Had to fix that. :nerd_face:


:rofl: :stuck_out_tongue_winking_eye:


Wow! Just WOW!!!

:+1: :+1:


Yes, your name came up right away when I was discussing this with Ven. Khemarato. This should kick your spotting of inconsistencies up to god like level.

I’m still working on getting other languages to work.


My goodness! And expectations will climb up … :person_climbing:

Well, usually I don’t quite know what I am comparing with. Sometimes I have a vague memory of a different translation of a certain passage, or what the (German) Bilara translation memory shows me differs from what I see in the English translation of the current Sutta—these are things that make me suspicious. But what the translation memory doesn’t show is where these other passages belong to. So I go searching … and my favorite tool is always @karl_lew’s scv-bilara. (Hopefully we’ll one day manage to build a nice user interface for it so that is is easier to use for anybody.)

But surely once my suspicion is concrete enough your new tool can be a great help to pin down the exact differences. :pray:


To come back to that one, just a possible use case:

In your link comparing MN 10 and DN 22, I see this passage:

Screenshot from 2022-10-02 14-29-01

I’d now be interested to know if the Pali in the two Suttas is different here or the same. If it’s the same, that would be a thing to point out to Bhante Sujato as an inconsistency. In order to find that out it would—especially when it comes to long Suttas—be easier if I could see the segment numbers of the two Sutta passages and then compare precisely these segments in Pali.

Is that too hard a coding task?

I would still assume that much is possible, but sometimes the relation between effort and benefit is just not fitting. So I leave that up to you.

I can always find that out by using a different tool, of course.

Again much thanks for all your efforts! :pray:


Ayya @sabbamitta, do you mean besides something like this? Pali text can be activated by menu item at the top.


So, you can also compare the Pali. Do you see the language drop down?

Let me play around with segment numbers and I’ll see what I can do.


The diff tool will be quite helpful to translators. Thank you!


Yes, I saw it.

There are actually more differences in the Pali, mostly spelling variants. To find the right segments that I want to compare is not so easy in a long Sutta.

1 Like

This is kind of an unusual case, since normally we won’t be comparing very long suttas like this. Or will we?

1 Like

I don’t know. :smile: I just tried out the link you provided because it was here.

I translate short Suttas and long Suttas, so I compare short Suttas and long Suttas. Sometimes I compare passages of short Suttas with passages in long Suttas. All these cases happen.

But as I said, it’s quite likely that the effort is not worth the benefit. I can usually get the information I need by other means. Actually what I really like is the trilingual view in scv-bilara.