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

Iris: Add event service #8834

Closed
wants to merge 499 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
499 commits
Select commit Hold shift + click to select a range
87cd2ee
Merge branch 'feature/iris/pyrisV2' into chore/iris/base-chatbot-comp…
bassner May 7, 2024
0607f36
Merge branch 'develop' into chore/iris/base-chatbot-component-refactor
bassner May 12, 2024
c3822af
redesign and refactor iris client
bassner May 12, 2024
59ec0cc
Merge remote-tracking branch 'origin/develop' into feature/iris/clien…
bassner May 13, 2024
a663357
pass chat service via input
bassner May 13, 2024
c5a5c28
`Adaptive learning`: Add endpoint to retrieve student course metrics …
MaximilianAnzinger May 14, 2024
957a0fa
`Learning analytics`: Add exercise statistics to student course dashb…
FelixTJDietrich May 15, 2024
8900a66
Merge remote-tracking branch 'origin/develop' into hd3-develop
bassner May 15, 2024
440597d
fix safari iris ui
bassner May 15, 2024
e25ff35
beautify scrollbar
bassner May 15, 2024
3783803
fix message sync
bassner May 15, 2024
8a52bbb
disable input if active stage
bassner May 15, 2024
83b8f02
Merge remote-tracking branch 'origin/develop' into hd3-develop
bassner May 16, 2024
3707543
`Development`: Add competency information to metrics DTO (#8601)
MaximilianAnzinger May 16, 2024
e5eede2
Merge remote-tracking branch 'origin/develop' into hd3-develop
bassner May 16, 2024
0652966
Merge remote-tracking branch 'origin/develop' into feature/iris/clien…
bassner May 16, 2024
d606b2a
Merge branch 'feature/iris/client-refactor' into hd3-develop
bassner May 16, 2024
132e4f6
`Learning analytics`: Add competency details to student course dashbo…
kaancayli May 17, 2024
ee35504
Merge branch 'develop' into hd3-develop
MaximilianAnzinger May 17, 2024
4a0c42e
`Learning analytics`: Next exercise objectives for course dashboard c…
FelixTJDietrich May 17, 2024
17576ed
`Learning analytics`: Add judgement of learning component (#8600)
FelixTJDietrich May 17, 2024
c4dc0ad
Merge branch 'develop' into hd3-develop
bassner May 22, 2024
4f0ab7c
Merge branch 'develop' into feature/iris/client-refactor
bassner May 22, 2024
c33dd93
fix status bar animation
bassner May 22, 2024
0ed88c4
`Development`: Add exercise information to metrics endpoint (#8643)
MaximilianAnzinger May 22, 2024
c148bfd
`Learning analytics`: Improve student course dashboard (#8651)
FelixTJDietrich May 23, 2024
40edcb4
Merge branch 'develop' into hd3-develop
FelixTJDietrich May 23, 2024
67590d4
`Adaptive learning`: Add sub-system for judgement of learning rating …
MaximilianAnzinger May 23, 2024
3219a0d
`Learning analytics`: Functional judgement of learning (#8657)
FelixTJDietrich May 23, 2024
b5c770d
Merge branch 'develop' into hd3-develop
bassner May 23, 2024
b054ec9
`Adaptive learning`: Add get endpoints to fetch judgement of learning…
MaximilianAnzinger May 24, 2024
98b75c2
`Learning analytics`: Hide competencies when judgement of learning is…
FelixTJDietrich May 24, 2024
75d26ca
Merge branch 'develop' into hd3-develop
bassner May 24, 2024
951cc1c
Merge branch 'develop' into hd3-develop
bassner May 25, 2024
2ab137c
fix merge
bassner May 25, 2024
a129c0b
Merge remote-tracking branch 'origin/develop' into hd3-develop
bassner May 25, 2024
56a2685
Merge remote-tracking branch 'origin/develop' into hd3-develop
bassner May 26, 2024
8beb764
Iris: Add course chat (#8613)
bassner May 26, 2024
d78757f
rename tutor package
bassner May 26, 2024
9125e40
fix undefined errors
FelixTJDietrich May 27, 2024
8a5c721
fix undefined errors again
FelixTJDietrich May 27, 2024
59669b4
remove JsonIgnoreProperties from entity
MaximilianAnzinger May 27, 2024
89c7f53
rename JOL to Jol
MaximilianAnzinger May 27, 2024
a091e58
Update IrisChatSession.java
MaximilianAnzinger May 27, 2024
5d3a0fe
Update IrisCourseChatSessionRepository.java
MaximilianAnzinger May 27, 2024
b4f5254
Apply suggestions from code review
MaximilianAnzinger May 27, 2024
0a3eb73
code review
MaximilianAnzinger May 27, 2024
4df22b3
Merge branch 'hd3-develop' of https://github.com/ls1intum/Artemis int…
MaximilianAnzinger May 27, 2024
de9792e
Update src/main/webapp/app/course/competencies/judgement-of-learning-…
MaximilianAnzinger May 27, 2024
e9b4ca4
Update src/main/java/de/tum/in/www1/artemis/web/rest/iris/IrisExercis…
MaximilianAnzinger May 27, 2024
7b0fa80
Update src/main/webapp/app/course/competencies/competency-accordion/c…
MaximilianAnzinger May 27, 2024
c4b3db5
Update src/main/webapp/app/course/competencies/competency-accordion/c…
MaximilianAnzinger May 27, 2024
0c52732
Update src/main/webapp/app/course/competencies/competency-accordion/c…
MaximilianAnzinger May 27, 2024
7e85157
Merge branch 'hd3-develop' of github.com:ls1intum/Artemis into featur…
kaancayli May 27, 2024
d31ae09
remove unused code
MaximilianAnzinger May 27, 2024
eba7535
Merge branch 'hd3-develop' of https://github.com/ls1intum/Artemis int…
MaximilianAnzinger May 27, 2024
1537b09
Update src/main/java/de/tum/in/www1/artemis/web/rest/dto/metrics/Comp…
MaximilianAnzinger May 27, 2024
3a4774e
Update src/main/webapp/app/course/competencies/competency-accordion/c…
MaximilianAnzinger May 27, 2024
7ebfe65
Update src/main/webapp/app/iris/base-chatbot/iris-base-chatbot.compon…
MaximilianAnzinger May 27, 2024
19304f5
Update IrisCourseChatSessionService.java
MaximilianAnzinger May 27, 2024
ca9bb73
Merge branch 'hd3-develop' of https://github.com/ls1intum/Artemis int…
MaximilianAnzinger May 27, 2024
0b06de8
fix instant conversion if submission date is null
bassner May 27, 2024
85aa32d
Merge remote-tracking branch 'origin/develop' into hd3-develop
bassner May 27, 2024
7786086
Update IrisExerciseChatSessionResource.java
MaximilianAnzinger May 27, 2024
fd792a8
Merge branch 'hd3-develop' of https://github.com/ls1intum/Artemis int…
MaximilianAnzinger May 27, 2024
bab09c7
make server boot
bassner May 27, 2024
5885493
Merge remote-tracking branch 'origin/develop' into feature/iris/clien…
bassner May 27, 2024
8911a21
Fix server tests
MichaelOwenDyer May 27, 2024
40080b1
Refactor IrisCourseChatSessionResource: replace @EnforceAtLeastStuden…
bassner May 27, 2024
4865e12
Refactor IrisExerciseChatSessionResource: replace @EnforceAtLeastStud…
bassner May 27, 2024
d4ee889
Refactor IrisStatusDTO into its own file
bassner May 27, 2024
be792c4
Refactor chat session repositories and resources to use Pageable for …
bassner May 27, 2024
23b8e24
use precomputed lowerCaseState instead of calling state.toLowerCase()…
bassner May 27, 2024
b64f3dc
Fix test
MichaelOwenDyer May 27, 2024
4e17d65
document status bar progress animation and add missing transform rule
bassner May 27, 2024
dde4563
remove 4 magic number of line height buffer in text area of iris input
bassner May 27, 2024
b928503
move type declarations
bassner May 27, 2024
7a87c75
clean up base chatbot scss
bassner May 27, 2024
a342e3c
fix firefox dashboard overflow by setting min-width to 0 (cmon Mozilla)
bassner May 27, 2024
8b56e06
use jhiTranslate directive; added new translations in iris.json files
bassner May 27, 2024
64d1dba
Refactor chat-status-bar.component.ts; add JSON and IrisStageStateDTO…
bassner May 27, 2024
d9f73d0
Update src/main/java/de/tum/in/www1/artemis/repository/UserRepository…
bassner May 27, 2024
a305b59
Initial tests
kaancayli May 27, 2024
ee0df9c
merge origin
kaancayli May 27, 2024
0466c7a
Refactor Iris Chat Session Entities
bassner May 27, 2024
7727866
Merge branch 'hd3-develop' of https://github.com/ls1intum/Artemis int…
bassner May 27, 2024
36d4b67
Refactor user repository method name
bassner May 27, 2024
a1a373f
Refactor IrisChatSession class
bassner May 27, 2024
ca910f5
fix iris ratelimit UI
bassner May 27, 2024
392985a
fix iris ratelimit UI
bassner May 27, 2024
18ce21d
Document PyrisPipelineService#executeChatPipeline
bassner May 27, 2024
2788b8d
more pyrispipeline service docs
bassner May 27, 2024
69097be
Rename removeJobIfJobTerminated method
bassner May 27, 2024
80972ad
document job removal
bassner May 27, 2024
ec46862
Update src/main/webapp/i18n/de/course.json
bassner May 27, 2024
c8009b2
Refactor Iris chat services
bassner May 27, 2024
5fd6629
Terminal Refactor Iris chat services
bassner May 27, 2024
7666f75
Finish service tests
kaancayli May 27, 2024
edaeb1c
Refactor IrisSessionService with switch expression
bassner May 27, 2024
93ddae8
Merge branch 'feature/iris/client-refactor' of github.com:ls1intum/Ar…
kaancayli May 27, 2024
fcbabe4
Fix service tests
kaancayli May 27, 2024
fde01e7
Write additional service tests
kaancayli May 27, 2024
ea1f7a6
Chat status bar component tests
kaancayli May 27, 2024
3cf2e29
remove unused code
MaximilianAnzinger May 28, 2024
6a7c52b
Merge branch 'hd3-develop' of https://github.com/ls1intum/Artemis int…
MaximilianAnzinger May 28, 2024
cd2d6c6
fix style
MaximilianAnzinger May 28, 2024
df1f0f6
add doc
MaximilianAnzinger May 28, 2024
34e6e1a
fix style
MaximilianAnzinger May 28, 2024
1363253
IrisBaseChatbot test setup
kaancayli May 28, 2024
1518faa
some more code style improvements
MaximilianAnzinger May 28, 2024
c43b729
Extract check to a function
kaancayli May 28, 2024
cff5911
fix redirect of course-exercises.component.ts
FelixTJDietrich May 28, 2024
0fc8fc1
fix redirects on programming exercise open repository
FelixTJDietrich May 28, 2024
f0db158
remove logging message
FelixTJDietrich May 28, 2024
c8b6daa
Finish IrisBaseChatbot tests implementation
kaancayli May 28, 2024
9bc3366
Implement CourseChatbotComponent tests
kaancayli May 28, 2024
e620020
Implement ChatbotWidgetComponent tests
kaancayli May 28, 2024
a18b062
fix redirect away from dashboard when refreshing
FelixTJDietrich May 28, 2024
5377bf3
`Development`: Fix programming exercise buttons in course dashboard (…
FelixTJDietrich May 28, 2024
8f6d1ad
change shorten maxXAxisTickLength for course dashboard
FelixTJDietrich May 28, 2024
f743fd5
fix undefined due date of exercise
FelixTJDietrich May 28, 2024
85647ae
refactor CompetencyAccordionToggleEvent
FelixTJDietrich May 28, 2024
07400d1
implement review suggestion for changing class name
FelixTJDietrich May 28, 2024
bef1bce
clean up subscription
FelixTJDietrich May 28, 2024
5f2cbcd
add comment
FelixTJDietrich May 28, 2024
2529caa
update comment
FelixTJDietrich May 28, 2024
f005c22
fix implicit boolean
FelixTJDietrich May 28, 2024
3bb9a87
remove unnecessary type
FelixTJDietrich May 28, 2024
9f79348
implement review comment about get in html markup
FelixTJDietrich May 28, 2024
f441abf
implement review comment about round in html
FelixTJDietrich May 28, 2024
bc88f4f
cleanup subscription
FelixTJDietrich May 28, 2024
de1a7e8
remove function from html
FelixTJDietrich May 28, 2024
13d3607
restore api compat with current pyris major version
bassner May 28, 2024
a45af4a
remove judgement of learning service in favor of competency service
FelixTJDietrich May 28, 2024
104c181
remove unnecessary css
FelixTJDietrich May 28, 2024
c74aa6d
remove question mark
FelixTJDietrich May 28, 2024
850e72a
replace parseInt with Number
FelixTJDietrich May 28, 2024
868e949
Fix typescript related errors.
kaancayli May 29, 2024
8745e6c
Adjust tests for exercise chatbot button component
kaancayli May 29, 2024
fea56ca
Fix typescript related errors
kaancayli May 29, 2024
608cd78
Fix test
kaancayli May 29, 2024
fe00068
Fix broken tests in other places
kaancayli May 29, 2024
872d3f2
run prettier
kaancayli May 29, 2024
f48e6bd
Merge remote-tracking branch 'origin/develop' into hd3-develop
bassner May 29, 2024
31e6e61
Merge origin/hd3-develop in to feature/iris/client-refactor
kaancayli May 29, 2024
04e565b
Fix tests
kaancayli May 29, 2024
fe4794f
Merge branch 'feature/iris/client-refactor' into hd3-develop
bassner May 29, 2024
a849218
`Development`: Add timestamp and competency progress to JoL (#8689)
MaximilianAnzinger May 31, 2024
93a2f2c
`Adaptive learning`: Change when judgement of learning prompt appears…
FelixTJDietrich May 31, 2024
dd4c4b3
`Adaptive Learning`: Fix broken tests (#8701)
kaancayli May 31, 2024
89abed8
Merge branch 'develop' into hd3-develop
FelixTJDietrich May 31, 2024
ca5aa3a
filter out exercises without due date for lateness calculation
MaximilianAnzinger May 31, 2024
0d3dda4
fix judgement of learning prompting
FelixTJDietrich May 31, 2024
be0036e
fix competency sorting
FelixTJDietrich May 31, 2024
0d55992
fix missing lecture units and exercises from competency detail
FelixTJDietrich May 31, 2024
2f0196b
remove caching for course competencies because it is too buggy
FelixTJDietrich May 31, 2024
551f4b9
fix client tests
FelixTJDietrich May 31, 2024
da68eba
add JavaDoc
MaximilianAnzinger May 31, 2024
885e86c
Merge branch 'hd3-develop' of https://github.com/ls1intum/Artemis int…
MaximilianAnzinger May 31, 2024
2efbae2
fix iris stuff
bassner May 31, 2024
bf21156
fix code style
MaximilianAnzinger May 31, 2024
a0a4f7d
improve code style
MaximilianAnzinger May 31, 2024
5e5c8d3
fix courseChatSession toString npe
bassner May 31, 2024
d322bd1
fix forbidden error and redirect to dashboard for rating
FelixTJDietrich May 31, 2024
aaf5963
Merge remote-tracking branch 'origin/hd3-develop' into hd3-develop
FelixTJDietrich May 31, 2024
eb2a616
Merge branch 'hd3-develop' of https://github.com/ls1intum/Artemis int…
MaximilianAnzinger May 31, 2024
a0c7298
trigger iris on new competency jol
bassner May 31, 2024
0490e79
hardcode hd3 experimental groups
bassner May 31, 2024
72eeb66
Refactor IrisService to Optional in CompetencyJolService
bassner May 31, 2024
b8f5391
add some more data to fetch
MaximilianAnzinger May 31, 2024
0ac52c9
Merge branch 'hd3-develop' of https://github.com/ls1intum/Artemis int…
MaximilianAnzinger May 31, 2024
16c3581
adjust client to use current jol and fix data loading
FelixTJDietrich Jun 1, 2024
cda6e4b
Merge branch 'develop' into hd3-develop
FelixTJDietrich Jun 1, 2024
d051c82
Merge remote-tracking branch 'origin/develop' into hd3-develop
bassner Jun 2, 2024
6769f8d
fix merge
bassner Jun 2, 2024
acfe36f
remove the typo i randomly added
bassner Jun 2, 2024
372180e
fix one test
bassner Jun 2, 2024
4f68fb1
fix arch test
bassner Jun 2, 2024
650b244
Initial functionality without UI implementation
kaancayli Jun 2, 2024
dde7d7d
Merge branch 'develop' into hd3-develop
MaximilianAnzinger Jun 3, 2024
b5df87b
remove test that tests the removed caching of competencies and prereq…
FelixTJDietrich Jun 3, 2024
5a795c3
Merge remote-tracking branch 'origin/hd3-develop' into hd3-develop
bassner Jun 3, 2024
ab6db66
reduce coverage requirements 😬
bassner Jun 3, 2024
a0de1ab
remove temp script
bassner Jun 3, 2024
9321abf
Merge branch 'hd3-develop' of github.com:ls1intum/Artemis into featur…
kaancayli Jun 3, 2024
24b7fff
Merge remote-tracking branch 'origin/develop' into hd3-develop
bassner Jun 4, 2024
4591721
Improved Pyris Health Indicator
bassner Jun 4, 2024
73b4125
fix test
bassner Jun 4, 2024
30af780
silence checkstyle
bassner Jun 4, 2024
f1a74ff
add missing star
bassner Jun 4, 2024
0098039
Merge branch 'hd3-develop' of github.com:ls1intum/Artemis into featur…
kaancayli Jun 4, 2024
aea926f
Merge branch develop into iris/chat-suggestions
kaancayli Jun 10, 2024
aa768db
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jun 11, 2024
e3800bc
UI implementation
kaancayli Jun 12, 2024
e786f49
Remove console.log
kaancayli Jun 12, 2024
9ebc29b
Add animations && remove remaining console.logs
kaancayli Jun 13, 2024
1c11807
Add client tests
kaancayli Jun 13, 2024
83b1a44
Add server tests
kaancayli Jun 13, 2024
7b41a53
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jun 13, 2024
686edd5
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jun 16, 2024
bf754a3
Persist latest suggestions to the session entity
kaancayli Jun 16, 2024
be526b7
Restore FeatureToggleService.java to 'develop' version
kaancayli Jun 17, 2024
582bb5f
Restore FeatureToggleServiceTest.java to 'develop' version
kaancayli Jun 17, 2024
e9a13a1
Fix javadoc
kaancayli Jun 17, 2024
86bc819
Refactoring and regex bug fix
kaancayli Jun 17, 2024
88556be
Small formatting fix
kaancayli Jun 17, 2024
ec3ad30
Merge branch 'develop' into feature/iris/chat-suggestions
kaancayli Jun 17, 2024
065546e
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jun 19, 2024
14b234f
Move rate limit interface to abstract class
kaancayli Jun 19, 2024
9dc544d
Merge branch 'feature/iris/chat-suggestions' of github.com:ls1intum/A…
kaancayli Jun 19, 2024
d66a7c9
Move null check to the function body
kaancayli Jun 19, 2024
fb4121b
Refactor
kaancayli Jun 19, 2024
3cf1be0
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jun 20, 2024
bfa40da
Add pyris event service
kaancayli Jun 20, 2024
e29a43c
Rename JOL event
kaancayli Jun 20, 2024
10d29da
Merge main
kaancayli Jun 22, 2024
1b568b3
Add simple version of the submssion failure event
kaancayli Jun 23, 2024
454e4c9
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jun 23, 2024
488c51f
Test dix
kaancayli Jun 23, 2024
d7584d7
Trigger only if last 3 subsequent submissions failed
kaancayli Jun 23, 2024
ec649f4
Some refactoring and fetch submissions eagerly.
kaancayli Jun 24, 2024
26be9ef
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jun 27, 2024
9c1799f
Fix dto creation bug for PyrisExerciseWithStudentSubmissionsDTO
kaancayli Jun 27, 2024
fbe0d88
Temporary ugly fix
kaancayli Jun 28, 2024
cd1cfd8
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jun 30, 2024
3addadd
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jul 8, 2024
54a72ad
Extend interface
kaancayli Jul 8, 2024
8791a11
Add pyris event dto
kaancayli Jul 8, 2024
8f3ecc5
Add settings for event system without migrations for now.
kaancayli Jul 9, 2024
cf926a7
Add event DB migrations
kaancayli Jul 14, 2024
ce4f6c8
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jul 14, 2024
23e5e59
Implement settings logic for events
kaancayli Jul 14, 2024
0aa22dc
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jul 14, 2024
49896ed
Add settings with only activate switch
kaancayli Jul 15, 2024
7b003b2
Integrate checks for active status of each pipeline
kaancayli Jul 16, 2024
515ddc0
Do not trigger submission successful event, if previously succeeded
kaancayli Jul 19, 2024
b9437db
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jul 19, 2024
6a78c27
chore: Implement tests partially
kaancayli Jul 22, 2024
3c09d56
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jul 22, 2024
da84986
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jul 22, 2024
aa84ca8
chore: Finish implementing tests
kaancayli Jul 22, 2024
a1db36d
chore: Address failing tests
kaancayli Jul 22, 2024
d523c76
fix: Adjust expected count for mockServer
kaancayli Jul 23, 2024
eadeb3c
fix: Server style
kaancayli Jul 23, 2024
724df1e
fix: Move SpyBean to Abstract Super Class
kaancayli Jul 24, 2024
527a3f1
fix: server style
kaancayli Jul 24, 2024
d86197c
fix: Move spybeans to AbstractSpringIntegrationLocalCILocalVCTest
kaancayli Jul 24, 2024
c5e8ed7
fix: IrisSettingsIntegrationTest.java
kaancayli Jul 24, 2024
df7ccc4
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jul 28, 2024
518b367
Merge branch 'develop' of github.com:ls1intum/Artemis into feature/ir…
kaancayli Jul 29, 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 @@ -32,6 +32,10 @@ public class IrisCourseSettings extends IrisSettings {
@JoinColumn(name = "iris_lecture_ingestion_settings_id")
private IrisLectureIngestionSubSettings irisLectureIngestionSettings;

@OneToOne(cascade = CascadeType.ALL, orphanRemoval = true, fetch = FetchType.EAGER, optional = false)
@JoinColumn(name = "iris_proactivity_settings_id")
private IrisProactivitySubSettings irisProactivitySettings;

@OneToOne(cascade = CascadeType.ALL, orphanRemoval = true, fetch = FetchType.EAGER)
@JoinColumn(name = "iris_hestia_settings_id")
private IrisHestiaSubSettings irisHestiaSettings;
Expand Down Expand Up @@ -63,6 +67,16 @@ public void setIrisLectureIngestionSettings(IrisLectureIngestionSubSettings iris
this.irisLectureIngestionSettings = irisLectureIngestionSettings;
}

@Override
public IrisProactivitySubSettings getIrisProactivitySettings() {
return irisProactivitySettings;
}

@Override
public void setIrisProactivitySettings(IrisProactivitySubSettings irisProactivitySettings) {
this.irisProactivitySettings = irisProactivitySettings;
}

@Override
public IrisChatSubSettings getIrisChatSettings() {
return irisChatSettings;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,15 @@ public IrisLectureIngestionSubSettings getIrisLectureIngestionSettings() {
public void setIrisLectureIngestionSettings(IrisLectureIngestionSubSettings irisLectureIngestionSettings) {
}

@Override
public IrisProactivitySubSettings getIrisProactivitySettings() {
return null;
}
kaancayli marked this conversation as resolved.
Show resolved Hide resolved

@Override
public void setIrisProactivitySettings(IrisProactivitySubSettings irisProactivitySettings) {
}
kaancayli marked this conversation as resolved.
Show resolved Hide resolved

@Override
public IrisChatSubSettings getIrisChatSettings() {
return irisChatSettings;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ public class IrisGlobalSettings extends IrisSettings {
@Column(name = "enable_auto_update_lecture_ingestion")
private boolean enableAutoUpdateLectureIngestion;

@Column(name = "enable_auto_update_proactivity")
private boolean enableAutoUpdateProactivity;

@Column(name = "enable_auto_update_competency_generation")
private boolean enableAutoUpdateCompetencyGeneration;

Expand All @@ -45,6 +48,10 @@ public class IrisGlobalSettings extends IrisSettings {
@JoinColumn(name = "iris_lecture_ingestion_settings_id")
private IrisLectureIngestionSubSettings irisLectureIngestionSettings;

@OneToOne(cascade = CascadeType.ALL, orphanRemoval = true, fetch = FetchType.EAGER, optional = false)
@JoinColumn(name = "iris_proactivity_settings_id")
private IrisProactivitySubSettings irisProactivitySettings;

@OneToOne(cascade = CascadeType.ALL, orphanRemoval = true, fetch = FetchType.EAGER, optional = false)
@JoinColumn(name = "iris_hestia_settings_id")
private IrisHestiaSubSettings irisHestiaSettings;
Expand All @@ -62,7 +69,9 @@ public boolean isValid() {
var competencyGenerationSettingsValid = !Hibernate.isInitialized(irisCompetencyGenerationSettings) || irisCompetencyGenerationSettings == null
|| (irisCompetencyGenerationSettings.getTemplate() != null && irisCompetencyGenerationSettings.getTemplate().getContent() != null
&& !irisCompetencyGenerationSettings.getTemplate().getContent().isEmpty());
return chatSettingsValid && hestiaSettingsValid && competencyGenerationSettingsValid;
var proactivitySettingsValid = !Hibernate.isInitialized(irisProactivitySettings) || irisProactivitySettings == null
|| (irisProactivitySettings.getEventSettings() != null && !irisProactivitySettings.getEventSettings().isEmpty());
return chatSettingsValid && hestiaSettingsValid && competencyGenerationSettingsValid && proactivitySettingsValid;
}

public int getCurrentVersion() {
Expand Down Expand Up @@ -105,6 +114,22 @@ public void setEnableAutoUpdateCompetencyGeneration(boolean enableAutoUpdateComp
this.enableAutoUpdateCompetencyGeneration = enableAutoUpdateCompetencyGeneration;
}

public boolean isEnableAutoUpdateProactivity() {
return enableAutoUpdateProactivity;
}

public void setEnableAutoUpdateProactivity(boolean enableAutoUpdateProactivity) {
this.enableAutoUpdateProactivity = enableAutoUpdateProactivity;
}

public IrisProactivitySubSettings getIrisProactivitySettings() {
return irisProactivitySettings;
}

public void setIrisProactivitySettings(IrisProactivitySubSettings irisProactivitySettings) {
this.irisProactivitySettings = irisProactivitySettings;
}

@Override
public IrisLectureIngestionSubSettings getIrisLectureIngestionSettings() {
return irisLectureIngestionSettings;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
package de.tum.in.www1.artemis.domain.iris.settings;

import java.util.HashSet;
import java.util.Set;

import jakarta.persistence.CascadeType;
import jakarta.persistence.DiscriminatorValue;
import jakarta.persistence.Entity;
import jakarta.persistence.FetchType;
import jakarta.persistence.OneToMany;

import com.fasterxml.jackson.annotation.JsonInclude;

import de.tum.in.www1.artemis.domain.iris.settings.event.IrisEventSettings;

/**
* Represents the specific ingestion sub-settings of lectures for Iris.
* This class extends {@link IrisSubSettings} to provide settings required for lecture data ingestion.
*/
@Entity
@DiscriminatorValue("PROACTIVITY")
@JsonInclude(JsonInclude.Include.NON_EMPTY)
public class IrisProactivitySubSettings extends IrisSubSettings {

@OneToMany(mappedBy = "proactivitySubSettings", cascade = CascadeType.ALL, orphanRemoval = true, fetch = FetchType.EAGER)
private Set<IrisEventSettings> eventSettings = new HashSet<>();

public Set<IrisEventSettings> getEventSettings() {
return eventSettings;
}

public void setEventSettings(Set<IrisEventSettings> proactivityStatuses) {
this.eventSettings = proactivityStatuses;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ public abstract class IrisSettings extends DomainObject {

public abstract void setIrisLectureIngestionSettings(IrisLectureIngestionSubSettings irisLectureIngestionSettings);

public abstract IrisProactivitySubSettings getIrisProactivitySettings();

public abstract void setIrisProactivitySettings(IrisProactivitySubSettings irisProactivitySettings);

public abstract IrisHestiaSubSettings getIrisHestiaSettings();

public abstract void setIrisHestiaSettings(IrisHestiaSubSettings irisHestiaSettings);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@
@JsonSubTypes.Type(value = IrisChatSubSettings.class, name = "chat"),
@JsonSubTypes.Type(value = IrisLectureIngestionSubSettings.class, name = "lecture-ingestion"),
@JsonSubTypes.Type(value = IrisHestiaSubSettings.class, name = "hestia"),
@JsonSubTypes.Type(value = IrisCompetencyGenerationSubSettings.class, name = "competency-generation")
@JsonSubTypes.Type(value = IrisCompetencyGenerationSubSettings.class, name = "competency-generation"),
@JsonSubTypes.Type(value = IrisProactivitySubSettings.class, name = "proactivity")
})
// @formatter:on
@JsonInclude(JsonInclude.Include.NON_EMPTY)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
package de.tum.in.www1.artemis.domain.iris.settings;

public enum IrisSubSettingsType {
CHAT, HESTIA, COMPETENCY_GENERATION, LECTURE_INGESTION
CHAT, HESTIA, COMPETENCY_GENERATION, LECTURE_INGESTION, PROACTIVITY
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package de.tum.in.www1.artemis.domain.iris.settings.event;

public enum IrisEventLevel {
EXERCISE, COURSE
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,145 @@
package de.tum.in.www1.artemis.domain.iris.settings.event;

import java.time.ZonedDateTime;

import jakarta.persistence.Column;
import jakarta.persistence.DiscriminatorColumn;
import jakarta.persistence.DiscriminatorType;
import jakarta.persistence.Entity;
import jakarta.persistence.EnumType;
import jakarta.persistence.Enumerated;
import jakarta.persistence.Inheritance;
import jakarta.persistence.InheritanceType;
import jakarta.persistence.JoinColumn;
import jakarta.persistence.ManyToOne;
import jakarta.persistence.PrePersist;
import jakarta.persistence.PreUpdate;
import jakarta.persistence.Table;

import javax.annotation.Nullable;

import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;

import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonSubTypes;
import com.fasterxml.jackson.annotation.JsonTypeInfo;

import de.tum.in.www1.artemis.domain.DomainObject;
import de.tum.in.www1.artemis.domain.iris.settings.IrisProactivitySubSettings;

@Entity
@Table(name = "iris_event_settings")
@Inheritance(strategy = InheritanceType.SINGLE_TABLE)
@DiscriminatorColumn(name = "discriminator", discriminatorType = DiscriminatorType.STRING)
@Cache(usage = CacheConcurrencyStrategy.NONSTRICT_READ_WRITE)
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, property = "type")
// @formatter:off
@JsonSubTypes({
@JsonSubTypes.Type(value = IrisSubmissionSuccessfulEventSettings.class, name = "submission_successful"),
@JsonSubTypes.Type(value = IrisSubmissionFailedEventSettings.class, name = "submission_failed"),
@JsonSubTypes.Type(value = IrisJolEventSettings.class, name = "jol")
})
@JsonInclude(JsonInclude.Include.NON_EMPTY)
public abstract class IrisEventSettings extends DomainObject {
// Is event active
@Column(name = "is_active", nullable = false)
private boolean isActive;

// The date until which the event is deferred
@Nullable
@Column(name = "deferred_until")
private ZonedDateTime deferredUntil;

@Nullable
@Column(name="last_triggered")
private ZonedDateTime lastTriggered;

// The variant of the pipeline the event is associated with
@Column(name = "pipeline_variant", nullable = false)
private String pipelineVariant;

// The priority of the event
@Column(name = "priority", nullable = false)
private int priority;

// The level of the event which type of session the event will be triggered in
@Nullable
@Enumerated(EnumType.STRING)
@Column(name = "level")
private IrisEventLevel level;

@JsonIgnore
@ManyToOne
@JoinColumn(name = "iris_proactivity_settings_id")
private IrisProactivitySubSettings proactivitySubSettings;

@PrePersist
@PreUpdate
protected void onCreate() {
if (level == null) {
level = getDefaultLevel();
}
if (pipelineVariant == null) {
pipelineVariant = getDefaultPipelineVariant();
}
}

public IrisProactivitySubSettings getProactivitySubSettings() {
return proactivitySubSettings;
}

public void setProactivitySubSettings(IrisProactivitySubSettings proactivitySubSettings) {
this.proactivitySubSettings = proactivitySubSettings;
}

public boolean isActive() {
return isActive;
}

public void setActive(boolean active) {
isActive = active;
}

public ZonedDateTime getDeferredUntil() {
return deferredUntil;
}

public void setDeferredUntil(ZonedDateTime deferredUntil) {
this.deferredUntil = deferredUntil;
}

public String getPipelineVariant() {
return pipelineVariant;
}

public void setPipelineVariant(String pipelineVariant) {
this.pipelineVariant = pipelineVariant;
}

public int getPriority() {
return priority;
}

public void setPriority(int priority) {
this.priority = priority;
}

public IrisEventLevel getLevel() {
return level;
}

public void setLevel(IrisEventLevel level) {
this.level = level;
}

// Check if the event can be triggered
public boolean canBeTriggered() {
return isActive && (deferredUntil == null || deferredUntil.isBefore(ZonedDateTime.now()));
}

public abstract IrisEventLevel getDefaultLevel();

public abstract String getDefaultPipelineVariant();
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package de.tum.in.www1.artemis.domain.iris.settings.event;

public enum IrisEventType {
SUBMISSION_FAILED, SUBMISSION_SUCCESSFUL, JOL
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package de.tum.in.www1.artemis.domain.iris.settings.event;

import jakarta.persistence.DiscriminatorValue;
import jakarta.persistence.Entity;

import com.fasterxml.jackson.annotation.JsonInclude;

@Entity
@DiscriminatorValue("JOL")
@JsonInclude(JsonInclude.Include.NON_EMPTY)
public class IrisJolEventSettings extends IrisEventSettings {

@Override
public IrisEventLevel getDefaultLevel() {
return IrisEventLevel.COURSE;
}

@Override
public String getDefaultPipelineVariant() {
return "jol";
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
package de.tum.in.www1.artemis.domain.iris.settings.event;

import jakarta.persistence.Column;
import jakarta.persistence.DiscriminatorValue;
import jakarta.persistence.Entity;

import javax.annotation.Nullable;

import com.fasterxml.jackson.annotation.JsonInclude;

@Entity
@DiscriminatorValue("SUBMISSION_FAILED")
@JsonInclude(JsonInclude.Include.NON_EMPTY)
public class IrisSubmissionFailedEventSettings extends IrisEventSettings {

// The number of failed attempts for the event to be triggered
@Column(name = "number_of_failed_attempts")
private Integer numberOfFailedAttempts;

@Nullable
@Column(name = "success_threshold")
private Double successThreshold;

public Integer getNumberOfFailedAttempts() {
return numberOfFailedAttempts;
}

public void setNumberOfFailedAttempts(Integer numberOfFailedAttempts) {
this.numberOfFailedAttempts = numberOfFailedAttempts;
}

public Double getSuccessThreshold() {
return successThreshold;
}

public void setSuccessThreshold(Double successThreshold) {
this.successThreshold = successThreshold;
}

@Override
public IrisEventLevel getDefaultLevel() {
return IrisEventLevel.EXERCISE;
}

@Override
public String getDefaultPipelineVariant() {
return "submission_failed";
}
}
Loading
Loading