@@ -140,8 +140,10 @@ def __init__(
140140 ----------
141141 ssm : PytensorRepresentation
142142 The state space representation containing system matrices.
143- name : str
144- Name of the model. If None, defaults to "StructuralTimeSeries".
143+ name : str, optional
144+ Prefix applied to all internal graph variable and data names, allowing multiple
145+ state space models to coexist in the same PyMC model without naming collisions.
146+ If ``None`` (default), no prefix is applied and variable names are unchanged.
145147 coords_info : CoordInfo
146148 Coordinate specifications for model dimensions.
147149 param_info : ParameterInfo
@@ -167,7 +169,6 @@ def __init__(
167169 mode : str | Mode | None, default None
168170 PyTensor compilation mode.
169171 """
170- self ._name = name or "StructuralTimeSeries"
171172 self .measurement_error = measurement_error
172173
173174 k_states , k_posdef , k_endog = ssm .k_states , ssm .k_posdef , ssm .k_endog
@@ -1025,8 +1026,13 @@ def build(
10251026
10261027 Parameters
10271028 ----------
1028- name: str, optional
1029- Name of the exogenous data being modeled. Default is "data"
1029+ name : str, optional
1030+ Prefix applied to all internal graph variable and data names, allowing multiple
1031+ structural models to coexist in the same PyMC model without naming collisions.
1032+ If ``None`` (default), no prefix is applied. When a name is provided, prior
1033+ variables must be named with the prefix, e.g. ``pm.Normal("m1_initial_trend", ...)``
1034+ for ``name="m1"``. Use ``model.prefixed_name(p)`` for each ``p`` in
1035+ ``model.param_names`` to get the expected names.
10301036
10311037 filter_type : str, optional
10321038 The type of Kalman filter to use. Valid options are "standard", "univariate", "single", "cholesky", and
0 commit comments