Class AgentKnowledgeController

java.lang.Object
com.alibaba.cloud.ai.controller.AgentKnowledgeController

@RestController @RequestMapping("/api/agent-knowledge") @CrossOrigin(origins="*") public class AgentKnowledgeController extends Object
智能体知识管理控制器
  • Constructor Details

  • Method Details

    • getKnowledgeByAgentId

      @GetMapping("/agent/{agentId}") public org.springframework.http.ResponseEntity<Map<String,Object>> getKnowledgeByAgentId(@PathVariable Integer agentId, @RequestParam(required=false) String type, @RequestParam(required=false) String status, @RequestParam(required=false) String keyword)
      根据智能体ID查询知识列表
    • getKnowledgeById

      @GetMapping("/{id}") public org.springframework.http.ResponseEntity<Map<String,Object>> getKnowledgeById(@PathVariable Integer id)
      根据ID查询知识详情
    • createKnowledge

      @PostMapping public org.springframework.http.ResponseEntity<Map<String,Object>> createKnowledge(@RequestBody AgentKnowledge knowledge)
      创建知识
    • updateKnowledge

      @PutMapping("/{id}") public org.springframework.http.ResponseEntity<Map<String,Object>> updateKnowledge(@PathVariable Integer id, @RequestBody AgentKnowledge knowledge)
      更新知识
    • deleteKnowledge

      @DeleteMapping("/{id}") public org.springframework.http.ResponseEntity<Map<String,Object>> deleteKnowledge(@PathVariable Integer id)
      删除知识
    • batchUpdateStatus

      @PutMapping("/batch/status") public org.springframework.http.ResponseEntity<Map<String,Object>> batchUpdateStatus(@RequestBody Map<String,Object> request)
      批量更新知识状态
    • getKnowledgeStatistics

      @GetMapping("/statistics/{agentId}") public org.springframework.http.ResponseEntity<Map<String,Object>> getKnowledgeStatistics(@PathVariable Integer agentId)
      获取智能体知识统计信息