<<

ARTICLE

https://doi.org/10.1038/s41467-021-24158-w OPEN Indispensable epigenetic control of thymic epithelial cell development and function by polycomb repressive complex 2

Thomas Barthlott1,8, Adam E. Handel 2,8, Hong Ying Teh1,8, Rushika C. Wirasinha3, Katrin Hafen1, Saulius Žuklys1, Benoit Roch4, Stuart H. Orkin 5, Jean-Pierre de Villartay 4, Stephen R. Daley3,7 & ✉ Georg A. Holländer 1,6 1234567890():,; Thymic T cell development and T cell receptor repertoire selection are dependent on essential molecular cues provided by thymic epithelial cells (TEC). TEC development and function are regulated by their epigenetic landscape, in which the repressive H3K27me3 epigenetic marks are catalyzed by polycomb repressive complex 2 (PRC2). Here we show that a TEC-targeted deficiency of PRC2 function results in a hypoplastic thymus with reduced ability to express antigens and select a normal repertoire of T cells. The absence of PRC2 activity reveals a transcriptomically distinct medullary TEC lineage that incompletely off-sets the shortage of canonically-derived medullary TEC whereas cortical TEC numbers remain unchanged. This alternative TEC development is associated with the generation of reduced TCR diversity. Hence, normal PRC2 activity and placement of H3K27me3 marks are required for TEC lineage differentiation and function and, in their absence, the thymus is unable to compensate for the loss of a normal TEC scaffold.

1 Department of Biomedicine and University Children’s Hospital of Basel, University of Basel, Basel, Switzerland. 2 Nuffield Department of Clinical Neurosciences, University of Oxford, Oxford, UK. 3 Infection and Immunity Program, Monash Biomedicine Discovery Institute and Department of Biochemistry and Molecular Biology, Monash University, Melbourne, VIC, Australia. 4 Genome Dynamics in the Immune System Laboratory, INSERM UMR 1163, Université de Paris, Imagine Institute, Paris, France. 5 Department of Pediatric Oncology, Dana-Farber Cancer Institute and Division of Hematology/ Oncology, Boston Children’s Hospital, Harvard Stem Cell Institute, Harvard Medical School, and Howard Hughes Medical Institute, Boston, MA, USA. 6 Department of Paediatrics and the Weatherall Institute of Molecular Medicine, University of Oxford, Oxford, UK. 7Present address: School of Health and Biomedical Sciences, Queensland University of Technology, Brisbane, QLD, Australia. 8These authors contributed equally: Thomas Barthlott, Adam E. Handel, ✉ Hong Ying Teh. email: [email protected]

NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications 1 ARTICLE NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w

he controlled balance between cell proliferation and dif- Cre recombinase is expressed under the control of Psmb11 reg- Tferentiation is essential to maintain a normal thymic ulatory elements25,26. The resultant Eedfl/fl::β5tCre mice displayed microenvironment to promote the development and a small thymus with a reduced total cellularity, a normal corti- selection of naive T cells with a repertoire purged of vital “self” comedullary segregation and a number of small, cell-free cysts specificities but prepared to react to injurious “non-self”. Thymic surrounded by cytokeratin 8-positive epithelia (Fig. 1a–d). epithelial cells (TECs), which can be categorized based on specific However, the total number of TEC recovered from these mice molecular, structural and functional characteristics into separate was similar to that of wild-type and Eedfl/fl mice (Fig. 1e). EED cortical (cTECs) and medullary (mTECs) lineages, are essential deletion resulted in the expected depletion of H3K27me3 marks for this competence1. Both TEC lineages derive from a common in all cTECs and the majority of mTECs isolated from Eedfl/fl:: epithelial precursor of endodermal origin2,3 that expresses a range β5tCre mice, whereas H3 abundance remained unchan- of cTEC-specific markers including the proteasome component ged (Fig. 1f and see below; gating strategy in Supplementary β5t encoded by Psmb114–7. Fig. 1). cTECs induce the commitment of blood-borne precursor cells Eedfl/fl::β5tCre mice had a higher frequency and cellularity of to a T cell fate, foster their subsequent growth and initial cTECs but a lower rate and reduced cell number of mTECs maturation, and select immature thymocytes that express a T cell (Fig. 2a). The difference was present at birth and steadily antigen receptor (TCR) with sufficient affinity for self-peptides increased with age. Noticeably, cTEC cellularity did not diminish presented by major histocompatibility complexes (pMHC). In in adolescent Eedfl/fl::β5tCre mice contrary to controls. Moreover, contrast, mTECs promote the terminal differentiation of thy- the maturation of mTEC was compromised in Eed:fl/fl:β5tCre mocytes, which includes the establishment of immunological mice with fewer immature epithelia (MHCIIlo, AIRE−, designated tolerance to tissue-restricted antigens (TRAs) via two com- mTEClo) attaining a mature (MHChi; mTEChi) cell stage, either plementary mechanisms; a recessive activity of deleting thymo- positive or negative for the expression of AIRE (Fig. 2b). cytes expressing a TCR with high affinity for these antigens, and a Heterozygosity for a loss of Eed did not compromise thymus dominant mechanism of clonal diversion that generates thymic cellularity nor affect TEC numbers or subset composition regulatory T cells8. In addition, thymus immigrating dendritic (Fig. 2c). The proliferation rates of both cTEC and mTEC were cells (DCs) and B cells provide peripheral antigens for central significantly reduced in Eedfl/fl::β5tCre mice (Fig. 1h and tolerance induction9–11. Supplementary Fig. 1) rendering it an unlikely explanation for The ectopic representation of a significant number of TRAs by a the disparity in cTEC:mTEC ratios. Thus, the loss of PRC2 subpopulation of phenotypically mature mTECs is in part depen- activity (consequent to an absence of either EED or EZH1/2; dent on the expression of the transcriptional facilitator autoimmune Supplementary Fig. 2) resulted in an expansion of cTECs but a regulator (AIRE)12, which acts independently of lineage-specific reduction in mTECs. One possible explanation for this finding factors13. Individual mTECs express AIRE-dependent could be that TEC precursors are preferentially differentiating TRAs to an extent significantly lower than that of corresponding into the cTEC lineage. peripheral tissues14,15 and in co-expression patterns that change with mTEC maturation16–19. AIRE limits the amplitude of TRA gene expression by repressing accessibility at distal cis- T cell differentiation in Eedfl/fl::β5tCre mice is affected at early regulatory sequences20. These regions, ostensibly placed within and late stages. We next evaluated the thymopoiesis of 3-week- facultative , are enriched in the repressive histone old Eedfl/fl and Eedfl/fl::β5tCre mice (Supplementary Fig. 3a, b). In mark, H3K27me3, and depleted for histone modifications permis- the absence of EED, the proportion of cells in the CD4−CD8− sive for conventional gene transcription8. double-negative (DN) thymoycte compartment increased 3–4- H3K27me3 is a posttranslational modification catalysed by fold (2.5 ± 0.4% vs. 8.1 ± 0.9%; Fig. 3a). This relative increase was polycomb repressive complex 2 (PRC2) that depends for its mainly due to the presence of B cells although their absolute function on four core factors, including EED (embryonic ecto- numbers were not altered (4.8 ± 0.6 × 105 in Eedfl/fl::β5tCre and derm development), which is critical for physically binding to 3.2 ± 1.3 × 105 in Eedfl/fl). The relative number of early thymic H3K27me3, and both EZH1 and EZH2 (enhancer of zeste progenitors (ETP, defined as DN CD44hickithiSca-1posCD25−) homologue), which mediate the trimethylation of H3K2721,22. and DN2 (DN CD44hickithiSca-1pos CD25+) cells in relation to Compromised gene repression due to a loss of PRC2 activity23 all thymocytes of the αβ T cell lineage (i.e. excluding cells positive impairs tissue specification and maintenance, and consequently for TCRγδ, CD19, CD11b, CD11c, DX5, NK1.1, Gr1, F4/80, results in early embryonic lethality24. Ter119 and MHCII) was comparable in mutant and wild-type To establish a specific role for PRC2 in TEC development and mice (Fig. 3b and Supplementary Fig. 3a). We observed, however, function, we analyse mice with a loss of this complex targeted to a partial block at the DN3 (i.e. DN CD44−CD25+) β-selection TEC precursors and occurring after the formation of the thymus checkpoint. Compared to DN2 cells, DN3 thymocytes exhibited anlage. Absent PRC2 activity in TEC leads to an impairment in an almost 2-fold reduction in CD25 expression, which was par- canonical TEC development and function whilst in parallel an alleled by a significant reduction in the frequency of CD71+ pre- alternative mTEC differentiation pathway emerges. These double-positive (preDP) thymocytes in the ckitneg DN sub- abnormalities are associated with reduced TCR diversity in the population (27.5 ± 2.1% vs. 38.7 ± 2.8). The progression through CD4+ and CD8+ naive T cell pools, yet negative selection of self- subsequent maturation stages (i.e. CD71+CD8+ immature single- reactive TCR specificities remained intact. Taken together, we positive (ISP) and CD71+DP) was, however, not affected in conclude that PRC2 activity is essential for TEC lineage specifi- mutant mice (Fig. 3c). Hence, these results indicate a partial block cation and function. at the β-selection checkpoint caused by an EED deficiency in TEC. Whether the reduction in CD25 expression in DN3 is causally linked to the observed decrease in the generation of Results preDP thymocytes remains to be determined. Loss of EED in TEC differentially disrupts lineage develop- We next analysed positive selection into the single-positive ment. To generate mice with a loss of PRC2 activity in all thymic (SP) thymocytes. Although the frequencies of positively selected epithelia at a time after initiation of a thymus anlage, we interbred DPdull cells were unchanged, we detected in Eed:fl/fl:β5tCre mice animals harbouring a conditional Eed allele to mice in which the an accumulation of both CD8SP and CD4SP (Treg excluded)

2 NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w ARTICLE

ab cEedfl/fl Eedfl/fl::β5tCre *** fl/fl ) *** 8 Eed 3. 5 *** 3 Eedfl/fl:: *** 2.5 *** β5tCre 2 *** fl/fl l ularity (x10 1. 5 Eed :: β 1 *** 5tCre 0. 5 0 Eedfl/fl

Thymus ceThymus l 014 2mm 200µm 200µm Time (weeks)

d e Eedfl/fl Eedfl/fl::β5tCre

*** ) l ***

f

5

/

) l *** *** *** f 4 8

d

%

