MCPcopy Create free account
hub / github.com/MARIO-Math-Reasoning/Super_MARIO / validate_config

Method validate_config

mcts_math/agents/react.py:53–61  ·  view source on GitHub ↗
(cls, cfg: Any)

Source from the content-addressed store, hash-verified

51
52 @field_validator("config")
53 def validate_config(cls, cfg: Any):
54 super().validate_config(cfg)
55 if not cfg.mode == "react":
56 raise ValueError(f"Wrong value for config mode, must be react")
57 if not cfg.n_generate_sample == 1:
58 raise ValueError(f"Wrong value for config n_generate_sample, must be 1")
59 if cfg.stop is None:
60 raise ValueError(f"Wrong value for config stop, cannot be None")
61 return cfg
62
63 def create_node(self, parent: Optional[Type[BaseNode]] = None) -> Type[BaseNode]:
64 return BaseNode(

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected