a Schematic diagram of bacterial transplantation and behavioral tests. b The cumulative distance (meters) in different zones in 30-min Open field test (OFT) in the three groups of mice with oral gavage of Streptococcus vestibularis, S. thermophilus, and saline, respectively. c the cumulative distance (meters) in every 10-minutes time interval of OFT traveled and d the number of rearing by S. vestibularis-gavaged mice compared to mice gavaged with S. thermophilus and control mice. e–g three-chamber social test (TCST) comparing sociability of S. vestibularis-gavaged mice to that of S. thermophilus-gavaged mice and control mice. The results show that S. thermophilus-gavaged mice and saline-gavaged mice display obvious sociability, i.e., demonstrate an increase in the number of times probing a mouse (e, P < 0.0001) and spending longer time interacting with a mouse (f, P = 0.002) compared to an empty cage, and obvious social novelty, i.e., spending longer time interacting with an unacquainted mouse (new mouse; g, P = 0.005) in comparison with an acquainted mouse. However, these types of social behaviors were not observed in S. vestibularis-gavaged mice (for sociability: e, P = 0.881; f, P = 0.282; for social novelty, g, P = 0.923). The data are representative of two independent experiments and are presented as means ± SEM (n = 16 S. vestibularis-gavaged mice or S. thermophiles-gavaged mice, 17 saline-gavaged mice per independent experiment in OFT; n = 16 mice/group/independent experiment in TCST). The circle represents one value from individual mice (b, d, e–g). P-values were determined by one-way analysis of variance (ANOVA) (b), repeated measure two-way ANOVA followed by Sidak’s multiple comparisons test (c; Blue P: S. vestibularis-gavaged versus saline-gavaged mice; green P: S. thermophilus-gavaged versus saline-gavaged mice), two-sided Kruskal-Wallis test followed by Dunn’s multiple comparisons test (d), or two-way (ANOVA) followed by Sidak’s multiple comparisons test (e–g). See detailed statistical data in supplementary Source Data file.