For the first design, port B is connected to the air chamber, port A is connected to the barrel.
This is how the valve on my gun is arranged.
    The o-rings on the piston don't need to be airtight for this design, so long as they don't leak more air than can be exhausted by the firing valve.

    For the second design, port A is connected to the air chamber, port B is connected to the barrel.
    As far as I know, this is similar to the arrangement the "Supah-Valve" uses.
The o-rings on this design need to form an airtight seal around the piston.

    For both designs, the face seal on the piston must be airtight.  For fast operation, the piston should be lightweight and there should be a minimum of dead air to exhaust behind it (less air to exhaust = faster operation).

Also, (this is critical), the piston MUST have more frontal surface area than the port that it seals against, or it simply will not function.