At the risk of boring the pants off everyone, I can add a bit more to the explanation. It is a misconception to think of the kinetic energy of a moving object as coming directly from its velocity, as it actually comes directly from the acceleration needed bring the object up to that velocity in the first place.

Imagine the pellet sitting in the barrel at rest, with zero velocity and zero energy. When the force from the compressed hits it, it is then rapidly accelerated along the barrel under the effect of the constantly applied force, the velocity increasing progressively until it leaves the muzzle. The law of physics states that the energy transferred to an object in such a process is given by the mass of the object, m, multiplied by the acceleration, a, and the distanced moved d.
Easy to remember as: E = m.a.d.

Acceleration is not the same as velocity, but is the rate at which the velocity is increasing. Acceleration times distance, a.d., is related to velocity squared, not velocity, which is why the kinetic energy of the pellet is not simply proportional to the velocity of the pellet.