In reviewing algorithmic systems for integrity, we often consider how the systems are tested and what the quality assurance process is.
Testing and quality assurance go hand in hand, with testing generally considered a subset of overall QA.
Testing is a core component of change control. It helps ensure that algorithms function as intended.
If you’re reading this, you probably already know why you need to test.
In brief, testing:
Before we explore the key testing stages, there are three important points to note:
This is not a comprehensive list, but it covers most core stages:
Developers perform initial code/flow reviews, tests on individual components or functions of the algorithmic system. This helps catch basic errors early in the development process.
Colleagues review the code and test results, providing a fresh perspective and potentially finding issues the developer might have missed.
A more experienced team member evaluates technical aspects, ensuring it meets architectural standards and performance requirements. This may also involve other teams to conduct non-functional testing (e.g., certain security related testing, if not covered elsewhere).
A non-technical team member ensures the system meets the intended functional requirements.
End-users or business stakeholders test the algorithm in a real-world context. This is to ensure that it meets their requirements, and functions as expected. This, ideally, uses real data across a variety of scenarios.
Effective testing should address multiple aspects of algorithm integrity.
Examples of core aspects include accuracy, fairness, security, privacy and performance.
Verify that the algorithmic system produces correct (complete, valid, accurate) outputs/results.
For example, test the system using known inputs and expected outputs - across various scenarios.
Evaluate the system for bias against protected attributes, looking for unintended discriminatory outcomes.
For example, if the system now uses free text fields, beyond structured data, protected attributes may be inferred.
Assess resilience against vulnerabilities, making sure that existing security controls are not inadvertently bypassed.
For example, check that security controls for authentication still work, especially if there are workarounds in place.
Check that confidentiality is maintained, and sensitive data is protected.
For example, verify that the algorithm doesn't reveal sensitive data through its outputs.
Measure efficiency and scalability.
For example, simulate high-volume scenarios to ensure the algorithm works under peak loads.
A testing strategy that covers various aspects can significantly enhance algorithm integrity.
Ensuring the systems are not only technically sound but also fair, secure, and aligned with business objectives.
Disclaimer: The information in this article does not constitute legal advice. It may not be relevant to your circumstances. It was written for specific algorithmic contexts within banks and insurance companies, may not apply to other contexts, and may not be relevant to other types of organisations.