AIIntelligentController.java 799 B

12345678910111213141516171819202122232425262728293031
  1. package com.ims.eval.controller;
  2. import com.ims.eval.entity.dto.result.R;
  3. import com.ims.eval.service.custom.AIIntelligentService;
  4. import org.springframework.beans.factory.annotation.Value;
  5. import org.springframework.web.bind.annotation.GetMapping;
  6. import org.springframework.web.bind.annotation.RequestParam;
  7. import org.springframework.web.bind.annotation.RestController;
  8. import javax.annotation.Resource;
  9. import java.util.List;
  10. @RestController
  11. public class AIIntelligentController {
  12. /**
  13. * 所有考评组织名称
  14. */
  15. @Resource
  16. private AIIntelligentService aiIntelligentService;
  17. @GetMapping("/AI")
  18. public R getText(@RequestParam(value = "question",required = true)String question) {
  19. String s = aiIntelligentService.intelligentGeneration(question);
  20. return R.ok().data(s);
  21. }
  22. }