← Writing

Project Chronicles Case Studies

Nepālākṣarā and the Pāla book hand: rebuilding the scripts of 1015

What were Tibet's great translators actually reading? I followed the letters over our temple doors back to a palm-leaf book written in Kathmandu in 1015, and set out to build a font and an OCR reader for Nepālākṣarā, the script it was written in.

Thupten Chakrishar

Lantsa on a temple: oṃ maṇi padme hūṃ on the lanterns, more Lantsa in gold along the beam. Photo: abhinavcoca, Pexels
Lantsa on a temple: oṃ maṇi padme hūṃ on the lanterns, more Lantsa in gold along the beam. Photo: abhinavcoca, Pexels

The letters over the door

The first time I saw them, I was very young. They were painted on temple walls, mostly around the entrances: tall, ornate letters that looked nothing like the Tibetan I was learning at school. Later I saw them again at the top of the title pages of our pecha (the long, loose-leaf Tibetan books). I always thought of them as ceremonial, a decoration and not a language anyone used. Like a sacred object in the house: you keep it and honor it, but you don’t use it every day.

It didn’t help that my father, Jamyang Dorjee, is a Tibetan calligrapher, and high lamas often ask him to make their official seals. Those seals are carved in yet another script, hor yig, “Mongol letters”, a square form of the script that Chögyal Phagpa, a Tibetan lama, made from Tibetan letters for Kublai Khan’s empire[11]. So I grew up thinking we Tibetans simply love all kinds of scripts.

Later I learned that these scripts are not only decoration. They carry real text, and a long, long history.

Earlier this year I was reading Grains of Gold by the Tibetan scholar Gendun Chöphel. In it he says that some of the Sanskrit mantras in our books do not match the originals[12]. That piqued my interest. At the same time we have been building Thonmi, our self-learning reader for Tibetan, and most of what we test it on is pecha manuscripts. So I spend my days looking at the very pages where those letters sit, and the question finally caught me.

We say the great lotsawas (translators) translated the Dharma “from Sanskrit.” But Sanskrit is a language, not an alphabet. It never had one script of its own; each region wrote it in its own letters[13]. So what was actually on the leaf in front of Marpa Lotsawa? What did the Indian masters carry over the mountains?

So I dug around.

The letters over the temple doors have a name: Lantsa, the Tibetan form of Rañjanā, a script of the Kathmandu Valley. Tibetans use it for the Sanskrit titles of translated books, and for mantras[14]. So the letters pointed to Nepal, and Nepal, it turns out, was one of the great roads.

I have been to Swayambhū several times. The stupa looms over the valley, and the Buddhist feeling there is different from anywhere else. I had heard a few small stories about Tibet and the old kingdom of Nepal. I had no idea how much scholarship lay behind them.

Tradition says that Śāntarakṣita, the Indian abbot invited by King Trisong Detsen, met such trouble in Tibet that he withdrew to Nepal for some years, and came back when Padmasambhava (Guru Rinpoche) was invited to tame the local spirits. Then Samye was built[15]. That is how the old histories tell it, and they don’t all tell it the same way.

By the eleventh century the accounts are fuller. Marpa’s biographies say that in the Kathmandu Valley he met two Nepalese disciples of Nāropa, Chitherpa and Paiṇḍapa, and lived three years at Swayambhū, to get used to the heat, before going down to India[16]. The same hill I had walked up, as a visitor. Atiśa left Vikramaśīla in 1040, was in the Valley in 1041, and reached western Tibet in 1042[17]. Not everyone came this way. Rinchen Zangpo went west, to Kashmir[18]. But many did.

Animated preview of the interactive map: the journeys of Atiśa, Marpa, Rinchen Zangpo, Śākyaśrībhadra and Padmasambhava drawn one after another, then a timeline of who was alive when Open the interactive map →

The roads of the masters and translators. Open the map to follow each journey stop by stop, with its sources, and to see on a timeline who was alive when. Solid lines are documented, dashed lines follow the traditional histories, dotted lines are a road we assume. Relief map: Esri.

And the books they carried? The Sanskrit manuscripts that survive in Tibet are mostly palm leaf, “copied, with a few exceptions, in eastern India or in Nepal”[4]. So I went looking for a Nepalese leaf from those years. One with a date.

