The OpenAI API call itself takes about ten lines. The real work is everything around it - streaming the response so the UI doesn't freeze, handling errors without showing users something terrifying, writing prompts that produce consistent output, and making the whole thing feel like a feature rather than a science experiment.