Description
I am currently using the tradingagents framework and would like to request the inclusion of Xiaomi's Large Language Models (MiLM). Additionally, to make the project more future-proof, I suggest implementing a mechanism that allows users to independently add new models without modifying the core model_catalog.py file.
Why Xiaomi (MiLM)?
Xiaomi has released several capable models (MiLM-6B, MiLM-1.3B, etc.) that are increasingly relevant for developers in the Chinese ecosystem. Integrating these would expand the diversity of the "Deep" and "Quick" selection modes, especially for users seeking highly optimized Chinese-language performance.
Proposed Changes
- Add Xiaomi to the Provider List:
In llm_clients/factory.py, Xiaomi should be added to the _OPENAI_COMPATIBLE list if they use an OpenAI-compatible API, or a dedicated client should be implemented.
- Update the Model Catalog:
Add a new entry for xiaomi or xiaomi-cn in llm_clients/model_catalog.py.
- Dynamic Model Support:
Instead of relying solely on the static MODEL_OPTIONS dictionary, implement a way for the system to read custom model configurations from an external .env file or a local custom_models.json.
Examples in Current Code
Currently, the factory.py uses a rigid check for providers:
if provider_lower in _OPENAI_COMPATIBLE:
from .openai_client import OpenAIClient
return OpenAIClient(model, base_url, provider=provider_lower, **kwargs)
And model_catalog.py requires manual entry for every new model:
MODEL_OPTIONS: ProviderModeOptions = {
"openai": { ... },
"anthropic": { ... },
# Needs a new 'xiaomi' key here
}
Benefit
Providing a method for users to "self-serve" new models (e.g., via a configuration file) would reduce the maintenance burden on the authors and allow the community to test new frontier models (like Xiaomi's) immediately upon release.
Advice for you
Since you are working with e-commerce operations for a liquor enterprise and developing AI-driven automation tools, you might find that Xiaomi's models are particularly useful for local deployment or integration with smart hardware in the future.
One question for you: Do you already have a specific API endpoint for Xiaomi's models (like through a specific cloud provider), or are you planning to run them locally via a tool like Ollama?
Description
I am currently using the
tradingagentsframework and would like to request the inclusion of Xiaomi's Large Language Models (MiLM). Additionally, to make the project more future-proof, I suggest implementing a mechanism that allows users to independently add new models without modifying the coremodel_catalog.pyfile.Why Xiaomi (MiLM)?
Xiaomi has released several capable models (MiLM-6B, MiLM-1.3B, etc.) that are increasingly relevant for developers in the Chinese ecosystem. Integrating these would expand the diversity of the "Deep" and "Quick" selection modes, especially for users seeking highly optimized Chinese-language performance.
Proposed Changes
In
llm_clients/factory.py, Xiaomi should be added to the_OPENAI_COMPATIBLElist if they use an OpenAI-compatible API, or a dedicated client should be implemented.Add a new entry for
xiaomiorxiaomi-cninllm_clients/model_catalog.py.Instead of relying solely on the static
MODEL_OPTIONSdictionary, implement a way for the system to read custom model configurations from an external.envfile or a localcustom_models.json.Examples in Current Code
Currently, the
factory.pyuses a rigid check for providers:And
model_catalog.pyrequires manual entry for every new model:Benefit
Providing a method for users to "self-serve" new models (e.g., via a configuration file) would reduce the maintenance burden on the authors and allow the community to test new frontier models (like Xiaomi's) immediately upon release.
Advice for you
Since you are working with e-commerce operations for a liquor enterprise and developing AI-driven automation tools, you might find that Xiaomi's models are particularly useful for local deployment or integration with smart hardware in the future.
One question for you: Do you already have a specific API endpoint for Xiaomi's models (like through a specific cloud provider), or are you planning to run them locally via a tool like Ollama?