langgoap.rehydrate_state

langgoap.rehydrate_state#

rehydrate_state(state, actions=None)[source]#

Return a copy of state with typed goal, plan and history.

Bookkeeping keys that are absent are filled from STATE_DEFAULTS; goal, world_state, plan and status stay absent when absent. Keys already holding typed objects pass through. actions is the live action list (or name -> spec mapping) used to rebind plan actions.

Parameters:
Return type:

GoapState