Initial commit: import from sinmb79/Gov-chat-bot

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
airkjw
2026-03-26 12:49:43 +09:00
commit a16c972dbb
104 changed files with 8063 additions and 0 deletions
+28
View File
@@ -0,0 +1,28 @@
from abc import ABC, abstractmethod
from typing import Optional
class LLMProvider(ABC):
@abstractmethod
async def generate(
self,
system_prompt: str,
user_message: str,
context_chunks: list,
max_tokens: int = 512,
) -> Optional[str]:
"""실패 시 None 반환. 예외 raise 금지."""
...
class NullLLMProvider(LLMProvider):
"""LLM_PROVIDER=none 기본값"""
async def generate(
self,
system_prompt: str = "",
user_message: str = "",
context_chunks: list = None,
max_tokens: int = 512,
) -> None:
return None