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

Function clean_obj_name

eval_heldout/science-world/eval_utils.py:361–366  ·  view source on GitHub ↗
(action)

Source from the content-addressed store, hash-verified

359
360
361def clean_obj_name(action):
362 if "unknown substance" not in action:
363 return action
364 for n in "ABCDEFGHIJKLMNOPQRSTUVWXYZ":
365 action = action.replace(f" {n}", "")
366 return action
367
368def try_to_replace(action, validActions, look=None, inventory=None):
369 if action.startswith("wait"):

Callers 1

try_to_replaceFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected