-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: 선택 가능한 어조를 조회한다 * refactor: Enum 요소를 가져오는 방법을 수정한다
- Loading branch information
Showing
5 changed files
with
43 additions
and
1 deletion.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
src/main/kotlin/me/misik/api/domain/response/ReviewStyleResponse.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package me.misik.api.domain.response | ||
|
||
import me.misik.api.domain.ReviewStyle | ||
|
||
data class ReviewStyleResponse( | ||
val icon: String, | ||
val style: String | ||
) { | ||
companion object { | ||
fun from(reviewStyle: ReviewStyle): ReviewStyleResponse { | ||
return ReviewStyleResponse( | ||
icon = reviewStyle.iconUrl, | ||
style = reviewStyle.name, | ||
) | ||
} | ||
} | ||
} |
15 changes: 15 additions & 0 deletions
15
src/main/kotlin/me/misik/api/domain/response/ReviewStylesResponse.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package me.misik.api.domain.response | ||
|
||
import me.misik.api.domain.ReviewStyle | ||
|
||
data class ReviewStylesResponse( | ||
val reviewStyles: List<ReviewStyleResponse> | ||
) { | ||
companion object { | ||
fun from(reviewStyles: List<ReviewStyle>) : ReviewStylesResponse { | ||
return ReviewStylesResponse( | ||
reviewStyles.map { ReviewStyleResponse.from(it) } | ||
) | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
INSERT INTO prompt (id, style, command, created_at, updated_at) VALUES | ||
INSERT INTO prompt (id, style, command, created_at, modified_at) VALUES | ||
(1, 'PROFESSIONAL', '자연스러운, 전문적인 말투, 존대말, 과거형으로 리뷰를 만들어줘. 응답 형식은 {“review”:”리뷰 내용”}이어야 해. 응답에는 해당 JSON만 있어야해. 또한, 리뷰는 공백을 포함해서 300자가 넘어야 해. 리뷰에는 다음 의견도 자연스럽게 넣어줘.', NOW(), NOW()), | ||
(2, 'FRIENDLY', '~다, ~요를 적절히 섞은 높임말로 리뷰를 만들어줘. 한국 중년처럼 보이도록 가끔 문장 끝에 ..같은 특수문자를 넣어줘. 응답 형식은 {“review”:”리뷰 내용”}이어야 해. 응답에는 해당 JSON만 있어야해. 또한, 리뷰는 공백을 포함해서 100자 이상 200자 이하여야해. 리뷰에는 다음 의견도 자연스럽게 넣어줘.', NOW(), NOW()), | ||
(3, 'CUTE', '~다, ~요를 적절히 섞은 높임말로 리뷰를 만들어줘. 깜찍한 10대처럼 보이도록 가끔 어미 뒤에 랜덤하게 😘, ㅎㅎ 같은 특수문자, "당, 용" 같이 끝나는 어미를 넣어줘. 응답 형식은 {"review":"리뷰 내용"}이어야 해. 응답에는 해당 JSON만 있어야 해. 또한, 리뷰는 공백을 포함해서 100자 이상 200자 이하여야 해. 리뷰에는 다음 의견도 자연스럽게 넣어줘.', NOW(), NOW()); |