Reinforcement Learning (RL) models

Overview

RL agents that can perform any dynamic foraging task in aind-behavior-gym and can fit behavior using MLE.

https://github.com/user-attachments/assets/1edbcdb4-932f-4674-bcdc-97d2c840fc72

Code structure

classes_aind_dynamic_foraging_models

Implemented foragers

  • ForagerQLearning: Simple Q-learning agents that incrementally update Q-values.

    Available agent_kwargs:

    number_of_learning_rate: Literal[1, 2] = 2,
    number_of_forget_rate: Literal[0, 1] = 1,
    choice_kernel: Literal["none", "one_step", "full"] = "none",
    action_selection: Literal["softmax", "epsilon-greedy"] = "softmax",
    
  • ForagerLossCounting: Loss counting agents with probabilistic loss_count_threshold.

    Available agent_kwargs:

    win_stay_lose_switch: Literal[False, True] = False,
    choice_kernel: Literal["none", "one_step", "full"] = "none",
    

Here is the full list of available foragers:

https://github.com/user-attachments/assets/db2e3b6c-f888-496c-a12b-06e030499165 https://github.com/user-attachments/assets/4f7b669c-2f0e-49cc-8fb4-7fa948926e2e

Usage

RL model playground

Play with the generative models here.

https://github.com/user-attachments/assets/691986b0-114b-437c-8df9-3b7b18f83de9