{'fraction_non_alphanumeric': 0.02925531914893617, 'fraction_numerical': 0.011845335515548281, 'mean_word_length': 5.041404029168212, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 6, 'https://': 1, 'lorem ipsum': 0, 'www.': 1, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
CREATE (Community deRivEd AutomaTEd insulin delivery) trial. Randomised parallel arm open label clinical trial comparing automated insulin delivery using a mobile controller (AnyDANA-loop) with an open-source algorithm with sensor augmented pump therapy in type 1 diabetes

Background Commercialised automated insulin delivery (AID) systems have demonstrated improved outcomes in type 1 diabetes (T1D), however, they have limited capacity for algorithm individualisation, and can be prohibitively expensive if an individual is without access to health insurance or health funding subsidy. Freely available open-source algorithms, which have the ability to individualise algorithm parameters paired with commercial insulin pumps, and continuous glucose monitoring make up the so-called "do it yourself" (DIY) approach to AID. Limited data on the open-source approach have shown promising results, but data from a large randomised control trial are lacking. Methods The CREATE (Community deRivEd AutomaTEd insulin delivery) trial is an open-labelled, randomised, parallel 24-week, multi-site trial comparing sensor augmented pump therapy (SAPT) to our AnyDANA-loop. The three components of AnyDANA-loop are: 1) OpenAPS algorithm implemented in a smartphone (a version of AndroidAPS), 2) DANA-i™ insulin pump and, 3) Dexcom G6R continuous glucose monitor (CGM). The primary outcome measure is the percentage of time in target sensor glucose range (3.9 -10mmol/L). Secondary outcomes include psycho-social factors and platform performance. Analysis of online collective learning, characteristic of the open-source approach, is planned. 100 participants with T1D aged 7 – 70 years (age stratified into children/adolescents 7–15 years and adults 16–70 years), will be recruited from four sites in New Zealand. A 24-week continuation phase follows, to assess long-term safety.


Background
Less than one third of people with T1D achieve glycaemic control targets known to reduce the risk of long-term complications [1]. Accordingly, rates of acute and chronic complications among people with T1D remain unacceptable, which impacts quality of life and generates significant costs to healthcare [2,3]. New therapies are essential to reduce both complications for people with T1D and healthcare costs.

Automated insulin delivery
AID, also known as closed loop or artificial pancreas, is an innovative new therapeutic approach that revolutionises outcomes for people with T1D [4][5][6][7][8]. AID links an insulin pump and a CGM to an algorithm that automatically adjusts insulin delivery to optimise glycaemic control. Currently, commercially available AID systems are expensive, and individuals that have access are either in a high income bracket, or live in countries with extensive private health insurance, or a public health system that subsidises modern diabetes technologies. A cost-effective AID system may improve global equity in access to AID. One solution is an open-source approach. Use of an algorithm developed through open-source innovation would facilitate the development of an AID system at a fraction of the cost of commercial models. In 2013, Dana Lewis and Scott Leibrand developed an algorithm to respond to changes in sensor glucose levels and automate insulin delivery. In 2014, their work evolved into a do-it-yourself (DIY) artificial pancreas, which they elected to make open-source by sharing the code, the reference design for the algorithm and all documentation [9]. Since then, a community of people living with T1D, openly frustrated with the lack of availability of commercial systems, have refined the algorithm and deployed their collective knowledge, underpinning the creation of a DIY open-source AID system. Although 'DIY' has been used to describe the open-source systems, it is a misnomer since the success of communitydesigned AID systems has been a collaborative effort, and users make use of various open-source resources. Opensource AID systems have the potential to reduce the cognitive burden associated with laborious diabetes tasks, hence improving quality of life for those living with T1D. The Open Artificial Pancreas System (OpenAPS) movement launched by Dana Lewis in 2015 has been fostered by thousands of people with T1D worldwide and numbers are flourishing [10] .
Several retrospective studies [11][12][13][14][15][16] show communitydesigned AID systems succeeding in the real world and, observational studies undertaken abroad [17][18][19] reveal the wider applicability of these systems. Furthermore, this opensource android-based AID system has already been tested and validated in silico trials for safety and efficacy, concluding it is safe and effective and, shows great potential to be tested further [20]. There have also been prospective trials, the latest presented at The European Association for the Study of Diabetes (EASD) suggested the AID system leads to better glycaemic control, less hypoglycaemic episodes and lower daily blood glucose level fluctuations compared to SAPT [21]. However, due to the open-source AID system being created by consumers, and existing insulin pump companies creating barriers to block the use of the open-source algorithm with their pump, the system has not undergone rigorous scientific assessment in terms of randomised control trials (RCTs) and has no regulatory approval. Therefore, widespread adoption of this technology has been somewhat limited, especially as there are substantial medico-legal concerns about patients using unapproved technologies [22][23][24].
The CREATE trial, is the first multi-centre randomised trial comparing a community-developed AID system to SAPT. This research will address the significant worldwide consumer and health regulatory demand for a study on an open-source AID algorithm to be performed.

