The norm in classical Sobolev spaces can be expressed as a difference quotient. This expression can be used to generalize the space to the fractional smoothness case. Because the difference quotient is based on shifting the function, it cannot be used in generalized Orlicz spaces. In its place, we introduce a smoothed difference quotient and show that it can be used to characterize the generalized Orlicz-Sobolev space. Our results are new even in Orlicz spaces and variable exponent spaces.