feat(backend): 이미지 요청만 vision 모델로 — OPENCODE_VISION_MODEL

로컬(OpenRouter)은 게이트웨이를 안 거쳐서 백엔드가 OpenCode prompt 에 model{providerID,modelID} 를 실어 분기.
기본 openrouter/google/gemma-4-31b-it(고객사 605 와 같은 모델). 텍스트는 기본 GLM 5.2.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
lee-hyeon-cheol
2026-09-21 14:54:04 +09:00
co-authored by Claude Fable 5.1
parent 6d7723a533
commit 113d97c77c
6 changed files with 28 additions and 2 deletions
+3
View File
@@ -75,6 +75,9 @@ OPENCODE_BASE_URL = _env("OPENCODE_BASE_URL", "http://localhost:4096").rstrip("/
OPENCODE_DIRECTORY = _env("OPENCODE_DIRECTORY") or str((BASE_DIR / "opencode").resolve())
# OpenCode 에 넘길 에이전트 이름 (opencode/.opencode/agent/<이름>.md)
OPENCODE_AGENT = _env("OPENCODE_AGENT", "codeassist")
# 이미지가 붙은 요청만 이 모델로("provider/model" 형식, opencode.json 에 등록돼 있어야 함). 비우면 기본 모델.
# 로컬(OpenRouter)용 — 고객사(FabriX)는 게이트웨이가 AAF_FABRIX_VISION_MODEL_ID 로 같은 분기를 함.
OPENCODE_VISION_MODEL = _env("OPENCODE_VISION_MODEL")
# 채팅 스트림 타임아웃(초). Gemma4 가 "안녕"에도 200초 걸리는 날이 있어 첫 이벤트 300, 한 턴 600.
STREAM_TURN_TIMEOUT_S = int(_env("STREAM_TURN_TIMEOUT_S", "600"))