Add Table To Display AI Feature Settings
What does this MR do and why?
This MR adds the table for displaying feature settings in the AI feature settings page in the admin menu. It currently uses stubbed data to render the table rows. This will be swapped out when the necessary back-end work is complete. @jpcyiza and I have agreed upon the format of the data here and this is what the stubbed data works off. Out of scope for this MR is the model selection dropdowns which will be handled in a follow-up MR.
Endpoint: admin/ai/feature_settings
Figma design: https://www.figma.com/design/xgC4SOG8aFxK2VfSvwjtgW/Self-hosted-models?node-id=828-86426&m=dev
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
Before | After |
---|---|
How to set up and validate locally
Prequisites
You will need an active GitLab ultimate license.
- Start GDK instance in self-managed mode:
GITLAB_SIMULATE_SAAS=0 && gdk start
- In the rails console, enable Code Suggestions and the custom models experiment:
add_on = GitlabSubscriptions::AddOn.find_or_create_by!(name: "code_suggestions") {|e| e.description = "Test"}
add_on_purchase = GitlabSubscriptions::AddOnPurchase.create!(add_on: add_on, expires_on: 1.month.from_now, quantity: 5, purchase_xid: 'A-S0001')
Feature.enable(:ai_custom_model)
ApplicationSetting.first.update(duo_features_enabled: true)
- Enable the admin ai-powered feature settings FF
Feature.enable(:custom_models_feature_settings_vue_app)
Test it!
- Log in as an admin
- Visit the index page Admin Area > AI-Powered Features > Features
- You should see a screen similar to the "After" screenshot above
Related to #476660 (closed)