2222from khiops .core .internals .runner import get_runner
2323
2424
25- def build_multi_table_dictionary_domain (
25+ def _build_multi_table_dictionary_domain (
2626 dictionary_domain , root_dictionary_name , secondary_table_variable_name
2727):
2828 """Builds a multi-table dictionary domain from a dictionary with a key
29-
3029 Parameters
3130 ----------
3231 dictionary_domain : `.DictionaryDomain`
@@ -36,6 +35,11 @@ def build_multi_table_dictionary_domain(
3635 secondary_table_variable_name : str
3736 Name, in the root dictionary, for the "table" variable of the secondary table.
3837
38+ Returns
39+ -------
40+ `.DictionaryDomain`
41+ The new dictionary domain
42+
3943 Raises
4044 ------
4145 `TypeError`
@@ -45,6 +49,16 @@ def build_multi_table_dictionary_domain(
4549 - the dictionary domain doesn't contain at least a dictionary
4650 - the dictionary domain's root dictionary doesn't have a key set
4751 """
52+
53+ # This is a special-purpose function whose goal is to assist in preparing the
54+ # coclustering deployment.
55+ # This function builds a new root dictionary and adds it to an existing dictionary
56+ # domain.
57+ # The new root dictionary only contains one field, which references a preexisting
58+ # dictionary from the input dictionary domain as a new (secondary) Table variable.
59+ # The preexisting dictionary must have a key set on it, as this is the join key
60+ # with the new root table.
61+
4862 # Check that `dictionary_domain` is a `DictionaryDomain`
4963 if not isinstance (dictionary_domain , DictionaryDomain ):
5064 raise TypeError (
@@ -279,7 +293,7 @@ def deploy_coclustering(
279293 # Create a root dictionary containing the keys
280294 root_dictionary_name = "CC_" + dictionary_name
281295 table_variable_name = "Table_" + dictionary_name
282- domain = build_multi_table_dictionary_domain (
296+ domain = _build_multi_table_dictionary_domain (
283297 tmp_domain , root_dictionary_name , table_variable_name
284298 )
285299
0 commit comments