This repository contains a Generative AI project created using Gemini API.
It is a simple multilingual AI powered questions generator based on the news article provided.
Project is developed under the Generative AI Applications using Vertex AI
course by SmartBridge in collaboration with Google.
Our client, NewsSphere, is a leading news organization dedicated to expanding its global reach and enhancing audience engagement. With a vast amount of content published daily in multiple languages, the organization faces the considerable challenge of manually creating quizzes and assessments for each article. This process is not only time-consuming but also prone to inconsistencies across different languages and cultural contexts.
Develop an AI-driven question generator for client to create relevant questions across multiple languages.
Implement language detection, translation, and question generation using Generative models and Machine translation services.
-
User Input: User submits a news article in any language.
-
Language Detection: The app utilizes the Translation API to detect the language of the submitted content.
-
Translation to English: If the content is not in English, the app translates it into English using the Translation API.
-
Question Generation: The app calls the Gemini API to generate diverse and contextually relevant questions based on the English version of the news article.
-
Translation Back: The generated questions are translated back into the original language of the news article using the Translation API.
-
Output: The app presents the questions in the original language to the user.
-
Automated Language Detection and Translation:
- Provides automated language detection, seamless translation, and generation of contextually appropriate questions.
-
Cultural Sensitivity and Accuracy:
- Ensures cultural sensitivity and accuracy across multiple languages.
- Adapts to linguistic nuances and cultural contexts, enhancing the relevance and appropriateness of generated questions.
-
Streamlined Quiz Creation:
- Streamlines the quiz creation process, making it faster and more efficient for content creators.
-
Enhanced User Engagement:
- Enhances user engagement by providing interactive and relevant questions that resonate with a global audience.
- Encourages users to explore news content more deeply through engaging and thought-provoking quizzes.
-
Improved Efficiency and Accuracy:
- Reduces the workload on content creators, allowing them to focus on curating and delivering impactful news content.
- Python
- Streamlit (python)
- Langdetect (python)
- Gemini API
-
Clone Repository:
git clone https://github.com/Bbs1412/GenAI_SB cd GenAI_SB
-
Create and activate python environment:
python -m venv env .\env\Scripts\activate
-
Install the required libraries:
pip install -r requirements.txt
-
Create a file 'api.env' in current directory and save the API-key in it:
PALM_API_KEY="your_key"
-
Run the app:
streamlit run app.py
- Video demonstration of project implementation:
Click here
- Bhushan Songire (LinkedIn)
- Soumya Nayak
- Anjith Thomas Jose
- Diya Shibu
Any contributions or suggestions are welcome!
- Email - bhushanbsongire@gmail.com