The near-infrared (NIR) wavelength range offers some unique spectral features, and it is less prone to the extinction than the optical one. Recently, the first flux calibrated NIR library of cool stars from the NASA Infrared Telescope Facility (IRTF) have become available, and it has not been fully exploited yet. We want to develop spectroscopic diagnostics for stellar physical parameters based on features in the wavelength range 1-5um. In this work we test the technique in the I and K bands. The study of the Y, J, H, and L bands will be presented in the following paper. An objective method for semi-empirical definition of spectral features sensitive to various physical parameters is applied to the spectra. It is based on sensitivity map - i.e., derivative of the flux in the spectra with respect to the stellar parameters at a fixed wavelength. New optimized indices are defined and their equivalent widths (EWs) are measured.