PurposeThe abundance and distribution of tumor-infiltrating lymphocytes (TILs) as well as that of other components of the tumor microenvironment is of particular importance for predicting response to immunotherapy in lung cancer (LC). We describe here a pilot study employing artificial intelligence (AI) in the assessment of TILs and other cell populations, intending to reduce the inter- or intra-observer variability that commonly characterizes this evaluation. DesignWe developed a machine learning-based classifier to detect tumor, immune, and stromal cells on hematoxylin and eosin-stained sections, using the open-source framework QuPath. We evaluated the quantity of the aforementioned three cell populations among 37 LC whole slide images regions of interest, comparing the assessments made by five pathologists, both before and after using graphical predictions made by AI, for a total of 1110 quantitative measurements. ResultsOur findings indicate noteworthy variations in score distribution among pathologists and between individual pathologists and AI. The AI-guided pathologist's evaluations resulted in reduction of significant discrepancies across pathologists: three comparisons showed a loss of significance (p > 0.05),whereas other four showed a reduction in significance (p > 0.01). ConclusionsWe show that employing a machine learning approach in cell population quantification reduces inter- and intra-observer variability, improving reproducibility and facilitating its use in further validation studies.