NEW YORK (AP) — Facebook has agreed to buy Oculus for $2 billion, betting that its virtual reality technology may be a new way for people to communicate, learn or be entertained.