Skip to content

lane: the daily activity claim rides the chat envelope (#85) - #88

Merged
LAGcomcom merged 1 commit into
LAGcomcom:masterfrom
ghshhf:pr-85-daily-activity-envelope
Oct 17, 2026
Merged

LAGcomcom merged 1 commit into
LAGcomcom:masterfrom
ghshhf:pr-85-daily-activity-envelope

Conversation

@ghshhf

@ghshhf ghshhf commented Oct 17, 2026

Copy link
Copy Markdown
Contributor

Fixes #85 — 每日活跃 auto-claim failed on every hourly retry with CLIENT_ERROR ("上游内容门拦截了请求里的客户端特征文本,改写后仍被拒绝") while the same model conversed perfectly on the normal path (1.0s to first token, images included).

#81 established that this gate's refusals are envelope checks, and wbPostOnce already enforces the system-opener half centrally. The daily claim was still the one caller sending shapes no chat turn ever produces:

chat turn daily activity
conversation id wbConversationID(seed) → 32 hex ""
deepseek params wbApplyModelQuirks (thinking:{type:enabled} + mapped effort) hand-written reasoning_effort:"none"

An empty X-Conversation-ID is the exact header the v1.7.16 fix put there for everyone else, and "none" is not a spelling the deepseek family accepts — it has no thinking field beside it at all.

What it does

  • The claim derives a 32-hex conversation id through wbConversationID("wb-daily-activity"), so the header is populated like real traffic.
  • It goes through wbApplyModelQuirks(..., "light"), which switches deepseek thinking on and maps the rung to its cheapest effort (low) — the claim is meant to be the smallest turn that counts, and thinking is forced for this family either way.
  • The hand-written stream_options goes away: wbApplyModelQuirks sets it.

Verified: go vet ./... + go test ./... green. A new test pins the wire shape the claim now sends (32-hex X-Conversation-ID, X-Model-ID, reasoning_effort=low, thinking.type=enabled) so a hand-rolled body cannot regress into this again without a failing test; the existing once-per-day and spent-window tests still pass.

One thing this does not fix: the 积分 card's HTTP 404 on /v2/billing/meter/get-user-resource for 国际版 accounts, which the issue raises alongside it. That is an endpoint question, not a parsing one — guessing the path would be worse than leaving it for someone who can see the real response.

It used to send an empty conversation id and a hand-written
reasoning_effort — shapes no chat turn ever produces — so the gate's
content check answered CLIENT_ERROR on every hourly retry while the
same model conversed fine. The claim now goes through
wbApplyModelQuirks (deepseek thinking switch, effort mapped at the
light rung) and wbConversationID like real traffic.
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.

[Bug] WorkBuddy 每日活跃自动领取每小时重试每小时失败(上游内容门 CLIENT_ERROR)

2 participants