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

Modeling exercises: Fix submission error and redundant tooltip for AI feedback #9437

Merged
Merged
Show file tree
Hide file tree
Changes from 129 commits
Commits
Show all changes
130 commits
Select commit Hold shift + click to select a range
f03e5e5
add UI options for AI Feedback and result history
Aug 4, 2024
1067ef1
Add Athena Feedback option for text exercises
Aug 16, 2024
80242a0
Add Athena AI Feedback button and history to Text Exercises
Aug 16, 2024
0245572
Add check for automatic Athena results in code editor so the student …
Aug 16, 2024
992a2bd
Update result components for Text Feedback
Aug 16, 2024
b49ca0f
Handle toggle of athena ai feedback request option
Aug 16, 2024
b79d325
Get the last submission for assessment for text exercises
Aug 21, 2024
c79b540
Preliminary Feedback Server
Aug 22, 2024
5405ae1
Fix Assessment tutor side issues
Aug 22, 2024
9ddc3d9
remove todo
Aug 22, 2024
01159dc
Merge branch 'feature/text-exercises/immediate-preliminary-feedback' …
Aug 22, 2024
79c4739
Merge branch 'develop' into feature/text-exercises/immediate-prelimin…
EneaGore Aug 22, 2024
a5b1c45
prettier
EneaGore Aug 22, 2024
da61ffa
Formattierung
Aug 22, 2024
95895b1
Merge branch 'feature/text-exercises/immediate-preliminary-feedback' …
Aug 22, 2024
f1cf351
Improve results for preliminary text AI Feedback
Aug 23, 2024
1c6ac3d
Fix result icon and color for Ai Feedback
Aug 23, 2024
52083fe
typo
Aug 23, 2024
6070cb6
ups
Aug 23, 2024
44f8cef
typo
Aug 23, 2024
ac360d4
improve result strings for text ai feedback
Aug 23, 2024
3de99f0
set ai feedback for text to graded
Aug 23, 2024
2f99541
add spinner for ai feedback
Aug 23, 2024
d1a30f7
small improvements
Aug 23, 2024
b192080
fix rate limit and editor sign when athena results
Aug 23, 2024
69a179e
clean up code
Aug 23, 2024
c8f5526
revert last change partially
Aug 23, 2024
f6e5aef
turn off automatic feedback requests if no module selected
Aug 23, 2024
753c050
update string for successful and failed athena feedback
Aug 27, 2024
a175663
refactor feedback request (Thanks Leon)
Aug 27, 2024
4c97671
show spinner, don't save or show empty or failed athena results
Aug 27, 2024
0c4f088
dont save emppty result, new method for new submission after athena f…
Aug 27, 2024
7269dcb
Improve error handling and better manage result templates
Aug 27, 2024
f73fad8
Add integration tests
Aug 28, 2024
464dfe8
no junit 4
Aug 28, 2024
560af55
no assert Throws
Aug 28, 2024
23dd234
save transient instance in test
Aug 28, 2024
db0e185
use text exercise id for text participation test
Aug 28, 2024
4067400
use text course
Aug 28, 2024
d60b372
separate programming and text athena tests
Aug 28, 2024
5dc5b6e
better tests
Aug 28, 2024
69ab55e
fix text case success
Aug 28, 2024
a9b2243
code clean up
Aug 28, 2024
a2c1ecd
more code clean up
Aug 28, 2024
fca28bc
turn athena created submission external and fix successful = false bugs
Aug 28, 2024
a684a48
address change Request (part 1)
Aug 28, 2024
ce056ff
optional chain
Aug 28, 2024
9de3a3f
disable feedback button when generating and address feedback (part 2)
Aug 28, 2024
d8f292d
bring back the spinner
Aug 28, 2024
8d5187d
better condition for spinner and some client tests
Aug 29, 2024
03c3bd1
fix result icon and color
Aug 29, 2024
4b72a4a
typo
Aug 29, 2024
b4dc9db
back to gray for Athena results
Aug 29, 2024
fc8c873
more result client tests
Aug 29, 2024
f59b2b3
result spec ts conflict
Aug 29, 2024
2099628
result spec ts conflict
Aug 29, 2024
c77e624
Merge branch 'develop' into feature/text-exercises/immediate-prelimin…
Aug 29, 2024
56982d0
add text athena result tests after conflict resolve
Aug 29, 2024
48d56c8
use notch instead of spinner
Aug 29, 2024
901eff2
blue notch, no endless spin in more results, error alert from client …
Aug 30, 2024
9010ae1
new submission only after student submits if athena results present, …
Aug 30, 2024
ce159f4
minor code improvements
Aug 30, 2024
4b0d29f
small bugfix
Aug 30, 2024
75f88ac
turn window alerts to alert warning and update tests
Aug 30, 2024
5b5554c
Add check if last submission already has results + test + getNonAthen…
Aug 31, 2024
6d2a594
Update server code to also handle AI Feedback for Modeling Exercises
LeonWehrhahn Sep 2, 2024
9a3f613
Add athenaEnabled check
LeonWehrhahn Sep 3, 2024
c1df8b0
test: Add automatic Athena result test for modeling exercises
LeonWehrhahn Sep 4, 2024
fe3d235
Merge branch 'develop' into feature/text-exercises/immediate-prelimin…
FelixTJDietrich Sep 4, 2024
287e20c
after develop merge entities -> entities/text
EneaGore Sep 4, 2024
f23244d
Fix integration tests. Also send null results with non athena results
Sep 6, 2024
cf1b90a
Merge branch 'develop' into feature/text-exercises/immediate-prelimin…
EneaGore Sep 7, 2024
86f7b6e
Merge branch 'develop' into feature/modeling-exercises/immediate-prel…
LeonWehrhahn Sep 8, 2024
ac8cb0a
Merge branch 'develop' into feature/text-exercises/immediate-prelimin…
EneaGore Sep 8, 2024
ad97f5f
Revert Integration Tests
EneaGore Sep 9, 2024
1bd4f94
Try a signle import of AthenaRequestMockProvider
EneaGore Sep 9, 2024
3deaceb
Spy Bean -> Mock bean
EneaGore Sep 9, 2024
69bf43b
Add websocket spy bean declaration
EneaGore Sep 9, 2024
6684a2b
remvoe mock bean websocket from participipation integration test
EneaGore Sep 9, 2024
20d3811
java style
EneaGore Sep 9, 2024
9618c23
Merge branch 'develop' into feature/text-exercises/immediate-prelimin…
FelixTJDietrich Sep 10, 2024
45e72ca
Merge branch 'develop' into feature/modeling-exercises/immediate-prel…
LeonWehrhahn Sep 10, 2024
6f5d47e
Merge branch 'feature/text-exercises/immediate-preliminary-feedback' …
LeonWehrhahn Sep 10, 2024
381f705
Merge branch 'develop' into feature/modeling-exercises/immediate-prel…
LeonWehrhahn Sep 10, 2024
9c667b2
Merge branch 'develop' into feature/modeling-exercises/immediate-prel…
LeonWehrhahn Sep 11, 2024
b3203a8
Refactor exercise feedback request handling in ParticipationResource
LeonWehrhahn Sep 11, 2024
02c80f9
Add ModelingAssessmentEditorComponent test for testing ngOnInit with …
LeonWehrhahn Sep 12, 2024
2f9e0aa
Add request modeling feedback participation integration test
LeonWehrhahn Sep 12, 2024
3f98504
Add request modeling feedback participation integration test
LeonWehrhahn Sep 12, 2024
2d59db8
Refactor ModelingAssessmentEditorComponent test to include AthenaService
LeonWehrhahn Sep 12, 2024
aee0d0b
Merge branch 'develop' into feature/modeling-exercises/immediate-prel…
LeonWehrhahn Sep 12, 2024
51e0778
Refactor package and imports
LeonWehrhahn Sep 12, 2024
9bad5dc
Add
LeonWehrhahn Sep 12, 2024
4b10bfc
Update src/test/javascript/spec/component/modeling-assessment-editor/…
LeonWehrhahn Sep 12, 2024
dd29c9f
Show the ResultHistoryComponent for Modeling Exercises
LeonWehrhahn Sep 13, 2024
15f7f1d
Merge branch 'feature/modeling-exercises/immediate-preliminary-feedba…
LeonWehrhahn Sep 13, 2024
48b2d4a
Merge branch 'develop' into feature/modeling-exercises/immediate-prel…
LeonWehrhahn Sep 13, 2024
c1a3263
Update ModelingSubmissionService to create new submissions for empty …
LeonWehrhahn Sep 13, 2024
a482732
Update ModelingSubmissionService to remove results present check
LeonWehrhahn Sep 13, 2024
9c910bd
Update ModelingSubmissionService add modelingSubmission.setResults
LeonWehrhahn Sep 13, 2024
3b2ac10
Update result retrieval for modeling exercises
LeonWehrhahn Sep 13, 2024
f523991
Add null check
LeonWehrhahn Sep 14, 2024
8e26c2f
Add null check
LeonWehrhahn Sep 14, 2024
7452923
Update getModelSubmissionForModelingEditor to ensure that exercise is…
LeonWehrhahn Sep 14, 2024
971d11f
Merge branch 'develop' into feature/modeling-exercises/immediate-prel…
LeonWehrhahn Sep 14, 2024
6480f4b
Filter out null values, to correctly display assessments in Assessmen…
LeonWehrhahn Sep 14, 2024
15c6151
Merge remote-tracking branch 'origin/feature/modeling-exercises/immed…
LeonWehrhahn Sep 14, 2024
33e53a7
Only filter out null values, to correctly display assessments in Asse…
LeonWehrhahn Sep 14, 2024
9fa7e44
Update comment
LeonWehrhahn Sep 14, 2024
52bd827
Implement change requests
LeonWehrhahn Sep 15, 2024
74d60a7
Merge branch 'develop' into feature/modeling-exercises/immediate-prel…
LeonWehrhahn Sep 15, 2024
9532cc3
Add FileUploadExercise to unsupported Feedback Generation Exercise types
LeonWehrhahn Sep 16, 2024
4e3527e
Merge remote-tracking branch 'origin/feature/modeling-exercises/immed…
LeonWehrhahn Sep 16, 2024
5085800
Refactor resultIsPreliminary function to use optional chaining for ex…
LeonWehrhahn Sep 16, 2024
cadab42
Add setSuccessful(true), as this indicates to the client that the gen…
LeonWehrhahn Sep 17, 2024
5c71554
Restructure ModelingExerciseFeedbackService
LeonWehrhahn Sep 17, 2024
d08d384
Merge branch 'develop' into feature/modeling-exercises/immediate-prel…
LeonWehrhahn Sep 17, 2024
1240732
Refactor exam exercise check to use examMode var
LeonWehrhahn Sep 17, 2024
5736c1a
Merge branch 'feature/modeling-exercises/immediate-preliminary-feedba…
LeonWehrhahn Sep 17, 2024
40e9ca3
Merge branch 'develop' into feature/modeling-exercises/immediate-prel…
LeonWehrhahn Sep 17, 2024
bb6e048
Adjust SubmissionService to filter out Athena results for complaints
LeonWehrhahn Sep 19, 2024
a756435
Merge branch 'develop' into feature/modeling-exercises/immediate-prel…
LeonWehrhahn Sep 19, 2024
c7044a2
Adjust hasAthenaResultForlatestSubmission check
LeonWehrhahn Sep 19, 2024
0623a03
Merge branch 'feature/modeling-exercises/immediate-preliminary-feedba…
LeonWehrhahn Sep 19, 2024
11d5f96
Check submission result present server side
LeonWehrhahn Oct 7, 2024
1255ae5
Merge remote-tracking branch 'origin/develop' into feature/modeling-e…
LeonWehrhahn Oct 7, 2024
f6470c6
Add null check
LeonWehrhahn Oct 8, 2024
a192afe
Merge branch 'develop' into feature/modeling-exercises/preliminary-fe…
LeonWehrhahn Oct 8, 2024
d18df7b
Update comment
LeonWehrhahn Oct 8, 2024
8fa6f9b
Merge branch 'develop' into feature/modeling-exercises/preliminary-fe…
LeonWehrhahn Oct 10, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -427,6 +427,14 @@ SELECT COUNT(DISTINCT p)
*/
boolean existsByParticipationId(long participationId);

