The current study characterized CD8 TRM cells in the tumor microenvironment of HCC and investigated the association between CD8 TRM cells and their subsets expressing CD39 or PD-1/PD-L1 signaling and the efficacy of ICB-based immunotherapy in patients with advanced HCC. The gene discussed is PDCD1; the disease is neoplasm.