agentscope-java icon indicating copy to clipboard operation
agentscope-java copied to clipboard

[Feature]:视觉理解模型支持 多模态消息

Open 707348125 opened this issue 8 months ago • 2 comments

使用视觉理解模型 https://bailian.console.aliyun.com/cn-beijing/?tab=doc#/doc/?type=model&url=2845871 百炼api支持,但 agentscppe暂时不支持

Map<String, Object> params = new HashMap<>(); params.put("video", "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20241115/cqqkru/1.mp4"); params.put("fps", 2); MultiModalMessage userMessage = MultiModalMessage.builder().role(Role.USER.getValue()) .content(Arrays.asList( params, Collections.singletonMap("text", "这段视频的内容是什么?"))).build(); MultiModalConversationParam param = MultiModalConversationParam.builder() // 若没有配置环境变量,请用百炼API Key将下行替换为:.apiKey("sk-xxx") // 各地域的API Key不同。获取API Key:https://help.aliyun.com/zh/model-studio/get-api-key .apiKey(System.getenv("DASHSCOPE_API_KEY")) .model("qwen3.6-plus") .messages(Arrays.asList(userMessage)) .build(); MultiModalConversationResult result = conv.call(param);

707348125 avatar Apr 03 '26 11:04 707348125

支持的,VisionExample.java

guanxuc avatar Apr 03 '26 13:04 guanxuc

不支持类似参数传递 只支持url params.put("video", "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20241115/cqqkru/1.mp4"); params.put("fps", 2); //主要这个参数

707348125 avatar Apr 04 '26 15:04 707348125