This is a Colab notebook which can be used to maximize alchemy profitability using the ingredients you have on hand in The Elder Scrolls V: Skyrim.
It uses integer linear programming from scipy.optimize.milp
to determine which potions to make, and in what quantities, to maximize total value. It needs a csv file of the ingredients you have with their quantities, and a csv file of all possible potions you could make with your ingredients. I used this helpful spreadsheet to create my csvs, which are available here as examples.