stock-lab: Gemini 모델 gemini-1.5-flash로 변경 (무료 할당량)
2.5 Pro는 결제 설정 필요. 1.5 Flash는 무료 1500 RPD. 결제 설정 후 GEMINI_MODEL 환경변수로 원하는 모델 지정 가능. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -30,7 +30,7 @@ services:
|
|||||||
- TZ=${TZ:-Asia/Seoul}
|
- TZ=${TZ:-Asia/Seoul}
|
||||||
- WINDOWS_AI_SERVER_URL=${WINDOWS_AI_SERVER_URL:-http://192.168.0.5:8000}
|
- WINDOWS_AI_SERVER_URL=${WINDOWS_AI_SERVER_URL:-http://192.168.0.5:8000}
|
||||||
- GEMINI_API_KEY=${GEMINI_API_KEY:-}
|
- GEMINI_API_KEY=${GEMINI_API_KEY:-}
|
||||||
- GEMINI_MODEL=${GEMINI_MODEL:-gemini-2.5-pro}
|
- GEMINI_MODEL=${GEMINI_MODEL:-gemini-1.5-flash}
|
||||||
volumes:
|
volumes:
|
||||||
- ${STOCK_DATA_PATH:-./data/stock}:/app/data
|
- ${STOCK_DATA_PATH:-./data/stock}:/app/data
|
||||||
|
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ def _get_model():
|
|||||||
import google.generativeai as genai # lazy import (설치 안 된 경우 대비)
|
import google.generativeai as genai # lazy import (설치 안 된 경우 대비)
|
||||||
|
|
||||||
genai.configure(api_key=api_key)
|
genai.configure(api_key=api_key)
|
||||||
model_name = os.getenv("GEMINI_MODEL", "gemini-2.5-pro")
|
model_name = os.getenv("GEMINI_MODEL", "gemini-1.5-flash")
|
||||||
return genai.GenerativeModel(
|
return genai.GenerativeModel(
|
||||||
model_name,
|
model_name,
|
||||||
generation_config={
|
generation_config={
|
||||||
|
|||||||
Reference in New Issue
Block a user