def METHOD_NAME(draw, ensemble_keys, summary_keys, std_cutoff):
    assume(ensemble_keys is not None or summary_keys is not None)
    names = st.text(
        min_size=1,
        max_size=8,
        alphabet=st.characters(min_codepoint=65, max_codepoint=90),
    )
    seen = set()
    unique_names = names.filter(lambda x: x not in seen).map(lambda x: seen.add(x) or x)
    unique_summary_names = summary_keys.filter(lambda x: x not in seen).map(
        lambda x: seen.add(x) or x
    )
    observation_generators = []
    if ensemble_keys is not None:
        observation_generators.append(
            general_observations(ensemble_keys, std_cutoff, unique_names)
        )
    if summary_keys is not None:
        observation_generators.append(
            summary_observations(summary_keys, std_cutoff, unique_names)
        )
        observation_generators.append(
            st.builds(
                HistoryObservation,
                error=st.floats(
                    min_value=std_cutoff, allow_nan=False, allow_infinity=False
                ),
                segment=st.lists(
                    st.builds(
                        Segment,
                        name=names,
                        start=st.integers(min_value=1, max_value=10),
                        stop=st.integers(min_value=1, max_value=10),
                    ),
                    max_size=2,
                ),
                name=unique_summary_names,
            ),
        )
    return draw(
        st.lists(
            st.one_of(*observation_generators),
            min_size=1,
            max_size=5,
        )
    )