The story behind the making of Devious is almost stranger than the plot itself - and for that we will only hint...
Devious is so named because most of the characters at one point or another are, well, "devious". Well maybe that's overstating it - shall we say that a few players in the story are not to be trusted! (that's the characters they're playing not the actual cast members - none of them can be trusted anyway!) (JOKE). Many of the cast are playing dual roles - simply because their characters are required to act as other characters for the benefit of the Doctor?
The basic plot involves the Doctor having to perform a test to redeem himself after his Trial (in the "War Games"). Certain Time Lords were unhappy with the verdict and felt he needed a second chance. Led by Callisto they persuaded certain members of the High Council (Chaldar, the Covellitor) that a test of non-interference should be set up.
The Doctor was extracted from his timestream midway through his regeneration after the Trial, and so his incomplete persona was stuck midway between the second and third incarnations. He is unaware of this, and as the story starts, is only gradually realising he has changed.
Before he is placed into the test environment his mind is fed with a set of memories and assigned some companions. These companions are in fact supporters of Callisto. One of them is Auriga who is an important TimeLord - one Callisto is trying to impress, and so he is given the 'lead companion' role as it were. Companion Adreinna is assigned as Amber Lyn (or Amber). The Covellitor (an influential and important Timelord, and Councillor Chaldar give themselves minor roles but intend to observe events.
The story starts where we see the Doctor beamed directly to a planet with two of his companions. Whilst they start to search for the source of a mysterious 'time ripple' effect the Doctor starts to recall these false memories, and we see them reenacted. We find out how the four first met up, and why Amber is no longer with them.
During this first part we are unaware as viewers that the Doctor has had his mind fed with memories, or that there is a test - all we see is an "Observer" (Aquilia) who is reporting on their progress.