An assembly is provided for a turbine engine. This turbine engine assembly includes a stationary structure, a rotating structure and an electric machine. The rotating structure is rotatably mounted to the stationary structure by a first bearing and a second bearing. The electric machine is between the first bearing and the second bearing. The electric machine includes a rotor and a stator circumscribing the rotor. The rotor is connected to the rotating structure. The stator is connected to the stationary structure.