Skip to content

feat(skills): 为vestack环境添加 minio 文件上传下载支持#546

Open
DawnGuoDev wants to merge 2 commits intovolcengine:mainfrom
DawnGuoDev:feat/vestack-skills-support-minio
Open

feat(skills): 为vestack环境添加 minio 文件上传下载支持#546
DawnGuoDev wants to merge 2 commits intovolcengine:mainfrom
DawnGuoDev:feat/vestack-skills-support-minio

Conversation

@DawnGuoDev
Copy link
Copy Markdown

添加对vestack环境的支持,包括:

  1. 通过GenTempTosObjectUrl/GenTempTosObjectDownloadUrl API获取临时URL
  2. 使用requests库实现文件上传下载
  3. 使用环境变量AGENTKIT_TOOL_SCHEME配置请求协议

添加对vestack环境的支持,包括:
1. 通过GenTempTosObjectUrl/GenTempTosObjectDownloadUrl API获取临时URL
2. 使用requests库实现文件上传下载
3. 使用环境变量AGENTKIT_TOOL_SCHEME配置请求协议
@DawnGuoDev DawnGuoDev force-pushed the feat/vestack-skills-support-minio branch from a64d80c to fb9c52e Compare March 26, 2026 06:42
save_path=save_path,
)
cloud_provider = (os.getenv("CLOUD_PROVIDER") or "").lower()
if cloud_provider == "vestack":
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

create new method for vestack?

if cloud_provider == "vestack":
import requests

try:
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

put into new method instead

"InnerTags": {"source": "sandbox"},
}
logger.debug(f"ListSkillsBySpaceId request body: {request_body}")
scheme = os.getenv("AGENTKIT_TOOL_SCHEME", "https").lower()
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minio schema? -> CUSTOM_SCHEME, e.g. minio

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个统一起来吧,针对 vestack 来说,走 top 的请求,都是统一的。AGENTKIT_TOP_SCHEME

将vestack环境下的技能下载逻辑提取到独立函数`_download_skill_via_vestack`中,提高代码复用性
同时将环境变量`AGENTKIT_TOOL_SCHEME`统一更新为`AGENTKIT_TOP_SCHEME`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants