Whether you love happy endings or a harsh blast of reality in TV dramas, you could soon be able to decide what you get.

Netflix, the TV-streaming company behind hit shows such as The Crown and House Of Cards, is working on ways to give viewers control of key plot decisions.

Some of the storylines will be simple and linear, like the Choose Your Own Adventure books many grew up with.

For example, viewers might decide whether an inmate in the prison drama Orange Is The New Black joins a gang or not.

Netflix, the TV-streaming company behind hit shows such as The Crown and House Of Cards (pictured), is working on ways to give viewers control of key plot decisions in a new interactive storytelling strategy

The technology could also potentially be used to allow Princess Margaret to marry Peter Townsend in The Crown, instead of having her relationship with the divorcee blocked by the Establishment. Other storylines will be much more complex, allowing viewers to connect plot points in a variety of ways using their TV remotes.

A source said: ‘We’re doing work on branch narratives so you are actually making choices as you watch. All the content will be there, and then people will have to get through it in different ways.

‘We’ll see how it plays out. It’s an experiment. We’ll see if it gets much success. For creators, it’s new territory.’

Actors would film numerous alternate plot segment in advance, letting viewers choose which route to take through the story.

The most complex versions could turn back on themselves, so viewers could in theory watch dramas that are ‘infinite’.

‘It is almost random – you could go through a story in incredibly weird ways,’ the source said. ‘I can’t imagine what the story will be like but it’s highly fragmented.’

Netflix will run a trial with choose-your-own-adventure shows for children later this year, based on an established character.

If they are successful, it will use the format for TV programmes aimed at adults. It has not said whether it would apply the format to established series, or use it exclusively for new ones.

Under the plans actors would film numerous alternate plot segment in advance, letting viewers choose which route to take through the story

Netflix president Reed Hastings confirmed the company is working on interactive shows, saying: ‘Once you have got interactivity you can try anything.’

At least five million UK households are thought to be signed up to Netflix, and it is challenging traditional broadcasters.

Earlier this year, BBC boss Lord Hall vowed to ‘reinvent’ the iPlayer so it overtakes Netflix as a ‘destination’ in its own right, rather than a catch-up service.