Skip to content

Commit

Permalink
Merge pull request #116 from 4m9d/feat/#115/add-lecture-title-paramet…
Browse files Browse the repository at this point in the history
…ers-to-ai-server-request(swm-337)

[SWM-337] feat : add lecture title parameter in ai server request
  • Loading branch information
Son-GyeongSik authored Oct 5, 2023
2 parents e5eab8a + f7c89ed commit 01c1b87
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ public void requestToFastApi(Video video) {
log.info("request to AI server successfully. videoCode = {}, title = {}", video.getVideoCode(), video.getTitle());

if (video.getMaterialStatus() == null || video.getMaterialStatus() == MaterialStatus.NO_REQUEST.getValue()) {
gptService.requestToFastApi(video.getVideoCode());
gptService.requestToFastApi(video.getVideoCode(), video.getTitle());
video.setMaterialStatus(MaterialStatus.CREATING.getValue());
videoRepository.updateById(video.getVideoId(), video);
}
Expand Down
5 changes: 3 additions & 2 deletions src/main/java/com/m9d/sroom/gpt/service/GPTService.java
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,9 @@ public void saveResultEach(MaterialResultsVo materialVo) {
}
}

public void requestToFastApi(String videoCode) {
String requestUrl = gptRequestUrl.concat("/?").concat("video_id=").concat(videoCode);
public void requestToFastApi(String videoCode, String videoTitle) {
String requestUrl = gptRequestUrl.concat("/?").concat("video_id=").concat(videoCode)
.concat("&video_title=").concat(videoTitle);

try {
HttpStatus status = webClient.get()
Expand Down

0 comments on commit 01c1b87

Please sign in to comment.