Skip to content

API Reference parrot.flows.dev_loop.dispatchers.zai

github-actions[bot] edited this page Dec 2, 2026 · 4 revisions

parrot.flows.dev_loop.dispatchers.zai

View source

ZaiCodeDispatcher — local coding-agent loop bound to ZaiClient / GLM-5.2.

Alias DispatchLabels

Re-exported from parrot.flows.dev_loop.models.DispatchLabels.

Alias LLMCodeDispatcher

Re-exported from parrot.flows.dev_loop.dispatchers.llm.LLMCodeDispatcher.

Alias LLMFactory

Re-exported from parrot.clients.factory.LLMFactory.

Alias SessionHost

Re-exported from parrot.flows.dev_loop.session_state.SessionHost.

Alias T

Re-exported from parrot.flows.dev_loop.dispatchers._shared.T.

Alias ZaiCodeDispatchProfile

Re-exported from parrot.flows.dev_loop.models.ZaiCodeDispatchProfile.

Class ZaiCodeDispatcher

Local coding-agent loop bound to ZaiClient / GLM-5.2.

Extends LLMCodeDispatcher to reuse the inherited local tool loop, Redis event streaming, cwd-safety guard, and output validation, while overriding the completion-args and chat-completion hooks so requests carry Z.ai-native thinking/reasoning_effort parameters instead of the Nvidia-style extra_body.chat_template_kwargs block emitted by the base class.

Parameter Type Default Description
max_concurrent int
redis_url str
stream_ttl_seconds int

Method ZaiCodeDispatcher.dispatch

dispatch(*, brief: BaseModel, profile: ZaiCodeDispatchProfile, output_model: Type[T], run_id: str, node_id: str, cwd: str, session_host: Optional[SessionHost] = None, labels: Optional[DispatchLabels] = None) -> T

Parameter Type Default Description
brief BaseModel
profile ZaiCodeDispatchProfile
output_model Type[T]
run_id str
node_id str
cwd str
session_host Optional[SessionHost] None
labels Optional[DispatchLabels] None

Returns: T

Architecture

Clients

Bots & Agents

Memory

Knowledge

Tools & Toolkits

Flows

Experts

Skills

Stores & Loaders

MCP & A2A

Server & APIs

Integrations

Outputs & A2UI

Prompts

Security

Operations

Migration

SDD Tooling

LLM Wiki

Deployment

Decisions

API Reference

Clone this wiki locally