Aims, objectives and hypotheses
The primary objective of this study is to evaluate the percentage of time spent in target sensor glucose range (3.9-10.0 mmol/L (default) and 3.9-7.8 mmol/L (secondary)), comparing the AID system (AnyDANA-loop) to SAPT during weeks 22 and 23 post randomisation. The secondary objectives of this study are to evaluate effectiveness of the AnyDANA-loop platform relative to SAPT therapy, with regards to: Glycaemic Control and Safety [25]; Psychosocial Factors; Platform Performance; and the Human-Technology Interaction as well as Online Collective Learning.
The hypothesis for device performance is that the opensource AID algorithm implemented on a phone (AnyDANA-loop) is safe in people with T1D, and furthermore, will improve time in the target sensor glucose range by at least 10%, when compared to SAPT. The hypothesis for device safety is that use of the open-source algorithm will not increase time spent in hypoglycaemia (% of sensor glucose values < 3.9 mmol/L per day) by more than 2% (absolute difference).

Study design
The CREATE trial is an open-labelled, multi-site, randomised, parallel-group 24-week superiority trial evaluating the effectiveness and safety of AnyDANA-loop compared to SAPT in participants with T1D on established pump therapy. The trial is registered with the Australian New Zealand Clinical Trials Registry (ACTRN12620000034932p) and has been approved by the Southern Health and Disability Ethics Committee (20/STH/1).
Following the four-week run-in phase, where all participants become familiar with the Dexcom G6 R CGM and DANA-i™ insulin pump running in SAPT mode, participants will be randomly allocated at this point to one of two treatment sequences; AA or BA on a 1:1 basis. Treatments are as follows: A. DANA-i™ insulin pump running in AID mode (delivered by the AnyDANA-loop application). B. DANA-i™ insulin pump running as SAPT.
This RCT phase is 24 weeks duration, with the primary endpoint measured in the final two weeks of this phase. All participants will then be invited into a 24-week continuation phase and those initially randomised to SAPT will cross into the AID arm. The expected duration of participation is 12 months (four-week run-in and 48-week study). At least six visits to the study centre are planned for each participant with allowance built in for extra days if logistics require (see Fig.  1).

Recruitment
The CREATE trial will enrol children and adolescents 7-15 years inclusive, and adults 16-70 years inclusive with T1D. These age strata emulate how paediatric and adult healthcare services are set up in New Zealand. Participants will be recruited according to age, from four health board regions of New Zealand: Southern District Health Board (children and adults), Canterbury District Health Board (children and adults), Waikato District Health Board (adults), and Auckland District Health Board (children).
The rationale for incorporating children in the study include: 1. Most people with T1D are diagnosed in childhood and children have higher uptake of diabetes technology than adults [26]. 2. Children's insulin requirements are highly variable [27] from day to day, so conventional diabetes therapies may be insufficient to achieve optimal glycaemic control.
3. The benefits of improved glycaemic control are greater in children, because they have a higher risk of developing diabetic complications in adulthood. 4. In addition, investigating this technology in children will establish the impact on quality of life of their caregivers.
Study candidates are able to be identified by local clinical team members, excluding investigative staff and formal recruitment will occur by research staff outside of routine clinical care. This will ensure subjects can give informed consent free from undue influence. The CREATE trial will be advertised on the University of Otago website https://www.otago. ac.nz/christchurch/departments/paediatrics/research/ otago717634.html. Evaluation of eligibility will be performed at screening according to inclusion/ exclusion criteria (see Table 1).

Sample size
Data from recent studies in a similar patient demographic show percentage of time spent in target range using SAPT was 57 ± 11% for children and 54 ± 12% for adults [28,29]. Assuming a standard deviation of 12.5%, a total sample size of 68 (17 per group per strata) will provide 90% power at a two-sided significance level of 0.05 to detect a treatment effect if the absolute improvement in time in target glycaemic range of children and adults is at least 10% or more (effect size = 0.8). The sample size in each strata (children and adults) will be inflated to 50 (a total study sample size of 100) to allow for the absolute improvement in one of the strata to be as low as 5% and to include up to 15% lost-to-follow-up. A sample size of 100 will also provide up to 69 person-years of intervention follow up giving 90% power to detect event rates as low as 3.4 per 100 person-years, capturing clinically meaningful data with respect to safety endpoints and time spent in significant hypoglycaemia (< 2.5 mmol/L).

Screening and enrolment
Individuals deemed a study candidate at pre-screening will be given the opportunity to review the participant information and consent form (PICF). Distinct, age appropriate PICFs exist for younger children, adolescents and adults. Processes of obtaining informed consent will include the requirements of ISO 14155:2011 and Good Clinical Practices. All participants aged 16-70 years inclusive and a parent/ guardian of participants 7-15 years inclusive must sign and date the current ethics approved written informed consent form before any study specific assessments or procedures are performed.
Written informed assent will also be sought from minors participating in the study. Additional consent will be sought for participation in interviews during the study as appropriate. Table 2 delineates the baseline information which will be gathered once consent has been obtained and participants have been screened, deemed eligible and enrolled in the study.

