At the end of Portal 2, GLaDOS sings "goodbye my only friend", but then follows up with "oh, did you think I meant you?" Did she really mean Chell, or was is Caroline? The Companion Cube? Wheatley? Sadness that Cave Johnson is gone? (which might come from the Caroline part of her personality) The bird? The potato?
GLaDOS is refering to Caroline. Here's why I think so:
- In the previous verse of "want you gone", GLaDOS mentions that Caroline is "in here too". This implies that Caroline is a part of GLaDOS, but not GLaDOS herself.
- Right before the ending song(s), GLaDOS says that she now knows where Caroline is in her brain. This is immediately followed by Aperture Science's computer announcing "Caroline deleted", and a marked change in GLaDOS's attitude. This was GLaDOS deleting the part of her that was Caroline.
- A few lines after singing "Goodbye my only friend", GLaDOS sings "Maybe when I delete you I'll stop feeling so bad". This implies that she's addressing the person she deleted, namely, Caroline.
- Right before the final battle, GLaDOS hears "her own voice" acting as a conscience, preventing her from betraying you. It makes sense that deleting the voice of your conscience would help you stop feeling bad. This harmonizes with the point above, suggesting that it was the more human "Caroline" side of GLaDOS that she was saying goodbye to, and then deleting (so her conscience would stop bothering her).
Caroline was a part of GLaDOS. Perhaps Caroline's personality was merged into the master system in a way similar to how they modified GLaDOS' personality by adding core modules to her (although not exactly the same way). Or perhaps GLaDOS started off as Caroline, but mutated or was modified into something more. Either way, the more menacing side of GLaDOS decides she no longer wants her more human "Caroline" side, and deletes her. She says goodbye to her in song as she does it.
I don't completely believe this, but here is a possibility I have come up with while reading these comments:
GLaDOS could be trying to cover a slip up. When she says "goodbye my only friend" she might actually be talking about Chell, and then adding the "do you think I meant you?" to save her image. Some evidence of GLaDOS considering Chell a friend is right before she deletes Caroline when she says "I thought you were my greatest enemy when all along you were actually my best friend".
Once again, this is only a possibility and I don't completely believe it myself but I would love to hear what everyone else thinks about this.
GLaDoS is most likely referring to Chell. The woman is a sarcastic, sardonic, piece of hardware with a penchant for lying. The one point we can unambiguously agree upon after playing both games, is that GLaDoS cannot be trusted, or taken at face value.
Sure, she could have deleted the part of her that was Caroline, or she could have just been lying, like she has so often before. Similarly, GLaDoS implies that Chell is her only friend, then, before one can assess the accuracy of that inference, she moves into an ad hominem attack, changing the argument to "you must be so stupid to think Chell is my friend" (which neatly bypasses the heart of the previous argument entirely).
The reason I posit this at all is because of some of the dev commentary available both within game and without (in interviews, etc.) mention that (and I paraphrase here) "The whole development of the relationship between Chell and GLaDoS is that Chell is really the only friend GLaDoS has ever had, but GLaDoS doesn't know how to do anything but test, so she keeps forcing Chell to test as a way of trying to come to terms with her feelings."
I'll try and update the above when I can find a solid reference to back it up.
It seems pretty obvious to me that GLaDOS is referring to Chell, if you just read through those lines.
First she is singing the song to Chell. Second, she refers to the listener (Chell) as her only friend, then backpedals (in typical GLaDOS fashion) with a misdirect "you think I was talking about you?" and even explains why she won't admit it's Chell: it would be pitiful if it was true that her only friend was someone who wanted nothing more than to get away and had killed her once already.
Third, GLaDOS admits that the friend will now be replaced with no one, which is exactly what's happening: GLaDOS is ejecting/rejecting Chell.
Fourth, it perfectly reflects the love/hate relationship that GLaDOS feels towards Chell. There are so many lines throughout both games where GLaDOS lets a little sentimentalism leak out, then turns around to slam Chell, or where she basically says that it's good to have Chell around to test her. (You could argue that it's GLaDOS's testing itch that must be scratched, but I think the interaction is much more nuanced than that.)