Skip to content

Commit

Permalink
Add missing superclass overrides.EnforceOverrides
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 650025315
Change-Id: Id9f352031b9f907a6e8e7bd6b66e3b9e4124830f
  • Loading branch information
duenez authored and Copybara-Service committed Jul 7, 2024
1 parent fe939f9 commit 3035fde
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion concordia/typing/component_v2.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
from typing import Any

from concordia.typing import entity as entity_lib
import overrides

ComponentName = str
ComponentContext = str
Expand Down Expand Up @@ -75,7 +76,7 @@ def get_component(self, component_name: str) -> "BaseComponent":
raise NotImplementedError()


class BaseComponent:
class BaseComponent(overrides.EnforceOverrides):
"""A base class for components."""

def __init__(self):
Expand Down
3 changes: 2 additions & 1 deletion concordia/typing/memory.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
import abc
from collections.abc import Mapping, Sequence
from typing import Any, Protocol
import overrides


class MemoryScorer(Protocol):
Expand All @@ -32,7 +33,7 @@ def __call__(self, query: str, text: str, **metadata: Any) -> float:
"""


class MemoryBank(metaclass=abc.ABCMeta):
class MemoryBank(overrides.EnforceOverrides, metaclass=abc.ABCMeta):
"""Base class for memory banks."""

@abc.abstractmethod
Expand Down

0 comments on commit 3035fde

Please sign in to comment.