I found Sujātabhadra.

Sujātabhadra was a scribe. In Nepāla Saṃvat 135, on Thursday 31 March 1015, he finished copying the Aṣṭasāhasrikā Prajñāpāramitā, the Perfection of Wisdom in Eight Thousand Lines, one of the great Mahāyāna sūtras. He wrote on palm leaf at the Hlāṃ monastery (vihāra) in the Kathmandu Valley, and he put the date and his name in the colophon, the scribe’s closing note. The book, with its painted panels, is now Cambridge University Library MS Add. 1643[1].

Folio 8v of Add. 1643, the whole leaf: Sujātabhadra's writing with a painting of the Buddha Dīpaṅkara in the middle and a painted vajra at each string hole

Detail of folio 8v: the Buddha Dīpaṅkara with Avalokiteśvara and Vajrapāṇi

From Sujātabhadra's book: folio 8v, the whole leaf, and the painting at its center. The Buddha Dīpaṅkara stands between Avalokiteśvara (white, to his right) and Vajrapāṇi (green, to his left). A small note with the painting, probably an instruction to the painter, reads sinhaladvīpe dīpāṅkara, “Dīpaṅkara in Siṃhala,” Sri Lanka[1]. No picture of the scribe himself is known. Image: Cambridge University Library, CC BY-NC 4.0.

The Tibetan letters I grew up with are not his descendants. Our script is nearly four hundred years older than his leaf, modeled on a north Indian script of the Gupta family[19]. His hand belongs to the other line: the Nepalese family from which Rañjanā, and so Lantsa, comes[7, 14]. The letters over the temple door that I took for decoration have an older relative, and here it was, dated to the day.

To copy this sūtra in eleventh-century Nepal was not only to make a text available. The Mahāyāna sūtras praise the copying and honoring of the book itself, and illustrated Prajñāpāramitā manuscripts of this age were kept, displayed and worshipped as sacred objects as well as read[2, 3]. So the scribe’s hand is part of what the object means. Its regularity, its weight, its rhythm—to me they are a kind of devotion made visible.

I wished I could run some of these old pages through an OCR reader. Text recognition exists for later Nepalese manuscripts in the Pracalit script[9], but for hands this old I found none. Could we build one? The usual way needs millions of labeled examples, and for these scripts they don’t exist. So we decided to try our own engine, Thonmi, which learns a hand from just a few pages and then reads pages it hasn’t seen. (More on Thonmi in a later post.) But to do that, Thonmi needs a font of the hand, and there is no published font for it. Only a handful of scholars can read this early hand at all. So we had to build the font as well.

That’s the path. The font comes first.

This post is about our attempt, over the past weeks, to recover his hand in two forms: as a digital typeface, and as a machine reader that can read manuscripts written in it. It is also about what went wrong, what the research turned up, and where the work honestly stands.

Why this hand matters

The script of transmission. Most of the Tibetan canon was translated from Indic, chiefly Sanskrit, manuscripts. Those that survive in Tibet date for the most part from the eleventh to the fourteenth century[4]. Delhey’s study of the twelfth-century manuscripts he links to the monastery of Vikramaśīla finds nearly all of them in the eastern Indian script known as Proto-Bengali, with Nepalese hands in two or three[5].

Sujātabhadra was writing in the lifetimes of Rinchen Zangpo (958–1055) and Atiśa (982–1054). His book is an early, securely dated Nepalese example of the kind of book they read.

A gap in the reference literature. And yet his hand has no complete published alphabet. The fullest record is still Cecil Bendall’s catalog of 1883. Its lithographed “Table of Selected Letters” (Plate IV) gives seventeen forms from Add. 1643, traced from the manuscript: the vowels e and i, eleven consonants, the vowel signs of cai and kau, and two conjuncts[6].

There is a widely reproduced comparative table of Nepalese scripts, issued by the Government of Nepal in 1962 and reprinted by Anshuman Pandey[7]. It does not fill the gap. It has no column for the so-called Transitional or Ṭhakurī period, conventionally about 879–1200—and 1015 falls squarely inside that period. The paleography of those centuries has to be rebuilt from the manuscripts themselves.

Bendall, Plate IV, Table of Selected Letters: rows for Add. 1643 and Add. 866

