# This file was auto-generated by Fern from our API Definition.

import enum
import typing

T_Result = typing.TypeVar("T_Result")


class MemoryType(str, enum.Enum):
    """
    Type of memory (`episode` or `belief`)
    """

    EPISODE = "episode"
    BELIEF = "belief"

    def visit(
        self,
        episode: typing.Callable[[], T_Result],
        belief: typing.Callable[[], T_Result],
    ) -> T_Result:
        if self is MemoryType.EPISODE:
            return episode()
        if self is MemoryType.BELIEF:
            return belief()
