We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f631f41 commit 7ce5e18Copy full SHA for 7ce5e18
ai_edge_torch/generative/utilities/litertlm_builder.py
@@ -114,10 +114,8 @@ def build_litertlm(
114
115
llm_metadata.max_num_tokens = context_length
116
117
- if (
118
- llm_metadata.llm_model_type
119
- == llm_model_type_pb2.LlmModelType.generic_model
120
- ):
+ mdl_type = llm_metadata.llm_model_type.WhichOneof('model_type')
+ if not mdl_type or mdl_type == 'generic_model':
121
match llm_model_type:
122
case litertlm_builder.LlmModelType.GENERIC:
123
llm_metadata.llm_model_type.CopyFrom(
0 commit comments