Figure 1. Bendall’s “Table of Selected Letters” (Plate IV, 1883), the rows for Add. 1643 (1015) and Add. 866, lithographed from tracings. As far as we know, it is still the only published table of his letters. Public domain.

Naming the hand correctly. Older catalogs often call any of these hands “Newari”, and popular sources reach for Bhujimol (bhujiṃmol, “fly-headed”), whose letters carry a small hook in place of the head bar. Bendall dates the hooked head from the twelfth century: his first certain example is of 1165, and Pandey places the style in the twelfth to seventeenth centuries[6, 7].

Sujātabhadra’s letters have no hook. Each one hangs from a straight, thick head bar with wedge-shaped ends; the only hooked writing in the book is a verse note added in 1139[1]. So we call his hand early Nepālākṣarā of 1015: an early stage of the Nepalese book hand, distinct from both the later Bhujimol and the later Pracalit.

From typeface to reader

A typeface lets the hand be written again. A reader lets the hand be read at scale—and for scholarship, that is the larger prize.

Thousands of Sanskrit manuscripts from Nepal and eastern India are held in Cambridge, Kathmandu, Tokyo, Oxford, Beijing and Tibet, and a growing number are photographed and online. Very few have searchable text. A reliable reader would let scholars search across collections, collate manuscripts against printed editions, and set Sanskrit witnesses beside the Tibetan translations made from books of the same families.

Our engine, Thonmi, is named for Thonmi Sambhoṭa, to whom Tibetan tradition attributes the adaptation of an Indian script for Tibetan. It is not meant to memorize images of letters. It is meant to learn how a script is constructed and how an individual scribe inflects it, so that it can read unseen leaves in the same hand from a few examples.

What went wrong

The first stage of the work failed. The reasons are worth writing down.

  • Reconstruction before observation. Our first letters were informed guesses: modern Newar forms made heavier. They were plausible, and they were wrong. Without a clean image of the ink itself, there was nothing authentic to trace.
  • A misidentification. The hand looks ornamental, so we took it for Bhujimol and went looking for features it does not have. That one cost us a full day before the dating evidence set us straight.
  • The limits of the images. The freely downloadable images were too small to show the edge of the pen. Faint ink broke strokes apart, abraded edges came out ragged, and some leaves did not match their labels.
  • Cutting lines into letters. We tried cutting whole lines into letters by expected width. It failed: the error compounded letter by letter (segmentation drift). An internal check—the punctuation bars (daṇḍas) must fall on real vertical strokes—exposed this at once.
  • No independent reader. I do not read this script fluently, so every check depended on transcriptions I could not easily produce. This, more than any technical problem, was the bottleneck.
  • Method before criterion. We built too many tools before agreeing what a correct result looked like. Now we fix a small test set and a pass/fail standard first, inspect the raw output, and only then scale up.

What we tried, in pictures

Our first letters, drawn from modern Newar shapes

Figure 2. Our first attempt: letters built from modern Newar shapes and thickened (black), over our reference shapes (pink). Every letter is plausible. None is his.

What the research changed

The shared letter body. Pandey’s paper introducing the Bhujimol script (which he spells Bhujinmol) makes an observation that unlocked the problem for me: the Newar styles share “a nearly identical structure for the letterforms” and are distinguished primarily by the shape of their head strokes[7]. Once I saw it that way, Sujātabhadra’s letters made sense. They are Newar bodies beneath a flat, heavy, wedge-ended head, written with a broad pen held at a steady angle.

The hand is not a lost alphabet. It is an early, bold form of a known one.

The eastern Indian twin. Cambridge also holds MS Add. 1464, an Aṣṭasāhasrikā copied in Bengal in the fifth regnal year of a king Mahīpāla, of the Pāla dynasty that ruled Bengal and Bihar from the eighth to the twelfth century. Its date depends on which Mahīpāla is meant. Cambridge’s catalog thinks Mahīpāla I more probable, which gives about 985; Mahīpāla II would give a date after about 1070. Bendall put it about 1020[1, 6]. He captioned its script the “Kuṭila writing of Bengal”[6].

