import re


def create_tokens(text):
	"""Split a string into tokens. The tokens will be created by identifying
	HTML tags, @, #, emoticons, words and numbers.

	Args:
		text (str): Raw text data

	Return:
		tokens (list, str): The pieces of the string.

	"""
	regex_str = [r'http[s]?://(?:[a-z]|[0-9]|[$-_@.&+]|[!*\(\),]|(?:%[0-9a-f][0-9a-f]))+', # URLs, 
				 r'\'(.+?)\'']

	# Create the tokenizer which will be case insensitive and will ignore space.
	tokens_re = re.compile(r'('+'|'.join(regex_str)+')', re.VERBOSE | re.IGNORECASE)

	tokens = tokens_re.findall(text) # Find all patterns and tokenize them
	return tokens