Separate show/generate methods, improve error handling