Randomisation
CREATE trial participants will be randomly allocated to receive AID or SAPT therapy with an allocation ratio of 1:1. A computer-generated randomisation list, with permuted blocks of random size, will be pre-prepared by the study statistician, not involved in participant enrolment or treatment allocation. Randomisation will be stratified by participants' age (as previously outlined), baseline HbA1c (≤ 8.0%/64 mmol/mol and > 8.0%/64 mmol/mol), and study site to ensure these prognostic factors are balanced between groups. The randomisation list will be concealed and loaded into the Research Electronic Data Capture (REDCap) database held on University of Otago servers.
Participants may only be randomised once obtainment of consent has been verified, they have been screened, eligibility criteria are fulfilled and stratification variables have been entered into REDCap. Then, research staff with authorisation to randomise participants may click the 'randomise' button within REDCap which will assign the treatment to the study number and lock the fields containing the treatment group and stratification variables. This process will ensure allocation is  A positive urine pregnancy test at screening is exclusionary • Alcohol or drug dependence • Severe visual impairment that would impair use of the device • Any comorbid medical or psychological factors that would, on assessment by the investigators, make the person unsuitable for the study • A lack of English literacy that would, on assessment by the investigators, make the person unsuitable for the study • Allergic or intolerant to NovoRapid® insulin a Since carbohydrate counting is a requisite for obtaining an insulin pump, the assumption is made that all candidates are capable of carbohydrate counting. b This reflects the New Zealand Pharmaceutical Management Agency (PHARMAC) criteria for funded access to insulin pump therapy in New Zealand. kept concealed from research staff and participants until after the participant has been enrolled. Devices will be allocated open-label. Blinding is not possible in the study due to the nature of the technology.
All participants will be provided with the DANA-i ™ insulin pump, Dexcom G6 R CGM, Android mobile device and a Nightscout account (cloud-based remote monitoring tool) at the inauguration of the study, and they will become familiar using these devices running in SAPT mode during the fourweek run-in phase. The study staff will be responsible for setting up the mobile devices, including installing the locked version of the OpenAPS algorithm. NovoRapid R insulin will be exclusively used in the trial. During the run-in phase, study staff will review and adjust participant pump settings each week, presenting the opportunity to optimise settings. At the end of the run-in phase, participants will either continue SAPT or begin AID.

Automated insulin delivery (AnyDANA-loop)
At the beginning of the RCT phase, participants randomised to the intervention arm will receive training on the use of the AID system by investigative staff. AID is intended to be used continuously throughout the RCT and continuation phases.
They will continue with their current Dexcom alerts/ alarms and pump settings, or these will be adjusted as per participant and/or investigator discretion.
A locked version of the OpenAPS algorithm will be used and installed as an app on the Android phone, similar to the open-source "AndroidAPS" implementation. This system is designed to make safe, temporary adjustments to basal insulin rates in order to maximise the time in target glucose range (3.9-10.0 mmol/L) and minimise the risk of hypoglycaemia. The algorithm is a simple, rules-based heuristic algorithm that closely matches what a patient would do to manage their diabetes. The algorithm makes micro-adjustments to the doses of insulin delivered every five minutes using predictions from previously inputted data and variables (such as previous insulin dosing, carbohydrate intake, CGM trend, et cetera).
Since no formal patient education or training is attached to open-source innovations, the CREATE study team have developed their own education strategy, including study specific training materials exclusively for CREATE participants and healthcare professionals (HCPs). Participants will be trained to use the study devices running in manual or AID mode according to randomisation, during in-person clinic visits (see Table 3). They will also be provided with learning guides and video demonstrations of key aspects of these guides. Those using AID mode will be invited to join a closed online community (Tribe Technologies Inc.) of participants in the trial, for ongoing consumer-driven peer support to simulate the community support that is used by existing OpenAPS users. Joining the online community is voluntary and the decision whether or not to partake will not impact participants wider participation in the study or the care provided by the study's HCPs. For participants under 16 years old, parents will be invited to join the community, rather than the child. Participants will be identified in online communities by either their study ID number or a pseudonym of their choice and provided with advice about how to maintain anonymity within these groups. They will also be provided with guidelines covering etiquette for constructive participation in online groups and appropriate topics to post to their community. Online communities will be monitored by investigative staff who will review new posts on a regular basis (maximum of 48 h between reviews). The online community is not intended to replace participant support, and participants will have clear instructions to contact study staff (research nurse, and associate investigators at each site) for any clinical or technical issues arising at any time.

