Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-84779

AI: Recall action settings when changing models

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • 5.0
    • AI
    • MOODLE_500_STABLE
    • MDL-84779-main
    • Hide

      There is Behat coverage too.

      Test settings

      1. Log in as admin
      2. Go to Site admin -> General -> AI -> Ai providers
      3. Click on 'Create a new provider instance'
      4. Choose 'OpenAI' from the provider dropdown (we need a provider with at least 2 models)
      5. Fill out the rest of the form and enter in a valid API key (we will need this later, reach out if you need credentials)
      6. Click on the 'Settings' link for your new provider
      7. Click on the 'Settings' link for 'Generate text'
      8. Change the 'AI model' to 'GPT-4o'
      9. Enter in some values under the 'Settings' area
      10. Save changes
      11. Click again on the 'Settings' link for 'Generate text'
      12. CONFIRM you see the values you entered for 'GPT-4o'
      13. Change the model to 'O1'
      14. CONFIRM the fields under 'Settings' are emptied
      15. Enter in some values under the 'Settings' area
      16. Save changes
      17. Click again on the 'Settings' link for 'Generate text'
      18. Change the model to 'Custom'
      19. Add in some JSON for 'Extra parameters'
      20. Save changes
      21. Click again on the 'Settings' link for 'Generate text'
      22. CONFIRM that toggling between all the models recalls their settings

      Extra test

      There shouldn't be changes to the processing part of the AI code, but just ensure that AI actions can still be performed as normal.

      1. Go to Site admin -> General -> AI -> Ai placements
      2. Enable 'Text editor placement'
      3. Go to your edit profile page and locate the editor
      4. Generate some AI text
      5. CONFIRM that there are no errors

       

      Show
      There is Behat coverage too. Test settings Log in as admin Go to Site admin -> General -> AI -> Ai providers Click on 'Create a new provider instance' Choose 'OpenAI' from the provider dropdown (we need a provider with at least 2 models) Fill out the rest of the form and enter in a valid API key (we will need this later, reach out if you need credentials) Click on the 'Settings' link for your new provider Click on the 'Settings' link for 'Generate text' Change the 'AI model' to 'GPT-4o' Enter in some values under the 'Settings' area Save changes Click again on the 'Settings' link for 'Generate text' CONFIRM you see the values you entered for 'GPT-4o' Change the model to 'O1' CONFIRM the fields under 'Settings' are emptied Enter in some values under the 'Settings' area Save changes Click again on the 'Settings' link for 'Generate text' Change the model to 'Custom' Add in some JSON for 'Extra parameters' Save changes Click again on the 'Settings' link for 'Generate text' CONFIRM that toggling between all the models recalls their settings Extra test There shouldn't be changes to the processing part of the AI code, but just ensure that AI actions can still be performed as normal. Go to Site admin -> General -> AI -> Ai placements Enable 'Text editor placement' Go to your edit profile page and locate the editor Generate some AI text CONFIRM that there are no errors  
    • Hide

      Code verified against automated checks.

      Checked MDL-84779 using repository: https://github.com/davewoloszyn/moodle.git

      More information about this report

      Built on: Fri May 16 03:29:46 UTC 2025

      Show
      Code verified against automated checks. Checked MDL-84779 using repository: https://github.com/davewoloszyn/moodle.git main (0 errors / 0 warnings) [branch: MDL-84779-main | CI Job ] More information about this report Built on: Fri May 16 03:29:46 UTC 2025
    • Show
      Launching automatic jobs for branch MDL-84779 -main https://ci.moodle.org/view/Testing/job/DEV.02%20-%20Developer-requested%20PHPUnit/19360/ PHPUnit (sqlsrv) https://ci.moodle.org/view/Testing/job/DEV.01%20-%20Developer-requested%20Behat/66165/ Behat (NonJS - boost and classic) https://ci.moodle.org/view/Testing/job/DEV.01%20-%20Developer-requested%20Behat/66166/ Behat (Firefox - boost) https://ci.moodle.org/view/Testing/job/DEV.01%20-%20Developer-requested%20Behat/66167/ Behat (Firefox - classic) https://ci.moodle.org/view/Testing/job/DEV.01%20-%20Developer-requested%20Behat/66168/ App tests (stable app version) Built on: Fri May 16 04:25:14 UTC 2025
    • 6
    • Team Hedgehogs 2025 Sprint 2.0, Team Hedgehogs 2025 Sprint 2.1, Team Hedgehogs 2025 Sprint 2.2

      When working with model action settings for AI provders it should be possible to save settings for several models.

      This will make it easier for admins to manage and try different models for an action.

      Currently when changing a model for an action the settings for the previous model are lost when the new model settings are saved. Instead the model action settings should be saved to the database independently and associted with the provider, so they can be recalled.

            david.woloszyn@moodle.com David Woloszyn
            matt.porritt@moodle.com Matt Porritt
            Meirza Meirza
            Huong Nguyen Huong Nguyen
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 week, 4 hours, 26 minutes
                1w 4h 26m

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.