I'm working on a Q-learning algorithm that navigates over OSMNX nodes. My goal is to offer the Q-learning agent an step based context where on each step I can list the possible actions like: "straight, turn left, turn right...". So I would need a list of immediate connected nodes that could offer this decision context step by step. The idea is to combine POI data so the agent can be "distracted" by the surroundings.
I've tried
ox.get_nearest_node()
but that only gets me the nearest node to those coordinates but not the list of immediate connected nodes