This study explores the use of artificial intelligence, specifically large language models like ChatGPT, in providing written corrective feedback (WCF) for second language composition classes. It emphasizes the importance of prompt engineering to enhance the effectiveness of AI-generated feedback, demonstrating through iterative prompts that clear, specific instructions are vital for improving learner outcomes. While AI can offer significant benefits in language learning, challenges such as dependency on AI feedback and the need for tailored instructional approaches remain.