def __sanitize_value(self, value: Any) -> str:
                """
                Sanitize a value for safe SQL inclusion.

                Args:
                    value: The value to sanitize

                Returns:
                    Properly formatted and sanitized value string

                """
                if value is None:
                    return "NULL"
                elif isinstance(value, (int, float)):
                    # Numeric values don't need quotes
                    return str(value)
                elif isinstance(value, bool):
                    # Convert boolean to integer
                    return "1" if value else "0"
                else:
                    # For strings and other types, escape single quotes and wrap in quotes
                    # Replace single quotes with two single quotes (SQL standard escaping)
                    escaped_value = str(value).replace("'", "''")
                    return f"'{escaped_value}'"

                Sanitize a value for safe SQL inclusion.

                Args:
                    value: The value to sanitize

                Returns:
                    Properly formatted and sanitized value string

                
llama-index-integrations/vector_stores/llama-index-vector-stores-deeplake/llama_index/vector_stores/deeplake/base.py