Dependency Inversion in Python

I’ve started to apply SOLID principles to my projects. All of them are clear for me, except dependency inversion, because in Python we have no change to define variable in type of some class inside another class (or maybe just I don’t know). So I’ve realized Dependency Inversion principle in two forms, and want to know which of them is true, how can I correct them. Here are my codes:

class IFood:
    def bake(self, isTendir: bool): pass
class Production:
    def __init__(self): = IFood()
    def produce(self):
class Bread(IFood):
    def bake(self, isTendir:bool):
        print("Bread was baked")

from abc import ABC, abstractmethod
class Food(ABC):
    def bake(self, isTendir): pass
class Production():
    def __init__(self):
        self.bread = Bread()
    def produce(self):
class Bread(Food):
    def bake(self, isTendir:bool):
        print("Bread was baked")

Source: Python-3x Questions