Skip to content

[Bug]: cron tool: local llamacpp model parameter serialization corrupts JSON property names (key concatenation) #88439

@Nassiel

Description

@Nassiel

Bug type

Behavior bug (incorrect output/state without crash)

Beta release blocker

No

Summary

What Happened

When using a local llamacpp model (qwen-27b via llama.cpp), every call to the cron tool with action: add or action: update results in corrupted JSON parameters reaching the gateway. Adjacent top-level property names are concatenated together, and nested objects get merged into flat keys.

Model & Environment

  • Model: local-llamacpp/qwen-27b
  • Host: Linux 6.19.12 (Fedora 43), x86_64
  • Node: v22.22.0
  • OpenClaw: latest (as of 2026-05-30, post-update)

Steps to reproduce

Reproduction

  1. Configure OpenClaw with any local llamacpp model
  2. Attempt any cron tool call via the assistant
  3. Observe that the gateway receives mangled raw_params

Expected behavior

Intended input (what the assistant emits):

json
{
"action": "add",
"job": {
"delivery": {"mode": "none"},
"enabled": true,
"name": "evidence-test",
"payload": {"kind": "agentTurn", "message": "Evidence test.", "timeoutSeconds": 10},
"schedule": {"everyMs": 999999, "kind": "every"},
"sessionTarget": "isolated"
}
}

Actual behavior

What gateway actually receives (from raw_params in logs):

{
  "action": "add",
  "job": {
    "delivery": {"mode": "none"},
    "enabled": true,
    "namePayload": {"kind": "agentTurn", "message": "Evidence test.", "timeoutSeconds": 10},
    "scheduleKind": {"everyMs": 999999, "kind": "every"},
    "sessionTargetName": "evidence-test"
  }
}

Gateway error response:

{
  "status": "error",
  "tool": "cron",
  "error": "invalid cron.add params: must have required property 'name'; at root: unexpected property 'namePayload'"
}

OpenClaw version

v2026.5.27

Operating system

Fedora 44 x86_64

Install method

npm global

Model

qwen-27b

Provider / routing chain

Whatsapp -> openclaw -> llamacpp -> model

Additional provider/model setup details

Corruption Patterns Observed

Intended Corrupted Pattern
"name" + "payload" (separate keys) "namePayload" Adjacent sibling keys concatenate
"schedule" → {"kind": "every"} "scheduleKind" Parent key merges with first nested child key
"sessionTarget": "isolated" "sessionTargetName": "evidence-test" Key merges with next sibling, value gets cross-wired

Impact

All cron add and cron update calls fail when using local llamacpp models
• Cannot create or modify any scheduled jobs via the assistant
cron list, cron remove, cron runs work correctly (simple params)
• Workaround: directly edit ~/.openclaw/cron/jobs.json (confirmed working)

Root Cause Theory

The parameter serialization layer between the llamacpp model's tool-call output and the gateway's JSON Schema validator is corrupting adjacent property names. This is specific to the local llamacpp path — not observed with remote API models. Likely in the tool-call extraction/parsing step before schema validation.

Logs, screenshots, and evidence

Impact and severity

No response

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Normal backlog priority with limited blast radius.bugSomething isn't workingbug:behaviorIncorrect behavior without a crashclawsweeper:fix-shape-clearClawSweeper found a clear likely implementation shape for this issue.clawsweeper:queueable-fixClawSweeper marked this issue as an existing queue_fix_pr work candidate.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.impact:otherThis issue has meaningful maintainer-visible impact outside the owned taxonomy.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions