Skip to content

feat: add ZCode (Zhipu AI) platform support#330

Open
CNHLAIA wants to merge 2 commits into
mindfold-ai:mainfrom
CNHLAIA:feat/zcode-platform
Open

feat: add ZCode (Zhipu AI) platform support#330
CNHLAIA wants to merge 2 commits into
mindfold-ai:mainfrom
CNHLAIA:feat/zcode-platform

Conversation

@CNHLAIA

@CNHLAIA CNHLAIA commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

Closes #329

Note: The platform count increases by 2 (14 → 16) because the previous Reasonix PR (#301) did not update the platform count or trellis-meta references; this PR brings both Reasonix and ZCode docs in sync.

Summary

Add ZCode (Zhipu AI's coding tool) as the 16th supported platform. ZCode is a class-2 (pull-based) platform — it uses agent files with context-reading prelude instructions instead of hooks.

Changes

Code (8 files)

File Change
packages/cli/src/types/ai-tools.ts Add zcode to union types and AI_TOOLS registry
packages/cli/src/configurators/zcode.ts New: ZCode configurator (shared skills + commands + agents)
packages/cli/src/configurators/index.ts Register ZCode in PLATFORM_FUNCTIONS
packages/cli/src/cli/index.ts Add --zcode CLI flag
packages/cli/src/commands/init.ts Add zcode to InitOptions
packages/cli/src/templates/zcode/index.ts New: template entry with getAllAgents()
packages/cli/src/templates/zcode/agents/trellis-implement.md New: implement agent with pull-based prelude
packages/cli/src/templates/zcode/agents/trellis-check.md New: check agent with pull-based prelude

Documentation (12 files)

File Change
README.md Platform count 14 -> 16
README_CN.md Platform count 14 -> 16
trellis-meta/references/platform-files/platform-map.md Add Reasonix + ZCode rows
trellis-meta/references/platform-files/overview.md Add .reasonix/ .zcode/ to directory list
trellis-meta/references/platform-files/agents.md Add Reasonix + ZCode path rows
trellis-meta/references/platform-files/skills-and-commands.md Add Reasonix + ZCode path rows
trellis-meta/references/platform-files/hooks-and-settings.md Add pull-based platform note
trellis-meta/references/local-architecture/overview.md Add directories
trellis-meta/references/local-architecture/generated-files.md Add agent/command example paths
trellis-meta/references/customize-local/overview.md Add .zcode/ to directory lists
trellis-meta/references/customize-local/change-agents.md Add Reasonix + ZCode path rows
trellis-meta/references/customize-local/change-skills-or-commands.md Add ZCode path row

Integration Pattern

ZCode follows the same class-2 pattern as OpenCode, Gemini CLI, and Reasonix:

  • resolveAllAsSkillsNeutral for shared .agents/skills/ (byte-identical across platforms)
  • applyPullBasedPreludeMarkdown for agent context loading
  • Three output paths: .agents/skills/, .zcode/commands/trellis/, .zcode/cli/agents/

Validation

  • pnpm typecheck — passed
  • pnpm lint — passed
  • pnpm test — 1023 passed (27 pre-existing failures unrelated to this PR)
  • Manual testing on separate machine — all three output paths verified
  • ZCode recognizes generated commands and agents

@CNHLAIA CNHLAIA force-pushed the feat/zcode-platform branch from 411a1f5 to c4e06fa Compare June 16, 2026 05:23
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.

新增 智谱 ZCode 平台支持

1 participant