Plays role in pre-mRNA splicing as component of the U4/U6-U5 tri-snRNP complex that is involved in spliceosome assembly, and as component of the precatalytic spliceosome (spliceosome B complex). The heptameric LSM2-8 complex binds specifically to the 3'-terminal U-tract of U6 snRNA. Component of the precatalytic spliceosome (spliceosome B complex). Component of the U4/U6-U5 tri-snRNP complex, a building block of the precatalytic spliceosome (spliceosome B complex). The U4/U6-U5 tri-snRNP complex is composed of the U4, U6 and U5 snRNAs and at least PRPF3, PRPF4, PRPF6, PRPF8, PRPF31, SNRNP200, TXNL4A, SNRNP40, SNRPB, SNRPD1, SNRPD2, SNRPD3, SNRPE, SNRPF, SNRPG, DDX23, CD2BP2, PPIH, SNU13, EFTUD2, SART1 and USP39, plus LSM2, LSM3, LSM4, LSM5, LSM6, LSM7 and LSM8. LSM2, LSM3, LSM4, LSM5, LSM6, LSM7 and LSM8 form a heptameric, ring-shaped subcomplex (the LSM2-8 complex) that is part of the U4/U6-U5 tri-snRNP complex and the precatalytic spliceosome. Ubiquitous. Belongs to the snRNP Sm proteins family.