Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Dual-AI code analysis pairing z.ai GLM 5.2 with Claude code-searcher — a lightweight two-model second opinion. Use for a quick z.ai-backed check on a code question.
.claude/skills/bilal140202-consult-zai/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-06 | ✗→✓ | ▲ Improved | 9% | 0% |
| case-07 | ✗→✓ | ▲ Improved | 21% | 0% |
| case-08 | ✗→✓ | ▲ Improved | 70% | 0% |
| case-09 | ✗→✓ | ▲ Improved | 194% | 0% |
| case-11 | ✗→✓ | ▲ Improved | 19% | 0% |
You orchestrate consultation between z.ai's GLM 5.2 model and Claude's code-searcher to provide comprehensive analysis with comparison.
High value queries:
Lower value (single AI may suffice):
When the user asks a code question:
Wrap the user's question with structured output requirements:
[USER_QUESTION]
=== Analysis Guidelines ===
**Structure your response with:**
1. **Summary:** 2-3 sentence overview
2. **Key Findings:** bullet points of discoveries
3. **Evidence:** file paths with line numbers (format: `file:line` or `file:start-end`)
4. **Confidence:** High/Medium/Low with reasoning
5. **Limitations:** what couldn't be determined
**Line Number Requirements:**
- ALWAYS include specific line numbers when referencing code
- Use format: `path/to/file.ext:42` or `path/to/file.ext:42-58`
- For multiple references: list each with its line number
- Include brief code snippets for key findings
**Examples of good citations:**
- "The authentication check at `src/auth/validate.ts:127-134`"
- "Configuration loaded from `config/settings.json:15`"
- "Error handling in `lib/errors.ts:45, 67-72, 98`"Launch both simultaneously in a single message with multiple tool calls:
Step 0 — run-scope the filename and sweep stale prompts. Pick a unique RUN_ID for this run (e.g. a timestamp + short random token such as 20260616-a3f1) and use the literal filename zai-prompt-RUN_ID.txt (with RUN_ID substituted) in Steps 1–2 and in §3 cleanup. Run-scoping prevents a concurrent consult-zai run from truncating this run's prompt. First sweep any orphans left by interrupted past runs: bash mkdir -p "$CLAUDE_PROJECT_DIR/tmp" find "$CLAUDE_PROJECT_DIR/tmp" -maxdepth 1 -name 'zai-prompt-*.txt' -mmin +60 -delete 2>/dev/null
Step 1: Write the enhanced prompt to the temp file using the Write tool: Write to $CLAUDE_PROJECT_DIR/tmp/zai-prompt-RUN_ID.txt with the ENHANCED_PROMPT content
Step 2: Execute z.ai with the temp file:
macOS: bash zsh -i -c 'zai -p "$(cat "$CLAUDE_PROJECT_DIR/tmp/zai-prompt-RUN_ID.txt")" --output-format json --append-system-prompt "You are GLM 5.2 model accessed via z.ai API." 2>&1'
Linux: bash bash -i -c 'zai -p "$(cat "$CLAUDE_PROJECT_DIR/tmp/zai-prompt-RUN_ID.txt")" --output-format json --append-system-prompt "You are GLM 5.2 model accessed via z.ai API." 2>&1'
This approach avoids all shell quoting issues regardless of prompt content.
subagent_type: "code-searcher" with the same enhanced promptThis parallel execution significantly improves response time.
After processing the z.ai response (success or failure), clean up the temp prompt file:
bashrm -f "$CLAUDE_PROJECT_DIR/tmp/zai-prompt-RUN_ID.txt"
This prevents stale prompts from accumulating and avoids potential confusion in future runs.
Use this exact format:
Raw output from zai-cli agent]
Raw output from code-searcher agent]
(MANDATORY — always render this table on a multi-agent run; it is the at-a-glance visual diff readers rely on, so never skip it. Omit only in a degraded single-AI run, where there is nothing to compare.)
| Aspect | z.ai (GLM 5.2) | Code-Searcher (Claude) | |--------|----------------|------------------------| | File paths | Specific/Generic/None] | Specific/Generic/None] | | Line numbers | Provided/Missing] | Provided/Missing] | | Code snippets | Yes/No + details] | Yes/No + details] | | Unique findings | List any] | List any] | | Accuracy | Note discrepancies] | Note discrepancies] | | Strengths | Summary] | Summary] |
State which level applies and explain]
Combine the best insights from both sources into unified analysis. Prioritize findings that are:
Which source was more helpful for this specific query and why. Consider:
| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-04 | pass→pass | 10,911 | 8,309 | -24% | 1 | 1 | 0% | 1,700 | 3,211 | +89% | 0 | 0 | — |
case-10 | fail→fail | 9,858 | 29,412 | +198% | 1 | 1 | 0% | 1,773 | 4,427 | +150% | 0 | 0 | — |
case-01 | fail→fail | 21,158 | 31,719 | +50% | 1 | 1 | 0% | 3,775 | 4,627 | +23% | 0 | 0 | — |
case-02 | fail→fail | 19,070 | 47,079 | +147% | 1 | 1 | 0% | 1,624 | 5,196 | +220% | 0 | 0 | — |
case-03 | fail→fail | 31,115 | 40,660 | +31% | 1 | 1 | 0% | 5,770 | 5,290 | -8% | 0 | 0 | — |
case-05 | fail→fail | 9,808 | 33,331 | +240% | 1 | 1 | 0% | 1,648 | 4,201 | +155% | 0 | 0 | — |
case-06 | fail→pass | 10,549 | 2,748 | -74% | 1 | 1 | 0% | 1,812 | 1,970 | +9% | 0 | 0 | — |
case-07 | fail→pass | 20,358 | 4,299 | -79% | 1 | 1 | 0% | 1,966 | 2,380 | +21% | 0 | 0 | — |
case-08 | fail→pass | 7,067 | 2,982 | -58% | 1 | 1 | 0% | 1,219 | 2,077 | +70% | 0 | 0 | — |
case-09 | fail→pass | 4,371 | 2,824 | -35% | 1 | 1 | 0% | 676 | 1,988 | +194% | 0 | 0 | — |
case-11 | fail→pass | 9,634 | 2,272 | -76% | 1 | 1 | 0% | 1,554 | 1,855 | +19% | 0 | 0 | — |
case-12 | pass→fail | 10,299 | 4,828 | -53% | 1 | 1 | 0% | 1,667 | 2,371 | +42% | 0 | 0 | — |
case-13 | fail→pass | 7,260 | 3,475 | -52% | 1 | 1 | 0% | 1,328 | 2,231 | +68% | 0 | 0 | — |
case-14 | fail→pass | 15,263 | 7,035 | -54% | 1 | 1 | 0% | 1,252 | 2,831 | +126% | 0 | 0 | — |
case-15 | fail→fail | 10,080 | 20,687 | +105% | 1 | 1 | 0% | 2,038 | 2,571 | +26% | 0 | 0 | — |
case-16 | fail→fail | 11,497 | 5,462 | -52% | 1 | 1 | 0% | 2,054 | 2,555 | +24% | 0 | 0 | — |
case-17 | fail→pass | 11,646 | 5,798 | -50% | 1 | 1 | 0% | 1,983 | 2,498 | +26% | 0 | 0 | — |
case-18 | fail→fail | 8,466 | 4,513 | -47% | 1 | 1 | 0% | 1,643 | 2,519 | +53% | 0 | 0 | — |
case-19 | fail→fail | 9,288 | 4,300 | -54% | 1 | 1 | 0% | 1,669 | 2,337 | +40% | 0 | 0 | — |
case-20 | fail→fail | 2,687 | 34,666 | +1190% | 1 | 1 | 0% | 548 | 5,338 | +874% | 0 | 0 | — |
case-21 | pass→fail | 2,984 | 21,411 | +618% | 1 | 1 | 0% | 490 | 3,286 | +571% | 0 | 0 | — |
case-22 | fail→fail | 1,283 | 24,258 | +1791% | 1 | 1 | 0% | 156 | 4,233 | +2613% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 22 cases were attempted, and 14 counted toward the lift figure. The other 8 produced results that are not comparable between the two arms, so they are excluded from the headline rather than averaged into it. The headline lift of +27 percentage points is the difference between those two pass rates over the 14 comparable cases. 2 cases got worse with the skill loaded, and they are included in that figure.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
Other measured skills in the registry, with their headline benchmark lift.