Put it beside our 1015 leaf, and letters such as ta and na are the same shapes. In these two books, the Nepalese scribe and the Bengal scribe write closely related forms of one ornamental book hand—although Bendall judged Add. 1643 less Kuṭila-like in general appearance than some other Nepalese books[6]. This shared ornamental hand of the Pāla period is what the title calls the Pāla book hand. Both hands differ from the twelfth-century script that Bühler called Proto-Bengali[8], which is a later and different design.

Add. 1643, Nepal, 1015, folio 179r

Nepal, 1015 · Add. 1643, folio 179r · Sujātabhadra

Add. 1464, Bengal, year 5 of Mahīpāla, folio 10r

Bengal, fifth year of Mahīpāla · Add. 1464, folio 10r

Add. 1648, dated 1216

Dated 1216 · Add. 1648 · enlarged ×1.5

Figure 3. Three books, shown at the same scale. The heavy wedge-headed letters of the first two, Nepal 1015 and Bengal, are close kin. The third, dated 1216 and enlarged ×1.5 to match letter size, is the later eastern Indian hand, a visibly different design. Images: Cambridge University Library, CC BY-NC 4.0.

A manuscript that checks its own reader. Add. 1464 carries the same sūtra, and the sūtra has a critical edition, P. L. Vaidya’s of 1960[10]. That means the manuscript can verify its own reading. An AI model reads only the first few letters of each line. We accept a reading only if it occurs exactly once in Vaidya’s text near the expected position, and if the following line’s opening then fits after it.

No reading is taken on trust.

This way we fixed the text of 24 sides of Add. 1464, line by line, to the edition. (A side is one face of a leaf.) Along the way the check flagged a passage of roughly 575 syllables on folio 31 that we could not find in Vaidya’s text. Is it a true variant, or a passage printed elsewhere? I can’t say. A specialist still has to check it.

Where the work stands

The typeface. The test letters are now built from the shared Newar bodies, Sujātabhadra’s head stroke, and a pen whose width was measured from his ink. A separate AI judge compared each letter against crops from the manuscript: 4 of 11 passed in the first round, and 6 of 11 after revision. Ka, ta, ma, ra and the vowel a still fail in their structure. The typeface is unfinished.

Eleven test letters across two rounds, beside copies by the scribe

Figure 4. The eleven test letters (ka, sa, na, ta, ma, ya, ra, va, pa, da, a). Left to right: the modern Newar letter each shape began from; round 1; round 2, after the judge’s fixes; three of Sujātabhadra’s own copies (gray boxes: no sharp copy picked yet). His letters are triangular masses with tiny counters; ours are still too open.

The reader. Our first reader works one line at a time. It learns from whole stretches of line whose text was fixed to the edition by the procedure described above, so letters never have to be cut apart by hand. (For specialists: it is a small convolutional and recurrent network trained with connectionist temporal classification.)

We test it on a side it never saw during training, folio 22v of Add. 1464 (1,056 characters). The measure is the character error rate: the share of characters the reader gets wrong.

Sides used for trainingCharacter error rate
435.6%
1014.6%
1614.3%
2210.4%

About one character in ten is still wrong. That is from a small model trained for minutes on a home computer, and the rate is still falling as we add leaves. The reader handles one Bengal manuscript only. It is a promising result—not yet a tool others should rely on.

A test stretch from folio 22v of Add. 1464, shown in two halves

Reader (never saw this leaf)

taprajñāpāramitā | punaraparaṃkauśikayasyatsarvavarmāanantāparyannānateṣāmantovānamadhyavāparyavasānaṃ

Vaidya’s edition

taprajñāpāramitā | punaraparaṃkauśikayasmātsarvadharmāanantāaparyantāḥnateṣāmantovāmadhyaṃvāparyavasānaṃ

Figure 5. One stretch from folio 22v of Add. 1464 (shown in two halves), which the reader never saw in training. Below it are the reader’s output and Vaidya’s text in transliteration, with the differences in red. About 9% of the characters in this stretch are wrong, close to the reader’s average. Image: Cambridge University Library, CC BY-NC 4.0.

Next steps

  • More leaves. We are adding further sides of Add. 1464, each fixed to the edition in the same way, and will stop when the error rate stops falling.
  • The Nepalese reader. Next we want to try the same method on Sujātabhadra’s own book of 1015.
  • Letters found by the reader. The trained reader locates each letter on the line by itself. That gives us many authentic examples of every letter, so the typeface can be completed from the manuscript rather than from guesswork.

