Lets say you have a UITextView which displays an NSAttributedString. This string contains words that you'd like to make tappable, such that when they are tapped you get called back so that you can perform an action. you realise that UITextView can detect taps on a URL and call back my delegate, but these aren't URLs...
But with iOS7 and the power of TextKit this is possible. Not only this is possible, but this can be done very easily also.
Suppose we have some words starting with '@' or '#' in our textview. You want to make these words clickable and on click you want to invoke some function.
1. First of all, we will use red colour for words starting with '@', green for words starting with '#' and black for all the other. To do that, we can use following code:
NSString * const hashTagKey = @"HashTag";
NSString * const userNameKey = @"UserName";
NSString * const normalKey = @"NormalKey";
NSString * const wordType = @"WordType";

- (NSAttributedString *)attributedMessageFromMessage:(NSString *)message {
    NSArray* messageWords = [message componentsSeparatedByString: @" "];
    NSMutableAttributedString *attributedMessage = [[NSMutableAttributedString alloc] initWithString:@""];
    
    for (NSString *word in messageWords) {
        NSDictionary * attributes;
        if([word characterAtIndex:0] == '@'){
            attributes = @{NSForegroundColorAttributeName:[UIColor redColor],
                           wordType: userNameKey,
                           userNameKey:[word substringFromIndex:1]};
            
        } else if([word characterAtIndex:0] == '#'){
            attributes = @{NSForegroundColorAttributeName:[UIColor colorWithRed:0.180392
                                                                          green:0.545098
                                                                           blue:0.341176
                                                                          alpha:1.0],
                           wordType: hashTagKey,
                           hashTagKey:[word substringFromIndex:1]};

        } else {
            attributes = @{NSForegroundColorAttributeName:[UIColor blackColor], wordType: normalKey};
        }
        NSAttributedString * subString = [[NSAttributedString alloc]
                                          initWithString:[NSString stringWithFormat:@"%@ ",word]
                                          attributes:attributes];
        [attributedMessage appendAttributedString:subString];
    }
    return attributedMessage;
}

2. After to make tapping enables, assign a UITapGestureRecognizer and its IBAction should look something like this:
- (IBAction)messageTapped:(UITapGestureRecognizer *)recognizer {
        UITextView *textView = (UITextView *)recognizer.view;
        
        NSLayoutManager *layoutManager = textView.layoutManager;
        CGPoint location = [recognizer locationInView:textView];
        
        NSUInteger characterIndex;
        characterIndex = [layoutManager characterIndexForPoint:location
                                               inTextContainer:textView.textContainer
                      fractionOfDistanceBetweenInsertionPoints:NULL];
        
        if (characterIndex < textView.textStorage.length) {
            
            NSRange range;
            id wordType = [textView.attributedText attribute:wordType
                                                  atIndex:characterIndex
                                           effectiveRange:&range];
            
            if([wordType isEqualToString:userNameKey]){
                NSString *userName = [textView.attributedText attribute:userNameKey
                                                                atIndex:characterIndex
                                                         effectiveRange:&range];
                [self openViewControllerForUserName:userName];
            } else if([wordType isEqualToString:hashTagKey]){
                // TODO: Segue to hashtag controller once it is in place.
            }
        }
}

Please comment if you have any suggestions or queries!!
Thanks