Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions nemoguardrails/llm/cache/interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def get(self, key: Any, default: Any = None) -> Any:
Returns:
The value associated with the key, or default if not found.
"""
pass
...

@abstractmethod
def put(self, key: Any, value: Any) -> None:
Expand All @@ -58,7 +58,7 @@ def put(self, key: Any, value: Any) -> None:
key: The key to store.
value: The value to associate with the key.
"""
pass
...

@abstractmethod
def size(self) -> int:
Expand All @@ -68,7 +68,7 @@ def size(self) -> int:
Returns:
The number of items currently stored in the cache.
"""
pass
...

@abstractmethod
def is_empty(self) -> bool:
Expand All @@ -78,7 +78,7 @@ def is_empty(self) -> bool:
Returns:
True if the cache contains no items, False otherwise.
"""
pass
...

@abstractmethod
def clear(self) -> None:
Expand All @@ -87,7 +87,7 @@ def clear(self) -> None:

After calling this method, the cache should be empty.
"""
pass
...

def contains(self, key: Any) -> bool:
"""
Expand Down Expand Up @@ -115,7 +115,7 @@ def maxsize(self) -> int:
Returns:
The maximum number of items the cache can hold.
"""
pass
...

def get_stats(self) -> dict:
"""
Expand Down