Improve sample script.