I have a data set from two groups: firms that use AI and their costs and firms that don't use AI and their costs. Within both groups I have data about their specific costs, e.g. fixed costs, variable costs, etc.
I'm not sure if regression is the best way to do this, but I want to explore whether firms that use AI have lower costs. Any ideas on how I'd do this? Could I run OLS on both groups and just compare? The sample for firms that use AI is ~40 and ~100 for those that don't.
You probably want to do a two-sample t-test since you are comparing two populations on one variable and you would like to check if the means of the costs from both groups are equal. There are a few variants of the two-sample t-test based on whether you want to pool or not.
You probably want to use the null hypothesis: $$H_0 : \mu_1 = \mu_2$$ where $\mu_1$ is the mean cost for the first population (those that use AI) and $\mu_2$ is the mean cost for the second population, and use an alternative hypothesis of: $$\mu_1 < \mu_2$$ to see whether firms that use AI (population 1) have less cost.
For reference, wikipedia article on t-tests or this article.