globe-and-citizen / Celebrity-Fanalyzer

Celebrities Over Analyzed
https://celebrityfanalyzer.com
GNU General Public License v2.0
5 stars 11 forks source link

Implemented ai comments analysis #398

Closed marclupanc closed 2 weeks ago

marclupanc commented 2 weeks ago

Implemented comments analysis using openAi api. Created an "Analyze sentimen" button. When clicked the request is sent to stats-api where we check if it exists in cache, if so return cached sentiment, otherwise we send an request to OpenAi to analyze users' sentiment based on comments and return + save in cache the result.

Analyze button appears only if there are 10 or more comments! This way we reduce unnecessary calls to API.

https://vimeo.com/961331486?share=copy

Screenshot 2024-06-18 at 18 55 16 Screenshot 2024-06-18 at 18 17 27