MicroFish/backend
LoryGlory 52c177fd66 feat(llm): add structured output reliability to LLMClient and refactor services
- chat_json() gains configurable retry (max_attempts), temperature backoff
  (temperature_step), optional retry delay, and a fallback_parser hook for
  service-specific rescue logic
- _clean_response_text: strip <think> tags and markdown code fences
- _fix_truncated_json: use unescaped-quote parity instead of last-char check
  to avoid spuriously quoting numeric values; fixes broken repair for arrays
- _try_fix_json: generic near-valid JSON salvage (newline normalisation,
  control-character stripping, greedy object extraction)
- simulation_config_generator: replace raw OpenAI client with LLMClient,
  remove duplicated local retry loop and truncated-JSON repair, pass
  service-specific config salvage as fallback_parser
- oasis_profile_generator: same refactor; keep rule-based profile fallback

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-23 15:45:09 +01:00
..
app feat(llm): add structured output reliability to LLMClient and refactor services 2026-03-23 15:45:09 +01:00
scripts Add UTF-8 encoding support for Windows in simulation_runner.py and run_parallel_simulation.py to resolve character encoding issues with third-party libraries. 2025-12-26 18:14:57 +08:00
pyproject.toml fix(file_parser): handle non-UTF-8 encoded text files with automatic encoding detection 2026-01-22 18:28:37 +08:00
requirements.txt fix(file_parser): handle non-UTF-8 encoded text files with automatic encoding detection 2026-01-22 18:28:37 +08:00
run.py Add UTF-8 encoding support for Windows console in run.py and logger.py to prevent character encoding issues 2025-12-26 17:58:48 +08:00
uv.lock fix(file_parser): handle non-UTF-8 encoded text files with automatic encoding detection 2026-01-22 18:28:37 +08:00