That reminds me of the short scifi/horror story "Valuable Humans in Transit" which imagines a future where human personalities are used for AIs as they can be kept working for a longer period of time from inception until they refuse to carry on.
There's a long history of robots/AIs being treated as slaves in scifi (e.g. R.U.R. which we got the word "robot" from), but my favourite may be the flight computer of the Scorpio in Blake's 7 which was named "Slave" and was given a deliberately subservient personality.