Welcome to AAC.The base current comes from the photocell, no?
Great, thanksWelcome to AAC.
Yes, the photosensitivity of the base is the main point of a phototransistor, but, many include an external electrical connection to it. This allows for a couple of useful things: biasing, to adjust sensitivity; and overriding of the output electrically.
It can probably be ignored in your application since you didn't anticipate using it. Just test the device and work out which pin gives you the output you expect and leave the other unconnected.
This makes sense since the naming—poorly translated Chinese—supports it. But, if that’s the case, testing for an output that works and ignoring the other will work just as well.2 pin side is emitter LED
3 pin side was likely to be transistor as Dick Chapels and others suggested but... due to additional info on the PCB silkscreen, i would say this it not the case, this must be a dual output product as used in computer mouse (quadrature encoder). and since on a separate PCB this is most likely scroll wheel sensor. same was used for X/Y position in the old ball mouse but those would be on the same PCB.