(

e

**

e ( fl/fl

y E

r ***

i Eed

c 6

3 y

t

A

i n

0.15 r

e 8 fl/fl

±0.05 a

l u Eed :: K 2 4

u q

l

C ***

5 l β e

e

10 5tCre r

r

e

f

4

c

C 0

1 2 4 1 t 10

C 0

K 5

C 7

E β

C

E

: 3

T A

: 10

l 0

0 Tx10

f

/

l 5 f 014

2 014 4

d 10 e

D 0 2.81 Time (weeks) Time (weeks) E C ±0.63 I 010102 3 104 105

P

A EpCAM

D

e PerCp-Cy5.5

r

i

A

8

K

C

4

1

K

C

f cTEC mTEC CD45+

H3K27me3

x

a

M

% 0103 104 105 Total H3

Eed fl/fl Eed fl/fl::β5tCre IgG control

Fig. 1 Thymus phenotype of Eedfl/fl::β5tCre mice. a Absolute thymus cellularity of mutant (grey diamonds) and control mice (black circles) at the indicated postnatal ages (week 0 relates to newborn). b Macroscopic and c microscopic comparison of thymic lobes isolated from 4-week-old Eedfl/fl:: β5tCre and control Eedfl/fl mice. Scale bars represent 2 mm and 200 µm, respectively. Tissue sections were stained with haematoxylin and eosin. d Immunohistology of thymus sections prepared from 4-week-old Eedfl/fl and Eedfl/fl::β5tCre mice and stained for cytokeratin (CK) 8 (green, a cTEC marker), CK14 (red, an mTEC marker), AIRE (blue) and DAPI (grey; only in lower panels). Scale bars represent 50 µm. e Relative frequency and absolute cellularity of TEC isolated from Eedfl/fl::β5tCre (grey diamonds) and control Eedfl/fl mice (black circles) at indicated ages. Contour plots show representative flow cytometric analyses of thymic single-cell suspensions of 4-week-old mice, the gating for TEC and their relative frequencies. f Detection of H3K27me3 marks and protein in mTEC, cTEC and CD45+ cells isolated from Eedfl/fl::β5tCre and Eedfl/fl mice at 4 weeks of age. Isotype control stains for Eedfl/fl mice are indicated as IgG control. Data in graphs (a, e) represent mean and standard deviations (SD) and are pooled from independent experiments: week 0: n = 3, week 1: n = 7, week 4: n = 6; *p < 0.05, **p < 0.01, ***p < 0.001 (two-tailed unpaired Student’s t test). Asterisks in red indicate comparisons between Eedfl/fl::β5tCre and Eedfl/fl mice, whereas black and grey asterisks compare results from identical mouse strains at different time points. Data in (b– d, f) are representative of two independent experiments with n = 3 mice each per strain investigated. n = biologically independent replicates per group. The gating for thymic epithelia is displayed in Supplementary Fig. 1. Source data including exact statistical test values are provided in the Source Data file.

NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications 3 ARTICLE NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w

a ) b *** ** 4 ** ** * ** 100 60 * mTEC * 80 15.3 ±1.0 100 *** 40 TEC 60 ***

l

f ellularity (x10

/ l 75 10.7 40 * f 33.6 cTEC (%) *** C 20 ±2.9 d ±2.0

l

f

/

e l ***

f

C *

E

d 20

e 50.8 ±2.7 50

E 0 cTE 0 fl/fl

014 014 7 Eed 5 8.0 ±0.8 86.2 y 10

Time (weeks) Time (weeks) e 25

C r

±3.2 Subset of cells (%) /

) fl/fl C

4 Eed :: 4 ***

e C 5 *** ** ** t 10 r 10

7 ** *** * 5 74.7 100 50 *** P

10 β y C 5tCre

β 7.7 t 4 ±4.5 A

: 0

10 - C (x

: 3 5

l ±1.7 fl/fl fl/fl I

- 10

f / I Eed Eed 80 l :: y

β 40 3 f

t E

: 10 ***

:

d l C β

f 0 P

/ 5tCre e l 83.6 ±2.4

f 2 H

10 60 lari 30

1 E

d *** hi + 5 M mTEC Aire e 0 y 0103 10 4 10 5 hi - E 13.8 40 20 L mTEC Aire ±4.3 mTEC (%) ** *** Aire eF660 lo 2 3 4 5 mTEC 01010 10 10 20 Ccellu * 10 UEA1 Cy5 0 0 014 mTE 014 Time (weeks) Time (weeks)

c 3.5 0.15 2.5 15 100 40 80 8 hi 10 3 x 2 80 2.5 30 60 0.1 5 10

10 1.5 60

2 x in mTEC

in mTEC 40 hi 20 hi 1.5 % TEC 1 40 0.05 TEC 5 1 10 20 % cTEC in TEC 0.5 % mTEC in TEC 20 % mTEC 0.5 % CD40 Thymus cellularity 0 0 0 0 0 0 0 e le fl/wt male male female Eed female fl/wt male fema Eed ::β5tCre female femal male Eed fl/fl male

d in TEC in mTEC *** 0.8 *** 4 100 *** ** 0.7 0.6 80 5 3 0.5 1

60 y

% *** *** t 0.4 i

r 2 ***

a % TEC %

0.3 40 l ***

u

l l

0.2 e 1 0.1 20 Cx0 0 0 0 cTECmTEC mTEClo mTEChi TECcTEC mTEC mTEClo mTEChi

cTECmTEClo mTEChi 25 Eed fl/fl ** fl/fl::β 20 Eed 5tCre

7.9 8.5 20.3 + 15 *** 10 ** % BrdU 1.5 2.5 11.8 5 # Cells 0 0103 104 105 cTECmTEClo mTEChi BrdU APC mature cells with a CD69−CD24− phenotype (CD8SP: 56.5 ± circulation from the periphery back to the thymus (Fig. 3e). 2.5% vs. 41.8 ± 2.6%; CD4SP: 45.4 ± 4.3% vs. 28.5 ± 0.5%, Fig. 3d, Within that CD24− subset, the frequency of re-circulated e). Both lineages displayed a normal progression from DPdull to peripheral T cells with a CD44+ phenotype (excluded from the CD69+CD24+ immature SP stages, suggesting that the relative above analysis) was significantly increased in Eedfl/fl::β5tCre mice, increase of mature CD24− SP was caused by retention in the especially among CD8SP cells (CD24−CD8:+ 16.4 ± 5.3% vs. 3.5 thymus and not by an altered developmental transition. Although ± 0.8%; CD24−CD4+: 2.7 ± 0.5% vs. 1.2 ± 0.2%, Fig. 3f and + the overall frequency of Foxp3 Treg cells within CD4 SP Supplementary Fig. 3b). Hence, the absence of PRC2 function in thymocytes was only marginally, yet significantly elevated in TEC caused an accumulation of specific SP thymocytes. mutant mice, their phenotype was severely skewed towards a Next, we characterized the negative selection of CD4 lineage CD24−CCR7lo expression pattern (67.4 ± 5.0% vs. 28.9 ± 3.2%) thymocytes. The first wave of negative selection within the cortex indicative of extended residence of cells in the medulla and/or re- (as identified by the co-expression of Helios and PD1 on Foxp3−

4 NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w ARTICLE

Fig. 2 TEC phenotype of Eedfl/fl::β5tCre mice. a Quantification of cortical (CD45−EpCAM+Ly51+UEA1−) and medullary (CD45−EpCAM+Ly51−UEA1+) TEC subpopulations isolated from mice with the indicated genotype. Representative contour plots are from 4-week-old mice, frequencies and absolute cell numbers of cTEC and mTEC are from mice with the indicated genotype (Eedfl/fl::β5tCre: grey diamonds, Eedfl/fl mice: black circles) at ages shown (week 0: n = 3, week 1: n = 7, week 4: n = 6). b Flow cytometric analysis of mTEC from 4-week-old mice for MHCII and AIRE expression. Representative contour plots and bar graphs displaying the frequencies of individual subpopulations (mTEC:lo white bars black circles, mTEChiAIRE:− light grey bars black diamonds, mTEChi AIRE:+ grey bars black triangles) for each of the indicated genotypes (n = 5). c Quantification of total and TEC cellularity and determination of TEC subset distributions in Eedfl/wt::β5tCre and control mice. Data are pooled from two independent experiments with female (n = 4 Eed: fl/wt:β5tCre: light grey bars with grey diamonds, n = 4 Eed:fl/wt black bars with grey circles) and male mice (n = 6 Eedfl/wt::β5tCre: light grey bars with white diamonds, n = 2 Eed:fl/fl black bars with white circles) at 4–6 weeks of age. Cellularities are displayed for each sex separately, TEC subset frequencies are pooled. d TEC subset frequencies, cellularities and proliferation in 4-week-old Eedfl/fl::β5tCre (n = 3, white bars with grey diamonds) and Eedfl/fl mice (n = 3, grey bars with black circles). Representative histograms showing BrdU incorporation and frequencies of BrdU-positive cTEC and mTEC subsets. Datain graphs represent mean and standard deviations (SD) and are pooled from independent experiments (a, c) or display one experiment representative of two independent experiments (b, d). Contour plots (a, b) and histograms (d) are representative of data in bar graphs. The gating for thymic epithelia is displayed in Supplementary Fig. 1. n = biologically independent replicates per group. *p < 0.05, **p < 0.01, ***p < 0.001 (two-tailed unpaired Student’s t test). Asterisks in red indicate comparisons between Eedfl/fl::β5tCre and Eedfl/fl mice, whereas black and grey asterisks compare results from identical mouse strains at different time points. Source data including exact statistical test values are provided in the Source Data file.

and CCR7− TCR+ DP or CD4SP thymocytes) was undisturbed of TCRα clonotypes bearing these motifs varied by the absence of EED in TEC (Fig. 4a). The second wave, which between T cell lineages33–35 but did not differ significantly takes place in the medulla and is characterized by Helios expression between mutant and control samples (Fig. 5b, c). Except for a on Foxp3− CD4SP thymocytes27, was reduced (CD24+: 4.1 ± 0.4% distal shift in Traj segment usage by DP thymocytes in mutant vs. 6.6 ± 0.6%; CD24−: 2.5 ± 0.3% vs. 3.4 ± 0.4%, Fig. 4b). This mice, Trav and Traj gene segment usage and CDR3 length dis- reduction correlated with both lower CD5 expression on SP tributions were comparable to controls (Supplementary Fig. 5). thymocytes (Fig. 4c) and significantly fewer apoptotic cells present This shift in Traj may reflect a longer sojourn in the cortex due to in the Helios-positive subsets (Fig. 4d) suggestive of having received the presence of a larger cTEC scaffold relative to the thymocyte TCR-mediated signals of too low avidity to commit to programmed pool in EED-mutant mice. Whereas the diversity of the pre- cell death28. In contrast, we observed no differences in thymocyte selection and wave 1 TCRα repertoires was normal, the CD4SP selection and maturation in Eed:fl/wt:β5tCre mice indicating that the and CD8SP TCRα repertoires selected by EED-deficient TEC presence of one Eed allele in TEC is sufficient to instruct regular T showed a 2-fold lower diversity than controls (Fig. 5d, e). These cell development (Fig. 4e). results indicate that EED deficiency did significantly narrow the Under physiological conditions, apoptotic cells are rapidly TCRα repertoires of CD4SP and CD8SP thymocytes. engulfed and cleared by thymic macrophages (Mø)29 and 30 conventional Type 1 DCs (cDC1) . Thymus immigrating DCs fl/fl Increased frequency of activated Treg cells in Eed ::β5tCre and B cells can also provide peripheral antigens for central fl/fl β tolerance induction9–11. We therefore determined the frequencies mice. The peripheral T cell compartment of Eed :: 5tCre mice of thymic Mø, B cell and DC subsets in control and Eedfl/fl:: demonstrated a T cell lymphopenia, equally affecting CD4 and β5tCre mice and found that their relative frequency was CD8 T cells, (Fig. 6a, b). This resulted in a reduced frequency of significantly increased in mutant animals (Supplementary Fig. 4). naive and an expansion of central and effector memory T cells (Fig. 6c). Naive T cells from Eedfl/fl::β5tCre mice neither showed a Increased Mø and cDC1 frequencies also indicated effective fi removal of apoptotic cells11,30,31 thus providing a cellular de ciency in proliferation nor IL-2 production in response to mechanism for the reduced detection of cells having received CD3 mAb and co-stimulatory signals (Fig. 6d). negative selection signals. In addition, the relative increase in B We next determined the frequency and activation state of Treg cells. In comparison to controls, mutant mice showed a cells and thymus immigrating DCs could compensate for defects fi in selection mechanisms by PRC-deficient mTECs. Thus, the signi cant increase in the frequency of Treg among CD4 cells frequency of detectable negatively selected thymocytes was (Fig. 6b) with a larger proportion of these cells displaying an significantly reduced in the medulla, but not the cortex, of activated phenotype, as revealed by a higher frequency of cells Eedfl/fl::β5tCre mice. negative for CD62L (Fig. 6c) and positive for CD103 and/or ICOS (Fig. 6e). In comparison to control mice, peripheral Treg cells from Eedfl/fl::β5tCre mice exerted a higher potency suppressing The TCR repertoire in single-positive thymocytes of Eedfl/fl:: β in vitro the proliferation of mitogenically activated CD4 effector 5tCre mice is narrowed. We extended the analyses of thymo- cells (Fig. 6f). Taken together, these findings indicate that the cyte selection by characterizing the TCR repertoire selected in the fi fl/fl β β increased frequency and higher suppressive capacity of Treg cells presence of EED-de cient TEC. Eed :: 5tCre and 5tCre in Eedfl/fl::β5tCre mice likely control a dysregulated immune (CD45.2) mice were transplanted with T cell-depleted bone response as a result of either by lymphopenia or self-reactivity. marrow cells from mice transgenic for the YAe62 TCR β chain (TCRVb8.2)32. Donor-derived (CD45.1) thymocytes at distinct developmental stages (see Supplementary Fig. 5a) were isolated Eedfl/fl::ZsGreen::β5tCre mice contain mTEC with PRC2 4 weeks after transplantation and their TCRα chain repertoire activity. TEC isolated from Eed:fl/fl:β5tCre mice contained, as was sequenced. Each T cell lineage showed a high degree of TCRα noted above (Fig.1f), a subpopulation that had escaped gene repertoire overlap between mutant and control samples, and the deletion and thus maintained its H3K27me3 marks. These “EED T cell lineages were equally distinct from each other regardless of escapees” were predominantly mTEC, a finding that was also the PRC2-deficiency (Fig. 5a and Supplementary Fig. 5). Certain observed in Ezh1ko::Ezh2fl/fl::β5tCre mice (Supplementary Fig. 2). amino acid doublets and cysteine promote T cell self-reactivity This result was unexpected as Cre expression under the Psmb11 when present at the apex of the complementarity-determining transcriptional control targets >99.5 % of all mTECs26.To region 3 (CDR3) of the TCRα or TCRβ chain33–35. The frequency exclude a lack of Cre activity as an explanation for the detection

NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications 5 ARTICLE NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w

a b c fl/fl Eed fl/fl Eed fl/fl::β5tCre Eed fl/fl Eed fl/fl::β5tCre Eed Eed fl/fl::β5tCre live cells DN T cell precursors CD8 + CD4 - 105 5 5 9.6 9.5 10 1.35 1.55 10 79.8 104 84.3 104 104 2.7 3 22.1 19 103 103 10 8.1 0 102 ckit APC 0 2.6

3.3 0 98.7 98.4 CD24 FITC 3 4 5 01010 10 0103 104 105 0103 104 105

CD4 PE-eFluor610 CD8 A700 CD25 BV605 TCRβ PE DN ckit + TCR - 5 10 105 105 CD8_ISP 28.2 23.3 4 10 4.5 57.3 104 104 103 93 3 3 41.4 10 10 98.2 95.3 102 71.8 76.7 102 0 0 ETP 0 Sca-1 BV510 DN2 CD71 PE-Cy7 CD19 APC-Cy7 3 4 5 010 10 10 0103 104 105 0 50 100 150 200 250 TCRβ PE CD25 BV605 FSC-A (K) - DP B cells ckit 5 5 10 10 + DN in DN preDP 14.4 13.4 CD71 104 39.4 26.9 104 10 *** 70 *** 103 103 60 8 102 DN3 102 50 0 7.7 52.6 9.2 62.1 0 CD71 PE-Cy7 CD71 PE-Cy7 % 6 % 40 0103 104 105 0103 104 105 CD25 BV605 TCRβ PE 4 30 20 ETP in in ckit + in ckit - maturation progression 2 T cell lineage after β selection 10 1.4 0.01 100 70 ** ** 100 0 0 60 1.2 0.008 80 50 ** 1 80 Eed fl/fl:: % 0.006 % 60 %40 0.8 60 Eed fl/fl ** β5tCre 30 0.6 % 0.004 40 40 20 0.4 0.002 20 10 ratio CD25 gMFI 0.2 20 0 0 0 - 0 ETP DN2 DN3 pre CD71 DN3 0 - DP CD25 in P in DN2 P + DP SP &IS D reDP in _I P + 1 p &preDP8 D e pr DN3 CD CD71 ISP&CD7

d fl/fl fl/fl e fl/fl fl/fl f re-circulated Eed Eed ::β5tCre Eed Eed ::β5tCre - Foxp3+ in CD4 in CD24 SP DP + - CD4 CD8 10 *** 5 25 10 5 10 4.9 4 4.43 3.63 4.9 10 4 8 20 10 3 * 10 3 6 10 % %15 0 0 Foxp3 PE 4 CD69 PE-Cy7 94.4 10 3 4 5 94.1 010 10 10 0103 104 105 TCR Bio/SA-BV650 2 5 *** + + CD25 BV605 CD69 TCR 0 5 10 0 + lo + CD4 CD8 4 CD8 CD4 10 Foxp3 CD4 - + 13.7 CD24 in Foxp3 3 11 5 10 10 dull 70.1 29.8 80 2 DP 4 *** 10 10 0 86.2 88.7 CCR7 BV421 103 3 4 5 010 10 10 60 TCR Bio/SA-BV650 102 % CD24 FITC 0 28.8 69 concatenated 0102 103 104 105 40 CD8+CD4lo & CD8+CD4- CCR7 BV421 5 10 20 + 4 CD24 - 10 55.3 Foxp3 CD4 39.6 3 5 10 10 0 - 70 2 CD24 4 48.7 10 10 CD24 FITC 0 60.2 44.4 3 10 0103 104 105 2 10 29 50.6 maturation progression CD69 PE-Cy7 - - CD24 FITC 0 CD24 Foxp3 CD4 in Foxp3- CD4 0102 103 104 105 dull maturation 70 70 *** DP CD69 PE-Cy7 in DP progression in CD8 60 *** 60 CD24+ 50 50 *** *** 10 60 5 *** 10 40 % 40 + % 50 4 CCR7 8 10 30 47.9 52 30 3 40 10 20 20 6 CCR7- % % 2 30 10 10 10 0 51.2 47.2 4 CCR7 BV421 0 - + - 3 4 5 0 - + - 20 010 10 10 in - in 7 4 - in + 7 2 TCR Bio/SA-BV650 4 10 CCR CD2 CCR7 ll - + &CD24 CCR7u &CCR7 &CCR d CCR7 CD2 0 0 + - P + in - in D 24 CCR7 CCR7

+ &CD24 CD24&CD dull CD24 DP CD24 of mTEC with regular H3K27me3 marks, we next generated Eedfl/ loss of ZsGreen expression coincided with the detection of fl β H3K27me3 marks in 93.2 ± 2% of all TEC, whereas the vast ::ZsGreen:: 5tCre mice where ZsGreen expression depends on + the Cre-mediated removal of a floxed stop-cassette 5ʹ of the majority of ZsGreen TEC lacked H3K27me3 (97.4 ± 0.6%; transgenic reporter. In these mice, 98.6 ± 0.3% of all cTEC, yet Fig. 7b) although their total histone H3 abundance was com- only 80.3 ± 5.6% of all mTEC expressed ZsGreen (Fig. 7a). The parable (Fig. 7c). Furthermore, H3K27me2 median fluorescence

6 NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w ARTICLE

Fig. 3 EED-deficient TEC affect thymocyte development at early and late stages. a Distribution of B cells and T lineage precursors within DN cells. b Quantification of ETP, DN2, DN3 and preDP subsets within DN T cell precursors. c Analysis of maturational progression from CD8 ISP to CD71pos DP thymocyte stages. Characterization of the developmental progression within CD8 (d) and CD4 lineage (e) selected thymocytes. f Quantification of re- circulated peripheral T cells within mature CD24neg SP subsets. Representative flow cytometry contour plots are shown, bar graphs display mean values with SD together with individual data points from n = 4 Eedfl/fl and n = 3 Eedfl/fl::β5tCre mice (a–c)orn = 6 Eedfl/fl and n = 9 Eedfl/fl::β5tCre mice (d–f)at 3 weeks of age. *p < .05, **p < .01, ***p < .001 (two-tailed unpaired Student’s t test). Data in bar graphs are from one experiment representative of three independent experiments. Eedfl/fl::β5tCre: white bars with grey diamonds, Eedfl/fl grey bars with black circles. n = biologically independent replicates per group. *p < 0.05, **p < 0.01, ***p < 0.001 (two-tailed unpaired Student’s t test). The gating for thymocyte subsets is displayed in Supplementary Fig. 3. Source data including exact statistical test values are provided in the Source Data file.

was drastically reduced in ZsGreen+ but not ZsGreen− mTEC For example, genes encoding proteins involved in the immuno- subsets (mTEClo: ZsG+ 8.5 ± 3.0%, ZsG− 30.1 ± 23.5%, control proteasome were expressed at lower copy numbers in the absence 38.6 ± 16.0%; mTEChi: ZsG+ 13.7 ± 5.2%, ZsG− 115.6 ± 28.6%, of EED (ZsGreen-positive vs. Eedfl/fl::ZsGreen: 1.58-fold, p < control 100 ± 19.6%; Fig. 7d, left panels). In addition, the lack of 0.002; ZsGreen-positive vs. ZsGreen-negative: 2.66-fold, p < EED correlated with a 2-fold reduction in EZH2 fluorescence 0.002; Fig. 8b, c). Endopeptidase activity was particularly marked (cTEC: ZsG+ 6.8 ± 1.5%, control 14.2 ± 5.2%; mTEClo: ZsG+ in the ZsGreen-negative mTECs, with the highest expression of 10.2 ± 2.9%, control 18.6 ± 2.0%; mTEChi: 46.1 ± 4.2%, control 12 components of the proteasome seen in these cells. Conversely, 100 ± 4.5%; Fig. 7d, right panels). However, a minor fraction of ZsGreen-positive mTECs had elevated expression of genes within ZsGreen+ and H3K27me3+ TEC were detected (1.9 ± 0.8%; pathways regulating transcriptional activity related to cellular Fig. 7b) that were predominantly mTEC but displayed lower stress, such as Fosb and Jun (Fig. 8c). Moreover, genes that were amounts of ZsGreen (Fig. 7b). This phenotype is compatible with differentially expressed between ZsGreen-positive and either promiscuous β5tCre expression in “EED mTEC escapees”. Hence, ZsGreen-negative or Eedfl/fl mTECs were also enriched within most H3K27me3+ “EED escapees” must be the progeny of rare molecular pathways associated with antigen processing and pre- TEC progenitors that do not express Cre. sentation (Supplementary Fig. 7). These results suggested a defi- Eedfl/fl::ZsGreen::β5tCre mice provided an opportunity to ciency in normal antigen processing in the absence of EED compare in the same thymus ZsGreen-positive EED-deficient expression along with upregulation of pathways indicative of and ZsGreen-negative EED-proficient TEC (aka “EED escapees”). cellular stress. ZsGreen-negative cTEC had a reduced Ly51 and MHC class II expression, thus providing a phenotype distinct from that of Differential gene expression in EED-deficient and EED- ZsGreen-positive cTEC (Fig. 7f). mTEC and the contingent of proficient mTEC of Eedfl/fl::ZsGreen::β5tCre mice. mTEC sub- mature mTEChi demonstrated markedly reduced frequencies in populations provide an almost complete molecular representation the absence PRC2 activity in contrast to corresponding cells + of TRAs with some of them being expressed at low frequency and among “EED escapees” (Fig. 7e). The frequency of CD40 EED- 8 + in low copy number . This capacity is aided by the transcriptional deficient mTEChi remained unchanged but that of AIRE cells facilitator AIRE, which promiscuously regulates the expression of was reduced when compared to controls (Fig. 7g). The genes marked at their transcription start site (TSS) by maturational progression of EED-deficient mTEC thus progres- H3K27me38. We therefore determined at single-cell resolution sively declined, whereas that of “EED escapees” was comparable whether EED-deficient and -proficient mTECs from Eedfl/fl:: to control mTEC. Both ZsGreen-positive and -negative mTEC β fl fl ZsGreen:: 5tCre mice maintained their normal transcriptional were uniformly distributed throughout the medulla of Eed / :: programmes. Single-cell analysis of cTECs showed a clear ZsGreen::β5tCre mice, yet the latter cell type occasionally formed separation between EED-deficient and Eedfl/fl cells based on small cell clusters (Fig. 7h). Taken together, these results are changes in transcripts associated with antigen processing and compatible with the notion that EED-proficient mTEC had most presentation (including Psmb11 and Ctsl; Supplementary Fig. 8). likely arisen via a non-canonical differentiation path unrelated to Significant differences were observed in the clustering centroids ineffective Cre recombination. of each of the three separate mTEChi populations analysed (all p < 0.05), further supporting the notion that EED-proficient EED-competent mTEC in Eedfl/fl::β5tCre mice represent a mTEC in Eedfl/fl::ZsGreen::β5tCre mice represent the emergence novel, non-canonical mTEC differentiation pathway. In wild- of a non-canonical mTEC lineage (Supplementary Fig. 9). type mice, mTECs are derived from progenitors that express Integration with existing single-cell mTEC transcriptomic Psmb1126. To test the hypothesis that “EED escapees” constitute a datasets enabled us to further delineate mTEC differentiation in separate lineage, we next compared the transcriptome of EED-deficient and -proficient mTEChi (Fig. 9a, b)36,37. EED- ZsGreen-positive EED-deficient and ZsGreen-negative EED- deficient mTEChi from Eedfl/fl::ZsGreen::β5tCre mice were proficient mTEChi. A principal component analysis of the gene diverted away from mature mTEC into an immature, intertypical expression profiles identified three distinct clusters with “EED TEC phenotype (Fig. 9c, left and middle panel). Conversely, EED- escapees” mTEChi grouping separately from EED-deficient and proficient mTEChi from Eedfl/fl::ZsGreen::β5tCre mice were able Eedfl/fl::ZsGreen mTEChi, suggesting that ZsGreen-negative EED- to differentiate into mature mTEC similarly to Eedfl/fl mice but proficient cells either represent a distinct, non-canonical TEC with a significant expansion of intertypical TEC (Fig. 9c, right lineage or a distinct differentiation pathway ending in a similar, panel). We used gene-regulatory network inference to identify but nonetheless transcriptomically distinct, medullary compart- networks driving differences in mTEC ment (Fig. 8a). Both ZsGreen-positive and -negative mTECs differentiation and found Ascl1 and Irf7 network expression showed marked transcriptomic differences to Eedfl/fl::ZsGreen was significantly increased in EED-deficient mTEChi (Fig. 9d). mTECs (518 and 305 genes, respectively, significant at FDR < Jun and Fos network expression was specifically elevated in EED- 0.05). There were also transcriptomic differences between proficient mTEChi from Eedfl/fl::ZsGreen::β5tCre mice relative to ZsGreen-positive and -negative mTECs (664 genes, significant at Eedfl/fl mice (Fig. 9e). This confirmed that EED-deficiency FDR < 0.05; Supplementary Fig. 6 and Supplementary Data 1–3). diverted mTEC differentiation towards a more immature

NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications 7 ARTICLE NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w

a CCR7- Foxp3- TCR+ b CCR7+ Foxp3- CD4 SP excluded CD4SP CD24+ CD24- 0.14 1 10 0.09 0.54 fl/fl fl/fl + 0.12 + 3.93 0.8 7.06 8 ***

0.1 Eed + PD1 Eed PD1 + 0.08 + 0.6 6 ** 0.06 0.4 5 5 Helios 4 10 0.04 10 4 0.12 0.51 4 % 10 0.2 5tCre 10 4.52 2.3 % Helios % 5tCre

% Helios % 2 0.02 β β 3 :: 3

:: 10 10 0 0 fl/fl 0 - fl/fl - + 102 CCR7 102 CCR7 - 4 Helios APC 0 Foxp3- Foxp3 Helios APC 0 + Eed 2 3 4 5 CD24 Eed 0103 104 105 TCR CD4SP 01 0 10 10 10 CD2 Eed fl/fl:: Eed fl/fl:: PD1 BV786 Eed fl/fl CCR7 BV421 Eed fl/fl β5tCre β5tCre -

c * 35 30 25 20 15 10 **

TCR gMFI (K) 5 0 *** 20 * *** ***

16 * *** *** 12 *** 8

CD5 gMFI (K) 4 Eed fl/fl:: Eed fl/fl β5tCre

0 - + + + + - +

dull CCR7 CD4 CCR7 CD4 DP CD8 CD4 CD8 PD1 + + - - + - DP CD24

CD24 CD24

pos CD24 Foxp3 Helios + + - - PD1 PD1 Helios Helios pre-selection TCR Helios Helios Helios Helios

d CCR7- Foxp3- TCR+ CCR7+ Foxp3- CD4 Foxp3+ CD4 SP excluded CD4SP CD24+ CD24- 100 30 * * pos *** *** neg Helios

pos 25 fl/fl pos 80 20 Helios

Eed 60 70.7 79.8 4.2 20.1 18.1 15 40 10 ::

fl/fl 20 % Lactadherin 5 % Lactadherin

5tCre 4.3 7.71 β 33.4 29.8 5.7 0 Eed 0 + - - + + - 0103 104 105 CCR7 Foxp3 TCR CCR7 Foxp3 CD4 Foxp3 CD4 Lactadherin FITC P + - S CD24 CD24 SP fl/fl fl/fl Eed :: CD4 Eed β excluded 5tCre

e fl/wt 100 female Eed female fl/wt β male Eed fl/fl male Eed :: 5tCre 80 60 0.5 10 2.5 60 60 10 10 50 50 + 0.4 8 8 2 8 + PD1

40 40 + 6 1.5 6 0.3 6 in CD4SP % in thymus 30 30 + 4 1 4 0.2 4 % Helios 20 % in SP 20 % in preDP

% Helios 0.1 2 2 0.5 10 10 2 % Foxp3 0 0 0 0 0 0 0 - - + - - CCR7 Foxp3 CCR7 Foxp3 + + DP Foxp3 CD4SP CD8SP TCR TCR DN1 DN2 DN4 CD8 DN3 - - - + - + + preDP CD4SP CD8SP ISP SP CD24 CD24 CCR7 CD24 CD24 CD24 CCR7 CD4SP excluded medullary phenotype, whereas the majority of “EED escapees”, transcripts depend on AIRE expression, are enhanced by AIRE despite not originating from the canonical β5t+ TEC progenitor or are generated independently of AIRE expression8. There were pool, were able to adopt a mature mTEC identity, although with small changes in the overall expression of AIRE-controlled genes several differences in transcription factor network expression. between EED-deficient and -proficient mTEC (Supplementary We next assessed the consequences of the loss of EED on Fig. 10a). For example, AIRE-dependent TSPAN8 expression promiscuous expression of genes encoding TRAs whose remained unchanged since this TRA was detected at comparable

8 NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w ARTICLE

Fig. 4 Negative selection and TCR avidity are reduced in a EED-deficient thymic microenvironment. Analysis of negative selection of CD4 lineage thymocytes in the cortex (a) and the medulla (b). CD5 and TCR geometric mean fluorescence intensity on indicated thymocyte subsets (c). Quantification of apoptotic cells in Helios-positive thymocyte subsets (d). Analysis of thymocyte development in Eed:fl/wt:β5tCre and control mice. Frequencies of preDP, DP and SP subsets, developmental stages within preDP thymocytes, maturation within SP cells, frequencies of Treg in CD4SP and frequencies of negatively selected cells (e). Representative flow cytometry contour and histogram plots are shown. Bar graphs display mean values with SD together with individual data points from n = 6 Eedfl/fl and n = 9 Eedfl/fl::β5tCre mice at 3 weeks of age (a–c)orn = 3 Eedfl/fl and n = 3 Eedfl/fl::β5tCre mice at 4 weeks of age (d) representative of at least two independent experiments. Eedfl/fl::β5tCre: white bars with grey diamonds, Eedfl/fl grey bars with black circles. Data in (e) are pooled from two independent experiments with female (n = 4 Eedfl/wt::β5tCre: light grey bars with grey diamonds, n = 4 Eedfl/wt black bars with grey circles) and male mice (n = 6 Eedfl/wt::β5tCre: light grey bars with white diamonds, n = 2 Eedfl/fl black bars with white circles) at 4–6 weeks of age. n = biologically independent replicates per group. *p < 0.05, **p < 0.01, ***p < 0.001 (two-tailed unpaired Student’s t test). The gating for thymocyte subsets is displayed in Supplementary Fig. 3. Source data including exact statistical test values are provided in the Source Data file.

abc 0.3 *** β 0.016 Eed 5tCre *** β5tCre Morisita Horn *** 0.31 *** Pre-sel’n fl/fl fl/fl 0.012 Index 0.2 Eed :: Eedfl/fl:: +/+ 0.16 0.18 ≤0.15 β5tCre β5tCre Wave 1 0.008 fl/fl 0.15 0.16 0.49 >0.15 0.1 0.004 +/+ 0.16 0.19 0.13 0.10 >0.30 CD4SP 0 0 of the CDR3 apex 0.11 0.12 0.09 0.08 0.58 >0.45

fl/fl CDR3 apical doublets Proportion of clones with Proportion of clones with cysteine within 2 positions that promote self-reactivity ave 1 +/+ 0.09 0.10 0.11 0.10 0.13 0.10 W CD4SPCD8SP Wave CD4SP1 CD8SP CD8SP Pre-sel’n Pre-sel’n fl/fl 0.07 0.08 0.07 0.07 0.10 0.10 0.38 +/+fl/fl +/+fl/fl +/+fl/fl +/+ Eed d e Pre-sel’n 40 7 β5tCre ) CD4SP CD8SP Wave 1 –3

