People-centric activity recognition is one of the most critical technologies in a wide range of real-world applications, such as intelligent transportation system, healthcare service and brain-computer interface. However, the large scale data collection and annotation make the application of machine learning algorithms prohibitively expensive when adapt to new tasks. One way to circumvent this limitation is to train the model in semi-supervised learning manner, which utilizes a percentage of unlabeled data to reduce the labeling burden in prediction tasks. Despite the appeal, such models often assume that labeled and unlabeled data come from the same or similar distributions, which leads to the domain shift problem due to the presence of distribution gaps. To address these limitations, we propose a novel method for people-centric activity recognition named Domain Generalization with Semi-Supervised Leaning (DGSSL) that effectively enhances the representation learning and domain alignment capabilities of the model. Specifically, we first design a new autoregressive discriminator for adversarial training between unlabeled source domain and labeled target domain, extracting domain-specific features to reduce the distribution gaps. Secondly, we introduce two reconstruction tasks to capture the task-specific features to avoid losing information related to representation learning while maintaining task-specific consistency. Finally, benefiting from the collaborative optimization of these two types of tasks, the model can accurately predict both the category label of target domain and domain label of source domain for classification task. Extensive experiments are conducted on three real-world sensing datasets, and the experimental results show that our proposed DGSSL surpasses the three types of state-of-the-art methods with better performance and generalization.