MCPcopy Create free account
hub / github.com/THUDM/AgentTuning / __init__

Method __init__

eval_heldout/hotpotQA/src/wrappers.py:31–37  ·  view source on GitHub ↗
(self, env, obs_format, prompt=None)

Source from the content-addressed store, hash-verified

29
30class HistoryWrapper(gym.ObservationWrapper):
31 def __init__(self, env, obs_format, prompt=None):
32 super().__init__(env)
33 assert obs_format in ["obs", "history"]
34 if obs_format == "history":
35 assert hasattr(self.env, "traj")
36 self.obs_format = obs_format
37 self.prompt = prompt if prompt is not None else ""
38
39 def observation(self, obs):
40 if self.obs_format == "obs":

Callers

nothing calls this directly

Calls 1

__init__Method · 0.45

Tested by

no test coverage detected