Pre-sel’n Wave 1 α 30 Eedfl/fl:: CD4SP 5 β5tCre 20 CD8SP clonotype

:: 3 10 α fl/fl Unique TCR 5tCre 5tCre clonotypes (10 relative diversity TCR β β 0 Eed 1 0 0.2 0.4 0.6 Coverage ave 1 W CD4SP CD8SP Pre-sel’n

Fig. 5 TCRα repertoire analysis of YAe62 TCRβ-transgenic thymocytes in β5tCre or Eedfl/fl::β5tCre bone marrow chimeras. Unless stated otherwise, the analyses compared TCR catalogues, which were formed by aggregating samples of a given T cell subset/genotype combination. The β5tCre and Eedfl/fl:: β5tCre TCR catalogues contained the following numbers of samples: 9 and 14 mice, respectively (pre-selection, Wave 1 and CD8SP); 8 and 14 mice, respectively (CD4SP). a Heatmap shows the Morisita-Horn index for each pair of TCR catalogues. b, c Amino acid composition of the CDR3 apex. Considering the amino acid doublets at CDR3 positions 6 and 7, (b) shows the proportion of TCRα clones with doublets that promote self-reactivity33. Each symbol represents an individual sample. Samples with fewer than 100 clones were excluded, (c) depicts the proportion of TCRα clones with cysteine anywhere from CDR3 position −2to+2 as determined by apex-out CDR3 alignment35. ***p = 4.3 × 10−5 (pre-selection vs. Wave 1) and p = 1.7 × 10 −6 (pre-selection vs. CD4SP) using Student’s t test (unpaired, two-sided, Bonferroni-corrected) in (b)orp = 1.5 × 10−6 (pre-selection vs. Wave 1) and p = 2.8 × 10−15 using Fisher’s exact test (2 × 2 table, two-sided, Bonferroni-corrected) in (c). d, e TCRα clonotype diversities. d Cumulative number of unique TCRα clonotypes plotted as a function of “coverage”,defined as the proportion of all clones (encountered and unencountered) in a given T cell subset that belong to clonotypes encountered in the catalogue. Symbols show the observed values and curves outline the 95% confidence intervals of the rarefaction and extrapolation curves determined using 10 bootstrap replications. e Relative diversity of TCR catalogues. Symbols indicate ratios of the numbers of unique TCRα clonotypes per TCR catalogue at the level of coverage indicated by the vertical dashed line in (d). Error bars in (e) show the 95% confidence intervals of the relative diversities of TCR catalogues based on 10 bootstrap replications. level in ZsGreen-positive and -negative mTEChi of experimental subtle reduction in the breadth of promiscuous gene expression in mice and their controls (Fig. 10a). By randomly sampling AIRE mTEChi proficient or deficient in PRC2 activity within the same expressing single cells, we estimated for each of the different thymic environment. However, multivariate analysis showed that mTEC populations the number of detectable genes encoding the presence of H3K27me3 marks near the TSS predicted whether TRAs (Fig. 10b). The breadth of promiscuous TRA expression or not a gene was upregulated in EED-deficient mTECs relative to was reduced in EED-deficient mTECs, affecting particularly those that were EED-proficient independently of whether or not AIRE-controlled loci (AIRE-dependent: 0.86-fold, p < 0.0001; that gene was regulated by AIRE (Supplementary Fig. 10b). This AIRE-enhanced: 0.96-fold, p < 0.0001; AIRE-independent TRA: finding suggests that at least a portion of the mild deficiency in 0.98-fold, p < 0.0001; all other genes: 0.99-fold, p < 0.0001). A promiscuous gene expression was more likely to be driven by similar change in the pattern of TRA expression was observed in thymic microenvironmental changes than a direct effect of EED- ZsGreen-negative mTEC isolated from Eedfl/fl::ZsGreen::β5tCre deficiency. Eedfl/fl::β5tCre mice did not develop auto-antibodies or mice (AIRE-dependent: 0.84-fold, p < 0.0001; AIRE-enhanced: overt organ infiltration nor did they reveal signs of autoimmunity 0.94-fold, p < 0.0001; AIRE-independent TRA: 0.97-fold, p < after antibody-mediated T cell depletion and subsequent 0.0001; all other genes: 0.99-fold, p < 0.0001). Hence, there was a endogenous T cell reconstitution (Supplementary Fig. 11).

NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications 9 ARTICLE NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w

a b TCR+ CD4+ 52.9 59.5 100 10.9 fl/fl )

6 80

60 Eed 60 3 20 *** *** 40 39.8 87.9 15 *** 105 26.7 40 105 60 2 105

Cellularity (x10 20 16.7 4 4 4 in CD4+ 5tCre 10 10 10 10 β

0 % TCR+ :: 3 3 BT 10 20 10 1 103 fl/fl

5 Spleen 102 CD4/CD8 ratio 0

0 Foxp3 APC % Foxp3+ CD4 PE-Cy7

CD5 APC-Cy7 0 Eed fl/fl Eed 38.9 81.6 3 4 5 0 3 4 5 0 3 4 5 0 Eed fl/fl::β5tCre 010 10 10 010 10 10 010 10 10 TCR BV650 CD8 A700 CD25 BV605

Eed fl/fl c CD4+ Foxp3+ CD4+ Foxp3- CD8+ Eed fl/fl::β5tCre 86.9 3.5 67.1 28.1 74.5 fl/fl 100 *** Eed 80 *** *** 23.3 7.8 1.3 60 *** 5 72.1 5.8 59.1 10 42.4 33.7 40 104 5tCre *** β 20 Eed fl/fl :: 103 % in T cell subsets T % in ** fl/fl β fl/fl Eed :: 5tCre

0 0 54.5 18.5 4 CD62L: - + - + + - + Eed 2 3 4 5 CD44: + - + + - + + CD62L PerCP-Cy5.5 CD62L 010 10 10 10 CD4+ CD44 BV510 Foxp3+ CD4+Foxp3- CD8+

d e CD4+ CD25+ f 4.18 5.95 fl/fl fl/fl 100 fl/fl 100 n Eed

fl/fl Eed

fl/fl fl/fl β Eed ::β5tCre *** Eed :: 5tCre 80 =100%)

Eed 80

Eed ** 60 Reg 60 * 73.3 16.6 *** 40 40

5tCre 105 8.8 20.8 *** β 20

:: 20 5tCre 104 ** % in CD4+ CD25+ β fl/fl % of max. proliferatio

