I have a Neural Network, each Neuron is made up of inputs, weights, and output. I have potentially multiple hidden layers. The activation function executed against the output is not known by the Neuron.
I would like to use TD(λ) to back-propagate errors through the network as it explores options. My understanding is that this is forward looking TD(λ) because I won't know the error until I reach a terminal state, and so an eligibility trace needs to be kept for each input+weight combination as I back-propagate the error between the NNs new output based on the state-change from the last prediction and the output from the last prediction.
To try and modularise my code as much as possible, the neuron won't know the loss function, but will instead be given the error as a derivative of whatever the activation function of its output was. It also won't know if it's in a hidden layer or not, it will just have inputs, weights, and an output
For example:
So when each Neuron is back-propagating the error signal from all its output connections (summed before it receives it), how do I calculate the eligibility trace?