| name | ulps-uncertainty-aware-llm-policy-shaping |
| description | Uncertainty-Aware LLM-Guided Policy Shaping for sparse-reward RL. Integrates calibrated LLM into RL training loop with uncertainty-modulated behavioral guidance. |
| version | 1 |
| created | 2026-06-10T00:00:00.000Z |
| source | arXiv 2606.06673v1 |
| tags | ["RL","LLM","policy-shaping","uncertainty","sparse-reward","PPO"] |
ULPS: Uncertainty-Aware LLM-Guided Policy Shaping
Methodology for integrating Large Language Models into Reinforcement Learning training loops with uncertainty-modulated behavioral guidance for sparse-reward domains.
Key Concepts
- A-Based Oracle*: Synthesize optimal symbolic trajectories for fine-tuning language model
- Monte Carlo Dropout Uncertainty: Estimate epistemic uncertainty for action suggestions
- Entropy-Based Blending: Adaptively balance LLM guidance vs learned policy
- PPO Integration: Work with Proximal Policy Optimization base policy
When to Use
- Sparse reward environments (MiniGrid, grid-world tasks)
- Multi-task RL with heterogeneous task sequences
- Partially observable settings
- When exploration is inefficient with vanilla RL
Core Components
1. Symbolic Trajectory Synthesis
class AStarOracle:
def synthesize_trajectory(self, task_spec):
return optimal_actions, path_cost
2. Uncertainty Estimation
def estimate_uncertainty(model, state, n_samples=10):
model.train()
predictions = [model.predict(state) for _ in range(n_samples)]
variance = np.var(predictions, axis=0)
return variance
3. Entropy-Based Blending
def blend_policies(llm_action, policy_action, uncertainty, entropy_threshold):
if uncertainty < entropy_threshold:
return llm_action, alpha=0.8
else:
return policy_action, alpha=0.3
4. Full Training Loop
def ulps_training_loop(env, llm_model, ppo_agent, n_episodes):
for episode in range(n_episodes):
state = env.reset()
while not done:
llm_action = llm_model.predict_action(state)
uncertainty = estimate_uncertainty(llm_model, state)
policy_action = ppo_agent.act(state)
action = blend_policies(llm_action, policy_action, uncertainty)
next_state, reward, done = env.step(action)
ppo_agent.update(state, action, reward, next_state)
Results (MiniGridUnlockPickUp)
- +9% improvement in execution accuracy after fine-tuning
- Fewer environment interactions required
- Higher reward AUC vs unguided baselines
Activation Triggers
uncertainty-aware RL, LLM-guided policy, sparse reward, A* oracle RL, epistemic uncertainty policy
References
- arXiv:2606.06673v1 - Bhatta et al., "Uncertainty-Aware LLM-Guided Policy Shaping for Sparse-Reward Reinforcement Learning"
- MiniGrid benchmark environments
- Monte Carlo dropout uncertainty estimation (Gal & Ghahramani, 2016)