legco_ai_assistant/backend/app
Woody 787c6b1692 fix: vLLM highlight batch failure — replace guided_json with response_format + add debug logging
Root cause: guided_json removed in vLLM v0.12.0, and the two-attempt
loop (structured_outputs → guided_json) merged chat_template_kwargs
into the extra_body, potentially causing param conflicts.

Changes:
- llm_client.py: Replace _complete_structured_vllm() with two-tier
  approach — response_format (Tier 1, v0.6.4+) then structured_outputs
  (Tier 2, v0.8+). Remove dead guided_json path. Add _strip_markdown_fence().

- chunk_highlight_service.py: Add complete() fallback as defense-in-depth
  when structured output fails. Strip markdown fences before parsing.

- chunks.py: Add request/response logging at router level.

- chunk_highlight_service.py: Add full logging chain — entry, ChromaDB
  fetch, LLM call, fallback, cache results, exit.

- ResponsePanel.tsx: Add console logging for request payload, response
  status/errors/timing. Handle status=failed explicitly (was silently
  ignored). Track round-trip timing via performance.now().
2026-05-15 11:08:36 +08:00
..
core feat: Phase 4 — System Audio & Listen Mic capture into ASR → RAG 2026-05-14 22:55:06 +08:00
models feat: Phase 3 — Half Question button, Final Submit rename, ASR text always black 2026-05-14 21:27:21 +08:00
routers fix: vLLM highlight batch failure — replace guided_json with response_format + add debug logging 2026-05-15 11:08:36 +08:00
services fix: vLLM highlight batch failure — replace guided_json with response_format + add debug logging 2026-05-15 11:08:36 +08:00
test feat: Phase 4.8-4.9 — integration tests, acceptance tests, docs, and polish 2026-05-15 09:51:45 +08:00
utils feat: add sentence splitter and highlight data models (Phase 5.4.1-5.4.2) 2026-04-29 09:26:06 +08:00
__init__.py feat: Phase 1.1 project setup with config, database, and models 2026-04-22 16:13:52 +08:00
main.py revert: remove Phase 3 YouTube proxy — all 7 sub-phases 2026-05-09 21:07:21 +08:00