Sensor augmented pump therapy
Participants randomised to the SAPT arm will have AnyDANA-loop installed on their phone in the background to receive pump and CGM data and upload these to Nightscout. However, the algorithm and other user features such as the bolus calculator will not be usable by the SAPT group. Like participants in the intervention arm, those randomised to SAPT can choose to have high/ low glucose alerts set in the Dexcom app. They will be managed clinically by the investigative team at each site, who will adjust the insulin pump settings as required. Participants using SAPT will also be invited to join a separate, closed online community of participants in the trial, for ongoing consumer-driven peer support. At the inception of the 24-week continuation phase, participants initially randomised to SAPT will undergo AnyDANAloop training prior to progressing into the continuation phase. Their pump will be set-up according to Appendix Table 4 to start AID mode.

Device settings
Appendix Table 4 elucidates the recommended initial settings for AID mode. As the study progresses, the AID settings will be adjusted at the discretion of participants and principal investigators (PIs), trending toward a more customisable system. An assortment of setting modifications exist, although a few basic parameters such as the Carbohydrate to Insulin Ratio (CIR), Correction Factor (CF) and basal rates have the greatest impact on glycaemic control. All device (DANA-i™ insulin pump, Dexcom R G6 CGM and algorithm) settings were developed and agreed upon by the CREATE investigative team.
Study staff will undertake weekly electronic reviews of all participants during the four week run-in-phase. Electronic reviews of device settings will occur three and six weeks into the RCT phase for those randomised to AID (and three and six weeks into the continuation phase for subjects in the SAPT arm who then cross into AID mode), and adjustments will be made. Three monthly clinic visits will afford investigative staff the opportunity to assess and adjust device/ algorithm settings in person however, similar to existing open-source users, our vision is that the online community will impart confidence in study participants so they feel equipped to make adjustments themselves in between study visits.

Outcome measures
The primary objective of this study is to evaluate the percentage of time spent in target sensor glucose range (3.9-10.0 mmol/L (default) and 3.9-7.8 mmol/L (secondary)), comparing AID to SAPT during the RCT phase. The timing of all assessments is presented in Table 3.

Anthropometric
Trained staff members will measure participants' weight and height using standard procedures and calibrated instruments. Weight will be measured once to the nearest 0.1 kg, with shoes and heavy clothing removed. Height will be measured once to the nearest 0.1 cm. Height and weight will be used to calculate body mass index (BMI) which will be automatically populated by REDCap.

Demographics
At the screening visit, investigative staff will collect demographic information including date of birth, gender, ethnicity, household income, and highest educational level. Participants may choose to select more than one ethnicity; however, each person will be allocated to a single ethnic group for the purposes of statistical analyses that will be prioritised in the order of Māori, Pacific, Asian and European/ Other [30]. Total household income from all sources, before tax or anything taken out of it in the last 12 months and, the participants highest completed qualification (as well as the parent/ guardians' if they are integral to their child's diabetes care) will be recorded in the same manner used by the New Zealand Health Survey 2018-2019 [31].

