Skip to content

Commit

Permalink
Merge pull request #36 from easy-lead/feat/#35
Browse files Browse the repository at this point in the history
feat : GPT Message 변경
  • Loading branch information
oU-Ua authored Oct 5, 2024
2 parents 549f945 + 254c776 commit 2ad385b
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package com.easylead.easylead.domain.gpt.dto;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import lombok.*;

@NoArgsConstructor
Expand All @@ -8,6 +9,8 @@
@Setter
@Builder


@JsonIgnoreProperties(ignoreUnknown = true)
public class Message {
String content;
String role;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ public TextFileResDTO easyToReadImage(MultipartFile file) throws JsonProcessingE
log.info("=========== reqText : "+reqText+"============");


HttpRequest request = gptService.requestGPTCustom(reqText);
TextFileResDTO result = textConverter.toTextFileResDTO(gptService.responseGPT(request));
return result;
HttpRequest request = gptService.requestGPT(reqText,"gpt-4o-mini");
return TextFileResDTO.builder().text(gptService.responseGPT(request)).build();

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ public class TextController {

@PostMapping(value = "/image")
public ResponseEntity<TextFileResDTO> easyToReadImage(

@RequestPart(value = "image") MultipartFile file) throws JsonProcessingException {

return ResponseEntity.ok(textBusiness.easyToReadImage(file));
Expand Down

0 comments on commit 2ad385b

Please sign in to comment.