In T363506: Pass image objects to the logo detection service we discussed options to prevent the service from downloading an uploaded image via a stash URL, which has limitations in terms of security (see T362749#9785333), privacy (see T362749#9785550, T362749#9786161), and likely performance.
The agreed solution is to send a thumbnail image object to the logo detection service within Upload Wizard: investigate its feasibility.
Steps
- investigate if we can access Thumbor's results of stashed images from MediaWiki - SpecialUploadStash has an outputThumbFromStash method, which seems to indicate that it's possible
- the thumbnail should be 224x224 pixels
- decide the image serialization format, e.g., binary or base64
- inform ML in T363506#9794241
- set up an internal API endpoint in Upload Wizard that
- accesses the stashed thumbnail
- sends it to a LiftWing internal endpoint - the logo detection service isn't exposed yet, so it might be worth trying with an available one
- includes a content length request header