Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Programming exercises: Add Artemis intelligence consistency check #10209

Merged
merged 80 commits into from
Jan 31, 2025

Conversation

wasnertobias
Copy link
Contributor

@wasnertobias wasnertobias commented Jan 26, 2025

Important

This PR builds on #10156, merge afterwards. The Pyris code is already merged and should work on TS1, TS3, and TS5 (TS3 had some issues, which might still persist. Use TS1 or TS5)

Checklist

General

Server

  • Important: I implemented the changes with a very good performance and prevented too many (unnecessary) and too complex database calls.
  • I strictly followed the principle of data economy for all database calls.
  • I strictly followed the server coding and design guidelines.
  • I added multiple integration tests (Spring) related to the features (with a high test coverage). -> Follow-up due to time reasons
  • I added pre-authorization annotations according to the guidelines and checked the course groups for all new REST Calls (security).
  • I documented the Java code using JavaDoc style.

Client

  • Important: I implemented the changes with a very good performance, prevented too many (unnecessary) REST calls and made sure the UI is responsive, even with large data (e.g. using paging).
  • I strictly followed the principle of data economy for all client-server REST calls.
  • I strictly followed the client coding and design guidelines.
  • Following the theming guidelines, I specified colors only in the theming variable files and checked that the changes look consistent in both the light and the dark theme.
  • I added multiple integration tests (Jest) related to the features (with a high test coverage), while following the test guidelines. -> Follow-up due tue time reasons
  • I added authorities to all new routes and checked the course groups for displaying navigation elements (links, buttons).
  • I documented the TypeScript code using JSDoc style.
  • I added multiple screenshots/screencasts of my UI changes.
  • I translated all newly inserted strings into English and German.

Motivation and Context

Although we try our best when creating a programming exercise sometimes there are inconsistencies between problem statement, template repository, solution repository and so one. Those mostly happen when updating an exercise to a different theme or generally forgetting to change something. To catch those inconsistencies, we want to use LLMs to detect them and make the instructors aware about them.

Description

Adds an Artemis Intelligence markdown action on the problem statement of programming exercises called "Check consistency". The action triggers a consistency check pipeline on the Pyris side and displays the result below the problem statement in a dismissible alert.

Steps for Testing

Prerequisites:

  • 1 Instructor (Editor or above)
  • 1 Programming exercise

Make sure to deploy to a test server with Iris enabled (i.e. TS1, TS5 or TS3 if it is fixed already)

  1. Log in to Artemis
  2. Navigate to Course Management
  3. Navigate to any course
  4. Click "Exercises"
  5. Click edit on a programming exercise (create one if none exist)
  6. Scroll to problem statement
  7. Add some inconsistency to the problem statement (i.e. QuickSort instead of MergeSort etc.)
  8. Save the problem statement (top right)
  9. In the toolbar of the markdown editor, right of "Insert Test Case", click AI [Artemis Intelligence] and then "Check consistency"
  10. Wait for a bit, can take 10s or so
  11. Below the problem statement a warning alert with the result should be shown
  12. The result will not be 100% correct but it might detect some issues (like CodeRabbit does for instance)
  13. Click X and the alert should disappear

Testserver States

Note

These badges show the state of the test servers.
Green = Currently available, Red = Currently locked
Click on the badges to get to the test servers.







Review Progress

Code Review

  • Code Review 1
  • Code Review 2

Manual Tests

  • Test 1
  • Test 2

Test Coverage

Will be done as follow-up.

Screenshots

Untitled mov

Summary by CodeRabbit

Release Notes: Artemis Intelligence Consistency Check Feature

  • New Features

    • Added a consistency check functionality for programming exercises.
    • Users can now trigger a consistency check on exercise instructions.
    • Provides real-time status updates and results via WebSocket.
    • New REST endpoint for checking consistency of programming exercises.
  • User Interface

    • New alert to display consistency check results in the instructions editor.
    • Added localized translations for consistency check commands and alerts.
  • Backend Improvements

    • Introduced new services and resources to support consistency checking.
    • Implemented secure endpoint for initiating consistency checks.
    • Enhanced job management for tracking consistency check status.
    • Improved loading state management for consistency checks.

cremertim and others added 30 commits January 16, 2025 11:55
…-pipeline' into feature/communication/rephrasing-pipeline
…-pipeline' into feature/programming-exercises/rephrase-action-for-problem-statement
@github-actions github-actions bot added deployment-error Added by deployment workflows if an error occured and removed deploy:artemis-test1 labels Jan 31, 2025
@ls1intum ls1intum deleted a comment from github-actions bot Jan 31, 2025
@FelixTJDietrich FelixTJDietrich added deploy:artemis-test1 and removed deployment-error Added by deployment workflows if an error occured labels Jan 31, 2025
@github-actions github-actions bot added deployment-error Added by deployment workflows if an error occured and removed deploy:artemis-test1 labels Jan 31, 2025
@FelixTJDietrich FelixTJDietrich removed the deployment-error Added by deployment workflows if an error occured label Jan 31, 2025
Copy link
Contributor

@coolchock coolchock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

code lgtm, just one small nit-pick

Copy link
Contributor

@cremertim cremertim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reapprove latest changes

Copy link
Contributor

@EneaGore EneaGore left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested on TS1, worked as described.

Copy link

@Cathy0123456789 Cathy0123456789 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-tested on TS1. Works as expected
image
Headers appear thrice sometimes though

Copy link

@SindiBuklaji SindiBuklaji left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested on Ts1. It works as described. 👍

@krusche krusche changed the title Programming exercises: Add Artemis Intelligence consistency check Programming exercises: Add Artemis intelligence consistency check Jan 31, 2025
@krusche krusche merged commit f7c5970 into develop Jan 31, 2025
51 of 55 checks passed
@krusche krusche deleted the feature/programming-exercises/consistency-check branch January 31, 2025 14:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
client Pull requests that update TypeScript code. (Added Automatically!) iris Pull requests that affect the corresponding module ready to merge server Pull requests that update Java code. (Added Automatically!)
Projects
Status: Merged
Development

Successfully merging this pull request may close these issues.

9 participants