Disclaimer: I haven't actually tested this but it seems feasible.
I agree with trichoplax that what you want could possibly be expressed more clearly but, assuming I've understood correctly, would the following do the job?
First I assume you can supply the opaque and translucent geometry separately, and that the opaque is sent first. I'm also going to assume there may be translucent geometry with exactly the same pixel Z values.(If this isn't the case, the stencil requirements could probably be dropped.)
To handle the "single translucent layer", clear the stencil buffer and send the translucent polygons to update the Z-buffer and set the stencil buffer on each pixel, but don't touch the frame buffer.
Submit the translucent data a second time (to actually update the framebuffer), but change the Z test to 'equal' and only allow drawing on the pixels that are currently set in the the stencil buffer. Also clear the stencil for any pixels that pass the tests.
This, I think, should result in only the closest translucency layer being applied.