Infectious disease spreading is a spatial interaction process. Assessing community vulnerability to infectious diseases thus requires not only information on local demographic and built environmental conditions, but also insights into human activity interactions with neighboring areas that can lead to the transition of vulnerability from locations to locations. This study presented an analytical framework based on the Particle Swarm Optimization model to estimate the weights of the factors for vulnerability modeling, and a local proportional parameter for use in the integration of the local and neighboring area risks. A country model and five cross-region validation models were developed for the case study of Singapore to assess the vulnerability to COVID-19. The results showed that the identified weights for the factors were robust throughout the optimization process and across various models. The local proportional parameter could be set slightly higher in between 0.6 and 0.8 (out of 1), signifying that the local effect was higher than the neighboring effect. Computation of the weights from the optimal solutions for the integrated vulnerability index showed that the factors of human activity intensity and accessibility to amenities had much higher weights, at 0.5 and 0.3, respectively. Conversely, the weights of population density, elderly population, social economic status and land use diversity were much lower. These findings underscored the importance of considering non-equal weights for factors and incorporating spatial interactions between local and neighboring areas for vulnerability modeling, to provide to a more comprehensive assessment of vulnerability to infectious diseases.