Store all suggestions in the database that are shown to users. Currently, only their interactions with suggestions are tracked ("accept" or "reject").
This feature will require all of the suggestion retrieving and processing logic to be moved to the back end.
This means we need two new GET API routes for ISA, e.g.
Each api route will do the following:
- Get any suggestions already stored in the suggestions table for the requested image
- Retrieve new suggestions from the API
- Filter results to remove Denylist items and permanently rejected suggestions
- Add any suggestions that are not already in the database (as a new row, with status "unreviewed")
- Respond with JSON array of suggestion objects, including a key to indicate if the logged in user has rejected any of the suggestions.
Front end would need to be adjusted to consume the new APIs and remove the processing logic that won't be needed there anymore.
Used for generating usage stats to better understand the quality of suggestions.
Would be able to calculate the percentage of of the suggestions that have been accepted/rejected by each service.