async def count_messages(
        self,
        key: str,
        status: Optional[MessageStatus] = MessageStatus.ACTIVE,
    ) -> int:
        """Count messages for a key with the specified status (async)."""
Count messages for a key with the specified status (async).
llama-index-core/llama_index/core/storage/chat_store/base_db.py