Do you need to ask a question?
Your Question
代码文件:modelprocessors.py 247 行的函数process_multimodal_content:
`
image_path = content_data.get("img_path")
captions = content_data.get("img_caption", [])
footnotes = content_data.get("img_footnote", [])
# Build detailed visual analysis prompt
vision_prompt = PROMPTS["vision_prompt"].format(
entity_name=entity_name
if entity_name
else "unique descriptive name for this image",
image_path=image_path,
captions=captions if captions else "None",
footnotes=footnotes if footnotes else "None",
)
# If image path exists, try to encode image
image_base64 = ""
if image_path and Path(image_path).exists():
image_base64 = self._encode_image_to_base64(image_path)
`
我发现传递进来的content_data中图片的路径是相对路径,而且函数process_multimodal_content也没有地方去获取存储图片的根路径,导致无法成功加载图片的base64。
Additional Context
No response
Do you need to ask a question?
Your Question
代码文件:modelprocessors.py 247 行的函数process_multimodal_content:
`
image_path = content_data.get("img_path")
captions = content_data.get("img_caption", [])
footnotes = content_data.get("img_footnote", [])
`
我发现传递进来的content_data中图片的路径是相对路径,而且函数process_multimodal_content也没有地方去获取存储图片的根路径,导致无法成功加载图片的base64。
Additional Context
No response