/**
* Checks if a result exists for the given submission ID.
*
* @param submissionId the ID of the submission to check.
* @return true if a result exists for the given submission ID, false otherwise.
*/
boolean existsBySubmissionId(long submissionId);

/**
* Returns true if there is at least one result for the given exercise.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,12 +131,10 @@ public ModelingSubmission handleModelingSubmission(ModelingSubmission modelingSu
}

// if athena results are present, then create a new submission on submit
LeonWehrhahn marked this conversation as resolved.
Show resolved Hide resolved
if (modelingSubmission.getParticipation() != null && modelingSubmission.getParticipation().getResults() != null
&& !modelingSubmission.getParticipation().getResults().isEmpty()) {
log.debug("Creating a new submission due to Athena results for user: {}", user.getLogin());
// If results exist for this submission, create a new submission by setting the ID to null
if (modelingSubmission.getId() != null && resultRepository.existsBySubmissionId(modelingSubmission.getId())) {
modelingSubmission.setId(null);
}
LeonWehrhahn marked this conversation as resolved.
Show resolved Hide resolved

modelingSubmission = save(modelingSubmission, exercise, user, participation);
return modelingSubmission;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,6 @@ public ResponseEntity<ModelingSubmission> createModelingSubmission(@PathVariable
@PutMapping("exercises/{exerciseId}/modeling-submissions")
@EnforceAtLeastStudent
public ResponseEntity<ModelingSubmission> updateModelingSubmission(@PathVariable long exerciseId, @Valid @RequestBody ModelingSubmission modelingSubmission) {
log.debug("REST request to update modeling submission: {}", modelingSubmission.getModel());
if (modelingSubmission.getId() == null) {
return createModelingSubmission(exerciseId, modelingSubmission);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ import { faExclamationTriangle, faGripLines } from '@fortawesome/free-solid-svg-
import { faListAlt } from '@fortawesome/free-regular-svg-icons';
import { onError } from 'app/shared/util/global.utils';
import { SubmissionPatch } from 'app/entities/submission-patch.model';
import { AssessmentType } from 'app/entities/assessment-type.model';

@Component({
selector: 'jhi-modeling-submission',
Expand Down Expand Up @@ -296,7 +297,9 @@ export class ModelingSubmissionComponent implements OnInit, OnDestroy, Component
this.assessmentResult = newResult;
this.assessmentResult = this.modelingAssessmentService.convertResult(newResult);
this.prepareAssessmentData();
this.alertService.info('artemisApp.modelingEditor.newAssessment');
if (this.assessmentResult.assessmentType !== AssessmentType.AUTOMATIC_ATHENA) {
this.alertService.info('artemisApp.modelingEditor.newAssessment');
}
LeonWehrhahn marked this conversation as resolved.
Show resolved Hide resolved
}
});
}
Expand Down
Loading