diff --git a/.generator/src/generator/templates/model_generic.j2 b/.generator/src/generator/templates/model_generic.j2 index 5bf20ea66c..5200780d34 100644 --- a/.generator/src/generator/templates/model_generic.j2 +++ b/.generator/src/generator/templates/model_generic.j2 @@ -74,6 +74,11 @@ class {{ name }}(ModelNormal): {%- if model.nullable %} _nullable = True {%- endif %} +{%- if model.get("x-keep-typed-in-additional-properties") %} + # Cross-SDK semantic marker. In Python, typed fields are already accessible via + # bracket notation (model["key"]) through _data_store, so no runtime change is needed. + _keep_typed_in_additional_properties = True +{%- endif %} {%- if model.properties %} @cached_property