Added function to ai API that returns the number of code lines.