MCPcopy Index your code
hub / github.com/dataease/SQLBot / create_llm

Method create_llm

backend/apps/ai_model/model_factory.py:124–128  ·  view source on GitHub ↗
(cls, config: LLMConfig)

Source from the content-addressed store, hash-verified

122 @classmethod
123 @lru_cache(maxsize=32)
124 def create_llm(cls, config: LLMConfig) -> BaseLLM:
125 llm_class = cls._llm_types.get(config.model_type)
126 if not llm_class:
127 raise ValueError(f"Unsupported LLM type: {config.model_type}")
128 return llm_class(config)
129
130 @classmethod
131 def register_llm(cls, model_type: str, llm_class: Type[BaseLLM]):

Callers 2

__init__Method · 0.80
generateFunction · 0.80

Calls 1

getMethod · 0.65

Tested by

no test coverage detected