This paper presents ADVICE (Adaptive Shielding with a Contrastive Autoencoder), a novel postprocessing technique for safe exploration of reinforcement learning (RL) agents. It focuses on reducing safety risks that arise when training RL agents in black-box environments without prior knowledge. ADVICE distinguishes between safe and unsafe features of state-action pairs, thereby protecting the agent from performing actions likely to lead to unsafe outcomes. Experimental results demonstrate that it reduces safety violations by approximately 50% compared to existing safe RL exploration techniques, while achieving competitive rewards.