AOSSIE-Org / AOSSIE-Org/EduAid

[FEATURE]: Allow the user to input an API key to an advanced LLM (by OpenAI, Anthropic etc) to generate higher quality questions

Aperta
#580 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
enhancement
Lingua principale
JavaScript
Stelle
171
Fork
425
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

**Feature and its use cases**
Add an optional external LLM mode in the extension so users can enter provider API credentials in the extension UI, select a model, and generate quizzes using that provider instead of only local/default models.

_What is the feature?_
- External provider mode toggle (local/default vs external)
- Provider selection (openai, anthropic)
- API key input in extension UI
- Model selection in extension UI
- Use selected provider/model in backend generation endpoints

_How would users benefit?_
- Better quiz quality for users with access to stronger models
- Flexible choice between local generation and external models
- No need to edit IDE/backend files for API key setup

_What scenarios would this address?_
- User wants higher-quality MCQ distractors
- User wants provider-specific output style
- User wants fallback to local mode when no API key is provided

**Additional Context**

_Scope_
- Extension UI changes for provider mode, API key, model selection
- Backend routing for external generation in:
1. get_mcq
2. get_boolq
3. get_shortq
4. get_problems

- Keep local/default generation unchanged when external mode is off
- Fix “All Questions” parsing/runtime issues for mixed output shapes

**Acceptance Criteria**
- External mode works end-to-end with OpenAI/Anthropic
- Local mode remains fully functional
- The user's provided API key is not exposed to others; it is stored locally.
- External MCQ output avoids obvious duplicates (answer repeated in options, repeated options)

### Additional Context

_No response_

### Code of Conduct

- [x] I have joined the [Discord server](https://discord.gg/hjUhu33uAn) and will post updates there
- [x] I have searched existing issues to avoid duplicates

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.