An invitation

This work rests on the labor of others: the Cambridge Digital Library’s photography and cataloging, Bendall’s and Bühler’s paleography, Vaidya’s edition, and Pandey’s careful work toward encoding these scripts.

If you read Nepālākṣarā or the eastern Indian book hands of this period, care for manuscripts written in them, or support research on the Buddhist heritage of Nepal and Tibet, I would welcome your correction and your company. I want the next version of this typeface, and of this reader, to be judged by people who know these hands far better than I do.

References

  1. Cambridge Digital Library, catalogue records for MS Add. 1643 (citing Petech 1984 for the date) and MS Add. 1464. cudl.lib.cam.ac.uk/view/MS-ADD-01643 ; cudl.lib.cam.ac.uk/view/MS-ADD-01464
  2. Gregory Schopen, “The Phrase ‘sa pṛthivīpradeśaś caityabhūto bhavet’ in the Vajracchedikā: Notes on the Cult of the Book in Mahāyāna”, Indo-Iranian Journal 17, nos. 3/4 (1975): 147–181.
  3. Jinah Kim, Receptacle of the Sacred: Illustrated Manuscripts and the Buddhist Book Cult in South Asia (Berkeley: University of California Press, 2013).
  4. Harunaga Isaacson, “Sanskrit Studies: Sanskrit Manuscript Culture”, manuscript cultures 4, pp. 101 ff.
  5. Martin Delhey, “The Library at the East Indian Buddhist Monastery of Vikramaśīla: An Attempt to Identify Its Himalayan Remains”, manuscript cultures 8 (2015).
  6. Cecil Bendall, Catalogue of the Buddhist Sanskrit Manuscripts in the University Library, Cambridge, with Introductory Notices and Illustrations of the Palaeography and Chronology of Nepal and Bengal (Cambridge: University Press, 1883).
  7. Anshuman Pandey, Introducing the Bhujinmol Script, Unicode document L2/14-283 (28 October 2014), figures 7–11 from Government of Nepal 1962.
  8. Georg Bühler, Indische Palaeographie (Strassburg: Trübner, 1896), §26.
  9. Alexander James O’Neill and Nathan Hill, “Text Recognition for Nepalese Manuscripts in Pracalit Script”, Journal of Open Humanities Data 8 (2022), article 26, doi:10.5334/johd.90.
  10. P. L. Vaidya (ed.), Aṣṭasāhasrikā Prajñāpāramitā, with Haribhadra’s Commentary Called Āloka, Buddhist Sanskrit Texts 4 (Darbhanga: Mithila Institute, 1960).
  11. BabelStone, “Phags-pa Script: Script Styles” (the Tibetan seal style, hor yig gsar pa, “new Mongolian letters”). babelstone.co.uk/Phags-pa/Scripts.html
  12. Gendun Chopel, Grains of Gold: Tales of a Cosmopolitan Traveler, trans. Thupten Jinpa and Donald S. Lopez Jr. (Chicago: University of Chicago Press, 2014).
  13. “Sanskrit language”, Encyclopaedia Britannica. britannica.com/topic/Sanskrit-language
  14. Anshuman Pandey, Preliminary Proposal to Encode Ranjana in Unicode, Unicode document L2/23-028 (5 January 2023); Rigpa Shedra Wiki, “Lantsha”.
  15. “Śāntirakṣita”, Encyclopaedia Britannica; “Padmasambhava”, The Treasury of Lives. treasuryoflives.org/biographies/view/Padmasambhava/TBRC_P4956
  16. Andrew Quintman, “Marpa Chokyi Lodro”, The Treasury of Lives (September 2010). treasuryoflives.org/biographies/view/Marpa-Chokyi-Lodro/4354
  17. Alexander Gardner, “Atiśa Dīpaṃkara”, The Treasury of Lives (December 2009); Digital Archive of Nepalese Arts and Monuments (Heidelberg), “Thã Bahī, Kathmandu”.
  18. “Rinchen Zangpo”, The Treasury of Lives. treasuryoflives.org/biographies/view/Rinchen-Zangpo/10199
  19. “Tibetan script”, Encyclopaedia Britannica. britannica.com/topic/Tibetan-script