About the Heatmap Project
The Secret Tantra of the Sun: Blazing Luminous Matrix of
Samantabhadrī (Tib. Kun tu bzang mo klong gsal ‘bar ma nyi ma’i
gsang rgyud) is often described as the scripture that spawned an
entirely new Heart Essence Great Perfection tradition called the
Heart Essence of the Ḍākinī, which was first revealed in Tibet in
1313. The Heart Essence of the Ḍākinī (mKha’ ’gro snying thig) is
associated with the tantric adept Padmasambhava (c. 8th century) who
first buried the collection as a Treasure (gter ma) in the 8th
century, to be revealed again in the 14th century. A few centuries
prior to the emergence of the Heart Essence of the Ḍākinī, there was
an earlier strain of Heart Essence teachings associated with the
Indian translator Vimalamitra already in circulation (Bi ma snying
thig).
This heatmap is a snapshot of the Tantra of the Sun’s reception in
Tibet, especially as it appears in the Heart Essence of the Ḍākinī
and its commentarial set, Quintessence of the Ḍākinī, authored by
Longchenpa. The heatmap displays instances of explicit
intertextuality between the Tantra of the Sun and volumes 5-8 of
Longchenpa’s Collected Works (Klong chen gsung ’bum). Volumes 5-8
are a part of Longchenpa’s famous Fourfold Heart Essence (Snying
thig ya bzhi), important to the Nyingma (rnying ma) lineage of
Tibetan Buddhism. Fourfold Heart Essence is critical for this study
because it contains within it the two Heart Essence streams named
above: 1) Heart Essence of Vimalamitra, and 2) Heart Essence of the
Ḍākinī, along with Longchenpa’s associated commentaries. Volumes 5-8
correspond to the Heart Essence of the Ḍākinī and Longchenpa’s
commentary, Quintessence of the Ḍākinī, respectively.
The story of the Tantra of the Sun becomes even more complex given
that there are several completely different versions of the tantra
available on BDRC (Buddhist Digital Resource Center), of varying
chapter lengths. For my dissertation and this heatmap, I have used
the 113-chapter version found in the Snga ‘gyur bka’ ma shin tu
rgyas pa (I call this version KM2, see bibliography below). I
chose this version of the tantra because it appears to be the
version that was cited throughout volumes 5-8 of Longchenpa’s
Collected Works (LS) i.e., the Heart Essence of the Ḍākinī and the
Quintessence of the Ḍākinī.
Given what the Heart Essence tradition says about the Tantra of
the Sun and its importance to the Heart Essence of the Ḍākinī, I
created the heatmap to help visualize and answer two main
questions:
1. How and where is the Tantra of the Sun cited throughout the
Heart Essence of the Ḍākinī and the Quintessence of the Ḍākinī?
(Longchenpa’s Collected Works volumes 5-8)
2. Which quotations of the Tantra of the Sun match the 113-chapter
version of the Tantra of the Sun which I have used as the basis of
my study? Alternatively, which quotations are broken links (i.e.,
they do not match the 113-chapter version)?
*A Note on Sources: the txt files of the Tantra of the Sun and
Longchenpa’s Collected Works volumes 5-8 used as the basis for
this heatmap were downloaded from the Buddhist Digital Resource
Center (BDRC). I did not edit these texts, so there are a number
of orthographic and transcription errors that are either in the
manuscripts themselves or appear as a result of the OCR rendering.
Luckily, these errors do not impact the overall heatmap results,
so I have abstained from editing them for the time being.
If you wish to access a critical edition of the 113-chapter
version of the Tantra of the Sun, see my dissertation “Heart
Essence Literature Through Time: A Close Study of the Secret
Tantra of the Sun: Blazing Luminous Matrix of Samantabhadrī”
(Elaine Lai, Stanford University, 2024).
If you are unfamiliar with the tradition of Heart Essence, I
suggest reading the “Background” section below before turning to
the “Method” and “How to Use this Heatmap” sections. If you wish
to read about the Tantra of the Sun or the heatmap in greater
depth, see my dissertation for these details.
Primary Source Bibliography
For the Tantra of the Sun (which I abbreviate sometimes as KM2_113, or just KM2):
Kun tu bzang mo. “Kun tu zang mo klong gsal ’bar ma nyi ma’i rgyud (KM2_113).” In Snga ʼgyur Bkaʼ Ma Shin Tu
Rgyas Pa, edited by Tshe ring rgya mtsho, BDRC: MW1PD100944., volume 111 of 133:1–290. Chengdu: Si khron dpe
skrun tshogs pa si khron mi rigs dpe skrun khang, 2009.
For Longchenpa’s Collected Works (which I abbreviate sometimes as LS):
Klong chen Rab ʼbyams pa Dri med ʼOd zer. Snying thig ya bzhi. In Gsung ʼbum dri med ʼod zer. Dpal brtsegs
mes poʼi shul bzhag. Par gzhi dang po par thengs dang po [BDRC:MW1KG4884]. Vol. volume 5-8 of 26. 26 vols.
Pe cin: Krung go’i bod rig pa dge skrun khang, 2009. http://purl.bdrc.io/resource/MW1KG4884.
In the left-hand container the user will find the base text, the Tantra of the Sun, which corresponds to
KM2_113 (or just KM2), the 113-chapter version of the tantra. For the heatmap, I did not edit KM2, so the
version you find there is different from the critical edition of the tantra provided in the appendix of my
dissertation. I have segmented the tantra by chapter—113 chapters total—and directly embedded the page
numbers in the Wylie transliteration—[1] for page 1 and so forth, so that the user may easily refer to the
page number of the KM2 manuscript if they choose to.
In the right-hand container, the user will find Longchenpa’s Collected Works (LS) volume 5-8. This is the
dpal brtsegs version which contains 26 volumes in total, but the heatmap only includes volumes 5-8, the
volumes that correspond to the Heart Essence of the Ḍākinī and the Quintessence of the Ḍākinī, respectively.
It is important to remember that LS volumes 5-8 each contain many different texts and that not all of the
texts cite from the Tantra of the Sun. The scroll bar corresponds chronologically to the texts found in
volumes 5-8, from the first text in volume 5 to the last text in volume 8.
I have not labeled all the page numbers in these volumes, but I maintained the page breaks in the original
txt. files through a visual line break. Most often, when a text in LS cites from the Tantra of the Sun, it
will explicitly say: “From Luminous Matrix… it is taught,” but sometimes there may be quotation/paraphrasing
as
well, without referencing the title of the Tantra of the Sun. As already mentioned, the heatmap and my
analysis of its results account primarily for the explicit quotations of the Tantra of the Sun.
In the left-hand container of the tantra, the different highlighted sections represent passages in the
tantra that are cited somewhere in LS, volumes 5-8. The darker the orange highlight color, the more that
particular line or segment is cited. If the user hovers the mouse over the highlighted quotation and clicks,
a window will emerge to indicate where the line is cited. For example, clicking on the line “thig le’i chos
rnams ngo bor rdzogs…” the user will find two entries where the line is cited in Longchenpa’s Collected
Works: 1) Vol. 5, No. 4: brtags grol rgyud drug gi ti ka, 2) Vol. 6, No. 7: khregs chod ngo sprod mtha’ grol
klongs yangs bzhugs so. Clicking on either of these entries will lead the right hand window to scroll to
target.
For Longchenpa’s Collected Works (LS) corpus view on the right-hand side of the screen, there are the same
functions as the Tantra of the Sun view, except that there are different highlight colors: orange, grey, and
blue. Clicking on a highlight color in orange scrolls directly to the corresponding passage match in the
Tantra of the Sun. On the rare occasion where a quotation of the Tantra of the Sun in LS yields two
different
entries in the tantra on the left-hand side, the highlight color will be a slightly darker orange; clicking
on a darker orange will yield a menu entry showing the two different chapters of the Tantra of the Sun that
the quotation shows up in, and clicking on either entry will scroll to target.
A highlight color in gray means that the explicit quotation of the Tantra of the Sun does not match the
113-chapter version of the tantra. Gray quotations are therefore “broken links;” clicking on them will not
lead to the corresponding passage on the left side Tantra of the Sun-view since there is no corresponding
passage in existence.
There is one additional highlight color in the LS corpus view which is not present in Tantra of the
Sun-view: blue. Blue indicates a reference to the Tantra of the Sun, but not an explicit quotation of it.
Therefore, blue highlights, like the gray ones, will not lead to any corresponding passage in the Tantra of
the Sun-view since there are none.
Search function: The user may also use the search bar to run their own searches of certain phrases or words
in either of the textual collections. In the Tantra of the Sun container, the user can refine their search
to one of three choices: 1) anywhere (in the text), 2) correspondences, or 3) correspondences > 1.
Correspondences refer to any part of the Tantra of the Sun that is highlighted. Correspondences > 1 refer to
any portion of the Tantra of the Sun that has more than one match in the LS corpus, and thus would be of a
denser highlight. After pressing enter, if there is a corresponding match, the text will highlight the match
in a small green line on the left hand scroll-bar so the user can see where the line is in relation to the
cited passages in orange, and whether or not it intersects with already cited passages. In the right-hand
container, the user can refine the searches according to: 1) anywhere, 2) correspondences (orange
highlights), 3) references (blue highlights), or 4) untraced quotations (gray highlights).
Finally, the user may toggle “Use Tibetan Script Tibetan” in the upper left-hand corner if they wish to read
everything in Tibetan instead of Wylie.
Early Heart Essence: Heart Essence of Vimalamitra and the Seventeen Tantras
To tell the story of the Secret Tantra of the Sun: Blazing Luminous Matrix of Samantabhadrī, first we must
learn a little about the Heart Essence tradition (Tib. Snying thig) of Buddhism and an important Treasure
cycle called the Heart Essence of the Ḍākinī, which emerged in the fourteenth century, in Tibet. There are
two reasons for this: 1) the earliest citations of the Tantra of the Sun appear in the Heart Essence of the
Ḍākinī, and 2) the Tantra of the Sun was considered a major source text for the Heart Essence of the
Ḍākinī.
“Heart Essence” refers to a particular strain of Great Perfection (rDzogs chen) Buddhist teachings that
began to emerge in Tibet around the eleventh to twelfth centuries. According to one of the earliest Heart
Essence histories (lo rgyus), the Seventeen Tantras (rgyud bcu bdun) were the first Heart Essence teachings
to emerge in the world, along with another tantra called the Only Child of the Buddhas (Sangs rgyas sras
gcig). The Seventeen Tantras are scriptures thought to be preached by Buddhas in other realms. In all
Seventeen Tantras, the primary narrator is a masculine Buddha. The content of the Seventeen Tantras covers
various aspects of the Heart Essence ground, path, and fruition. The Heart Essence of Vimalamitra cites from
the Seventeen Tantras and contains texts devoted to the Only Child of the Buddhas.
Emergence of the Heart Essence of the Ḍākinī
In 1313, a figure named Pema Ledreltsel revealed a hidden Treasure (gter ma) called the Heart Essence of the
Ḍākinī. This new Heart Essence collection was similar to the earlier Heart Essence of Vimalamitra in many
ways, including its frequent citation of the Seventeen Tantras. However, unlike the earlier Heart Essence of
Vimalamitra, the Heart Essence of the Ḍākinī yoked an eighteenth tantra called the Secret Tantra of the Sun
to the canonical Seventeen Tantras, and positioned this new tantra as a supreme synthesis of all previous
Heart Essence tantras.
Importantly, unlike the Seventeen Tantras, the Secret Tantra of the Sun features a feminine Buddha,
Samantabhadrī, speaking to an audience of non-human feminine entities called ḍākinīs. For the first time
ever in the tradition of Heart Essence Great Perfection, here was a Buddhist scripture featuring an all
female cast! The significance of this all-female cast is mirrored in the histories associated with the Heart
Essence of the Ḍākinī where female figures like Yeshe Tsogyel and Princess Lhacam Pemasel came to occupy
pivotal roles in the transmission of Heart Essence teachings for Tibetans.
A Brief History of the Heart Essence of the Ḍākinī: Princess Pemasel and Padmasambhava
For this new Heart Essence tradition to gain legitimacy, it was necessary to show that both the Tantra of
the Sun, and its associated Treasure cycle, the Heart Essence of the Ḍākinī, could connect back to the
imperial period of Tibet (8th century), during the first wave of Buddhist scriptural transmissions from
India to Tibet. According to traditional histories that mention the Tantra of the Sun, the tantra was first
taught by the Buddha Vajradhara to Vajrapāṇi and Vajrasattva through a mind-to-mind transmission—a form of
direct knowledge transmission that is not bound to natural language. In the eighth century, the Tantra of
the Sun, along with the Seventeen Tantras, and their pith instructions Heart Essence of the Ḍākinī, were
transmitted from the Indian adept Śrī Siṃha to a yogi from Oḍḍiyāna named Padmasambhava. This transmission
took the form of symbolic means. Padmasambhava, or the “Lotus-born one” is of paramount importance to
Vajrayāna Buddhists, especially of the Nyingma lineage.
Traditional histories of the Heart Essence of the Ḍākinī teach us that when Padmasambhava first arrived in
Tibet in the eighth century under the invitation of King Trison Detsen, he realized that it was not yet the
appropriate time to spread the Heart Essence lineage he had received from Śrī Siṃha—Heart Essence of the
Ḍākinī. Instead, it was time for Vimalamitra’s Heart Essence teachings to spread.
Then, when King Trisong Detsen’s daughter Princess Lhacam Pemasel died at the age of eight, King Trisong
Detsen was grief stricken. Padmasambhava revived the Princess from the bardo and transmitted his precious
Treasure, the Heart Essence of the Ḍākinī, to her. Additionally, he made a prophecy that in a future life,
this young princess would become the foremost lineage holder of this Heart Essence Treasure and re-reveal it
when the time was ripe for this cycle to spread in Tibet. Then the princess passed on.
Among Padmasambhava’s most important disciples was the former Tibetan Queen, Yeshe Tsogyel. With Yeshe
Tsogyel’s help, Padmasambhava had the Seventeen Tantras plus the Tantra of the Sun, along with the Heart
Essence of the Ḍākinī committed to writing. The pair then buried these texts in different places, including
a Lion-like cave in Bumthang (Bhutan).
Six centuries after her premature death, Princess Pemasel was reborn as a man named Pema Ledreltsel
(1291-1315/1317). Pema Ledreltsel revealed the Treasure, Heart Essence of the Ḍākinī, and transmitted it to
his primary disciple Gyalse Lekden (rGyal sras legs pa, 1290-1366), who transmitted it to the Third Karmapa
Rangjung Dorje (Rang ‘byung rdo rje, 1284-1339), and perhaps even to Rinchen Lingpa (Rin chen gling pa,
1289-1368).
Longchenpa (Klong chen rab ‘byams pa, 1308-1364), an extremely prolific yogi and scholar, claimed to be the
next reincarnation of both the eighth century Princess Pemasel and the princess’s supposed reincarnation,
Pema Ledreltsel. However, the date of Longchenpa’s birth (1308) did not line up with the date of Pema
Ledreltsel’s death (1315/1317), which made his claim somewhat tenuous. Regardless of whether or not
Longchenpa is the true reincarnation of Princess Pemasel, by positioning himself as her reincarnation,
Longchenpa was able to claim authority as a lineage holder of the Heart Essence of the Ḍākinī Treasure
connected to the princess, and to Padmasambhava.
Longchenpa’s codification of the two Heart Essence streams–Vimalamitra’s and Padmasambhava’s–led to the
formation of the Fourfold Heart Essence which remains of tantamount importance to Nyingma practitioners
today. Although wide scale initiations of the Fourfold Heart Essence are still administered by Vajrayāna
teachers throughout the Buddhist world, we know very little about the contents of the Fourfold Heart Essence
or the history of these early Heart Essence traditions. This heatmap seeks to recover a snapshot of this
early history of the Heart Essence of the Ḍākinī, and the scripture–Tantra of the Sun–which became a
critical part of its own story and self-fashioning.
The goal of the heatmap is to trace the Tantra of the Sun’s reception in the Fourfold Heart Essence and to
determine to what extent the version of the tantra cited throughout Longchenpa’s Fourfold Heart Essence is
the same as the 113-chapter version.
“Citation/quotation” here means that there is a corresponding match when I run the search “klong gsal las”
(“From the
Luminous Matrix”) in LS–this denotes an explicit quotation from this tantra. In most of the cases, an
explicit quotation of the tantra is marked by “klong gsal las,” but sometimes there could be variations such
as “klong gsal nyi ma’i rgyud las” (“From the tantra of the Sun of the Luminous Matrix) or even “klong gsal
tan+tra las” (From the tantra Luminous Matrix) and so forth. “Reference” here means that the Tantra of the
Sun was referenced by its title, usually in the context of the transmission history of the Heart Essence of
the Ḍākinī, but it was not quoted from directly.
My method to document these explicit quotations of the Tantra of the Sun was simple. I ran the search “klong
gsal las” (“From Luminous Matrix….”) and its variations to find all the explicit quotations of the Tantra of
the Sun in LS. Because there were zero quotations of the Tantra of the Sun in the Heart Essence of
Vimalamitra or its commentaries, the final heatmap did not include the full Fourfold Heart Essence. All
quotations of the Tantra of the Sun occurred in the Heart Essence of the Ḍākinī and its commentary,
Quintessence of the Ḍākinī.
I arranged these matches in a csv file and then ran individual searches of each of these quotations in KM2
(the 113-chapter version of the Tantra of the Sun) to see if the explicit quotations of the Tantra of the
Sun
corresponded to any passages in the 113-chapter version of the tantra. To account for possible orthographic
differences and so forth, I manually ran the search of each quotation in a number of different ways, pasting
different portions of the quoted segment to see if a match to KM2 would emerge. I then documented every
instance of an exact match and also every instance of an approximate match. To find references to the Tantra
of the Sun, I ran the search “klong gsal ’bar ma” (Blazing Luminous Matrix), “nyi ma’i gsang rgyud” (Tantra
of the Sun) and “klong gsal rgyud” (Luminous Matrix Tantra) to see if this would yield results. Again, I
documented every reference on the csv file.
As I searched through KM2 to see if the quotations of the Tantra of the Sun found within LS5-8 corresponded
to any part of the 113-chapter version, I began to notice some patterns. For example, most of the quotations
that correspond to passages in KM2 are located in chapter 18 or chapter 101 of the tantra. Chapter 18 is the
longest chapter of the tantra, and chapter 101 is the vajra song summarizing the entire tantra.
Altogether, I found almost 400 explicit quotations of the Tantra of the Sun, and 16 references to the
tantra.
Around 68% of the explicit quotations of the Tantra of the Sun found in Longchenpa’s Heart Essence of the
Ḍākinī and Quintessence of the Ḍākinī match passages in the 113-chapter version. It is important to note
that there are likely more than 400 quotations of the Tantra of the Sun. Sometimes, when the texts in
Longchenpa’s Collected Works are citing another tantra, it will just say, “From the Tantra” (rgyud las…) or,
“As the former said,” (snga ma las…). In any of these instances, it is possible that the text from
Longchenpa’s Collected Works is citing from the Tantra of the Sun, or alternately, from another tantra.
For the purposes of this preliminary documentation of intertextuality matches between the 113-chapter
version and the Heart Essence of the Ḍākinī and the Quintessence of the Ḍākinī however, I did not feel that
the output from additional searches on “From the tantra,” or “As the former said,” would considerably change
the overall conclusion which is that the majority of explicit quotations of the Tantra of the Sun in the
Heart Essence of the Ḍākinī and the Quintessence of the Ḍākinī (LS5-8) correspond to passages in the
113-chapter version of the tantra. Therefore, I did not pursue these additional searches. However, I do
maintain that there are likely over 400 quotations of the Tantra of the Sun within Fourfold Heart Essence,
quoted explicitly or implicitly, some of which I cannot currently account for.
Acknowledgements
I would like to express deep gratitude to Aftab Hafeez and Simon Wiles for helping me to bring my initial
vision for this heatmap to fruition. Aftab’s passion for technology and his devotion to creating projects that
will be of benefit to others has been the motor behind so much of the labor involved in this heatmap,
including hours of painstaking troubleshooting together. Simon’s expert knowledge in coding as well as
Buddhism (a very rare combination indeed!) made him the ideal technical advisor for this project. Simon’s
ability to deconstruct and explain, step-by-step, how to build this website from scratch has been critical to
the completion of this project. Thank you both for working alongside me, and for many hours of joyful
exchange.
I completed this heatmap as part of my fellowship with Stanford’s CESTA (Center for Spatial and Textual
Analysis) in 2024. Thank you to my CESTA colleagues (Merve Tekgürler, Ellis Schriefer, Matthew Randolph, Kelly
Boles, Junyi Tao, and Anuj Amin) for your input and collegiality, and for helping me to think more broadly
about digital humanities.Thank you especially to the Director of the Digital Humanities Fellows, Nicole
Coleman, CESTA Faculty Director, Giovanna Ceserani, and CESTA Programs and Research Coordinator, Eyüp Eren
Yürek for creating such a supportive and intellectually stimulating space to discuss our work and to connect
with other scholars in the digital humanities.
Last but not least, thank you to my advisor James Gentry and to my friend and teacher Khenpo Yeshi for
bringing my attention to the Tantra of the Sun and advising me to translate this text.
You can visit the GitHub repo here.
Elaine Lai,
Creator
PhD in Religious Studies, Stanford University
COLLEGE Lecturer, Stanford University
Aftab Hafeez,
Frontend/Backend Engineer
Audio UX Research Engineer,
Google
Visiting VR Designer & Engineer, CESTA at Stanford
Simon Wiles,
Technical Advisor
Digital Scholarship Research Developer, Center for Interdisciplinary Digital Research (CIDR),
Stanford
University