In generalized linear models, the score function can be viewed as an inner product of random error and certain functions of covariates, the random error here is the difference between response variable and its expectation conditioning on covariates. Consider the Hilbert space that consists of random variables with finite 2nd moments, the conditional mean is viewed as the projection of response variable onto the subspace of covariates.
If the mean function is correctly specified, then residual will be close to the random error and hence approximately orthogonal to the space of functions of covariates. But when the model is misspecified, one is unable to find the projection and hence the residual will not be orthogonal to the space. It implies that there exist functions of covariates that has inner product with residual not being 0.
Based on this observation, we develop a series of test statistics for testing whether or not the inner product is 0. This testing procedure is novel, straightforward in interpretation and easy for implementations. We show this test is favorable when comparing with many existent methods through simulation study.