In both cases, the value they provide is relative to the value of the house being transacted.
A seller's agent definitely makes sense to take some percentage of the purchase.
The services they render - for say a $20M home in the Beverly Hills - are completely different than when selling a $1M house in San Jose or a $200k condo in Chicago.
I disagree in how valuable buyer's agents are, though. The value they provide is mainly for people who are completely clueless about real estate - which I guess could be a lot of buyers.