Glycaemic control
HbA1c will be measured every three months throughout the RCT and continuation phases by calibrated point-of-care instruments (DCA Vantage Analyzer, Siemens Healthcare Diagnostics, Ireland), which meets acceptance criteria for HbA1c [32]. Measurements > 130 mmol/mol (maximum reading possible) will be recorded as 130.
Individual CGM data will be pushed from the Android phone into a cloud-based server; Nightscout (this platform is b Seated blood pressure, recorded as the average of two measurements at least five minutes apart. c A urine pregnancy test for females of child bearing potential only (all postmenarchal and premenopausal women). d Versions of the Hypoglycaemia Fear Survey II include: Both child and parent version to be completed for participants 7-17 years inclusive, and the adult version to be completed for participants 18 years inclusive and older. e The PSQI will only be completed by participants 13 years inclusive and older. f DTSQs versions include: Parent version to be completed for participants 7-12 years inclusive, teen version to be completed by participants 13-17 years inclusive (parents can also do this), and the adult version to be completed by participants 18 years inclusive and older. g The EQ-5D-Y will be completed by participants 8-15 years inclusive. The EQ-5D-5L will be completed by participants 16 years (inclusive) and older. This questionnaire will not be completed by participants 7 years of age. h All participants will be asked to complete a food diary at home using the Research Food Diary app on four non-consecutive days (three weekdays and one weekend day) over one week during the run-in period and during the last week of the RCT phase. i Pump settings will be reviewed remotely by investigative staff and adjustments made as clinically indicated. j Up to 15 adults and up to 15 children/caregivers, and all Māori participants who have completed the RCT on AID will be invited to attend an interview (face-to-face or via video teleconferencing) with a member of the research team during the first six weeks of the continuation phase (days 168 -210). k All Māori participants who have transferred from the SAPT group to the AID group for the continuation phase will be invited to attend an interview (face-to-face or via video teleconferencing) with a member of the research team within six weeks of completing the continuation phase. l One remote focus group will be held with participating HCPs via video conferencing and will be conducted within one month of all sites having five participants on AID complete the first three months of the RCT phase. Interviews with a selection of HCPs may also be conducted at each site as all the all participants randomised to AID at their site complete the RCT phase (to occur within one month of the site's last subject completing AID during the RCT phase). m All participants who discontinue the trial will be invited to take part in a face-to-face interview (either at the research centre or via a video conference) with a research staff member within four weeks of discontinuing the study.
better described under Data Management). CGM data will be analysed according to standardised CGM metrics for clinical care [25].

Psychosocial factors
Validated instruments will assess the self-reported impact the AID system has on participants/ their family at baseline, 24 weeks (day 168 + 7) and at 48 weeks (day 336 + 7). These instruments have been widely used in research and have demonstrated reliability and validity in our cohort completing them. Data will be collected via electronic (REDCap) questionnaires during clinical assessments and the order of administration will be standardized to increase reliability. All questionnaires are administered in English. Participant reported outcomes including fear of hypoglycaemia, eating behaviours, sleep quality, device experience and general health state will be monitored during the study and clinical teams will be alerted if participants report physical or mental problems demanding follow-up.

Hypoglycaemia Fear Survey II (HFS II)
The HFS II was developed to measure behaviours and worries related to fear of hypoglycaemia in people with T1D. It is a valid and reliable measure of fear of hypoglycaemia [33][34][35][36]. HFS II is composed of two subscales, the Behaviour (HFS-B) and Worry (HFS-W). HFS-B items describe behaviours in which people with T1D may engage to avoid hypoglycaemic episodes and/or their negative consequences (for example, maintaining higher BG levels, ensuring they are in the company of others, limiting exercise). HFS-W items describe specific concerns that people with T1D may have about their hypoglycaemic episodes (for example, being alone, episodes occurring during sleep). Participants aged 7-17 years inclusive and their parent/ guardian will complete child and parent versions of the HFS II respectively. Participants 18 years and older will complete the adult version.

Sleep quality (Pittsburgh Sleep Quality Index; PSQI)
The PSQI is a 19-item self-report measure of subjective sleep quality and quantity in the previous month. The 19 items generate seven component scores: subjective sleep quality, sleep latency, sleep duration, sleep efficiency, sleep disturbance, sleep medication, and daytime dysfunction, with component scores summed to produce a global score. A global score > 5 suggests a "poor sleeper" with significant sleep complaints [37]. The PSQI will be completed by participants 13 years inclusive and older.

Diabetes Treatment Satisfaction Questionnaire status (DTSQs)
The DTSQs is a questionnaire used to assess patients' satisfaction with their diabetes treatment [38]. The adult 8-item version is composed of two factors to measure treatment satisfaction and the burden from hyper/ hypoglycaemia. The DTSQs is internationally validated and officially approved by The World Health Organisation (WHO) and the International Diabetes Federation (IDF) [38]. The 12-item DTSQs-Teen and 14-item DTSQs-Parent were developed through interviews with parents and teenagers to improve relevance, accessibility and intelligibility for teenagers [39].
In this study, DTSQs: Parent will be completed for participants 7-12 years inclusive. Participants 13-17 years inclusive will complete the teen version and the DTSQs: Adult will be completed by participants 18 years inclusive and older.

Health status (EuroQol 5-dimensional Questionnaire; EQ-5D)
EQ-5D is a family of three simple instruments to describe and value health. The CREATE trial will make use of two instruments; the EQ-5D-Y will be completed by subjects 8-15 years inclusive and the EQ-5D-5 L by those 16 years and older (an apt version does not exist for subjects of 7 years). Both versions comprise five dimensions: mobility, self-care, usual activities, pain/discomfort and anxiety/depression (substituted for child friendly terms in the EQ-5D-Y). Respondents rate their health TODAY on each dimension. The EQ-5D-Y has three levels of severity (no problems, some problems and a lot of problems) and the EQ-5D-5 L five levels (no problems, slight problems, moderate problems, severe problems and extreme problems). EQ-5D is widely used and research has shown it to be valid and reliable [40]. While the EQ-5D has not been validated in this instance to show improvement, it is still the preferred tool for including in any subsequent health economic analyses. The study has been set up to identify the burden of care in other ways, and so we are not entirely reliant on the EQ-5D for this.

Eating behaviours (Research food diary)
All participants will be asked to complete a food diary at home using the Research Food Diary app on four non-consecutive days (three weekdays and one weekend day) over one week during the run-in period and during the last week of the RCT phase. Research Food Diary is a free app from Xyris Software (Australia) Pty Ltd available on both Android and iPhone. This app is for use by participants in research studies only. Research Food Diary enables participants to record the foods they consume by searching the food database or by scanning barcodes. Participants will be asked to share their food diary with the research team to view in Easy Diet Diary Connect and the diary will then be analysed using FoodWorks 10 Professional (Version: 10.0.4266).

Platform performance
Platform performance will be gauged by assessing the percentage of time using AID mode for participants in the intervention arm during the RCT phase, and all participants during the continuation phase. Any technical issues encountered/ reported, both software and hardware related will be recorded in REDCap as device deficiencies.

Human-technology interaction and online collective learning
CREATE will aim to define the collective learning of participants and HCPs using open-source technology, so an education strategy can be effectively developed for clinical translation, as open-source innovations are not accompanied by the usual commercial training manuals. Quantitative analysis as well as qualitative tools such as ongoing content analysis of online peer-to-peer learning and individual interviews of both HCPs and participants as well as a HCP focus group will be used achieve this.

Individual interviews
A purposive sample of participants (up to 15 children and parents/ caregivers, and up to 15 adults) in the intervention arm will be invited to participate in a face-to-face interview (either at the research centre or via a video conference) to obtain user feedback within six weeks of completing the RCT phase. Participants who discontinue the study will be offered this same opportunity to participate in an interview within one month leaving the study. Participant interviews will explore usability and acceptability of the intervention.
The CREATE trial is being conducted in New Zealand and recognises Māori as the tāngata whenua (indigenous people) of Aotearoa (New Zealand). In line with the Guidelines for Researchers on Health Research involving Māori [41], specific interviews informed by a kaupapa Māori framework (acknowledging Māori ways of knowing and conducting research) will be held to ensure determinants of health and cultural acceptability are explored within a safe environment. The CREATE trial endeavours to recruit 10 Māori participants in total (population representation), an example that the researchers are committed to fulfilling the principles of embodied in the Treaty of Waitangi -the founding document of New Zealand [42]. In light of these small numbers, all Māori participants will be invited to participate in such an interview whether they completed 24 weeks of AID mode during the RCT phase or continuation phase. Interviews with Māori participants will be treated as an independent data set from non-Māori.
Remote or in-person interviews will be conducted with select HCPs within four weeks of their site completing the RCT phase of the study. The selection of HCPs will be informed by the makeup and emergent findings from the HCP focus group.

Healthcare professional focus group
A remote (video link) focus group will be held for HCPs in the study using Zoom (Zoom Video Communications Inc.) The HCP focus group will occur within one month of all sites completing five participants who have experienced three months of AID mode during the RCT phase. The focus group for HCPs will converge on their experiences supporting trial participants to use the AID system and the training materials provided.

Safety/ Adverse events (AE)
In this study reportable AE's include any untoward medical occurrence meeting criteria for an: 1. Adverse Device Effect (ADE): an AE related to the use of the investigational devices (that is, insulin pump infusion set, sensor, transmitter or algorithm).

Serious ADE (SADE) or Sserious AE (SAE): an AE/ADE
that is fatal or, life-threatening or, causes permanent impairment to a body structure/ function or, requires hospitalisation or, demands medical/ surgical intervention to curb such serious sequalae.
AE's that do not satisfy seriousness criteria will not be recorded (for example, inter-current illness such as a viral upper respiratory tract infection or gastro-enteritis). Furthermore, hypoglycaemia and/ or hyperglycaemia events are an expected occurrence in patients with T1D and hence are not expected to be reported as an AE. However, any glycaemic excursion consistent with severe hypoglycaemia (that is, the participant experiences altered mental consciousness and as a result is unable to assist in their care), severe hyperglycaemia (that is, blood glucose > 16.7 mmol/L, blood ketones > 1.5 mmol/L and symptomatic) or DKA (that is, blood glucose > 13.9 mmol/L, either arterial pH < 7.3 or venous pH < 7.24, bicarbonate less than < 15 mEq/L, moderate ketonuria/ ketonemia and requiring hospital treatment) is considered an untoward event and will be reported as a SAE.
Device deficiencies (DD), that is, inadequacy of a medical device with respect to its identity, quality, durability, reliability, saftey or performance (requirements of ISO 14155:2011) will be reported and assessed as to whether they possess SADE potential. A DD with SADE potential will be managed as per a SADE with expedited reporting to the Co-ordinating Investigator within one working day. Use errors will not be recorded unless they result in an ADE.
ADE, SADE, SAE and DD collection will occur unceasingly from initial product use until completion of the final study assessments. These events will be entered into REDCap in a timely manner and the following information will be captured: start/ stop date of the event, associated symptoms, seriousness, intensity, relationship to the investigational device, treatment and outcome.

Data management
Data flow and management for this study is complex and is depicted in Fig. 2. The primary outcome data (sensor glucose values) is a large data set. Individual data will be pushed from the Android phone into Nightscout. Nightscout is an opensource, cloud based remote monitoring tool that will be used in the study for remote monitoring and settings review, plus storage of the study data. Raw data, including all pump data at approximately five-minute intervals, will be uploaded to individual Nightscout sites that are created by the study team for each individual and is tied only to the randomised study ID number. This is an important clinical interface and is necessary for health care delivery. This data will be downloaded on the backend into a secure university database on a monthly basis. All data is anonymised to protect privacy and will only hold insulin pump, CGM, and other diabetes treatment data, and the Nightscout site will only contain the study ID number.
In the situation that a participant withdraws from the study, their data will be purged if they request it to be. At the outset of the study, each participant will be assigned a URL which will be recorded, so the study staff will be able to correctly identify which data set needs purging.
All other de-identified data, which includes demographic, auxological, clinical, diabetic and lifestyle information as well as the four psychosocial questionnaires and AEs will be electronically stored on REDCaphosted on secure University of Otago servers. REDCap is a web-based application designed to support data capture for research studies, providing validated data entry and audit trails for tracking data manipulation and export procedures, and custom modules for randomisation of participants and scheduling of data collection events [43]. Data generated by the study will be made available for algorithm refinement, research and development, education, product surveillance and regulatory submissions. This data will be de-identified and the key linking participant number and participant identifiers will not be made available for such purposes. No documents containing personal identifiable data will be removed from the study sites.
The Health Research Council of New Zealand have an appointed Data Monitoring Committee (DMC). The CREATE trial DMC will be responsible for safeguarding the interests of trial participants, assessing the safety and efficacy of the interventions during the trial, and for monitoring the overall conduct of the clinical trial. To contribute to enhancing the integrity of the trial, the DMC may also formulate recommendations relating to the selection/recruitment of participants, their management, improving adherence to protocolspecified regimens and retention of participants, and the procedure for data management and quality control.

Statistical analysis
Participants will be analysed as-randomised (intention-totreat) and multiple imputation methods used if missing data exceeds 10%. Two-sided P values will be reported and an alpha of 0.05 considered statistically significant. No interim analysis will be undertaken. Analysis will be performed using an up-to date version of specialist statistical software (R, SAS, or Stata). The primary endpoint, mean percentage of time spent in target glucose range (3.9-10.0 mmol/L (default) and 3.9-7.8 mmol/L (secondary)), will be collected from days 155-168 of the RCT phase, and will be calculated for each participant by dividing the number of CGM measures within range by the total number of CGM measures recorded. The overall treatment effect (primary outcome) shall be determined by using a global F-test (ANOVA) to compare a linear model containing age strata and treatment group and their interaction, versus the 'null' model containing age strata only. Simulation shows that this approach preserves the overall type 1 error rate, whilst allowing for investigation of treatment effects at a subgroup level. Group means and differences in group means will be estimated with 95% confidence intervals using ordinary least squares linear regression models with adjustment for stratification factors.
Continuous secondary endpoints will be calculated and compared in a similar manner. Where possible (for example for HbA1c and psychosocial factors), analysis of covariance (ANCOVA) models will be used to also adjust for participants' levels at baseline.
Primary and secondary outcomes based upon CGM data will be calculated for each participant for each adjacent 14-day block throughout the study (for example, day 1 to day 14, day 15 to day 28, …, day 155 to day 168). This data will be summarised as medians and quantiles by treatment group and time and presented in figures.
The stability of outcomes achieved by participants at day 168 +/-7 (end of the RCT phase) will be assessed by entering data collected during the continuation phase into likelihoodbased linear mixed-effect models. The mean change and standard deviation of change in outcomes over the continuation phase (days 168 +/-7 to 420 +/-7) will be estimated with 95% confidence intervals, stratified by treatment group.
A social-ecological lens will be used to group psychosocial data. Such a lens is useful in providing context to experience and helping to target interventions appropriately [44]. The social ecological model depicts the individual as nested within various levels of influence: the intrapersonal, the interpersonal, the institutional and the community level [45]. Content (quantitative) and thematic (qualitative) analysis will be undertaken of interactions on both HCPs and participants' online platforms. Thematic analysis will be undertaken on interview and focus group data. Content analysis will be separately undertaken for HCPs and patients' data sets as follows: HCPs use of a shared, private Slack Workspace (Slack Technologies Ltd, 2018) will be stored in Slack and downloaded into R for analysis. Analysis will focus on the topics being discussed and changes in frequency of topic, and frequency with which Crocket and Lewis provide answers vs. other HCPs providing answers over the duration of the trial. Descriptive summaries of platform use for study HCPs will be summarised for the entire HCP group using counts and rates by topic and role of the poster.
Participants' use of a shared, private online platform (Tribe Technologies Ltd, 2019) for peer-to-peer learning and support will be stored in Tribe and downloaded as CSV files and opened in R. Descriptive summaries of platform use by topic, changes in topic, and by user will be summarised using counts and rates. Proportions of participants posting on the platform over time will be provided. A profile of 'super-users', those who are regularly engaged in providing support to other users on the platform, will be produced, including glycaemic control and demographic characteristics.
Data for qualitative analysis from interviews and the focus group (verbatim transcripts) and online platforms (screenshots of posts) will be imported into qualitative data management software NVivo (QRS International Pty Ltd, 2014) for management, retrieval and interrogation. Thematic analysis, as described by Braun and Clark, will be used [46]. Coding will be undertaken inductively. Generation of themes from these codes will be informed by social-ecological theory and prior literature relating to human factors in AID use.

Discussion
Individuals with T1D experience ample burden from their prescribed lifestyles [47]. Commercial AID systems are the new standard in diabetes care as they have been shown to improve glycaemic control, reduce burden of care and likely diminish the risk of long-term diabetic complications [48]. However, current commercial systems are either too expensive or unavailable. Although, an open-source AID system is one solution to this dilemma, its lack of regulatory approval simply raises another dilemma.
Tidepool, California, United States of America, is in the midst of a single group observational study hoping to deliver the first FDA-approved open-source AID system termed Tidepool Loop (a hybrid closed loop system for iPhone/ Apple based on the open-source Loop app) [49]. Lack of comparative effectiveness is a limitation inherent to single group studies like this. In contrast to Tidepool's study, the CREATE RCT trial is innately equipped to investigate both safety and efficacy of the open-source, community developed algorithm used in AID for people with T1D.
The CREATE trial is likely to have immediate and longterm health benefits for the participants, and their caregivers. Establishing the effectiveness and safety of the open-source algorithm will address the inequity of care for people with T1D worldwide. The results will have global impact, and likely set an example for the world that health innovation and the delivery of real tangible results can be achieved using opensource, patient-driven advancements, all at a lower price and translated at a much faster pace than is usually associated with such medical advancements. While the overall aim of the CREATE trial is to test an affordable alternative to commercial AID systems to address inequity, lack of access to funded CGM may limit the adoption of such systems. Realtime CGM (rtCGM) is an essential component of AID systems, but in reality, outside of the United States many people using CGM from around the globe are self-funding it. As the evidence base for CGMs clinical value grows, rates of reimbursement grow also. In the United Kingdom, funded rtCGM has been available to a subset of PWD who satisfy the National Institute for Health and Care Excellence (NICE) clinical guidelines since 2015 [50], and access to fully subsidised CGM and flash glucose monitoring (FreesStyle Libre) in Australia is becoming more pervasive [51]. Unlike many similar high-income countries, CGM and flash glucose monitoring are not currently funded in New Zealand, however this is likely to change in the foreseeable future as Diabetes New Zealand is placing pressure on the government to fund these technologies [52]. In the meantime there are other avenues to realising an AID system: although the cost of CGM is prohibitive in New Zealand, many families of children with T1D are financing flash glucose monitoring using their Child Disability Allowance (a non-taxable government provision), which can readily be converted to rtCGM with the addition of hardware such as Miao Miao.
To fully realise the potential of AID in the future, significant headwinds are necessary to improve access to AID system clinical trials, allowing for the inclusion of minority populations, who have not previously enjoyed access to diabetes technologies. The CREATE trial will only recruit people with diabetes already on insulin pump therapy as a safety measure, however this may well make it difficult to recruit the desired indigenous cohort since they have poorer metabolic outcomes [53], and as a result of this are denied access to insulin pump therapy [26,54]. Future AID studies allowing for recruitment of people with T1D using multiple daily injections would render pre-determined criteria for accessing insulin pumps (such as having an HbA1c < 91 mmol/mol) obsolete for research purposes.
The global Covid-19 pandemic emerged in the lead up to recruiting CREATE trial participants, and although New Zealand has fared well thus far, the country has entered a state of lock down, and the trial sponsor, the University of Otago has interrupted all human subject research. Currently, it is obvious study recruitment will be deferred, but by how long is undecided. The CREATE study team feel strongly the initial study visit must be in-person since this is when the baseline tasks are performed and participants are taught the fundamentals. However, subsequent visits could be conducted in a remote manner harnessing the advantages of Nightscout. Virtual Paediatric T1D clinics using Zoom, have already proven to be successful in the primary study site during Covid-19, and so remote reviews are both appealing and feasible in the event of continued pandemic adjournment.
Author contributions MdB, DL and HC conceived the study. MdB, DL, HC, CJ, BJW and RP initiated the study design. MdB is the grant holder. JW provided statistical expertise in clinical trial design and is conducting the primary statistical analysis. All authors contributed to refinement of the study protocol. MB composed this manuscript. All authors contributed to, and approved the final manuscript.
Funding information The CREATE trial was funded by the Health Research Council New Zealand, with hardware support from SOOIL Developments Co., Ltd, South Korea and DexCom R , San Diego, United States, as well as cloud software support from Nightscout New Zealand. The study design, management, analysis, and reporting for this investigator-driven research will be conducted entirely independently from study sponsors.
Data Availability Not applicable.

Compliance with ethical Standards
Conflict of interest The authors declare that they have no conflict of interest.
Ethics approval This study has been approved by the Southern Health and Disability Ethics Committee (20/STH/1).
Consent to participate Consent to participate in this study will be obtained by all future participants as per the requirements of ISO 14155:2011 and Good Clinical Practices.

Consent for publication Not applicable.
Code availability Not applicable.