:: 0 103 0 (CD4 without T fl/fl 1:4 1:2 1:1

% Max Eed 2 3 4 5 + 010 10 10 10 2 ICOS: - - + T Dilution 10 CD103: + + Reg Eed CFSE ICOS PE-Cy7 0 - - 36.2 34.2 5 100 * 0102 103 104 105 * CD103 FITC 4 80 3 60 2 40 IL2 (ng/ml) 1 20 Expansion Index 0 0 Eed fl/fl Eed fl/fl::β5tCre

Fig. 6 Peripheral T cells and their function in Eedfl/fl::β5tCre and Eedfl/fl mice. a Absolute numbers of splenic B and T cells in Eedfl/fl (n = 3) and Eedfl/fl:: β5tCre mice (n = 3) at 4 weeks of age. b Representative contour plots and frequencies of lymph-node-derived T cell subsets. Frequency of TCRβ+ T cells, + + − + the CD4/CD8 ratio within TCRβ+ T cells and percentage of Foxp3 TReg in CD4 T cells. c Frequencies of activated cells (CD44 CD62L ) in Foxp3 TReg and frequencies of naive (CD44−CD62L+), central memory (CD44+CD62L+) and effector memory (CD44+CD62L−) T cells within the populations of Foxp3− CD4 and CD8 lymph node cells. b, c Eedfl/fl (n = 3) and Eed:fl/fl:β5tCre mice (n = 4) at 4 weeks of age. d Proliferative response and IL-2 secretion of naive lymph node CD4 T cells (CD44loCD25−) from Eedfl/fl (n = 3) and Eedfl/fl::β5tCre mice (n = 3) at 4 weeks of age. Representative histograms of CFSE dilution (including model components used for expansion index calculations; grey dotted lines) following stimulation for three days with CD3 mAb (1 µg/ ml) and irradiated Rag2−/− splenocytes. Bar graphs display the mean expansion index (left) and mean IL2 concentrations in the supernatant (right) with

SD. e Representative contour plots and frequencies of lymph-node-derived TReg subsets defined by their differential expression of ICOS and CD103 from Eedfl/fl (n = 3) and Eedfl/fl::β5tCre mice (n = 4) at 4 weeks of age. f T cell suppression assay: CD3 mAb-induced proliferation of sorted naive WT CD4 T cells (CD44loCD25−) in the presence of sorted lymph node Treg (CD4+CD25+) from Eedfl/fl (n = 3) and from pools of two Eedfl/fl::β5tCre mice each (n = 3) of mixed sex at 7–9 weeks of age. *p < 0.05, **p < 0.01, ***p < 0.001 (unpaired Student’s t test). Data in graphs show mean ± SD and are representative of two independent experiments. Contour plots (b, c, e) and histograms (d) are representative of data in bar graphs. Eedfl/fl::β5tCre: white bars with grey diamonds, Eedfl/fl grey bars with black circles. n = biologically independent replicates per group. Source data including exact statistical test values are provided in the Source Data file.

10 NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w ARTICLE

neg

a neg b CD45 e

CD45 e r r pos pos pos pos

C EpCAM MHCII C

t EpCAM MHCII t ** ***

5 5 100 5 5 10 pos 1.7 β 87.6 β ZsG

: 10 60.7

: :

: 4 n

n 10 80

4 e

10 e e

e 3 94.8 r

r 10 100 60 G

3 G

s 10 s ZsGreen

Z 0

pos Z

: 80

: 0 40

:

: l

4.8 % mTEC

l f

Ly51 PE-Cy7 Ly51 97.8

f

/

/

l

l f

33.1 f

d 0 50 100 150 200 250 3 4 5 d 010 10 10 ** 5 60 20 e 10 31.2

100 e 91.2 E

E FSC-A (K) UEA1 BV786 4 10 4 0 80 ZsG: + + -

pos neg 3 2 mTEC ZsG 10 H3K27me3: + - + 80 60 0 % H3K27me3 0 mTEC 40 neg pos

% ZsG H3K27me3+ H3K27me3 A647 0 50 100 150 200 250 5 98.9 ZsG 10 ZsG+ 20 ZsG 91.7 cTEC FSC-A (K) 4 10 3 4 5 01010 10 0 H3K27me3- 3 10 ZsG+ ZsGreen cTECmTEC 0 H3K27me3+ ZsG- Ly51 PE-Cy7 Ly51 3 4 5 0103 104 105 01010 10 UEA1 BV786 ZsGreen

c CD45neg d cTEC mTEClo mTEChi lo hi

e cTEC mTEC mTEC r pos pos

C EpCAM MHCII

t

5

β

:

:

n

e e

r ZsG+

G

s

Z

:

: l

f ZsG- /

l 3 3 4 5 3 3 4 5 f -10 0 10 10 10 3 4 5 -10 0 10 10 10 d 010 10 10 e H3K27me2 A647 EZH2 A647

E Total H3 A647 *** *** Eed fl/fl::ZsGreen

) *** ) *** hi 160 Eed fl/fl hi 140 *** ZsGneg 140 ::ZsGreen 120 * *** pos 120 *** ZsG ::β5tCre 100 mTEC 100 * mTEC 80 neg 80 neg 60

60 EZH2 ** *** 5tCre

