feat(nacos): Update NacosSkillRepository extension module version#1080
Merged
Conversation
# Conflicts: # agentscope-dependencies-bom/pom.xml
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
liangxingguang
pushed a commit
to liangxingguang/agentscope-java
that referenced
this pull request
May 21, 2026
…entscope-ai#1080) ### Description **Background & motivation** Enable AgentScope-Java to load AI Skill packages from Nacos via `AiService`, aligned with `AgentSkillRepository` and `AgentSkill`, so teams using Nacos can host, version, or label skills in one place. **What changed** - New module **`agentscope-extensions-nacos-skill`**: `NacosSkillRepository` implements `AgentSkillRepository`, downloads the skill ZIP through Nacos `AiService` (`downloadSkillZip`, `downloadSkillZipByVersion`, `downloadSkillZipByLabel`), then parses it with `SkillUtil#createFromZip`. - **Version & label resolution**: `agentscope.nacos.skill.version` / `agentscope.nacos.skill.label` from `Properties`, JVM system properties, or env vars (`AGENTSCOPE_NACOS_SKILL_VERSION` / `AGENTSCOPE_NACOS_SKILL_LABEL`); precedence is documented on the class. - **Read-only semantics**: `getSkill`, `skillExists`, `getRepositoryInfo`, `getSource`, `isWriteable` are implemented; list/write APIs (`getAllSkillNames`, `getAllSkills`, `save`, `delete`) are documented no-ops with warnings. - **YAML frontmatter adaptation**: Rewrites Nacos-exported `SKILL.md` frontmatter (indented continuation lines) so it matches AgentScope’s flat `key: value` parsing. - **Build & distribution**: Module is wired under `agentscope-extensions-nacos`, and included in `agentscope-bom` / `agentscope-all` for dependency alignment; `nacos-client` version is managed in the BOM. **How to test** 1. Format: `mvn spotless:apply` (whole repo or selected modules). 2. Unit tests: `mvn test -pl agentscope-extensions/agentscope-extensions-nacos/agentscope-extensions-nacos-skill`. 3. Optional integration: Use a real Nacos AI skill and `AiService`, build `NacosSkillRepository(aiService, namespaceId, properties)`, call `getSkill` / `skillExists`; repeat with version or label properties set.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Background & motivation
Enable AgentScope-Java to load AI Skill packages from Nacos via
AiService, aligned withAgentSkillRepositoryandAgentSkill, so teams using Nacos can host, version, or label skills in one place.What changed
agentscope-extensions-nacos-skill:NacosSkillRepositoryimplementsAgentSkillRepository, downloads the skill ZIP through NacosAiService(downloadSkillZip,downloadSkillZipByVersion,downloadSkillZipByLabel), then parses it withSkillUtil#createFromZip.agentscope.nacos.skill.version/agentscope.nacos.skill.labelfromProperties, JVM system properties, or env vars (AGENTSCOPE_NACOS_SKILL_VERSION/AGENTSCOPE_NACOS_SKILL_LABEL); precedence is documented on the class.getSkill,skillExists,getRepositoryInfo,getSource,isWriteableare implemented; list/write APIs (getAllSkillNames,getAllSkills,save,delete) are documented no-ops with warnings.SKILL.mdfrontmatter (indented continuation lines) so it matches AgentScope’s flatkey: valueparsing.agentscope-extensions-nacos, and included inagentscope-bom/agentscope-allfor dependency alignment;nacos-clientversion is managed in the BOM.How to test
mvn spotless:apply(whole repo or selected modules).mvn test -pl agentscope-extensions/agentscope-extensions-nacos/agentscope-extensions-nacos-skill.AiService, buildNacosSkillRepository(aiService, namespaceId, properties), callgetSkill/skillExists; repeat with version or label properties set.