Skip to main content
Toggle menu

Search the website

The OpenSAFELY Collaborative

Posted:
Written by:
Categories:
This article is part of a series: The Past, Present and Future of OpenSAFELY

OpenSAFELY is a huge collaborative project that spans a diverse range of organisations including universities, the NHS, and GP system suppliers.

The core technical platform teams at Oxford now have around 50 software developers, researchers, clinicians, and data policy experts. This core team designs and runs the network of components that make up the OpenSAFELY service: the technical tools (some made by our teams, some re-purposed) and the human services like output checking and co-piloting.

These teams have been built over the past decade specifically to deliver digital tools and services on top of health data. We set out to pool skills, knowledge, and best practice from our constituent communities. Our software engineers arrive with great developer skills, but they acquire deep knowledge on epidemiology research, electronic health records and more. Conversely our traditional epidemiology researchers have acquired deep technical skills on software development, not to replace developers, but to work closely alongside them, in one technically creative community.

These OpenSAFELY tools can be built in any data centre containing electronic health records data. For the NHS England OpenSAFELY GP Data Service, the tools are integrated onto the databases and technical services inside the machines owned by the major GP system suppliers – the companies that make the electronic health records systems that GP practices use to store their patient notes. We don’t just integrate into these companies’ technical services: we also pool skills, knowledge and ideas with their teams, because their developers literally designed the underlying primary care datasets that our research community want to analyse.

NHS England are the Data Controllers of the service as a whole, and the core funder of the NHS England OpenSAFELY GP Data Service. They resource us to support 50 new projects a year (we’d always love to support more, so do get in touch if you have any funding opportunities!).

But they also work closely with us on getting new users and projects into the platform, managing all the information governance, and generating and delivering ideas for new services or analyses. We are working with NHS England to help them take on more of the service aspects in the platform.

GP practices remain the Data Controllers for all the raw records that our tools run against, inside the GP system suppliers’ machines. They are also a core part of our community: we work closely with the RCGP, the BMA and the Joint GP IT Committee to make sure that our tools and services meet their needs, and they contribute energetically to our oversight and governance.

Patients and the public are at the heart of what we do: they live the lives that are encoded in this data, and any findings that our researchers make are only possible because of that data, so we are closely focused on earning and retaining trust in all our design choices. Our Digital Critical Friends group is one way that we make sure we stay close to the needs of patients and the public, alongside Citizens Juries and other policy and public engagement initiatives.

Then there are the users of the platform: epidemiologists, health service analysts, and people from think-tanks and other organisations. Some of these teams – like LSHTM, Bristol and Manchester – are very close collaborators. They do their own research analyses, of course; but in addition, many of their researchers also give extra time, helping us to develop and test new ways of working, writing their own tools, and taking on tasks like output checking.

Code for one is code for all

Alongside all this, the design of OpenSAFELY means that every user contributes re-usable shared code to the community: every subsequent user can see it, evaluate it, and re-use it, efficiently and productively.

This works in two ways. Firstly, the design of OpenSAFELY means that all the code that’s been run is automatically shared openly. But that wouldn’t be enough, on its own, to build a growing ecosystem of technical collaboration across so many different groups. Preparing electronic health records data is a complex business: in the past everybody did similar tasks – like data preparation – in their own esoteric way, on their own machine. So even if they did share their code, it would be hard for any other group to disentangle what they have done.

In OpenSAFELY we have imposed light-touch pragmatic standardisation of common tasks like data preparation, using tools like ehrQL. This brings many efficiency benefits, but also one critical community benefit: everybody is doing the same task in the same way, which means they can more easily read, understand, evaluate and re-use each other’s code. This is called “legibility” in the coding community, and you can see the benefits in the huge productivity of our users. It means that every use of OpenSAFELY is contributing to the growing stack of knowledge, code and tools needed to prepare and analyse GP data. For that, we are hugely grateful to all our wonderful, energetic users.

How to work with us

OpenSAFELY was designed from the outset as a huge collaborative project, with structures that capture and share all the work of everyone using the platform. There are lots of ways that teams and individuals can contribute and benefit our large community: some are obvious, and some less so.

Use the NHS England OpenSAFELY GP Data Service to do your own research

There is currently no charge for access to the platform, and the application process is a short form, followed by a short wait. NHS England pays for 50 projects per year, and they prioritise the projects, with input from our teams on technical issues.

Implement our tools in your own data centre

The OpenSAFELY platform is constituted from a detailed network of components, tools and services that each deliver key tasks like data preparation, remote execution of code, federated analytics and so on. Our philosophy is that the data stays put, and the code comes to the data. Our tools were built to be portable, and run in any data centre containing electronic health records data. If you would like to use our tools and methods, we are always happy to talk. You might want your data centre to be fully “OpenSAFELY-enabled”; or just use single components, like our standardised tools for preparing raw GP data into analysis-ready tables.

Build your own tools into our platform

OpenSAFELY is best thought of as a network of components. Some are technical (a particular bit of code that does a particular job); and some are services, run by teams of people following templates (like our output checking service, or our co-pilot service). We spend our time thinking carefully about how to build networks of these components: identifying existing components to re-use; and, where necessary, building new components in this carefully designed network. We’re always keen to have more people contributing. We can’t open all the core code up for anyone to make occasional changes, because the network is complex, and the platform is busy, with critical private data inside. So we’ve specifically created new ways for people to contribute components for their own tasks:

  • Contribute to the actions pipeline. Our actions framework is a well documented set of services that allow users to write their own components and stitch them into an actions pipeline. Our documentation has detailed guides for contributors, and lots of examples of actions that users have produced already, to help their pipelines work the way they want
  • Talk to us about deep changes and feature requests. Sometimes, users want new features or changes that require deeper integration into the network of components. We’re always happy to talk with teams about how to do this, either in collaboration with our own teams, or working more on their own if they prefer

Fund us, so we can do more!

Lastly, you can fund us. We are always keen to help more users, whether that’s more projects in our existing services, or new features and different types of data. We are here to help, on team@opensafely.org