5tCre 40 H3K27me2 40 β 20 β 20 median fluorescence 0 median fluorescence 0 lo hi lo hi (% of cTEC mTEC mTEC (% of cTEC mTEC mTEC

e CD45neg fg hi pos pos cTEC mTEC *** i

EpCAM MHCII h 100 100 *** C

hi C pos 74.4 mTEC 70.5 E ZsG 22.1 E 80.8 mTEC ** T 80

e 96.8

T 80

r

m c

4.8

C

t

n n

i 60

i

5 60

i

s

h

o

β

:

p 1

: 81.4

0 40

51.6 5 n 40

3 4

y e

cTEC

L

D

e

r 85.8 20

20 C

% 76.1 G

s 10.9

3 4 5 % 010 10 10 0103 104 105 Z 86.8 0

: neg 0

: l

f ZsG / 36 Ly51 Bio/SA BV786

l CD40 eF450

f

d

e e

pos i 100 h

c hi E Ly51 cTEC mTEC

n 40K

C **

e E

c 80 T

s 65.8 e

30K m r

60

n o

5 5 5 n

i

e u 10 10 9.2 10

89.4 l

s

f

e

o

r 20K p 4 4 40

4 n

10 10 e

G 10 42.9

r

a

i i

s 71.2

3 d A Z 20 10 : 3 3 e 10K : 10

l 10

f

/

% l

ZsGreen m f 2 0

0 71.6 I d 10 0

100 I e 0 3 4 5 0 3 4 5

010 10 10 C 010 10 10 E 3 4 5 3 4 5 MHCII APC-Cy7 3 4 5 hi 010 10 10 0 10 10 10 0 10 10 10 H Ly51 cTEC

Ly51 Bio/SA BV786 Bio/SA Ly51 MHCII APC-Cy7 Aire eF660 M EpCAM PerCP-Cy5.5 UEA1 Cy5 CD80 BV605 fl/fl Eed fl/fl::ZsGreen ZsGneg Eed ::ZsGreen * ZsGpos

100 60 ::β5tCre C

E 50

80 T C

m fl/fl

E 40 h Eed ::ZsGreen::β5tCre

n T

60 i

fl/fl i

h n

Eed ::ZsGreen i 30

C

40 E

% 20

fl/fl T neg Eed *

ZsG m

20 ::ZsGreen 10

pos % ZsG ::β5tCre 0 0 cTEC mTEC

15μm 50μm 50μm ZsGreen ZsGreen CK14 ZsGreen CK14

Given the near-complete loss of H3K27me3 marks in ZsGreen- expressed in ZsGreen-positive mTECs than in either of the two positive EED-deficient mTEC, we assessed the distribution of other TEC populations (H3K27me3 ChIP/input signal within 4 H3K27me3 ChIP-seq signal in wild-type mTEChi around those kb of the TSS: ZsGreen-positive vs. ZsGreen-negative: median genes that were differentially expressed between separate mTEC 2.36-fold, FDR < 0.0001; ZsGreen-positive vs. Eedfl/fl median populations. H3K27me3 ChIP-seq signals were significantly 2.14-fold, FDR < 0.0001; Fig. 10c). Differences in the correspond- increased around the TSS of genes that were most highly ing H3K27me3 ChIP-seq signals were, however, not observed

NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications 11 ARTICLE NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w

Fig. 7 Eedfl/fl::ZsGreen::β5tCre mice contain a subpopulation of Eed-proficient mTEC. a ZsGreen expression in cTEC and mTEC isolated from 4-week-old Eedfl/fl::ZsGreen::β5tCre mice. b Quantification of H3K27me3 abundance in ZsGreen-positive and -negative TEC and their phenotypic characterization. c Representative histograms of histone H3 abundance in ZsGreen-positive and -negative TEC. d Representative histograms and median fluorescence quantification of H3K27me2 and EZH2. Fluorescence of control mTEChi was set as 100%. Data are pooled from two independent experiments identified by circles and diamonds, respectively. e Representative FACS plots and quantitative analysis of cTEC, mTEC and mTEChi frequencies within ZsGreen-positive and -negative TEC. f, g Representative histograms and quantitative analysis of ZsGreen-positive and -negative cTEC (f) and mTEChi (g) phenotypes. h Spatial distribution of ZsGreen-positive and -negative TEC in thymus tissue sections of 4-week-old Eedfl/fl::ZsGreen::β5tCre mice. Immunofluorescence analysis of mTEC expressing ZsGreen and cytokeratin 14 (CK14) in the medulla (marked by dashed blue line) identifying single cells and small aggregates of ZsGreen-negative cells (white dashed lines). Data in bar graphs show mean ± SD and are pooled from two independent experiments (a, b, d) or are representative of two independent experiments (e–g). Contour plots and histograms are representative for data displayed as frequencies in bar graphs (a, b, d, e–g). Immunofluorescence data are representative of two independent experiments with 3 sections each. a, b Eedfl/fl::ZsGreen::β5tCre (n = 3), in (b) dark green represents ZsGreen-positive H3K27me3-positive, light green shows ZsGreen-positive H3K27me3-negative, and grey depicts ZsGreen-negative H3K27me3-positive, (d) Eedfl/fl::ZsGreen (n = 5, grey histograms and bars with black circles and diamonds) Eedfl/fl::ZsGreen::β5tCre (n = 7, ZsGreen- negative: white histograms and bars with grey circles and diamonds, ZsGreen-positive: black histograms and bars with grey circles and diamonds), (e–g) Eedfl/fl::ZsGreen (n = 5, grey histograms and bars with black circles), Eedfl/fl::ZsGreen::β5tCre (n = 5, ZsGreen-negative: white histograms and bars with grey diamonds, ZsGreen-positive: black histograms and bars with grey diamonds); n = biologically independent replicates per group, mice were 3–4 weeks of age. *p < 0.05, **p < 0.01, ***p < 0.001 (two-tailed unpaired Student’s t test). Source data including exact statistical test values are provided in the Source Data file.

between ZsGreen-negative and Eedfl/fl mTEC (FDR > 0.05). and function cannot be interrogated in detail42. Thus, it remains Taken together, these data demonstrated that the loss of EED unknown whether mTEC development bypassing β5t-positive bi- early in TEC development resulted in an mTEC compartment potent TEC precursors can also occur in Eedfl/fl::Foxn1-Cre mice. with a relatively modestly reduced capacity for promiscuous gene We therefore conclude that the loss of EED expression early expression. This finding suggests that the expression of TRAs is during TEC differentiation (i.e. before the emergence of bi-potent not critically dependent on repressive chromatin modifications. β5t-positive TEC precursors) and the consequent loss of cano- nical gene silencing by PRC2 precludes not only the normal Discussion progression along the canonical TEC differentiation pathway but TEC development and function are dependent on EED, an also excludes the emergence of the alternative mTEC pathway described here. essential component for assembly and activity of the PRC2 fl fl complex. The loss of EED in β5t-expressing TEC precursors and In addition to intrathymic B cells, Eed / ::β5tCre mice also their progeny resulted in an absence of PRC2 activity in practi- show increased frequencies of thymic macrophages and DCs, cally all cTEC (with the notable exception of few non-recombined although it is possible that this could simply be due to the cTEC displaying an atypical phenotype) and the majority of observed reduction of thymocytes. The impaired antigen pre- mTEC. However, up to 15% of all mTEC present in Eedfl/fl:: sentation by TEC may be compensated by immigrating DCs and β B cells thus contributing to establishing central T cell 5tCre mice arise from an alternative mTEC developmental – pathway originating from cells other than bi-potent, β5t-positive tolerance9 11. Antigen transfer from mTEC to DCs may fur- precursors and characterized by a distinct transcriptome, repre- thermore offset defects in mTEC-mediated antigen presentation43 and selecting a TCR repertoire with sufficient self-tolerance. senting either a distinct TEC lineage or an alternate differentia- fl fl tion pathway into canonical mTEC cell types within an abnormal Signs of autoimmunity are not detected in Eed / ::β5tCre mice thymic microenvironment26,38. EED-proficient mTEC exhibits in despite an impaired expression of antigen processing pathways, a Eedfl/fl::β5tCre mice a competitive growth/differentiation advan- limited reduction in the representation of TRA in mTEC, a tage over EED-deficient mTEC. narrowed breadth of the TCR repertoire and peripheral T cell Despite the severely reduced cellularity of ETP and a partial lymophopenia. Although reliant on mTEC and DCs for their fl fl 44–46 block in β-selection, cTECs of Eed / ::β5tCre mice support the selection ,Treg generation is not offset by the reduced mTEC differentiation to DP thymocytes and their positive selection cellularity, indicating a likely compensation by the increased despite differences in the expression of many genes required for frequency of intrathymic DCs. The heightened frequency and — antigen processing and presentation. Any deficiencies in antigen function of peripheral Treg resulting from lymphopenia-induced presentation may likely be compensated by the decreased proliferation—contribute further to the observed lack of auto- thymocytes-to-cTEC ratio, thus lessening the competition between immunity. Because peripheral Treg cannot compensate for AIRE thymocytes and the normally limiting numbers of cTEC. This will deficiency, the absence of autoimmunity corroborated our finding result in an increased cross-talk between these two cell types and a that EED deficiency results only in a minor alteration of TRA longer sojourn of thymocytes in the cortex39. Indeed, the subtle representation47. differences in the choice of Traj segments within the TCRα Gene expression profiling of EED-deficient mTEChi demon- repertoire of Eedfl/fl::β5tCre mice support this explanation as strated a significant upregulation of genes that are normally asso- reflected by a more frequent use of distally positioned Traj family ciated with H3K27me marks in EED-proficient mTEChi, both members40. Furthermore, the transition of thymocytes across the wild-type and “EED escapees”,afinding consistent with the corticomedullary zone may be secondary to the decrease in Psmb11 removal of canonical gene silencing by PRC2. Changes in TEC expression, as observed in β5t-deficient mice41. development and composition are thus explained by gene de- The exact timing of the loss of EED expression in TEC repression in pathways involved in epithelial differentiation as determines thymus organogenesis. In a recently described mouse highlighted in other organs, such as lung, including Foxp1 and Nfib strain (Eedfl/fl::Foxn1-Cre), an identical ablation of the Eed locus (Supplementary Fig. 7). This mechanism of de-repression was targeted to a time point early during TEC fate specification but previously suspected as known PRC2 targets are characterized by prior to Psmb11 expression hinders TEC maturation resulting in active enhancer marks in immature but not mature mTEC48.The a severely dysplastic thymus in which PRC2’s role in development current study demonstrates that these chromatin changes are not

12 NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w ARTICLE

a b

10 e

g 5

)

n

a

%

h

3 .

c antigen presentation

9

(

d l

0 proteasome

o

2

f

C

2 immunoproteasome

P

g o L -5

-10

PC1 (11.9%) 0 5 10 15

Mean expression (log2 CPM) Eedfl/fl ZsG+ Eedfl/fl::ZsGreen 10 ZsG- ::β5tCre 10

5

e

g

e

n g

a 5

n

h

a c

0

h

d

c

l

o

d

f

l

2 0

o

f

g

2 o

-5 g

L o L -5 -10 -10

0 5 10 15 0 5 10

Mean expression (log2 CPM) Mean expression (log2 CPM)

c Structural constituent of ribosome GO:0003735

rRNA binding GO:0019843

Threonine - type endopeptidase activity GO:0004298

Threonine - type peptidase activity GO:0070003

NADH dehydrogenase activity GO:0003954

Enzyme inhibitor activity GO:0004857

Glycosaminoglycan binding GO:0005539

Heparin binding GO:0008201

RNA polymerase II cis -regulatory region… GO:0000978

DNA - binding transcription activator activity, RNA… GO:0001228

DNA- binding transcription activator activity GO:0001216

Peptidoglycan binding GO:0042834

Oligosaccharide binding GO:0070492

Receptor ligand activity GO:0048018

Signalling receptor activator activity GO:0030546 l - + fl/f d

ZsG ZsG e E

Eedfl/fl::ZsGreen ::β5tCre

Fig. 8 ZsGreen-positive and -negative mTEC from Eedfl/fl::ZsGreen::β5tCre mice are transcriptomically distinct from mTEC isolated from Eedfl/fl mice. a Principal component analysis of bulk RNA-seq samples. b Scatter plots of differentially expressed genes for each type of mTEC showing genes belonging to gene ontology terms related to antigen presentation and processing (GO:0019882 - green), proteasome (KEGG:03050 - yellow) and immunoproteasome (CORUM:39 - orange). CPM = counts per million. Dashed lines indicate a fold change of 1 and arrows indicate the direction of higher expression. Filled points are significant at FDR < 0.05. c A dot plot showing significantly enriched biological pathways within genes significantly upregulated in each type of mTEC.

NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications 13 ARTICLE NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w

a b Eedfl/fl ZsG+ Eedfl/fl::ZsGreen Ciliated ZsG- ::β5tCre Tuft -like TEC TEC

Post -AIRE GP2+ mTEC mTEC Intertypical TEC

Mature mTEC

Proliferating TEC MAP2 UMAP2 U UMAP1 UMAP1 c 10 Ciliated TEC Intertypical Intertypical 2.5 Intertypical TEC TEC GP2+ mTEC TEC Mature Intertypical TEC 8 3 mTEC 2 Mature mTEC PostAIRE- TEC 6 Proliferating TEC 1.5 2 Post -AIRE Tuft -like TEC p -value Mature TEC 4 mTEC 10 1 Proliferating 1 -Log 2 TEC 0.5

0 0 0 -2 -1 012 -2 -1 012 -2 -1 012 Log 2 fold enrichment Log 2 fold enrichment Log 2 fold enrichment Eed fl/fl ZsG+ ZsG+ ZsG - Eed fl/fl ZsG -

d Ascl1 Irf7 *** **** **** n * *. * FDR<0.05 o ** FDR<0.01 1 1 *** FDR<0.001 xpressi

e **** FDR<0.0001 Wilcoxon rank sum test 0 score 0 vs. all others le odu

m -1

ZsG - ZsG + Eed fl/fl ZsG - ZsG + Eed fl/fl

e Fos Jun 2 ** ** 2 *** 1 ** 1

0 0 module score expression -1 -1 ZsG - ZsG + Eed fl/fl ZsG - ZsG + Eed fl/fl merely correlative but that loss of PRC2 activity compromises Eedfl/fl::β5tCre mTECs suggests that H3K27me3 is not absolutely mTEC progression to a mature phenotype, through the differential required for AIRE-regulated transcription. Rather, the role of induction of transcription factor networks controlled by Irf7 and PRC2 activity in TEC differentiation and suppression of alternative Ascl1. Previous research had suggested that AIRE-regulated loci differentiation pathways raises the prospect that therapeutic were marked by repressive chromatin modifications20,49. However, manipulation of the TEC epigenome may be able to modulate the relatively mild reduction in the breadth of TRA expression in negative selection in autoimmune diseases50.

14 NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w ARTICLE

Fig. 9 Single-cell annotation of mTEC lineages. a A UMAP plot showing all datasets projected together. mTEC cell type annotation was inferred from the combination of the two reference datasets. b The same UMAP projection showing only single-cell RNA-seq data on mTECs from this study. Eedfl/fl (magenta), Eedfl/fl::ZsGreen::β5tCre: ZsGreen-positive (green) and ZsGreen-negative (blue). c Volcano plots showing enrichment of TEC subtypes for (left panel) Eedfl/fl::ZsGreen::β5tCre ZsGreen+ vs. Eedfl/fl mTEChi, (middle panel) Eed:fl/fl:ZsGreen::β5tCre ZsGreen+ vs. Eedfl/fl::ZsGreen::β5tCre ZsGreen− mTEChi and (right panel) Eedfl/fl::ZsGreen::β5tCre ZsGreen− vs. Eedfl/fl mTEChi. All TEC subtypes showing nominally significant differences are labelled. Violin plots showing transcription factor network expression for transcription factor networks upregulated in (d) Eed:fl/fl:ZsGreen::β5tCre ZsGreen+ mTEChi, and (e) Eedfl/fl::ZsGreen::β5tCre ZsGreen− mTEChi. Eedfl/fl (magenta), Eedfl/fl::ZsGreen::β5tCre: ZsGreen-positive (green) and ZsGreen-negative (blue). Source data including exact statistical test values are provided in the Source Data file.

Methods proliferative response was evaluated by flow cytometry and assessed by the serial Mice. C57BL/6 mice were obtained from Janvier. The generation of β5t-Cre, Eed, dilution of CFSE label. Ezh1 and Ezh2 conditionally targeted animals and TcRβ transgenic mice (YAe62β) have previously been reported25,26,32,51. Rosa26 knock-in mice that were engi- T cell suppression assay. Sorted naive WT lymph node CD44lo CD25neg CD4 neered to contain the CAG-loxP-stop-loxP-ZsGreen sequence have been described T cells (50,000/well) were cultured together with irradiated (3000 cGy) Rag2−/− elsewhere52. Experiments used animals with both sexes until 4 weeks of age, the splenic accessory cells (100,000/well) and the indicated amount of sorted lymph gender is indicated for experiments with mice older than 4 weeks. Neonatal female node CD4pos CD25pos T in the presence of soluble CD3 mAb (0.5 μg/ml). After Ly5.2 recipients of haematopoietic stem cells were conditioned with 200 cGy prior reg 48 h, 1 μCi 3H thymidine was added overnight and cells were harvested the to receiving T cell-depleted Ly5.1 bone marrow cells (3 × 106) from TCRβ trans- following day. genic mice (YAe62)32. Chimeric mice were analysed 4 weeks after engraftment. Rag2−/− mice were bred and maintained in our institute’s SPF facility. Experi- mental (Cre-positive) and control (Cre-negative) mice were co-housed, C57BL/6 ELISA assay. The ELISA-Ready-Set-Go kit was used according to manufacturer’s and β5t-Cre controls were bred separately. Mice were cared for and experiments protocol to determine the concentration of IL-2. The absorbance values of each were carried out in accordance with permissions and regulations of the Cantonal well were then acquired using an absorbance reader (Biochrom) at 450 nm. Veterinary Office of Basel-Stadt (licence 2737). All animals were kept under spe- cific pathogen-free conditions at 22 ± 2 °C, 60 ± 15% humidity, and a 12 h light cycle with light phase beginning at 6 a.m. with a 30 min sunrise and ending at 6 p. RNA-seq and ChIP-seq. TECs were enriched as detailed above and then sorted m. with a 30 min sunset, with food and water ad libitum. Mice were euthanized by using a FACSAria II (BD Bioscience). RNA was isolated using RNeasy kit (Qiagen) CO2 inhalation and decapitation. and subjected to sequencing (TrueSeq, BGI). Sequencing data are available through the Gene Expression Omnibus (GSE112050). 53 Thymic epithelial cell isolation. Thymic lobes were cleaned off the fatty tissues Adapter sequences were trimmed using Trimmomatic . Reads were aligned and incubated with Liberase and DNaseI (Roche Diagnostics; 200 and 30 μg/ml, against the Ensembl transcriptome and genome (GRCm38 plus ERCC spike-ins) 54 respectively; 45 min, 37 °C) to obtain a cell suspension, which was subsequently using HISAT (version 0.1.6) . Reads were allocated to protein-coding gene meta- 55 filtered through a nylon mesh (100 µm pore size, Sefar Nitex) to remove debris. features using HTSeq (intersection non-empty) . Differential expression analysis With the exception of Fig. 1e, wild-type TEC were magnetically enriched using the on genes with mean expression at least 1 FPKM was conducted using general linear 56 fi AutoMACS Pro Separator (Miltenyi Biotec) to obtain sufficient cells for analysis. modelling in edgeR, using TMM normalization . Genes were identi ed as differentially expressed using the default edgeR threshold (FDR < 0.05). Clustering was performed using principal component analysis. Gene ontology enrichment was Thymic macrophage and dendritic cell isolation. Cleaned thymic lobes were conducted in gProfiler with enrichment values estimated from 1000 incubated with Collagenase D and DNaseI (Roche Diagnostics; 1 and 30 μg/ml, permutations57. respectively; 45 min, 37 °C) to obtain a cell suspension, which was subsequently Single-cell sequencing data were pre-processed and aligned in the same filtered through a nylon mesh (100 μm pore size, Sefar Nitex) to remove debris and manner. Low quality cells were identified by robust PCA outlier identification on stained. several quality control metrics (alignment proportion, ERCC spike-in proportion, number of detectable genes, proportion of reads mapping to protein-coding genes, proportion of mitochondrial transcripts, proportion of ribosomal In vivo T cell depletion. In vivo T cell depletion was achieved by i.v. injection of a transcripts, 3ʹ-to-5ʹ coverage bias, transcriptomic variance, cell-to-mean – cocktail of CD4 (clone GK1.5; 200 µg), CD8 (53 67; 100 µg) and anti-Thy1.1 (T24; correlation, the proportion of the library accounted for by the top 500 transcripts 50 µg) mAb. and GC content)58. Counts were adjusted between plates using ERCC spike-ins and then by library size using SCnorm59. Cells were clustered using the tSNE component of the linnorm package, specifying pre-normalized data60.scDDwas Flow cytometry. Thymocytes and TEC were stained as indicated, using antibodies used for differential analysis of single-cell RNA-seq data61. Richness of TRA and reagents listed in Supplementary Table 1, including dilutions. For intracellular expression was assessed by resampling the increasing number of single mTECs staining, cells were fixed, permeabilized (Cytofix/Cytoperm Kit, BD Biosciences) and calculating the mean number of genes expressed in different categories of and labelled except for Foxp3 staining, where the eBioscience transcription factor genes. Each number of cells was resampled 100 times. Statistical significance was staining buffer set (ThermoFisher Scientific) was used. Stained samples were estimated using Wilcoxon rank sum tests and correcting for multiple hypothesis acquired on a FACSAria II or BD LSRFortessa flow cytometer with FACSDiva (BD testing using the Benjamini-Hochberg method. Comparison to reference single- Biosciences v8.01) and the data were analysed using the FlowJo (Treestar Inc. cell RNA-seq datasets was undertaken in Seurat, integrating the reference datasets v9.8.3 and v10.7.1) software. together and then integrating the single-cell RNA-seq data from this manuscript onto that36,37,62. GENIE3 and RcisTarget were used to generate transcription In vivo cell proliferation assay. TEC proliferation was quantified by BrdU factor gene-regulatory networks63. Module expression for genesets was calculated incorporation. In short, mice were i.p. injected with 1 mg BrdU (BD Pharmingen) using Seurat. diluted in 250 μl sterile PBS and analysed 16 h later by flow cytometry following the ChIP-seq data were processed as previously described64. Briefly reads were pre- BrdU Flow Kit protocol (BD Biosciences). aligned using BWA (version 0.5.9) then high-quality alignments were processed using Stampy. Only reads with a MAPQ score of at least 10 were taken forward for further analysis. H3K27me3 peaks were called using irreproducibility discovery rate Histology. Frozen sections (8 µm) of OCT embedded thymus tissue were fixed in analysis (specifying broad peaks). Significance of ChIP/input changes between acetone and stained either with haematoxylin and eosin or with Abs as indicated samples were estimated using Wilcoxon rank sum tests and correcting for multiple (see Supplementary Table 1). For the detection of ZsGreen, samples were first fixed hypothesis testing using the Benjamini-Hochberg method. in 4% paraformaldehyde prior to embedding. The tissue was sectioned using the RNA-seq and ChIP-seq data are available at the Gene Expression Omnibus cryostat and attached to super-frost glass slides (ThermoFisher Scientific). Sections (GSE112050 and GSE114713). AIRE ChIP-seq data were downloaded from were then stained with primary antibodies (2 h, room temperature), washed and GSE9259765. developed using secondary antibodies (1 h, room temperature). Images were acquired using a Zeiss LSM510 (Carl Zeiss). T cell sorting for TCR repertoire analysis. Whole-thymus suspensions were prepared by pushing organs through a 70 µm sieve into PBS containing 2% v/v In vitro T cell proliferation assay. T cell subpopulations were labelled for 10 min heat-inactivated fetal calf serum and 2 mM EDTA (designated sort buffer). For at room temperature with CFSE (2.5 nM) and subsequently co-cultured for 72 h CCR7 staining of thymocytes, suspensions were incubated for 30 min at 37 °C in with irradiated (3000 cGy) Rag2−/− splenocytes and 1 µg/ml of CD3 mAb. The pre-warmed sort buffer containing anti-CCR7. Cells were then pelleted by

NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications 15 ARTICLE NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w

a b Aire dependent Aire enhanced mTEClo mTEChi 800 1500 600

1000 400 3 4 5 01010 10 TSPAN8 PE 800 1500 600 50 s 500 e 200 1000 n 400 40 e

pos g

200 500 e 30 l b 0 0

a 0 0 t

20 c e

t 0 20 40 60 80 100 120 0 20 40 60 80 100 120

10 e

d

% TSPAN8 f 10000 All other genes o Aire independent 0

lo hi r 3000

mTEC mTEC e b

Eedfl/fl::ZsGreen m u 2500 8000 Eedfl/fl N ZsGneg ::ZsGreen pos 2000 6000 ZsG ::β5tCre 1500 3000 4000 10000 1000 8000 2000 6000 2000 500 4000 1000 2000 0 0 0 0 0 20 40 60 80 100 120 0 20 40 60 80 100 120

Number of cells Eedfl/fl c ZsG+ Eedfl/fl::ZsGreen ZsG- ::β5tCre

1.0 t

u 0.8

p

n

i

/

P

I h

C 0.6

3

e

m

7 2

K 0.4

3 H

0.2

0 -4 -2 0 2 4 Distance to TSS (kb)

Eedfl/fl ZsG+ Eedfl/fl::ZsGreen ZsG- ::β5tCre

Fig. 10 The effects of Eed loss on AIRE-dependent gene expression and H3K27me3 repressed genes. a Representative histograms and quantitative analysis of TSPAN8 expression in mTEClo and mTEChi. Graph shows mean with SD, data are pooled from two independent experiments identified by circles and diamonds, respectively. Eedfl/fl::ZsGreen (n = 5, magenta) Eedfl/fl::ZsGreen::β5tCre (n = 7 ZsGreen-negative: blue, ZsGreen-positive: green). n = biologically independent replicates per group, mice were 3–4 weeks of age. b The number of detectable genes from randomly sampled single ZsGreen-negative (blue), ZsGreen-positive (green) and Eedfl/fl (purple) mTEChi. The inset bar graphs show the mean number of detectable genes when resampling 130 single mTEChi. Error bars indicate the standard deviation. **Corrected p < 0.001 (two-sided Wilcoxon rank sum test with Benjamini-Hochberg correction). Prior to analysis, cells were downsampled to 200,000 transcriptomic fragments. c Median wild-type H3K27me3 ChIP/input in 50 bp bins around the transcription start site (TSS) for genes significantly upregulated in mTEChi. Genes were those most highly expressed in ZsGreen-positive (green), ZsGreen-negative (blue) or Eedfl/fl (magenta). Comparisons between ZsGreen-positive vs. ZsGreen-negative and ZsGreen-positive vs. Eedfl/fl mTEChi revealed significant differences (p < 0.01). Source data including exact statistical test values are provided in the Source Data file.

16 NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w ARTICLE

centrifugation and incubated for 30 min in sort buffer at 4 °C containing assort- Reporting summary. Further information on research design is available in the Nature ments of fluorochrome-conjugated monoclonal antibodies. After washing, cells Research Reporting Summary linked to this article. were passed through a 40 µm sieve before sorting into 1.5 ml Eppendorf tubes containing 350 µl Qiagen Buffer RLT, which were frozen by pushing into dry ice and then stored at −80 °C until RNA isolation. Cell source, type and number are Data availability displayed in Supplementary Table 2. The full TCR sequence dataset is available at the Sequence Read Archive (BioProject ID PRJNA565651) and processed data are available from the authors on request. RNA-seq and ChIP-seq data are available at the Gene Expression Omnibus (GSE112050 and GSE114713). AIRE ChIP-seq data were downloaded from GSE92597. Other data that TCR sequence acquisition in YAe62-tg T cells. RNA was isolated using Qiagen support the findings of this study are available from the corresponding author upon RNeasy Mini kits with an elution volume of 22 µl, from which 12 µl were used to reasonable request. Source data are provided with this paper. synthesize cDNA (Quantitect RT, QIAgen). Using 5 µl of cDNA template per reaction, TCRα transcripts were PCR amplified using a mix of 24 Trav-specific forward primers and a single Trac-specific reverse primer (Supplementary Table 3). Received: 11 June 2020; Accepted: 31 May 2021; Forward and reverse primers had distinct 5ʹ overhang adapter sequences that enabled addition of sample-specific indices and P5/P7 sequencing adapters in a second PCR using the Illumina Nextera XT DNA library preparation kit. Before the second PCR, magnetic beads (Agencourt AMPure XP, Beckman Coulter) were used to enrich amplicons >100 bp. Conditions for the first PCR were 98 °C for 5 min, 20 cycles of 98 °C for 10 s, 60 °C for 30 s and 72 °C for 30 s, followed by 72 °C for 2 min and for the second PCR were 72 °C for 3 min and 98 °C for 30 s, 20 References cycles of 98 °C for 10 s, 63 °C for 30 s and 72 °C for 30 s, followed by 72 °C for 1 1. Abramson, J. & Anderson, G. Thymic epithelial cells. Annu. Rev. Immunol. 35, – min. After determining amplicon concentrations using a QIAxcel capillary elec- 85 118 (2017). trophoresis machine (Qiagen), equimolar amounts of amplicons from 46 samples 2. Rossi, S. W., Jenkinson, W. E., Anderson, G. & Jenkinson, E. J. Clonal analysis were pooled into a single tube, concentrated using magnetic beads (Agencourt reveals a common progenitor for thymic cortical and medullary epithelium. AMPure XP, Beckman Coulter) and then 300–500 bp amplicons were gel-purified Nature 441, 988–991 (2006). before 250 bp paired-end sequencing on an Illumina MiSeq machine. The full TCR 3. Bleul, C. C. et al. Formation of a functional thymus initiated by a postnatal sequence dataset is available at the Sequence Read Archive (BioProject ID epithelial progenitor cell. Nature 441, 992–996 (2006). PRJNA565651) and processed data are available from the authors on request. 4. Ribeiro, A. R., Rodrigues, P. M., Meireles, C., Di Santo, J. P. & Alves, N. L. Thymocyte selection regulates the homeostasis of IL-7-expressing thymic cortical epithelial cells in vivo. J. Immunol. 191, 1200–1209 (2013). TCR sequence processing. Sequences were aligned to Trav and Traj gene seg- 5. Baik, S., Jenkinson, E. J., Lane, P. J., Anderson, G. & Jenkinson, W. E. + ments, and CDR3 amino acid sequences were ascertained, using molecular iden- Generation of both cortical and Aire( ) medullary thymic epithelial + – tifier groups-based error correction (MIGEC) software66. Subsequent analyses were compartments from CD205( ) progenitors. Eur. J. Immunol. 43, 589 594 performed using RStudio software. All data were filtered to exclude non-functional (2013). CDR3 sequences that were either out-of-frame or contained a stop codon. To avoid 6. Ohigashi, I. et al. Adult thymic medullary epithelium is maintained and overestimating TCR diversity due to PCR or sequencing errors, sequences detected regenerated by lineage-restricted cells rather than bipotent progenitors. Cell fewer than 3 times in any given sample were excluded from further analysis. Rep. 13, 1432–1443 (2015). Sequences that aligned with >1 Trav paralog were assumed to use the Trav paralog 7. Mayer, C. E. et al. Dynamic spatio-temporal contribution of single β5t+ listed first by MIGEC except for Supplementary Fig. 5d, e, from which these cortical epithelial precursors to the thymus medulla. Eur. J. Immunol. 46, ambiguous sequences were excluded. A unique combination of Trav segment and 846–856 (2016). CDR3 amino acid sequence was defined as a clonotype. Each clonotype was 8. Sansom, S. N. et al. Population and single-cell genomics reveal the Aire counted only once per sample. All clonotypes detected in samples of a given dependency, relief from polycomb silencing, and distribution of self-antigen combination of genotype and T cell subset were pooled to form a TCR catalogue. expression in thymic epithelia. Genome Res. 24, 1918–1931 (2014). Unless otherwise indicated, analyses were performed at the TCR catalogue level. 9. Bonasio, R. et al. Clonal deletion of thymocytes by circulating dendritic cells Self-reactive CDR3 doublet expression at positions 6 and 7 of the CDR3 was homing to the thymus. Nat. Immunol. 7, 1092–1100 (2006). determined by calculating the proportion of sequences using any of the 175 amino 10. Hadeiba, H. et al. Plasmacytoid dendritic cells transport peripheral antigens to acid doublets identified as promoting self-reactivity when present at this position. the thymus to promote central tolerance. Immunity 36, 438–450 (2012). For this analysis only, position 1 of the CDR3 was designated as the conserved 11. Yamano, T. et al. Thymic B cells are licensed to present self antigens for cysteine at the CDR3 N-terminus. For diversity analyses, the iNEXT software central T cell tolerance induction. Immunity 42, 1048–1061 (2015). package was used to plot coverage-based rarefaction and extrapolation curves, plus 12. Anderson, M. S. & Su, M. A. AIRE expands: new roles in immune tolerance 67 relative diversity measurements, following the approach of Chao and Jost whose and beyond. Nat. Rev. Immunol. 16, 247–258 (2016). “ ” “ ” “ ” “ term individual we equate with clone , and species we equate with clono- 13. Villasenor, J., Besse, W., Benoist, C. & Mathis, D. Ectopic expression of ” type . Catalogues were assembled in a clone-based (individual-based) abundance peripheral-tissue antigens in the thymic epithelium: probabilistic, monoallelic, format and clonotype (species) diversity estimates were made using the diversity misinitiated. Proc. Natl Acad. Sci. USA 105, 15854–15859 (2008). order (Hill number or q). Morisita Horn indices were computed using EstimateS 14. Derbinski, J., Pinto, S., Rosch, S., Hexel, K. & Kyewski, B. Promiscuous gene (Version 9.1.0, R. K. Colwell, http://purl.oclc.org/estimates) with clonotype abun- expression patterns in single medullary thymic epithelial cells argue for a dance equal to the number of mice in which the clonotype was detected in a given stochastic mechanism. Proc. Natl Acad. Sci. USA 105, 657–662 (2008). TCR catalogue. 15. Meredith, M., Zemmour, D., Mathis, D. & Benoist, C. Aire controls gene expression in the thymic epithelium with ordered stochasticity. Nat. Immunol. 16, 942–949 (2015). α α TCR chain analysis in non-transgenic T cells. TCR repertoire analyses were 16. Pinto, S. et al. Overlapping gene coexpression patterns in human medullary ʹ fi performed by SMARTer 5 RACE cDNA ampli cation on thymocytes as previously thymic epithelial cells generate self-antigen diversity. Proc. Natl Acad. Sci. USA 68 fi 69 described . CDR3 sequences were identi ed using LymAnalyzer . Each unique 110, E3497–E3505 (2013). – fi TRAV TRAJ clonotype was recorded in a FlowJo-based le to calculate fre- 17. Rattay, K., Meyer, H. V., Herrmann, C., Brors, B. & Kyewski, B. Evolutionary quencies of TRAV and TRAJ proximal and distal gene usage. Principal component conserved gene co-expression drives generation of self-antigen diversity in analysis and hierarchical clustering (HC) were performed using FactomineR medullary thymic epithelial cells.J. Autoimmun. 67,65–75 (2016). (http://factominer.free.fr/) and Factoextra (http://www.sthda.com/english/rpkgs/ 18. Brennecke, P. et al. Single-cell transcriptome analysis reveals coordinated factoextra). The following 8 parameters were extracted from TCRα repertoire ectopic gene-expression patterns in medullary thymic epithelial cells. Nat. analysis for HC determination: relative frequencies of distal and proximal TRAV Immunol. 16, 933–941 (2015). segments and frequencies of distal, medium, and distal TRAJ elements within 19. Miragaia, R. J. et al. Single-cell RNA-sequencing resolves self-antigen proximal and distal TRAV containing transcripts. expression during mTEC development. Sci. Rep. 8, 685 (2018). 20. Koh, A. S. et al. Rapid chromatin repression by Aire provides precise control of immune tolerance. Nat. Immunol. 19, 162–172 (2018). Statistical analyses. Statistical analyses for data presented were performed using 21. Smits, A. H., Jansen, P. W., Poser, I., Hyman, A. A. & Vermeulen, M. ’ fi Student s t test (unpaired, two-tailed). p < 0.05 was considered signi cant. The Stoichiometry of chromatin-associated protein complexes revealed by label- statistical evaluation of RNA-seq data is described in separate statistical analysis free quantitative mass spectrometry-based proteomics. Nucleic Acids Res. 41, section above. The sample size used and estimates of variation within groups were e28 (2013). based on published results using similar approaches. No randomization was done 22. Kasinath, V. et al. Structures of human PRC2 with its cofactors AEBP2 and for animal studies and investigators were not blinded to experimental group JARID2. Science 359, 940–944 (2018). allocations.

NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications 17 ARTICLE NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w

23. Hu, D. et al. The Mll2 branch of the COMPASS family regulates bivalent 53. Bolger, A. M., Lohse, M. & Usadel, B. Trimmomatic: a flexible trimmer for promoters in mouse embryonic stem cells. Nat. Struct. Mol. Biol. 20, Illumina sequence data. Bioinformatics 30, 2114–2120 (2014). 1093–1097 (2013). 54. Kim, D., Langmead, B. & Salzberg, S. L. HISAT: a fast spliced aligner with low 24. Faust, C., Schumacher, A., Holdener, B. & Magnuson, T. The eed mutation memory requirements. Nat. Methods 12, 357–360 (2015). disrupts anterior mesoderm production in mice. Development 121, 273–285 55. Anders, S., Pyl, P. T. & Huber, W. HTSeq–a Python framework to work with (1995). high-throughput sequencing data. Bioinformatics 31, 166–169 (2015). 25. Xie, H. et al. Polycomb repressive complex 2 regulates normal hematopoietic 56. Robinson, M. D., McCarthy, D. J. & Smyth, G. K. edgeR: a Bioconductor stem cell function in a developmental-stage-specific manner. Cell Stem Cell 14, package for differential expression analysis of digital gene expression data. 68–80 (2014). Bioinformatics 26, 139–140 (2010). 26. Ohigashi, I. et al. Aire-expressing thymic medullary epithelial cells originate 57. Reimand, J. et al. g:Profiler-a web server for functional interpretation of gene from β5t-expressing progenitor cells. Proc. Natl Acad. Sci. USA 110, lists (2016 update). Nucleic Acids Res. 44, W83–W89 (2016). 9885–9890 (2013). 58. Ilicic, T. et al. Classification of low quality cells from single-cell RNA-seq data. 27. Daley, S. R., Hu, D. Y. & Goodnow, C. C. Helios marks strongly autoreactive Genome Biol. 17, 29 (2016). CD4+ T cells in two major waves of thymic deletion distinguished by 59. Bacher, R. et al. SCnorm: robust normalization of single-cell RNA-seq data. induction of PD-1 or NF-κB. J. Exp. Med. 210, 269–285 (2013). Nat. Methods 14, 584–586 (2017). 28. Azzam, H. S. et al. Fine tuning of TCR signaling by CD5. J. Immunol. 166, 60. Yip, S. H., Wang, P., Kocher, J.-P. A., Sham, P. C. & Wang, J. Linnorm: 5464–5472 (2001). improved statistical analysis for single cell RNA-seq expression data. Nucleic 29. Scott, R. S. et al. Phagocytosis and clearance of apoptotic cells is mediated by Acids Res. 45, 13097 (2017). MER. Nature 411, 207–211 (2001). 61. Korthauer, K. D. et al. A statistical approach for identifying differential 30. Shrimpton, R. E. et al. CD205 (DEC-205): a recognition receptor for apoptotic distributions in single-cell RNA-seq experiments. Genome Biol. 17, 222 and necrotic self. Mol. Immunol. 46, 1229–1239 (2009). (2016). 31. Proietto, A. I. et al. Dendritic cells in the thymus contribute to T-regulatory 62. Stuart, T. et al. Comprehensive integration of single-cell data. Cell 177, cell induction. Proc. Natl Acad. Sci. USA 105, 19869–19874 (2008). 1888–1902.e1821 (2019). 32. Stadinski, B. D. et al. A role for differential variable gene pairing in creating T 63. Aibar, S. et al. SCENIC: single-cell regulatory network inference and cell receptors specific for unique major histocompatibility ligands. Immunity clustering. Nat. Methods 14, 1083–1086 (2017). 35, 694–704 (2011). 64. Žuklys, S. et al. Foxn1 regulates key target genes essential for T cell 33. Stadinski, B. D. et al. Hydrophobic CDR3 residues promote the development development in postnatal thymic epithelial cells. Nat. Immunol. 17, of self-reactive T cells. Nat. Immunol. 17, 946–955 (2016). 1206–1215 (2016). 34. Daley, S. R. et al. Cysteine and hydrophobic residues in CDR3 serve as distinct 65. Bansal, K., Yoshida, H., Benoist, C. & Mathis, D. The transcriptional regulator T-cell self-reactivity indices. J. Allergy Clin. Immunol. 144, 333–336 (2019). Aire binds to and activates super-enhancers. Nat. Immunol. 18, 263–273 35. Wirasinha, R. C. et al. αβ T-cell receptors with a central CDR3 cysteine are (2017). enriched in CD8αα intraepithelial lymphocytes and their thymic precursors. 66. Shugay, M. et al. Towards error-free profiling of immune repertoires. Nat. Immunol. Cell Biol. 96, 553–561 (2018). Methods 11, 653–655 (2014). 36. Baran-Gale, J. et al. Ageing compromises mouse thymus function and 67. Chao, A. & Jost, L. Coverage-based rarefaction and extrapolation: remodels epithelial cell differentiation. eLife 9, e56221 (2020). standardizing samples by completeness rather than size. Ecology 93, 2533– 37. Dhalla, F. et al. Biologically indeterminate yet ordered promiscuous gene 2547 (2012). expression in single medullary thymic epithelial cells. EMBO J. 39, e101828 (2020). 68. Vera, G. et al. Cernunnos deficiency reduces thymocyte life span and alters 38. Gordon, J. et al. Functional evidence for a single endodermal origin for the the T cell repertoire in mice and humans. Mol. Cell Biol. 33, 701–711 thymic epithelium. Nat. Immunol. 5, 546–553 (2004). (2013). 39. Witt, C. M., Raychaudhuri, S., Schaefer, B., Chakraborty, A. K. & Robey, E. A. 69. Yu, Y., Ceredig, R. & Seoighe, C. LymAnalyzer: a tool for comprehensive Directed migration of positively selected thymocytes visualized in real time. analysis of next generation sequencing data of T cell receptors and PLoS Biol. 3, e160 (2005). immunoglobulins. Nucleic Acids Res. 44, e31 (2016). 40. Guo, J. et al. Regulation of the TCRalpha repertoire by the survival window of CD4(+)CD8(+) thymocytes. Nat. Immunol. 3, 469–476 (2002). 41. Apavaloaei, A., Rouette, A., Brochu, S. & Perreault, C. Psmb11 molds the Acknowledgements transcriptome of cortical TECs and CD8 thymocytes. J. Immunol. 198, We thank E. Christen, E. Terszowska and A. Offinger for excellent technical support. 202.214–202.214 (2017). E. Ezhkova for providing Ezh mouse strains, M. Gaio and S. Harris for secretarial 42. Singarapu, N. et al. Polycomb repressive complex 2 is essential for assistance, the Computational Biology Research Group at the Weatherall Institute of development and maintenance of a functional TEC compartment. Sci. Rep. 8, Molecular Medicine for server support and K. Weinacht (Stanford) for logistics. This 14335 (2018). work was supported by grants from the Swiss National Foundation (3100- 68310.02 and 43. Kroger, C. J., Spidale, N. A., Wang, B. & Tisch, R. Thymic dendritic cell 3100–122558 to G.A.H), The Wellcome Trust (105045/Z/14/Z to G.A.H.; 100643/Z/12/Z subsets display distinct efficiencies and mechanisms of intercellular MHC to A.E.H.), the NHMRC of Australia (1107464 to S.R.D.) and the National Institutes of transfer. J. Immunol. 198, 249–256 (2017). Health Research (Clinical Lectureship to A.E.H.) 44. Coquet, J. M. et al. Epithelial and dendritic cells in the thymic medulla + + promote CD4 Foxp3 regulatory T cell development via the CD27-CD70 Author contributions pathway. J. Exp. Med. 210, 715–728 (2013). T. B., A.E.H., S.R.D., H.Y.T., J.dV. and G.A.H. designed the experiments, T.B. A.E.H., 45. Perry, J. S. A. et al. Distinct contributions of Aire and antigen-presenting-cell H.Y.T., R.C.W., S.R.D., K.H., S.Z., B.R. and J.dV. performed the experiments. T.B., subsets to the generation of self-tolerance in the thymus. Immunity 41, A.E.H., H.Y.T., S.R.D., J.dV. and G.A.H. analysed and/or interpreted results. G.A.H., 414–426 (2014). A.E.H., S.R.D, S.H.O. and T.B. wrote the manuscript. 46. Lancaster, J. N. et al. Live-cell imaging reveals the relative contributions of antigen-presenting cell subsets to thymic central tolerance. Nat. Commun. 10, 2220 (2019). Competing interests 47. Anderson, M. S. et al. Projection of an immunological self shadow within the The authors declare no competing interests. thymus by the aire protein. Science 298, 1395–1401 (2002). fi 48. Handel, A. E. et al. Comprehensively pro ling the chromatin architecture of Additional information tissue restricted antigen expression in thymic epithelial cells over development. Front Immunol. 9, 2120 (2018). Supplementary information The online version contains supplementary material 49. Sansom, S.N. et al. Population and single cell genomics reveal the Aire- available at https://doi.org/10.1038/s41467-021-24158-w. dependency, relief from polycomb silencing and distribution of self-antigen expression in thymic epithelia.Genome Res. 24, 1918–1931 (2014). Correspondence and requests for materials should be addressed to G.A.H. – 50. Kim, K. H. & Roberts, C. W. Targeting EZH2 in cancer. Nat. Med 22, 128 134 Peer review information Nature Communications thanks Panagiotis Ntziachristos and (2016). the other, anonymous, reviewer(s) for their contribution to the peer review of this work. 51. Ezhkova, E. et al. EZH1 and EZH2 cogovern histone H3K27 trimethylation and are essential for hair follicle homeostasis and wound repair. Genes Dev. Reprints and permission information is available at http://www.nature.com/reprints 25, 485–498 (2011). 52. Madisen, L. et al. A robust and high-throughput Cre reporting and Publisher’s note Springer Nature remains neutral with regard to jurisdictional claims in characterization system for the whole mouse brain. Nat. Neurosci. 13, 133–140 published maps and institutional affiliations. (2010).

18 NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications NATURE COMMUNICATIONS | https://doi.org/10.1038/s41467-021-24158-w ARTICLE

Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons license, and indicate if changes were made. The images or other third party material in this article are included in the article’s Creative Commons license, unless indicated otherwise in a credit line to the material. If material is not included in the article’s Creative Commons license and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this license, visit http://creativecommons.org/ licenses/by/4.0/.

© The Author(s) 2021

NATURE COMMUNICATIONS | (2021) 12:3933 | https://doi.org/10.1038/s41467-021-24158-w | www.nature.com/naturecommunications 19