org.eyelanguage.rl.reading
Class ReadingReinforcementFunction

java.lang.Object
  extended by net.pakl.rl.ReinforcementFunction
      extended by org.eyelanguage.rl.reading.ReadingReinforcementFunction
Direct Known Subclasses:
ReadingParallelReinforcementFunction

public class ReadingReinforcementFunction
extends ReinforcementFunction


Constructor Summary
ReadingReinforcementFunction(SentenceWorld sWorld)
           
 
Method Summary
 double getReward(State state, Action action)
          Return the reward given an action from a particular state.
 double getReward(State state, Action action, State resultingState)
          Sometimes a reward is also based on the resulting state.
 double getRewardForSuccessfulIdentification()
           
 void setReinforcementsForActionsOntoTerminalState(double reward)
           
 void setRewardForSuccessfulIdentification(double rewardForSuccessfulIdentification)
           
 
Methods inherited from class net.pakl.rl.ReinforcementFunction
getDefaultReinforcement, setDefaultReinforcement, setReward, toText
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReadingReinforcementFunction

public ReadingReinforcementFunction(SentenceWorld sWorld)
Method Detail

setReinforcementsForActionsOntoTerminalState

public void setReinforcementsForActionsOntoTerminalState(double reward)

getReward

public double getReward(State state,
                        Action action)
Description copied from class: ReinforcementFunction
Return the reward given an action from a particular state.

Overrides:
getReward in class ReinforcementFunction

getReward

public double getReward(State state,
                        Action action,
                        State resultingState)
Description copied from class: ReinforcementFunction
Sometimes a reward is also based on the resulting state. Rather than re-computing the resulting state of the action (and if the results of actions are stochastic rather than deterministic, that could be the wrong thing to do), this function lets you pass in the state that actually resulted.

Overrides:
getReward in class ReinforcementFunction

getRewardForSuccessfulIdentification

public double getRewardForSuccessfulIdentification()

setRewardForSuccessfulIdentification

public void setRewardForSuccessfulIdentification(double rewardForSuccessfulIdentification)