Enhancing Cognitive Robotics with Commonsense through LLM-Generated Preconditions and Subgoals