Files
ZNJJ-api-server/test/api
Eric Wang 11131885a6 feat(api): warn on unrecognized stage codes (B4 gray-release monitoring)
LLM/output stage codes outside STATUS_CODE_MAP were passed through
silently with an empty nextStage - undetectable drift between the
prompt output code set and the endpoint mapping table.

- endpoints: _stage_label / _warn_unknown_stage_code helpers; both
  streaming and non-streaming paths emit a warning with sessionId,
  clientMode, raw and normalized codes when the label lookup misses
  (transparency behavior unchanged: code passes through, label empty)
- known codes and covered internal normalizations (e.g. 2020->0002)
  stay silent; the warning fires on the normalized value

Verified: 229 unit tests (4 new monitoring tests)
2026-10-22 23:19:11 +08:00
..
2025-06-20 11:08:18 +08:00