<?xml version="1.0" encoding="UTF-8"?><feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
                                        <id>https://www.samanvayfoundation.org/resources</id>
                                            <link rel="self" href="https://www.samanvayfoundation.org/resources"></link>
                                <title><![CDATA[Resources]]></title>
                                                                                                                <updated>2024-04-08T15:54:40+00:00</updated>
                        
            <entry>
            <title><![CDATA[Benefits and constraints of shared software teams]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/benefits-and-constraints-of-shared-software-teams" />
            <id>https://www.samanvayfoundation.org/resources/benefits-and-constraints-of-shared-software-teams</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<h4>Shared Software Team</h4>
<p>If you as a customer want software developed, supported &amp; maintained - but the size of your project is such that it doesn't require a full time person, let alone a software team of multiple people - then shared software team is an option for you. Some examples of where it can be commonly seen.</p>
<ul>
<li>B2B product implementation / customisation projects</li>
<li>CMS (like Wordpress) based website development</li>
<li>Small custom application development projects</li>
</ul>
<p>It is lot more common for smaller business customers and non-profits organisations. In my experience when in large business software projects - this was rarely seen.</p>
<p> </p>
<h5>What problem it solves and how</h5>
<p><span style="font-size: 16px;">When the software needs to be developed over disjointed periods of time, it may need technical support in an unpredictable manner (at any point in time). A shared software team can solve this problem. </span>As the name suggests there is a permanent software team that works on these multiple software projects and provides production support for them. While the projects start, stop, end, resume, etc - the team is always in place and busy working on some project or the other.</p>
<p> </p>
<p>Such software teams are built around a theme. The theme could be a product (like Avni, Wordpress) or simple applications developed on common tech stack (like Ruby on Rails, Django, etc). This theme allows the team members to be able to switch across projects and still be quite productive.</p>
<p>Economically a shared team, helps the customers in not having to pay for software services when they have no work to be done while still having a team that they can depend on when they do have work. It is also a fit for the need of ongoing production support that can be provided by the team - on continuos basis.</p>
<p><br>The above is quite an intuitive idea and that is why shared teams are quite prevalent. But the downsides or tradeoffs are not quite obvious and well understood - at least it was not for me. Lack of awareness of these downsides can make the experience of the software teams as well as that of customers quite frustrating and unpleasant. Customers may even believe that their software team is not capable while the issues often are inherent to the model itself. The main goal of this article it to enumerate and explain these tradeoffs.</p>
<p><br>A shared software team technically works because of the familiarity with the codebases across projects. The familiarity come from uniformity due to - common approach, language, libraries, code pattern etc. The less uniform the code is, even on the same platform, lesser the number of projects the team will scale to. Standardisation is key. It could be enforced by the underlying platform (done quite well by Wordpress and web in general) or by the software team themselves.</p>
<h5><br>Tradeoffs and constraints of Shared Team model</h5>
<ul>
<li>Unless the team is created for a specific domain - the domain of the customers can be many. This means that the software team is really not an expert in any of the domain.</li>
<li>Discontinuity has cost for software team. Even for the same person working on a project, coming back after 3-6 months may mean significant loss of context and understanding. This is especially severe for production support. The customers on the other hand, have no discontinuity on their side as they are using the software regularly. The loss of context causes basic errors that is difficult to accept / appreciate for the customers. Customers may end up explaining the same business / domain concepts and sharing same information with "each new person". This can be frustrating for them.</li>
<li>I have found that switching across software projects is psychologically quite demanding for all members / roles of the software team. From their perspective as soon as they start becoming comfortable with a codebase/project/domain/customer they have to switch to another project.</li>
<li>Attrition in team members has severe negative impact on shared teams than a dedicated team. One person leaving may take away significant percentage of context for any given customer, if not nearly 100% sometimes. This is a risk that customer carries.</li>
</ul>
<h5><br>What one customers and the software team do?</h5>
<ul>
<li>It is better to work in larger batches as much as possible. It is better to batch smaller requirements, from a customer, over time into a small project and then execute in one go than work on them in smaller sizes. This reduces discontinuity in work and switching to some extent.</li>
<li>It is better for customers to have more quality safe-guards on their end compared to dedicated team software projects. The defect rates, after first release, are likely to be high from shared teams.</li>
<li>People with some technology skills on customer end can be quite a boon in these arrangements. Such people lend continuity, context, and specific technical skills that the shared software team lacks, by its design.</li>
<li>Sustainable and useful documentation. Good documentation can help team members new to that project to learn quickly - but it has to be done well and then used too. Having said this - increasingly I find people have lesser appetite to learn from documentation and show preference for learning by working oneself as well as learning orally from other team members. The team should decide based on their own context on this item.</li>
<li>Customers should ask the software team to explain their working model - so that they can also adapt their own processes based on this.</li>
<li>Finally - I believe the most helpful thing is to reset expectations if one has worked in or with dedicated software team. These expectations are unlikely to be met and may cause only frustrations to all involved. And of course nothing like having a permanent team.</li>
</ul>
<h5><br>What one should avoid?</h5>
<ul>
<li>Avoid non-standard type of work, even if it is technically possible for the team. Always ask the question will someone else in your team able to understand this after 6 months. It is very important to reflect and understand what is "standard" work. The scalibility of the software team depends on this. It is possible that both team and customers may want non-standard projects. The team may want it as it provides some diversity in work. This is where the "business" should come in and decide whether it is a good idea from long term perspective or not.</li>
<li>Sometimes frustrated customers may want to the take path of creating their own in-house software team at reduced cost so that they have a permanent team. But in my view, it is quite difficult to pull this off for non-profits. We have written <a href="https://www.samanvayfoundation.org/resources/the-challenge-of-building-technology-team-in-nonprofit-organisations">about this</a>.</li>
</ul>
<h4><br>Other relevant articles</h4>
<ul>
<li>Difference between software platform and bespoke solution. How to make the choice? - <a href="https://www.samanvayfoundation.org/resources/software-platform-and-bespoke-solution">https://www.samanvayfoundation.org/resources/software-platform-and-bespoke-solution</a></li>
<li>The challenge of building technology team in nonprofit organisations - <a href="http://www.samanvayfoundation.org/resources/the-challenge-of-building-technology-team-in-nonprofit-organisations">https://www.samanvayfoundation.org/resources/the-challenge-of-building-technology-team-in-nonprofit-organisations</a></li>
<li>Domain expertise doesn't travel from high-resource to a low-resource setup - <a href="https://www.samanvayfoundation.org/resources/domain-expertise-doesnt-travel-from-high-resource-to-a-low-resource-setup">https://www.samanvayfoundation.org/resources/domain-expertise-doesnt-travel-from-high-resource-to-a-low-resource-setup</a></li>
</ul>
<p> </p>
<h5>Credits</h5>
<p>Cover image - <a href="https://www.canva.com/p/kanchanachitkhamma/">https://www.canva.com/p/kanchanachitkhamma/</a></p>
<p> </p>
<p><span style="font-size: 16px;">Author: <strong>Vivek Singh<br></strong></span><span style="font-size: 16px;">Published on: <strong>10 April 2024</strong></span></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-39-screenshot-2024-04-10-at-94642-am-17127237320598.png" length="2727176" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2024-04-08T15:54:40+00:00</updated>
                            <dc:description><![CDATA[Shared software team is quite a useful software delivery organisation model when the size of the projects are small. Shared teams are quite prevalent, but the downsides and tradeoffs are not well understood. Lack of awareness of these downsides can make the experience of the software teams as well as that of customers quite frustrating, unpleasant and failure even. Customers may even believe that their software team is not capable while the issues often are inherent to the model itself.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Planning for security testing of open source projects]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/planning-for-security-testing-of-open-source-projects" />
            <id>https://www.samanvayfoundation.org/resources/planning-for-security-testing-of-open-source-projects</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>Open source projects in social sector undergo security testing when they deal with a largish entity like government, who have security standards for what they will run in their data centre. Having gone through security testing for three projects now - Bahmni, Gunak and Avni, we see that there are many commonalities in the process, testing, issue types, and their resolution. These two write-ups (this is first) is aimed to help anyone going through such process. In this we discuss considerations for planning for security testing. That is, imagine when you have a software and the customer wants it to take it through security audit - for clearance.</p>
<p><br><span style="font-size: 16px;">Following are the main topics that one needs to think-about and plan for</span></p>
<ol>
<li><strong><span style="font-size: 16px;">Scope of testing</span></strong></li>
<li><strong><span style="font-size: 16px;">Server environment in which the testing will be done</span></strong></li>
<li><strong><span style="font-size: 16px;">Process - from testing start to closing all the issues</span></strong></li>
<li><strong><span style="font-size: 16px;">Preparedness for negotiation on the resolution of the issues</span></strong></li>
</ol>
<h5> </h5>
<h4>Scope of testing</h4>
<p>Usually the scope of testing may be clear i.e. involving everything. But it maybe useful to work backwards from production environment to make a list of components that may be in/out of scope. This is quite useful in the following scenarios:</p>
<ul>
<li>You have an open source project with multiple components and not everything may be used in the project/implementation in question. For example in the Bahmni deployment we were worked on - Odoo and PACS was not used, so those go out of scope.</li>
<li>You may have replaceable components. We use Cognito and S3 for our own hosting of Avni, but the customer's deployment may use open source equivalents like Keycloak and Minio. This is of course assuming that your product allows for such switching.</li>
<li>There are components that need not be made available publicly. For example - you may be using a BI tool that falls here because it is meant to be used by customer internally. If possible then you may want to restrict its usage behind VPN for select users - hence taking it out of scope.</li>
<li>The platforms that are configurable like Avni per customer, then one can define the scope of testing for the features relevant to that customer.</li>
</ul>
<p>In case of software platforms the above decisions should be reflected in the deployed system. If the deployed system doesn't reflect the scope of testing - then it will like cause a lot of communication issues and perhaps wasted effort for both the teams.</p>
<p>This process should also help bring out questions like - look we are using Power BI but that is not something we can do anything about, so should it be even part of the testing? If such a component is not part of the testing then how should we one go about certifying them, requires discussion.</p>
<h4><br>Isolate important systems from the blast radius</h4>
<p>In social sector open source projects, funds are scarce and the temptation maybe to use one of the existing deployments to perform security testing on. But this may create bigger problems. It is important to setup the security test environment in such a way that there are no important systems in its blast radius. <br><strong>About blast radius</strong><br>When offering one's system for security testing, one must be pessimistic. For example - one should assume, whether likely or not, that the security testing team can find a SQL injection attack and execute any SQL on your database. Even if it is remotely possible for them to do this, then you must setup your security test environment to protect other important system from such an event. It may be important to consider the shared development environments as production environment of as well. If shared development environments are corrupted they can result in loss of days/weeks of productivity for entire team.<br>It would be ideal if you have an automated process and backups for setting up an environment as it is quite likely that your security testing team may come back to you to "reset" their test environment so that they can resume testing - since they have broken something and made the system un-testable.<br>Practical issues that I have seen happening here is that the security team can do is:</p>
<ul>
<li>change the super-admin password and doesn't remember it</li>
<li>has deleted data/tables (including the base/user data)</li>
</ul>
<p> </p>
<h4>Process</h4>
<p>The team that is going for first/second time for security testing may have certain perceptions of the complete security testing process. The team that does security testing - does it daily. Their process is very clear to them. There is usually and naturally large process understanding mismatch between these two teams.<br>It is much better for the software team to get into as much detail as possible, right in the beginning to understand the process. The questions you can ask:</p>
<ul>
<li>How many rounds of testing will there be?</li>
<li>How it will be reported - severity/priority/versions?</li>
<li>How issues will be tracked?<br>
<ul>
<li>This can be done quite poorly. The issues can end being all over emails, PDF, and excel files. It is better to agree on a shared editable document (like Google Doc) for error reporting.</li>
</ul>
</li>
<li>The open source software teams must avoid putting up these issues in public domain or in open issue tracking system - since to avoid making the job easier for the exploiter and to not make your customer's nervous.</li>
</ul>
<h4><br>Negotiation</h4>
<p>This is quite important part of security testing and issue fixing projects. While there are standards but application of standards has to be negotiated. This is because:</p>
<ul>
<li>There are less nuances in the standard. The standard is based on the idea that all applications are the same and must adhere to the same standard irrespective of the number of users, type of usage, and the criticality of the data. While some issues like SQL injection, unprotected URLs are non-negotiable, but how much importance should be placed on social engineering attacks, rogue user, can vary.</li>
<li>While all the parties may want fix all the security issues, but there may not be time or resources available to fix all everything.</li>
</ul>
<p>That is why relationships, consulting skills, negotiation approach, and above all collaborative process - matters a lot in such projects. It is in software team's interest to explain that issues or resources and time may come up even before security testing starts - as many a times the customer may also be going through this process for the first time.</p>
<p><br>In the next 1 or 2 article we will discuss the common (90%) of the issues that get reported and technical approach to solve them (in similar stack as ours).</p>
<p> </p>
<p> </p>
<p>Published On: <strong>05 September 2023</strong></p>
<p>Author: <strong>Vivek Singh</strong></p>
<p> </p>
<p><em>Logo credit: Raj Agarwal, <a href="https://www.canva.com/p/templates/EAE-T26xHMo-internet-security-logo/" target="_blank" rel="noopener noreferrer">https://www.canva.com/p/templates/EAE-T26xHMo-internet-security-logo/</a></em></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-38-screenshot-2023-09-05-at-120507-pm-16938957180766.png" length="164437" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2023-09-05T04:39:16+00:00</updated>
                            <dc:description><![CDATA[Based on our experience of having gone through security testing of multiple open source projects - we are sharing how one can plan and prepare for it.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Software volatility is a good thing]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/articles/on-software-architecture/software-volatility-is-a-good-thing" />
            <id>https://www.samanvayfoundation.org/articles/on-software-architecture/software-volatility-is-a-good-thing</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<h5>What do we mean by software volatility</h5>
<p>Software volatility is the variation in existing working functionality of a software product. A less volatile software is one that is quite stable in how predictably it performs all its user functions over time. Of course, we all want such systems and want that new features get added over time.</p>
<p>Users and customers convey this expectation to the leaders of the software team. The leaders communicate this to the engineers. They may even have quality metrics that measure number of new defects per release and keep them as low as possible. They may even judge the software team's capability based on this. THIS IS A FOLLY. Complex systems do not evolve in this way (may be simple software systems do). Similarly for customers to lose their confidence when a product degrades in certain areas once in a while is a mis-judgment. Why is this a so?</p>
<p> </p>
<p><img src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2023-06-02-at-12556-pm-1685780672183.webp" alt="" width="1337" height="404" data-width="1337" data-height="404"></img></p>
<p> </p>
<h5>Low volatility system</h5>
<p>When a software engineer is asked to add new functionality - he/she may instinctively or due to the nature of work environment avoid changing code that is already working and adds the new functionality in a way that the code for both old and new don't overlap much. This is a low risk way of adding software features and is quite common in our experience. When this process is repeated over and over again - everyone is happy.</p>
<p>This was one example but a software team can take other types of such short-sighted approaches:<br>- forking the code for a new customer because it is too risky to generalise existing code and jeopardise existing customers functionality<br>- not upgrading the underlying software libraries because the impact can be high<br>- not changing the code so that it more testable</p>
<p>- not deleting code</p>
<p> </p>
<p>But this cannot last very long. Slowly this option of not changing the old code much (hence not improving it) and adding only the new becomes less and less available to the engineer. This leads to a very bad place. Now, there is a lot duplication in the code. Changes need to be made in several places for one thing. Some changes get missed out. But most importantly - <strong>it is no longer possible to reason about the code and change it</strong>. This is because the code was written with a different objective in mind - deliver new things without breaking old things - and not understandability of the code. Such low volatile software hide much bigger risks.</p>
<p> </p>
<h5>Why you must not take volatility for sign of a problem</h5>
<p>Volatility by itself is not what we want, but if we build the software the right way there is no escaping functional volatility. Making software involves regularly improving the internal structure and organisation of the code - to be in line with the new reality i.e. updated functionality, usage, ecosystem. This internal improvement while in very short term (a few weeks) introduces defects, but the decision to go ahead and take this risk, improve the code, is essential to creating long lasting good quality software.</p>
<p> </p>
<p>Published on: <strong>02 Jun 2023</strong></p>
<p>Author: <strong>Vivek Singh</strong></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-37-screenshot-2023-06-02-at-12556-pm-16856925924452.png" length="866842" type="image/png" />
                        <category term="Software Architecture" />
            <updated>2023-06-02T07:08:11+00:00</updated>
                            <dc:description><![CDATA[Long lasting and valuable software products cannot avoid volality in its functionality. Customers must not lose their nerves when they see this.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Product integration as a solution approach]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/product-integration-as-a-solution-approach" />
            <id>https://www.samanvayfoundation.org/resources/product-integration-as-a-solution-approach</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p> </p>
<p>There are several projects that do not neatly fit into a single product's target domain. For example let's consider a project that requires beneficiary data management from the field (typical <a href="https://avniproject.org">Avni</a> use case), but also requires stock/inventory management of items distributed by the field workers. When creating technical solution for such a project there are following options:</p>
<ol>
<li>Find a product that does most and extend it's scope</li>
<li>Develop a custom solution</li>
<li>Use two functionally complimentary products</li>
<li>Integrate two functionally complimentary products but create a new user facing app</li>
</ol>
<p>In this article we will discuss these options so that we can make a decision.</p>
<p> </p>
<h5>1. Find a product that does most and extend it's scope</h5>
<p>Usually people who have this need approach a product maker (like Samanvay) and enquire whether the project's requirement fits their product. When there is a project, extending the scope of product can be quite tempting (because makers like to make things). The customers, in nonprofits, find it comforting too - that they can just use one product.<br>But mature product teams will avoid this route because:</p>
<ul>
<li>Adding unrelated features to one's product makes the product development unsustainable because of increased complexity.</li>
<li>Orthogonal features usually get used by very few customers and slowly get less love and the quality deteriorates.</li>
</ul>
<p>The decision of what goes in the product is a subjective one and the product team is best placed to make that decision. The product teams must explain their rationale to the customers.</p>
<p> </p>
<h5>2. Develop a custom solution</h5>
<p>We have written a lot about this earlier <a href="https://www.samanvayfoundation.org/resources/software-platform-and-bespoke-solution">here</a>, where we give reasons for why in most cases for nonprofits this is not a good idea.</p>
<p> </p>
<h5>3. Use two functionally complimentary products</h5>
<p>Before getting into this option, let us further detail our example. In our example project, let's say we have two set of users - field users and stock managers.  The field users use the mobile app while they provide service in the field and the stock managers use desktop based web interface.<br>Potentially, we can use two separate products and give it to each type of users respectively. But what happens when we want the field users to see/manipulate stock data? They can use both apps - field app and the stock management app. But what if the stock management app is not capable of working offline or it is too complex for the user to learn and use two apps. More importantly what if the field users workflows requires managing beneficiary and stock data in the same flow (e.g. fieldworker hands over certain medicines to the beneficiary while doing anaemia screening).</p>
<p><br>Integrating two products can solve these issues. The field users can capture/view data related to stocks in field app's regular workflows (e.g. filling a form) and let the integration component ensure that the stock management system is updated. But the idea in this approach is not to develop all the stock management screens in field app.</p>
<p> </p>
<p>The benefit of this approach lies in reusability of the integration component. The integration component can be generalised to cater to more use cases where there is are similar requirements. This makes the approach sustainable for the development team - as they have to maintain less software and hence for the customer ecosystem too.</p>
<p> </p>
<h5>4. Integrate two functionally complimentary products but create a new user facing app</h5>
<p>Another approach is to not do integration but develop a new user facing app that uses the API of both the products. This approach is useful if the use case is simple. But as the use case becomes complex one may find that one is duplicating the user interface of both the products into this new app.</p>
<p><br>At Samanvay we have experience of having used option 3 quite a lot. In fact one of the value proposition of <a href="https://bahmni.org" target="_blank" rel="noopener noreferrer">Bahmni</a> was that instead of re-developing everything into the product it integrated 3 different products - OpenMRS, OpenELIS, and Odoo. Similarly, we have also integrated Avni with Bahmni using the same idea.</p>
<p> </p>
<p> </p>
<p><strong>Author</strong>: Vivek Singh</p>
<p><strong>Published On</strong>: 05 Apr 2023</p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-36-screenshot-2023-04-05-at-83708-pm-16807072522919.png" length="3493194" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2023-04-05T15:08:23+00:00</updated>
                            <dc:description><![CDATA[Integrating multiple products offers a sustainable approach by not creating more software hence requiring more engineers and resources]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[REST API Pagination and race condition]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/articles/on-software-architecture/rest-api-pagination-and-race-condition" />
            <id>https://www.samanvayfoundation.org/articles/on-software-architecture/rest-api-pagination-and-race-condition</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>When we integrate two systems, we use the REST APIs to access the data. Using these API we get access to the historical data and once we have processed all the historical data, we want to get any of the newer data - as time passes. The APIs present the data in the form of pages of records by the source system (for more you can see the <a href="https://www.mscharhag.com/api-design/rest-event-feed" target="_blank" rel="noopener noreferrer">Feed</a> and <a href="https://www.mscharhag.com/api-design/rest-pagination" target="_blank" rel="noopener noreferrer">Pagination</a> patterns). The pagination is usually done based on the last modified date time of the record. This is quite simple for the consumer of the API to understand as the data is arranged in chronological order of change. But there is something interesting going on with the records that have been modified in the past few seconds. If these few seconds are not handled by the API provider correctly, then it can cause a lot of issues for the consumer of the API and/or lost records.</p>
<p> </p>
<p>To understand this, let's start with a simple system. The table below describes the sequence of the last modified date time assigned to a record, it getting saved in the database, and then appearing in a paginated feed.</p>
<p style="text-align: center;"> </p>
<table style="border-collapse: collapse; width: 665px; height: 185px; border-color: #000000; border-style: solid; margin-left: auto; margin-right: auto;" border="2">
<tbody>
<tr style="height: 31px;">
<td style="width: 61.1797px; height: 31px; text-align: center;">
<p><strong>STEPS</strong></p>
</td>
<td style="width: 55.1641px; height: 31px; text-align: center;">
<p style="text-align: center;"><strong>TIME</strong></p>
</td>
<td style="width: 546.656px; height: 31px;">
<p><strong> EVENT</strong></p>
</td>
</tr>
<tr style="height: 31px;">
<td style="width: 61.1797px; height: 31px; text-align: center;">
<p><span style="font-weight: 400;">S0</span></p>
</td>
<td style="width: 55.1641px; height: 31px; text-align: center;">
<p><span style="font-weight: 400;">T0</span></p>
</td>
<td style="width: 546.656px; height: 31px;">
<p><span style="font-weight: 400;">The user saves a record</span></p>
</td>
</tr>
<tr style="height: 61px;">
<td style="width: 61.1797px; height: 61px; text-align: center;">
<p><span style="font-weight: 400;">S1</span></p>
</td>
<td style="width: 55.1641px; height: 61px; text-align: center;">
<p><span style="font-weight: 400;">T1</span></p>
</td>
<td style="width: 546.656px; height: 61px;">
<p><span style="font-weight: 400;">Server application assigns current time = T1 value to the records last modified date time</span></p>
</td>
</tr>
<tr style="height: 31px;">
<td style="width: 61.1797px; height: 31px; text-align: center;">
<p><span style="font-weight: 400;">S2</span></p>
</td>
<td style="width: 55.1641px; height: 31px; text-align: center;">
<p><span style="font-weight: 400;">T2</span></p>
</td>
<td style="width: 546.656px; height: 31px;">
<p><span style="font-weight: 400;">The record gets saved in the database</span></p>
</td>
</tr>
<tr style="height: 31px;">
<td style="width: 61.1797px; height: 31px; text-align: center;">
<p><span style="font-weight: 400;">S3</span></p>
</td>
<td style="width: 55.1641px; height: 31px; text-align: center;">
<p><span style="font-weight: 400;">T3</span></p>
</td>
<td style="width: 546.656px; height: 31px;">
<p><span style="font-weight: 400;">This record appears on the page requested by the API user at time = T3</span></p>
</td>
</tr>
</tbody>
</table>
<p style="text-align: center;"> </p>
<p style="text-align: left;">Let's see what happens to the records coming into the system from various users.</p>
<table style="border-collapse: collapse; width: 665px; height: 160px; border-color: #000000; border-style: solid; margin-left: auto; margin-right: auto;" border="2">
<tbody>
<tr style="height: 61px;">
<td style="width: 94.2656px; height: 61px;">
<p style="text-align: center;"><strong>STEPS</strong></p>
</td>
<td style="width: 98.2891px; height: 61px; text-align: center;">
<p><strong>USER 1</strong></p>
<p><strong>R1</strong></p>
</td>
<td style="width: 96.2891px; height: 61px; text-align: center;">
<p><strong>USER 2</strong></p>
<p><strong>R2</strong></p>
</td>
<td style="width: 106.305px; height: 61px; text-align: center;">
<p><strong>USER 3</strong></p>
<p><strong>R3</strong></p>
</td>
<td style="width: 121.352px; height: 61px; text-align: center;">
<p><strong>USER 4</strong></p>
<p><strong>R4</strong></p>
</td>
<td style="width: 147.5px; height: 61px; text-align: center;">
<p><strong>USER 5</strong></p>
<p><strong>R5</strong></p>
</td>
</tr>
<tr style="text-align: center;">
<td style="width: 94.2656px; height: 31px;">
<p><span style="font-weight: 400;">S0</span></p>
</td>
<td style="width: 98.2891px; height: 31px;">
<p><span style="font-weight: 400;">T0</span></p>
</td>
<td style="width: 96.2891px; height: 31px;">
<p><span style="font-weight: 400;">T100</span></p>
</td>
<td style="width: 106.305px; height: 31px;">
<p><span style="font-weight: 400;">T200</span></p>
</td>
<td style="width: 121.352px; height: 31px;">
<p><span style="font-weight: 400;">T300</span></p>
</td>
<td style="width: 147.5px; height: 31px;">
<p><span style="font-weight: 400;">T410</span></p>
</td>
</tr>
<tr style="text-align: center;">
<td style="width: 94.2656px; height: 31px;">
<p><span style="font-weight: 400;">S1</span></p>
</td>
<td style="width: 98.2891px; height: 31px;">
<p><span style="font-weight: 400;">T10</span></p>
</td>
<td style="width: 96.2891px; height: 31px;">
<p><span style="font-weight: 400;">T110</span></p>
</td>
<td style="width: 106.305px; height: 31px;">
<p><span style="font-weight: 400;">T210</span></p>
</td>
<td style="width: 121.352px; height: 31px;">
<p><span style="font-weight: 400;">T310</span></p>
</td>
<td style="width: 147.5px; height: 31px;">
<p><span style="font-weight: 400;">T420</span></p>
</td>
</tr>
<tr style="text-align: center;">
<td style="height: 37px; width: 94.2656px;">
<p>S2</p>
</td>
<td style="height: 37px; width: 98.2891px;">
<p>T20</p>
</td>
<td style="height: 37px; width: 96.2891px;">
<p>T120</p>
</td>
<td style="height: 37px; width: 106.305px;">
<p>T220</p>
</td>
<td style="height: 37px; width: 121.352px;">
<p>T320</p>
</td>
<td style="height: 37px; width: 147.5px;">
<p>T430</p>
</td>
</tr>
</tbody>
</table>
<p style="text-align: center;"> </p>
<p style="text-align: left;"><span style="font-weight: 400;">If an API user asks for all records newer than T0 and with pageSize = 3, the API will provide the data in two pages as [R1 (T10),  R2 (T110),  R3(T210)] followed by [R4 (T310), R5 (T430)] in step S3. For simplicity, we assumed that the time gap between various steps is the same across different users.</span></p>
<p><span style="font-weight: 400;">But this assumption cannot be made due to a few reasons - different amounts of data processed for each record, thread scheduling, IO availability, other processes interfering, etc. This lack of consistency in the time gap between S1 and S2 referred to as </span><a href="https://en.wikipedia.org/wiki/Race_condition"><span style="font-weight: 400;">race condition,</span><span style="font-weight: 400;"> </span></a><span style="font-weight: 400;">causes step 3 (S3) not to work as one would expect. Let’s see how.</span></p>
<p> </p>
<p style="text-align: left;"><span style="font-weight: 400;">Let’s use the scenario same as above but change the timings for USER 4 - note the time gap between steps.</span></p>
<p style="text-align: left;"> </p>
<table style="border-collapse: collapse; width: 76.1678%; height: 158px; border-color: #000000; border-style: solid; margin-left: auto; margin-right: auto;" border="2" width="68.8275%">
<tbody>
<tr style="height: 62px;">
<td style="width: 73.5156px; height: 62px; text-align: center;">
<p><strong>STEPS</strong></p>
</td>
<td style="width: 82.0859px; height: 62px; text-align: center;">
<p><strong>USER 1</strong></p>
<p><strong>R1</strong></p>
</td>
<td style="width: 82.0859px; height: 62px; text-align: center;">
<p><strong>USER 2</strong></p>
<p><strong>R2</strong></p>
</td>
<td style="width: 82.0859px; height: 62px; text-align: center;">
<p><strong>USER 3</strong></p>
<p><strong>R3</strong></p>
</td>
<td style="width: 82.0859px; height: 62px; text-align: center;">
<p><strong>USER 4</strong></p>
<p><strong>R4</strong></p>
</td>
<td style="width: 82.1406px; height: 62px; text-align: center;">
<p><strong>USER 5</strong></p>
<p><strong>R5</strong></p>
</td>
</tr>
<tr style="height: 32px;">
<td style="width: 73.5156px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">S0</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T00</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T100</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T200</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T202</span></p>
</td>
<td style="width: 82.1406px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T410</span></p>
</td>
</tr>
<tr style="height: 32px;">
<td style="width: 73.5156px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">S1</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T10</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T110</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T210</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T208</span></p>
</td>
<td style="width: 82.1406px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T420</span></p>
</td>
</tr>
<tr style="height: 32px;">
<td style="width: 73.5156px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">S2</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T20</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T120</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T220</span></p>
</td>
<td style="width: 82.0859px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T223</span></p>
</td>
<td style="width: 82.1406px; height: 32px; text-align: center;">
<p><span style="font-weight: 400;">T430</span></p>
</td>
</tr>
</tbody>
</table>
<p style="text-align: center;"> </p>
<p style="text-align: left;"><span style="font-weight: 400;">Since there are a couple of common ways to implement pagination, both described </span><a href="https://www.mscharhag.com/api-design/rest-pagination"><span style="font-weight: 400;">here</span></a><span style="font-weight: 400;"> - we will try to see what resources we get in response for both approaches.</span></p>
<p><strong>1. Using offset and limit</strong></p>
<p><span style="font-weight: 400;">(a) When an API user tries to get the first page at T222 (limit=3, offset=0). The user would get R1, R2, and R3. Then the API user navigates to the next page at time T230. </span></p>
<p><span style="font-weight: 400;"><span style="font-weight: 400;">(b) </span>When an API user calls at T230, s/he will get R3 again on the second page at T230 (limit=3, offset=3). R3 &amp; R5 both will appear after T430. Note that R4 will never appear for this user. But note that if the user came much later (let's say T500) for offset=0 and offset=3 - one will get all the records as {R1, R2, R4} and {R3, R4}.</span></p>
<p><strong>2. Using seek pagination</strong></p>
<p><span style="font-weight: 400;">(a) When an API user tries to get the first page at time T222 (limit=3, time &lt; T00 ). The user would get R1, R2, and R3.</span></p>
<p><span style="font-weight: 400;"><span style="font-weight: 400;">(b) </span>Then the API user navigates to the next page at time T230 (limit=3, time=T220). In this case, the API user gets only R5 on the second page (again missing R3). Again here if the user comes later s/he will get all the records as above.</span></p>
<p><span style="font-weight: 400;">The main reason R4 is being missed out is that the timestamp assignment has happened but it is not visible to the API user yet as it is not saved. The caller of API and the system assigning timestamp plus saving are in a race condition with each other.</span></p>
<p> </p>
<h5>Consequence</h5>
<p><span style="font-weight: 400;">In some software systems, missing odd records may not be an issue e.g. getting notifications. But in some systems e.g. in the business process flow, this could be a bigger problem. If one is trying to read through multiple such APIs from a source, of dependent entities (e.g. customer, account, transaction) then missing customer records will mean also not being able to process all accounts of such customer records. In a large graph of entities, this can have a cascading effect.</span></p>
<p> </p>
<h5>Solutions</h5>
<p><strong>API Provider</strong></p>
<p><span style="font-weight: 400;">Once we are aware of this issue there can be a number of solutions we can come up with using messaging, another data store, etc. But there is also a simple solution that one can employ without increasing the complexity by adding additional infrastructure. We have already hinted at that above.</span></p>
<p><span style="font-weight: 400;">Since the records can be missed only when the API call and timestamp assignment are happening in the same real-time. What if we can avoid this? If the API provider cuts all resources from the paginated response that have been created/updated in let's say in the last 1 minute.</span></p>
<p> </p>
<p><span style="font-weight: 400;">Assuming that 1 minute translates to 10 units of T, let's see what happens.</span></p>
<p><strong>1. Using offset and limit</strong></p>
<p><span style="font-weight: 400;">(a) at time T222 (limit=3, offset=0) user gets R1,R2</span></p>
<p><span style="font-weight: 400;"><span style="font-weight: 400;">(b) </span>at time T230 (limit=3, offset=2) user gets R4,R3,R5</span></p>
<p><strong>2. Using seek pagination</strong></p>
<p><span style="font-weight: 400;"><span style="font-weight: 400;">(a) </span>at time T222 (limit=3, time &lt; T00) user gets R1,R2</span></p>
<p><span style="font-weight: 400;"><span style="font-weight: 400;">(b) </span>at time T230 (limit=3, time=120) user gets R4,R3,R5</span></p>
<p> </p>
<p><span style="font-weight: 400;">In your system, you can decide what is the right time duration to use for what we have used 1 minute. This time duration essentially needs to be the maximum expected time duration between S1 and S2. As you can see, in most systems 1 minute will be sufficient.</span></p>
<p> </p>
<p><strong>API Consumer</strong></p>
<p>It is possible that you are integrating with another system and you do not have a way to get this race condition fixed. In such a case as a consumer of the API, you can figure out a way to not process records that have timestamps up to the last minute (or time duration of your judgment). It is important to note that you will need to ascertain that the timestamp you are getting in the API resources is semantically the same as what you expect it to be. Basically, you should rule out timezone and other such issues - so that get timestamp matches the wall clock time.</p>
<p> </p>
<h5>Conclusion</h5>
<p>This issue may seem trivial to consider and solve - but for someone to technically support such systems in production, it is quite important that it was never there.</p>
<p> </p>
<p><strong>Author</strong>: Vivek Singh</p>
<p><strong>Published on</strong>: 19-July-2022</p>]]>
            </summary>
                        <category term="Software Architecture" />
            <updated>2022-07-19T10:38:42+00:00</updated>
                            <dc:description><![CDATA[There is less widely understood race condition in paginated REST API responses which can cause serious and difficult to find issuwa.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Factoring software codebase size and complexity is most important factor to consider when taking ownership of generic open source products]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/factoring-software-codebase-size-and-complexity-is-most-important-factor-to-consider-when-taking-ownership-of-generic-open-source-products" />
            <id>https://www.samanvayfoundation.org/resources/factoring-software-codebase-size-and-complexity-is-most-important-factor-to-consider-when-taking-ownership-of-generic-open-source-products</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>Since the time we have made Bahmni but more so with Avni, we get inquiries during our sales about customers wanting to own the software solution after the initial few years. This happens mostly with large nonprofits or when government entities are involved. Since these products are open source technically there is no restriction in taking the entire source code of the solution - without even asking the authors of the software. But in practice taking over open-source products is far more complex than it appears. In this article, we explain why this is so.</p>
<p> </p>
<p>Bahmni, Avni, and other such products are generic in nature by design, so they can serve the purposes of multiple organizations with slightly different needs. We have written about the generic and specific nature of such software <a href="https://www.samanvayfoundation.org/resources/software-platform-and-bespoke-solution">previously</a> and discussed <a href="https://www.samanvayfoundation.org/resources/what-does-it-mean-to-use-open-source">what it technically means to use open source</a>. When considering such a solution from an ownership point of view one has to account for the complexity of ownership. These platforms are much larger in their codebase size compared to if the same solution was developed for one customer for the same use case. This is for two reasons:<br>1. Most customers of these products will not use all the features of the software. But there is usually no clean way to remove such unwanted code. Some components can be done away with but feature-wise removal of unnecessary code is quite difficult.<br>2. This is the more important reason. A generic software solution implements many things in an indirect manner. For example in the case of Avni usage for maternal and child health programs, one will not be able to find even the mention of the term pregnancy in the code, or any table called mother and so on. These are concepts implemented on top of generic entities like Subject, Encounters, Visits, and so on. For any specific customer, most of the generalization done in code is of little value. But more importantly, the code base is far more complex due to this necessary generalization.</p>
<p> </p>
<p>Overall one may be owning the size of the codebase which is 5x to 10x larger in size compared to if one just developed a custom solution for oneself. For a software team that will maintain and enhance this software on their own - there is a lot of unnecessary complexity in the code without a corresponding value. The value of this complexity is only for the product team - because they want to solve the problems of multiple customers. Hence owning such a codebase requires a higher level of skills and team size, making it more expensive and not practical.</p>
<p><br>Surely for smaller generic open-source solutions some of these problems are easier to tackle - as even a generalized product code may not be so difficult to maintain.</p>
<p> </p>
<p>This doesn't imply that one should develop one's own solution. We have discussed here why it is a <a href="https://www.samanvayfoundation.org/resources/open-source-products-offer-a-technology-evolution-path-and-help-avoid-risks-in-technology-projects">better idea to use open source products</a> and here <a href="https://www.samanvayfoundation.org/resources/the-challenge-of-building-technology-team-in-nonprofit-organisations">why developing one's own solution is difficult</a>. Developing in-house poses risks and costs which are not obvious. But in generic products, there is a complexity-related tradeoff involved which one should be aware of.</p>
<p> </p>
<p>We have a couple of suggestions to resolve this problem to some extent.</p>
<ol>
<li>Support the existing product team in ensuring that they continue to support you in the long run. Maybe for other reasons, but this is getting recognized across the world with open source software projects that underlie many software systems in use.</li>
<li>Expect these software products to have the integration ability so that in the future one can slowly migrate to a different system.</li>
</ol>
<p> </p>
<p><strong>Author</strong>: Vivek Singh</p>
<p><strong>Published on</strong>: 27 May 2022</p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-29-screenshot-2022-05-27-at-40949-pm.png" length="98217" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2022-05-27T10:44:30+00:00</updated>
                            <dc:description><![CDATA[Generic software solutions have very large codebases compared to custom solutions. Nonprofit organizations must factor in this when taking over ownership of such products.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Measuring and scaling community engagement]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/measuring-and-scaling-community-engagement" />
            <id>https://www.samanvayfoundation.org/resources/measuring-and-scaling-community-engagement</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>The social programs in the domain of environment, water (like others) eventually aim to improve the lives of the communities in which they work. These programs aim to achieve this by working with governments and nonprofit providers. The last mile of the main stakeholders which is community members (or citizens) is difficult to bring into the intervention - as it increases the scale of effort required by a few orders of magnitude. This has been a challenge. The community engagement project described here is trying a simple technology-based idea to make a small headway in this direction. We have developed the solution but the idea itself came from the work of <a href="https://arghyam.org/" target="_blank" rel="noopener noreferrer">Arghyam</a> and <a href="https://vruttiimpactcatalysts.org/" target="_blank" rel="noopener noreferrer">Vrutti</a>. In the article, we try to explain the idea.</p>
<p> </p>
<h4>Context</h4>
<p>Let's say as a social organization wants to improve the condition in villages in the following areas:</p>
<ul>
<li>Creating pasture for farm animals</li>
<li>Pest and disease management in farms</li>
<li>Water, soil moisture, soil nutrients management</li>
</ul>
<p>...and other such topics of concern. While one may have some knowledge and beliefs about what a particular community's needs are - how does one find out what the community's top needs are and hence what to focus on and improve upon. Secondly, how do organizations reach more and more people about spreading awareness on these topics? For organizational activities related to information dissemination at scale, this is a challenge.</p>
<p> </p>
<h4>Idea</h4>
<p>The idea being tried out is towards this is as follows.</p>
<ol>
<li>Create QR codes where each code links to a piece of web content (video, pdf in local language about a topic). One such sample content can be seen <a href="https://bright-mailman-710.notion.site/V-8f1b43ecab0e440698dfd7f58349282d" target="_blank" rel="noopener noreferrer">here</a>.</li>
<li>These QR codes are distributed at the village level via posters, WA messages. The posters are put up at prominent places in the villages like the gram panchayat office, Anganwadi center.</li>
<li>When people scan these QR codes the link takes the user to a website that asks the user to share their location. Irrespective of whether they share location or not they are taken to the content. If they share their location then it gets recorded too. No other details are asked for.</li>
<li>If people find content relevant they would spread it themselves (instead of organizational effort alone to scale).</li>
</ol>
<p> </p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2022-03-23-at-84734-pm.png" alt="" width="924" height="519" data-height="519" data-width="924"></img></p>
<p style="text-align: center;"><em>One of the posters used in Karnataka</em></p>
<p> </p>
<p>This creates the 3 major data points for each scan - which QR is scanned, when, and from where. This data (as explained in the technical section) allows for, people who created these QR codes, to understand the interest level in topics by village/block/district and over time. Based on this data community-based organizations can further engage with the communities on the topics of communities' interest - for better outcomes.</p>
<p> </p>
<h4>Technical Implementation</h4>
<ol>
<li>The diagram below explains how the system works. <a href="http://qrd.by">qrd.by</a> is a service (QRD) where one can design the QR code containing a hyperlink to the content which should be provided to the user upon scanning.</li>
<li>Once the user scans the QR code the user is first redirected to QRD. The QRD<span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);"> stores the location (if provided by accepting a pop-up message), DateTime, anonymized IP, a few other device details. The user is immediately redirected to the educational content.</span></li>
<li>Then (on a regular basis) the community engagement solution developed for this project, downloads this data from QRD.</li>
<li>The service uses then uses reverse geocoding service API provided by FES to resolve latitude/longitude data from QRD into the village, panchayat, block, district, and state information.</li>
<li>The service provides a dashboard (using <a style="font-family: var(--p-font-family); font-size: var(--p-font-size); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing); background-color: #ffffff;" href="https://datastudio.google.com/" target="_blank" rel="noopener noreferrer">Google Data Studio</a><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);">) based on all the data for organizations who created the QR codes and content, to understand the nature of engagement from the communities. This is achieved by securely exposing the PostgreSQL database to Google Data Studio.</span></li>
</ol>
<p> </p>
<p style="text-align: center;"><img src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2022-03-23-at-85730-pm.png" alt="" width="891" height="503" data-height="498" data-width="882"></img></p>
<p style="text-align: center;"><em>Conceptual Data Flow</em></p>
<p style="text-align: center;"> </p>
<p style="text-align: center;"><img src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2022-03-23-at-90032-pm.png" alt="" width="895" height="553" data-height="648" data-width="1049"></img></p>
<p style="text-align: center;"><em>Screenshot of dashboard</em></p>
<p style="text-align: center;"> </p>
<p style="text-align: left;"><strong>Conclusion and Possibilities</strong></p>
<p style="text-align: left;">It is important to mention that, the content to which the QR codes link can be continuously be improved upon based on feedback and changing times - with no on-ground work required.</p>
<p style="text-align: left;">The project is currently rolled out by <a href="https://www.fes.org.in/" target="_blank" rel="noopener noreferrer">FES</a> in Rajashthan, Odhisha, and Karnataka. If you have similar requirements please get in touch with us, FES, Arghyam, or Vrutti.</p>
<p style="text-align: left;"> </p>
<p style="text-align: left;"> </p>
<p style="text-align: left;"><strong>Author</strong>: Vivek Singh</p>
<p style="text-align: left;"><strong>Published On</strong>: 23-Mar-2022</p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-28-screenshot-2022-03-23-at-84734-pm.png" length="3083438" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2022-03-23T15:12:57+00:00</updated>
                    </entry>
            <entry>
            <title><![CDATA[Making Gunak - enabling journey from access to healthcare to quality of healthcare]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/making-gunak-enabling-journey-from-access-to-healthcare-to-quality-of-healthcare" />
            <id>https://www.samanvayfoundation.org/resources/making-gunak-enabling-journey-from-access-to-healthcare-to-quality-of-healthcare</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<h5><strong>Background</strong></h5>
<p>The first objective of the National Rural Health Mission (now just National Health Mission) was to provide access to the public healthcare system over almost the last two decades. As this objective is getting met to a great extent, the focus in the last few years has evolved from access to quality of health care provided in these hospitals and clinics. We are not experts but as we understand this quality involves - assessment/measurement, training/mentoring to improve quality, and certification. The scope of the Gunak system is helping in assessment and certification.</p>
<p>Towards this, we* have been engaged with <a href="https://nhsrcindia.org/" target="_blank" rel="noopener noreferrer">NHSRC India</a> in the development of Gunak for the last 5-6 years. Gunak is a software platform for various quality improvements programs run by the ministries of health (national and state) in India across the country.</p>
<p> </p>
<h5><strong>About the program</strong></h5>
<p>The public healthcare system consists of various types of health facilities (clinics, hospitals) right from health and wellness centers (for every half a dozen villages) to medical colleges (which are tertiary hospitals, one or more in number in each state). NHSRC (part of the national MoH) has been working towards improving the quality of these health facilities. These quality improvements are related to the core functioning of the hospitals, focus areas of maternal and child health, and the cleanliness of facilities (under Swatcch Bharat).</p>
<p>Following are the key activities involved in this.<br>1. Development of very detailed checklists on which the health facilities can be measured. The checklists do vary by the level of facilities, programs, and sometimes by state. Some of the checklists are shared <a href="http://qi.nhsrcindia.org/cms-detail/national-quality-assurance-standards/MTAx" target="_blank" rel="noopener noreferrer">here</a>, <a href="http://qi.nhsrcindia.org/cms-detail/musqan-initiative/MjQ4" target="_blank" rel="noopener noreferrer">here</a>, and <a href="http://qi.nhsrcindia.org/cms-detail/tools-for-kayakalp/MTA1" target="_blank" rel="noopener noreferrer">here</a> - under the tools section. For a quick feel of these checklists please see the images below.<br>2. Conducting training for quality assessors who can be internal or external. External assessors can be state or national-level assessors.<br>3. Verify assessments done by assessors and provide certification reports to the facility administrators.</p>
<p> </p>
<p style="text-align: center;"><strong>SAMPLE from KAYAKALP Checkpoints</strong></p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2022-03-05-at-54157-pm.png" alt="" width="724" height="468" data-height="468" data-width="724"></img></p>
<p> </p>
<p style="text-align: center;"><strong>Sample of NQAS Checkpoints</strong></p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2022-03-05-at-53144-pm.png" alt="" width="723" height="441" data-height="441" data-width="723"></img></p>
<p> </p>
<h5><strong>What Gunak does</strong></h5>
<p>Broadly, the scope of the Gunak system is to allow for management of the checklists and performing assessments. For context, the Gunak system supports:</p>
<ul>
<li>42 different types of assessment checklists</li>
<li>1,29,176 individual assessment units (called checkpoints) across them A single assessment may involve assessing thousands of checkpoints across various departments in a large hospital.</li>
<li>Gunak mobile is currently active on 9700+ mobile devices. These are assessors across the country who use the app to perform assessments.</li>
</ul>
<p>Technically the software system to support this must be able to do the following (apart from the regular functions of such a system):</p>
<ul>
<li>A platform for checklists where the users can define them instead of programmers. Essentially the checklists should be data and not code.</li>
<li>The assessors should be able to perform assessments and get insights into them from their own devices without unnecessary restrictions.</li>
</ul>
<p> </p>
<h5><strong>Main user components of Gunak</strong></h5>
<p>1. <strong>Mobile app</strong> which can be used by assessors to perform assessment while on the move within the premises of the hospital.<br>The mobile app allows for performing assessments without requiring the internet. Hospital buildings, the remoteness of some facilities, and the number of data points to be collected require the mobile app to work as efficiently as possible for the user.<br>The mobile app (<a href="https://play.google.com/store/apps/details?id=com.facilitiesassessment" target="_blank" rel="noopener noreferrer">available from Playstore</a>) doesn't require any login, except when the user wants to submit their assessments. The assessor can perform a basic analysis of scores on the device itself and share a CSV format of the assessments via email or other channels. The ability to perform assessments without login is a win-win. The people operating the system do not have to issue login to everyone (as there are many assessors who may be doing internal assessments). Certain types of assessments require login as they may result in rewards or official certificates given to them.</p>
<p> </p>
<p><img src="https://play-lh.googleusercontent.com/jGKQ9avLnPYn1DSADdeSEvYVvxi_9mdVtn32Wvn8LhU_6x6Zab31iB7q40RXRMSJTUp-=w1440-h798-rw" alt="स्क्रीनशॉट का चित्र" width="424" height="624" data-height="556" data-width="378"></img> <img src="https://play-lh.googleusercontent.com/B5qTQYoE57UGnHy47QnNtlw-s6kkRNSE6N06OJB1lQJXv219KFfDuccTenSbe30giZk=w1440-h798-rw" alt="स्क्रीनशॉट का चित्र" width="419" height="622" data-height="552" data-width="372"></img></p>
<p> </p>
<p><img src="https://play-lh.googleusercontent.com/-AJWQ6FIaFxhmKASy2TFTAzz7OulguPQjY8ROY4lhqykjY86WbYpDhHOkOSX-E7jvnY=w1440-h798-rw" alt="स्क्रीनशॉट का चित्र" width="415" height="614" data-height="584" data-width="395"></img></p>
<p style="text-align: center;"><em>Few screenshots of mobile app used by assessors</em></p>
<p> </p>
<p>2. <strong>Web application to manage the checklists</strong><br>Checklists are managed in two modes - bulk and corrections. Since a checklist could contain thousands of checkpoints entering them one by one is tedious and error-prone. Excel is a much better tool for this. Gunak supports importing checklists in excel form. Once checklists are imported into the system the Gunak provides the ability to edit them for making corrections, retiring them, adding new items.</p>
<p> </p>
<p>3. <strong>Dashboard and reports</strong> for various state and national stakeholders to understand and analyze the quality of health facilities, districts, states across various types of checklists.</p>
<p style="text-align: center;"> </p>
<p><img src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2022-03-07-at-113318-am.png" alt="" data-height="0" data-width="0"></img></p>
<p style="text-align: center;"><em>Comparison of average and median scores of various departments for a state (demo data not actual)</em></p>
<p> </p>
<p>4. <strong>REST API</strong> for other systems to access the checklists and assessments done using them.<br>Almost all the data managed in Gunak is available via REST API for third-party systems to integrate with. The API documentation is available <a href="https://app.swaggerhub.com/apis-docs/samanvay/gunak/1.0.0" target="_blank" rel="noopener noreferrer">here</a>. Gunak doesn't provide API for facilities because it integrates with the national registry for the same - hence for facilities, one must integrate with the national registry.</p>
<p> </p>
<p>The software for Gunak is available here - <a href="https://github.com/nhsrc" target="_blank" rel="noopener noreferrer">https://github.com/nhsrc</a></p>
<p> </p>
<p> </p>
<p><strong>* Disclaimer</strong></p>
<p>All the ideas about the domain and use cases came from specialists at NHSRC India. We have interacted very closely with (in no particular order) - Dr. J.N. Srivastava, Dr. Deepika Sharma, Dr. Nikhil Prakash, Dr. Rashmi Wadhwa, and Anand Yadav.</p>
<p>Folks at Samanvay have all worked in an *individual* capacity with NHSRC over the last 5-6 years.</p>
<p>The initial mobile app design was created by <a href="https://www.linkedin.com/in/varunpai">Varun Pai</a>.</p>
<p> </p>
<p> </p>
<p> </p>
<p><strong>Author</strong>: Vivek Singh</p>
<p><strong>Published on</strong>: 07-Mar-2022</p>
<p> </p>
<p> </p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-27-screenshot-2022-03-07-at-115137-am.png" length="452637" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2022-03-07T06:22:28+00:00</updated>
                            <dc:description><![CDATA[Short note on Gunak software system used in health programs for improving the quality of health services and facilities at public hospitals and clinics]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Deployment Architecture for Low Resource Contexts]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/deployment-architecture-for-low-resource-contexts" />
            <id>https://www.samanvayfoundation.org/resources/deployment-architecture-for-low-resource-contexts</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p><span style="font-size: 16px;"><a href="https://www.samanvayfoundation.org/resources/evolution-of-public-system-from-reporting-systems-to-point-of-work-systems">Point of work and reporting systems is one way to classify the low resource systems</a> (LRS). It classifies the LRS based on the objective of such systems. LRS when considered from a technical implementation perspective, can be classified differently. In this article, we shall try to understand the key features of LRS - when considered technically.</span><br><br><span style="font-size: 16px;">Technical architectures of LRS make them different because of two main constraints - availability of Internet and technical complexity of deployment. These constraints restrict what we can offer to the users and where.</span><br><span style="font-size: 16px;">a) The user dimension can be split into single-user or multiple users applications.</span><br><span style="font-size: 16px;">b) Further, these users can use the system in the facility or in the field (on the move).</span><br><br><span style="font-size: 16px;">Let's cross these two dimensions and see an example of each type of LRS.</span></p>
<p> </p>
<p><span style="font-size: 16px;">1. <strong>Single user in a facility</strong> - Classic data entry application</span><br><span style="font-size: 16px;">2. <strong>Multiple users in a facility collaborating with each other</strong> - Rural hospital system</span><br><span style="font-size: 16px;">3. <strong>Single user in the field</strong> - Community health worker application</span><br><span style="font-size: 16px;">4. <strong>Multiple users in the field</strong> <strong>collaborating with each other </strong>- Large health camps or refuge camps</span></p>
<p> </p>
<p><span style="font-size: 16px;"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2021-12-07-at-34013-pm.png" alt="" width="632" height="345" data-height="346" data-width="632"></img></span></p>
<p> </p>
<p><strong><span style="font-size: 16px;">1. Single user in a facility</span></strong><br><span style="font-size: 16px;">From an engineering standpoint, there aren't many interesting things about such systems. So let's jump to the rest three.</span></p>
<p><br><strong><span style="font-size: 16px;">2. Multiple users in a facility collaborating with each other</span></strong><br><span style="font-size: 16px;">Engineers who are used to developing software systems in high-resource environments have a very high probability of making mistakes here - based on our numerous discussions. The biggest illusion is that a progressive web app can be used because they provide higher availability of the application to the user despite poor internet. But the users need to collaborate with each other in real-time e.g. if the doctor orders a lab test, the pathologist should be able to view the order when the patient turns up in their department. Each of these two users having a PWA is not sufficient.</span><br><span style="font-size: 16px;">There are two options here.</span><br><span style="font-size: 16px;">a) Deploy the server on the premises of the hospital available to the users from LAN. This provides a great user experience but requires local technical support to deal with issues of network, server, power. At scale, with a lot of hospitals, this becomes quite an expensive proposition.</span><br><span style="font-size: 16px;">b) Use the service from the cloud, but each facility has two independent Internet connections. The higher the independence of these connections, the higher is the likelihood of Internet availability. We have not seen this tried out anywhere but seems like a good idea - and less resource-poor context can benefit from it.</span><br><br><strong><span style="font-size: 16px;">3. Single user in the field</span></strong><br><span style="font-size: 16px;">Offline mobile applications are now widely used in low-resource settings. In simple terms, each mobile device needs to keep ALL the data, for their work area, that the field user will require. Important again to highlight that offline applications are not typical PWAs - which can hold user-created data on the device and save when the internet is available. The issue with PWAs is that they do not hold all the data that the user needs - hence the application becomes useless in many use cases.</span><br><span style="font-size: 16px;">But there are certain issues with offline applications too.</span><br><span style="font-size: 16px;">a) At some point the volume of data even for a single work area becomes very large. This causes the first-time download of data to take a long time.</span><br><span style="font-size: 16px;">b) Management of data for clients moving from one work area to another is a tricky problem.</span><br><span style="font-size: 16px;">These are not insurmountable problems but they do require better engineering and user experience design to make it work. Even we in Avni have not fully tackled these.</span><br><br><strong><span style="font-size: 16px;">4. Multiple users in the field collaborating with each other</span></strong><br><span style="font-size: 16px;">Since this is the same as 2 but in the field. In 2, while technical operations are a challenge, in 4, deployment is also difficult. This requires multiple computing devices, having the applications and connected to each other. Given the technical complexity and place of technology in the hierarchy of requirements - such systems are not seen in the real world. Perhaps they may remain so.</span></p>
<p> </p>
<p> </p>
<p><span style="font-size: 16px;"><strong>Author</strong>: Vivek Singh</span></p>
<p><span style="font-size: 16px;"><strong>Published on</strong>: 07-Dec-2021</span></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-26-screenshot-2021-12-07-at-23059-pm.png" length="123120" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2021-12-07T09:05:36+00:00</updated>
                            <dc:description><![CDATA[We often discover that PWAs and cloud-based solutions, though applicable sometimes, but are often wrongly applied to low-resource setups. Hence, we attempt to develop a simple thumb rule for choosing deployment architecture for low-resource environments - with their tradeoffs.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Evolution of public system from reporting systems to point-of-work systems]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/evolution-of-public-system-from-reporting-systems-to-point-of-work-systems" />
            <id>https://www.samanvayfoundation.org/resources/evolution-of-public-system-from-reporting-systems-to-point-of-work-systems</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p><span style="font-size: 16px;">In a reporting software system (unlike point of work), the users don't use it when they are providing services to their clients (citizens). They use them later on, periodically, to report data about their work. Intuitively we like the point of work system, but it is the reporting systems that have dominated.</span></p>
<p> </p>
<p> </p>
<p><span style="font-size: 18px;"><strong>Why do reporting systems dominate?</strong></span></p>
<p><span style="font-size: 16px;">The success and dominance of dhis2, which is a reporting system, over the last 2 decades are because it understood three important aspects of technology for development. The first two have been understood well, the last one is appreciated much lesser.</span><br><br><span style="font-size: 16px;">1. No code &gt; Low code &gt;&gt; Programming - when it comes to distribution in LMICs. It pushes the cost down significantly, reduces project risk, requires less maintenance, and drives down the need to have developers available all the time.</span><br><span style="font-size: 16px;">2. Be a platform for both local tech communities, funders, and health organizations like WHO - making it easy for governments to get done.</span><br><span style="font-size: 16px;">3. Only reporting systems are feasible and point of work systems are not.</span><br><br><span style="font-size: 16px;">There is criticism of dhis2 based on what it offers as a user experience (not the user interface, which certainly can improve). The lament is that dhis2 is successful because of non-technical reasons. This is not true. The user experience offered by dhis2 is a natural outcome of the design of reporting systems. The real question is why point-of-work systems haven't succeeded.</span><br><br><span style="font-size: 16px;">Point of work and reporting system by example</span><br><span style="font-size: 16px;">Very simply, in such a system, the user does their work, and data gets generated and is useful for other purposes like reporting. Example of point of work system - a person doing vaccination of children is the user and the system offers workflow like - register, look up child, create a new immunization schedule, check due/overdue vaccines, give vaccine dose, so on. A reporting system on the other may be of one of the following types:</span><br><span style="font-size: 16px;">- At the end of the day report the number of jabs given, the number of children who came, missed jabs</span><br><span style="font-size: 16px;">- At the end of the day report child name, age, vaccine-given, etc.</span><br><br><span style="font-size: 16px;">The reporting systems can be quite sophisticated and can allow for longitudinal records, but essentially the design of such a system is to report and not to use previously reported data much, at least in ways that support the workflows of the user at the point of work.</span></p>
<p> </p>
<p><br><span style="font-size: 18px;"><strong>Reasons reporting systems dominate in governmental systems</strong></span></p>
<p><span style="font-size: 16px;">1. Point of work system requires a mobile device or a personal computer for each user. On the national/sub-national scale providing so many devices/computers to the users require a very large budget. Whereas with reporting system the users can use paper at their point of work and later use a common or public device/computer to report. Such implementations do decide the frequency of reporting based on the volume of data and availability/access of common/public computers.</span><br><span style="font-size: 16px;">2. The reporting of data from paper can be done by a data entry person as well (supporting several end service providers) - if everyone cannot be trained to use a computer or workloads.</span><br><span style="font-size: 16px;">3. A user who is once familiar with dhis2 can use the same product to report some other type of data for another program. Hence such users need less training subsequently.</span></p>
<p> </p>
<p><span style="font-size: 16px;">In short reporting systems are very cost-effective.</span></p>
<p> </p>
<p> </p>
<p><span style="font-size: 18px;"><strong>Point of work systems will replace reporting systems with economic growth/development</strong></span></p>
<p><span style="font-size: 16px;">As a country/state develops and can afford to spend more on technology, the reporting systems will have to give way to point of work systems. This is because the point of work systems can deliver significantly more value to all the users and stakeholders compared to a reporting system.</span><br><span style="font-size: 16px;">1. When software is used at the point of work, the user can become more effective and efficient - supported by features and data. They can provide better services to their clients (citizens) and provide feedback to the organization to improve the processes.</span><br><span style="font-size: 16px;">2. The quality of data generated is far superior because:</span><br><span style="font-size: 16px;">- Unlike in reporting where data moves from real-world to paper, then paper to the software system, in point of work it goes in straight.</span><br><span style="font-size: 16px;">- Data entry is quite mundane work and the users lose focus when they are entering data in bulk and they make mistakes.</span><br><br><span style="font-size: 16px;">Unlike reporting systems like dhis2 which can be developed once and used again and again, one will require many point-of-work systems for each domain-specific use case. This is likely to further elongate the life of reporting systems as it will be competing with all different quality of point-of-work systems.</span><br><br><span style="font-size: 16px;">Reporting systems will give way eventually, but they have served very well and they should get their due appreciation.</span></p>
<p> </p>
<p> </p>
<p><span style="font-size: 16px;"><strong>Author</strong>: Vivek Singh</span></p>
<p><span style="font-size: 16px;"><strong>Published on</strong>: 22-Nov-2021</span></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-25-screenshot-2021-11-22-at-122002-pm.png" length="131965" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2021-11-22T06:37:21+00:00</updated>
                            <dc:description><![CDATA[Public software systems are dominated by reporting systems due to cost reasons and not due to lack of technical imagination. As a country/state economically develops, the reporting systems will get replaced by point-of-work systems.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Domain expertise doesn&#039;t travel from high-resource to a low-resource setup]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/domain-expertise-doesnt-travel-from-high-resource-to-a-low-resource-setup" />
            <id>https://www.samanvayfoundation.org/resources/domain-expertise-doesnt-travel-from-high-resource-to-a-low-resource-setup</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p><span style="font-size: 16px;">In software development, it is well understood that product development requires knowledge of the domain in which the software will be used. People who have this knowledge are called subject matter (domain) experts or business analysts. For example, for developing a hospital system you require hospital administration understanding, or for a tax filing system tax-accounting knowledge.</span></p>
<p> </p>
<p><span style="font-size: 16px;">But, is hospital administration in a regular metro city hospital the same as the hospital administration in a rural (i.e. rural, tier-3, tier-4 city) hospital? At a technical level, it may appear that both have patients, departments, doctors, similar processes e.g. for outpatient registration-&gt;queue-&gt;doctor-&gt;test-&gt;prescription-&gt;pharmacy-&gt;home. One may use this understanding and develop a hospital management system - but will it work in the rural hospitals. We argue that a domain expert not exposed to the rural hospitals - will bake numerous bad decisions into the product, making it an inappropriate solution eventually. This phenomenon applies to many domains.</span></p>
<p> </p>
<ul>
<li><span style="font-size: 16px;">Let's take some examples of a rural hospital and understand how it is materially different from a tier-1 hospital.</span></li>
<li><span style="font-size: 16px;">Almost all patients do not take appointments before visiting the hospital. So if one develops a patient-facing appointment system, it is completely useless.</span></li>
<li><span style="font-size: 16px;">Patients are not good at keeping their older medical records. Hence usually hospitals tend to keep their record with them instead of handing it over to them.</span></li>
<li><span style="font-size: 16px;">Patient's phone number registered with the hospital changes all the time (either because their number changes or they provide different family members' numbers every time). As a result, patients take a lot of time at the registration desk - as the reidentification process takes a lot of time. The software should be sophisticated in this area.</span></li>
<li><span style="font-size: 16px;">Rural doctors see 2 to 3 times more patients. They simply do not have time to enter any data in the hospital system. Also, a token-based queue in front of the doctors' room is useless in rural setups, as many patients are not that literate to follow it. Usually, there is an usher.</span></li>
</ul>
<p> </p>
<p><span style="font-size: 16px;">You can read more about two other examples, recently in the news where this same phenomenon is in play.</span><br><span style="font-size: 16px;">a) COVID Vaccination system - <a href="https://www.livemint.com/opinion/columns/the-challenges-of-our-vaccination-drive-s-final-stretch-11631122982430.html">https://www.livemint.com/opinion/columns/the-challenges-of-our-vaccination-drive-s-final-stretch-11631122982430.html</a></span><br><span style="font-size: 16px;">The system developed a pull-based system i.e. citizens will take appointments/walk-in and take vaccines. But in a low resource setup, it works based on a push mechanism. Pushed by health workers. Secondly it the very basic mistake of assuming good internet.</span></p>
<p> </p>
<p><span style="font-size: 16px;">b) Nutrition system to be used by AWW - <a href="https://www.livemint.com/science/health/why-childcare-workers-are-suddenly-up-in-arms-11631117319254.html">https://www.livemint.com/science/health/why-childcare-workers-are-suddenly-up-in-arms-11631117319254.html</a> (use reader mode in firefox). Same and wrong internet assumption. Too complex workflows in the app.</span></p>
<p> </p>
<hr></hr>
<p> </p>
<p><span style="font-size: 16px;">Examining this as a software practitioner, we see that although we have a domain expert among ourselves but the domain in itself is quite different when we switch context to a low resource setup. We cannot assume even the basic understanding of low resource setup since most domain experts (like many urban folks) have almost never set their foot in such places - for any meaningful length of time. It doesn't come very naturally to someone who is in a high-resource setup.</span></p>
<p><span style="font-size: 16px;">In essence, we are dealing with an orthogonal dimension (see the diagram below) - to the extent that each domain expertise needs to be further qualified into a high resource (being default) and low resource.</span></p>
<p> </p>
<p><img src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2021-11-09-at-113023-am.png" alt="" width="643" height="449" data-height="732" data-width="1049"></img></p>
<p> </p>
<p><span style="font-size: 16px;">Broadly, the general low resource expertise consists of deeply understanding how the following factors impact the inner workings of the domain for which software is built. This is not an exhaustive list.</span></p>
<ul>
<li><span style="font-size: 16px;">Internet is not everywhere and/or is not available all the time.</span></li>
<li><span style="font-size: 16px;">Demand massively surpasses the supply of providers.</span></li>
<li><span style="font-size: 16px;">Local IT support is difficult to get and retain.</span></li>
<li><span style="font-size: 16px;">Client literacy levels are low.</span></li>
<li><span style="font-size: 16px;">Client finances are poor.</span></li>
<li><span style="font-size: 16px;">Clients have to work hard for their livelihood hence leaving less time for availing themselves of even important services.</span></li>
<li><span style="font-size: 16px;">Distances are high and play an important role (unlike cities)</span></li>
</ul>
<p> </p>
<p><strong><span style="font-size: 16px;">In software teams, we should strive to have domain experts who have low resource understanding to avoid having serious design mistakes in our solution.</span></strong></p>
<p> </p>
<p> </p>
<p><span style="font-size: 14px;"><strong>Author</strong>: Vivek Singh</span></p>
<p><span style="font-size: 14px;"><strong>Published on</strong>: 09-Nov-2021</span></p>
<p> </p>
<p> </p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-24-screenshot-2021-11-09-at-113023-am.png" length="145531" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2021-11-09T05:46:53+00:00</updated>
                            <dc:description><![CDATA[Lack of understand of the low resoiruce constraints is the underlying cause behind many poorly designed software. Low resource is its own cross-cutting domain requiring expertise in it.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Taking stock of the state of in-house lightweight data analysis]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/taking-stock-of-the-state-of-in-house-lightweight-data-analysis-1" />
            <id>https://www.samanvayfoundation.org/resources/taking-stock-of-the-state-of-in-house-lightweight-data-analysis-1</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p> </p>
<p><span style="font-size: 16px;">Nonprofit projects are adopting software and data systems for monitoring and tracking purposes. These are done through pre-developed dashboards and reports. But in this article, we look at whether organizations are doing data ad-hoc data analysis to gain insights about their work, what determines the success, and inherent challenges of nonprofits in analyzing the data in-house.</span><br><br><span style="font-size: 16px;">In-house data analysis in nonprofits is traditionally been done by using tools like SPSS, Excel, Stata, and R. There are trained public sector professionals who specialize in these tools. This approach fits projects that require research. Usually, this is done by someone who is not running the program but by a dedicated personnel/team. Let's call it heavyweight in-house data analysis and very few projects are required to do this.</span><br><br><span style="font-size: 16px;">But is there is a much wider need for in-house data analysis which can be done in few hours than few weeks?</span><br><span style="font-size: 16px;">1. People who run programs have questions and curiosity about their projects. Since they also have data, they want to query the data to get some rough answers to their questions. This is extremely important for the continuous improvement of the program.</span><br><span style="font-size: 16px;">2. When a project is completed, the software provider hands over dashboards and reports. Before the data is in place and the project is in full swing - it is very difficult to pin these down exactly. But when the data is in place (maybe due to lack of funds) the funds for software are exhausted.</span><br><br><span style="font-size: 16px;">Even when the best of the analytics and data warehousing tools are available, user-driven data analysis has a learning curve. Without the conceptual/intuitive understanding of entities/tables, relationships between them, grouping methods, drilling along dimensions, etc - there is a limit to how much one can do. Many tools allow the above using visual methods, but one still will have to tell it what it should do. The tool cannot do that by itself. Hence in my assessment, there is not that much scope for tools to help you further.</span><br><span style="font-size: 16px;">On the other hand, budgets are constrained hence paying a software provider to help with reports, dashboards on an ongoing basis is an expensive proposition.</span><br><br><span style="font-size: 16px;">Some organizations that have long-running programs have been able to learn and get better over time with data analysis. Shorter programs that run only for few months, do not provide the opportunity - hence unless one already has someone in-house who can do it, it doesn't materialize - given other responsibilities.</span><br><span style="font-size: 16px;">Secondly, what follows is that there should be some funds available (or not used upfront) so that the right type of dashboard, reports can be built at the right time.</span><br><br><span style="font-size: 16px;">Finally, economically speaking, one can argue that the value of such in-house ad-hoc analysis has not been recognized yet fully, or maybe the value isn't there (at least relatively speaking compared to other priorities). But if the value is there and once it is recognized an economic solution will emerge. Organizations will have in-house people to do the analysis, or have formal training in data analysis for their program people, or will have funds to hire technical support for such work. To a large extent, it is not a technology problem.</span></p>
<p> </p>
<p> </p>
<p><strong>Date published</strong>: 13-Oct-2021</p>
<p><strong>Author</strong>: Vivek Singh</p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-23-screenshot-2021-10-13-at-104708-am.png" length="94116" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2021-10-13T05:17:04+00:00</updated>
                            <dc:description><![CDATA[Affordable technology is available, but there are other issues to be tackled to allow for in-house data analysis in nonprofits]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Functional considerations for integrating community health and hospital systems]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/functional-considerations-for-integrating-community-health-and-hospital-systems-1" />
            <id>https://www.samanvayfoundation.org/resources/functional-considerations-for-integrating-community-health-and-hospital-systems-1</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p><span style="font-size: 16px;">The main objective of the integration of data between hospital and community programs is to make the patient/member health data accessible to the counterparties - so that better health services can be provided to them. This is explained in more detail <a href="https://medium.com/avni-bahmni-integration/introduction-and-context-c82c480e7de4" target="_blank" rel="noopener noreferrer">here</a>. For the integration between these software systems to be of value let's consider the following four scenarios.</span></p>
<p> </p>
<p><img src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2021-09-02-at-85755-pm.png" alt="" width="904" height="510" data-height="592" data-width="1049"></img></p>
<p> </p>
<p><img src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2021-09-02-at-90200-pm.png" alt="" width="903" height="501" data-height="496" data-width="894"></img><br><br></p>
<p><img src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2021-09-02-at-90535-pm.png" alt="" width="901" height="568" data-height="568" data-width="901"></img></p>
<p> </p>
<p><img src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2021-09-02-at-90956-pm.png" alt="" width="900" height="499" data-height="528" data-width="952"></img></p>
<p> </p>
<p><span style="font-size: 18px;">Common Identifier</span></p>
<p>It is perhaps obvious, but if this data has to be made available across these systems then we need an individual identifier (ID) or a reliable set of fields that can be used to link records. In Ashwini's case, community members are provided an ID in the community by the health workers. If the patient brings their ID card with them to the hospital then the hospital uses the same ID to register the person by putting some prefix to it which separates such patients from non-community patients.<br><br><em>Let's assume for the rest of this writeup that we have scenario 3 above as that allows us to explore all other issues that we may have to deal with - which may not arise in other scenarios.</em><br><br><span style="font-size: 18px;">Should a community member be automatically registered as a hospital patient by the integration process - if they are not present?</span><br>Automatically registering a patient in a hospital system may confuse the registration and hospital administration department - when the patient in future visits the hospital for the first time. It will also inflate the number of patients registered with the hospital, used for operational planning. <a href="https://bahmni.org" target="_blank" rel="noopener noreferrer">Bahmni</a> allows for keeping individual records without registration with the hospital - this provision is quite useful because if and when such patient visits for the first time, his/her community records will be ready to use after registration.<br><br><strong>Now let's look at the reverse.</strong></p>
<p>If there is a patient in the hospital but not present in the community program - should such a patient be automatically registered. Intuitively, we should follow the same as above but if a community program is where ID is provided then a member not existing indicates that something is wrong and hence better resolved manually.<br><br><span style="font-size: 18px;">Do not synchronize - Lab, Radiology Orders, and other workflow-related data</span><br>We decided that making these available in the community health system is not of much value. What community health workers will require is the results, not the order information. The order information is really about the workflow within the hospital. An even simpler example is if the hospital provides a token number to the patient, it is not all that relevant to anyone after the patient leaves the hospital. Making such records available in the community health system is not very useful.<br><br><span style="font-size: 18px;">For the inpatient, records synchronize only discharge summary</span><br>Making the outpatient clinical records available to the community health worker is quite useful. But when a patient is admitted to a hospital the s/he is prescribed and administered several medicines and many tests are conducted. We thought that making all these drug orders and lab results available to the community health worker is not going to be helpful (too much detail, perhaps also requires deeper clinical understanding to make sense of it). As in the same way, a patient rarely uses/requires such inpatient records after one is discharged. Patients mainly use discharge summaries. We decided to do the same for the integration, i.e. in case of inpatient visits, we synchronize discharge summary with the community health system and leave out drugs administered and lab results.<br><br><span style="font-size: 18px;">Hospital record drives the workflow of CHW, but the reverse is not true</span><br>Let's say if a woman delivers in the hospital. When she is discharged the CHW should follow up with her (and her child) for post-natal care (PNC). This implies that there must a be mechanism by which CHW can find out this information. There are a couple of features in Avni (the CHW system) that help here - Avni provides a dashboard where CHW can find such women from their catchment and perform the next step. <a href="https://avniproject.org/" target="_blank" rel="noopener noreferrer">Avni</a> android app performs periodic auto-sync which ensures that hospital records are made available at the earliest.<br>The follow-up within the community after someone comes back from the hospital to CHW needs to be supported digitally because CHW's role is to provide proactive care. The same is not true for the hospital. Hospitals typically provide care only when a patient visits the hospital. Hospitals are not structured to provide <em>proactive</em> health services. In fact, the workflow from the CHW to the hospital is also facilitated by the CHW - by asking patients to visit the hospital. Hospitals are reactive setups.</p>
<p> </p>
<p><br>To summarise the integration between community health and the hospital system should be based on understanding how patients behave and how community programs and hospitals operate. Lastly, the integration should leave difficult decisions of deduplicating individuals, deleting records, when to register, when to enroll in or exit from disease programs to the humans - because doing them automatically can create difficult-to-resolve data problems and may impact health services provided to an individual. Following do no harm is a good thumb rule.</p>
<p> </p>
<p> </p>
<p><strong>Author</strong>: Vivek Singh</p>
<p><strong>Date</strong>: 03-Sept-2021</p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-20-screenshot-2021-09-03-at-33356-pm.png" length="84429" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2021-09-03T10:04:02+00:00</updated>
                            <dc:description><![CDATA[Making the community health and hospital systems data available to each other holds promise to improve health outcomes for the community member/patient. If you are planning or considering doing something like this, this article may help uncover certain issues beforehand and may help you make the right decision.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[The challenge of building technology team in nonprofit organisations]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/the-challenge-of-building-technology-team-in-nonprofit-organisations" />
            <id>https://www.samanvayfoundation.org/resources/the-challenge-of-building-technology-team-in-nonprofit-organisations</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p><span style="font-size: 16px;">The usage of software and technology in nonprofits is increasing. Nonprofits use software that are general purpose like office tool, video conferencing, excel, etc. But there are also solution that are specific to the sector (customisable products) or to be custom made for an organisation. Acquiring or developing them requires access to software development professionals. There are various ways in which the organisations can go about it.</span></p>
<ol><li><span style="font-size: 16px;">Hire external software service provider for software project execution</span></li>
<li><span style="font-size: 16px;">Do long term partnership with a software service provider</span></li>
<li><span style="font-size: 16px;">Hire senior technology person inhouse and do one of 1 or 2 for junior people, or hire junior technology people inhouse and do one of 1 or 2 for senior people</span></li>
<li><span style="font-size: 16px;">Develop in-house software team</span></li>
</ol><p><span style="font-size: 16px;">To help you decide what is the right choice for you, lets us lay down a few fundamental issues that have a bearing on it and how it impacts the outcome. </span></p>
<p> </p>
<p><span style="font-size: 16px;">It is found that software teams understand less about your nonprofit ecosystem, organisation's context, and their requirements - since they often do not work for nonprofits. It is common to hear from nonprofits that communicating requirements and expectations is one of the biggest challenges. A common complaint is - <em>"they (software people) just don't understand what we are saying and we don't understand what they tell us".</em> Needless to say, this leads to unsatisfactory outcomes. </span><span style="font-size: 16px;">This drives nonprofits towards seeking to develop in-house software teams as a solution. The logic is right but the conclusion is not. Let us see why.</span></p>
<p> </p>
<p><span style="font-size: 16px;">Talented software professionals like working in teams where they can learn from each other about technology, design, etc. They also prefer a working culture suited for technologists. We cannot explain what this culture means, as it would take up a lot of space. But the key is that this culture is unique and is not easy to re-create/replicate in small embedded teams within large non-technology organisations. </span><span style="font-size: 16px;">Hence when non-profits try to create in-house teams, the inability to hire the right skills, high attrition rates, short tenures etc - plague them. There is also the issue of compensation, which is well known and plays an important role too. Many organisations which have tried, find it extremely difficult to keep a stable team in house.</span></p>
<p><span style="font-size: 16px;">(here it must be said that there are exceptional individuals who are beyond these rules for their own special reasons)</span></p>
<p> </p>
<p><span style="font-size: 16px;">So what should organisations do? Before we get to that it is worth reminding that the need for software teams is <em>a second-order question</em>. The first-order question is - do you need your own software built or can you use a product already available or customise one. Even if one customises an existing product, the demand for having a technical team reduces significantly. With that dealt with, let us get back to the question at hand - </span><span style="font-size: 16px; font-family: var(--font-family);">what should organisations do, if they do need a software team.</span></p>
<p> </p>
<p><span style="font-size: 16px;">We believe that - partnering with software organisations that have a good understanding of the social sector is a sustainable long term approach. One can offload the problem of developing a technology culture and competence to the partner - who can focus on that part. Please also note that we have are saying partner, not provider. A partnership most importantly develops understanding of your organisation within the people of software organisation.</span></p>
<p> </p>
<p><span style="font-size: 16px;">Finally, what about the other hybrid approach mentioned in point 3? We reckon that in theory, it is easier to have an inhouse senior person working with the external software team. But this runs the risk of a single point of failure which one needs to reconcile with. Lack of continuity can be quite challenging especially if technology is strategic to your organisation.</span></p>
<p> </p>
<p> </p>
<p><span style="font-size: 16px;"><strong>Conclusion</strong></span></p>
<p><span style="font-size: 16px;">Professionals like doing work they find meaningful. Finding meaning is usually not an issue in the social sector. But professionals <em>also</em> seek fulfilment from their work which they get by applying themselves fully and constantly getting better at what they do. Meaningful work without fulfilment is insufficient and is not sustainable. A software provider can afford to assemble a larger group of people, in which people can be inspired and learn from each other, as it serves multiple organisations. This also provides opportunity for people to work on different problems - which will be difficult working in a single nonprofit.</span></p>
<p> </p>
<p> </p>
<p><span style="font-size: 16px;"><strong>Published on</strong>: 07-Jan-2021</span></p>
<p><span style="font-size: 16px;"><strong>Author</strong>: <a href="https://www.linkedin.com/in/vivek-singh-4535a61/" target="_blank" rel="noopener">Vivek Singh</a></span></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-17-developer-coding-in-php.jpg" length="1520280" type="image/jpeg" />
                        <category term="Nonprofit and Software" />
            <updated>2021-01-07T09:37:50+00:00</updated>
                            <dc:description><![CDATA[More and more nonprofits have to think about, how should they get the software developed for themselves. Should they outsource or have in-house teams or do something else? We go through the challenges in each of the approaches and what are the sustainable options.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[What does it mean to use open source?]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/what-does-it-mean-to-use-open-source" />
            <id>https://www.samanvayfoundation.org/resources/what-does-it-mean-to-use-open-source</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<blockquote>
<p><span style="font-size: 16px;">If I use open source then does it mean that</span></p>
<p><span style="font-size: 16px;">...everyone will have access to our data?</span></p>
<p><span style="font-size: 16px;">...we have to give our data to the organisation which provided us with the software?</span></p>
<p><span style="font-size: 16px;">...anyone can change the code and introduce defects in our system?</span></p>
<p> </p>
</blockquote>
<p><span style="font-size: 16px;">These are actual questions that get asked by our nonprofit customers. We usually take a step back and discuss what is software, how it's ownership works, data, and hosting. In this article, we go through the same process and try to explain this in as simple terms as we can.</span></p>
<p> </p>
<p><span style="font-size: 16px;">These questions are not about licensing but what is the overall "customer experience" of open source. Through these conversations, we have understood that it is about - "open source" "software" and "reusable products". We have gathered that we cannot explain open source alone without explaining about software and product as well. But to keep the article shorter, we would stick to work-software-products that is used by organisations (like donor management system, accounting systems) and not by individuals for personal/official use (like MS Office, browser, WhatsApp etc).</span></p>
<p> </p>
<p><span style="font-size: 16px;">Let's start by understanding what is software. Each software project exists in two forms - as passive source code in forms of text files, and as a running package on the server or your device. Please see the diagram below.</span></p>
<p> </p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni1-1.jpg" alt=""></img></p>
<p> </p>
<p><span style="font-size: 16px;">Let us expand the server a bit to see that the server also has your data stored in the database.</span></p>
<p> </p>
<p><span style="font-size: 16px;"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni3-16087155839504.jpg" alt=""></img></span></p>
<p> </p>
<p><span style="font-size: 16px;">The power of software, unlike physical goods, is that it can be copied any number of times - provided it is functionally reusable (e.g. an organisation's website code is likely to not reusable for other companies). Hence we can provide it to multiple organisation at almost no additional cost. But, when we do that it is important to note that each organisation has its own servers running the software and their own databases.</span></p>
<p> </p>
<p><span style="font-size: 16px;"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni2.jpg" alt=""></img></span></p>
<p> </p>
<p><span style="font-size: 16px;">Now let us get back to the top part of the above diagram - the three arrows. Even though the software has the ability to be copied an infinite number of times, there are legal and commercial restrictions to it. The organisation which owns the software programs decides who gets the software - usually with permission and fees. The other difference is that the organisation usually provides only the installable files and not the source programs. This is because mostly the customer organisation doesn't have much use for the source code.</span></p>
<p> </p>
<p><span style="font-size: 16px;"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni4-1608715828519.jpg" alt=""></img></span></p>
<p><span style="font-size: 16px;">Let us look at the ownership of each of the pieces now.</span></p>
<p> </p>
<p><span style="font-size: 16px;"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni5.jpg" alt=""></img></span></p>
<p> </p>
<p><span style="font-size: 16px;">Now let us look at how it works in case of open-source software. The software source code and installable are both available free of cost publicly and anonymously. That is, you don't need to pay anything, take any permission, nor do your need to tell anyone. Like, commercial software earlier, you retain the ownership of the server and database.</span></p>
<p> </p>
<p><span style="font-size: 16px;"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni6.jpg" alt=""></img></span></p>
<p> </p>
<p><span style="font-size: 16px;">With that context, let us try to answer the questions at the top of this article.</span></p>
<p><strong><span style="font-size: 16px;">1. Does opensource mean everyone will have access to our data?</span></strong></p>
<p><span style="font-size: 16px;">As you can see from the diagram above, there is no relationship between your data and whether the software is open source or not. Your data is owned by you.</span></p>
<p> </p>
<p><strong><span style="font-size: 16px;">2. Does opensource mean we have to give our data to the organisation which provided us with the software?</span></strong></p>
<p><span style="font-size: 16px;">Again as you can see in the diagram, the open-source software provider (community) doesn't impose any such conditions on the users of their output. While they would like attributions, it is not binding.</span></p>
<p> </p>
<p><strong><span style="font-size: 16px;">3. Does opensource mean anyone can change the code and introduce defects?</span></strong></p>
<p><span style="font-size: 16px;">...since anyone can copy the code and change it. Let us look at what would happen in this case. The diagram below has a couple of examples of such copying - one by another open source community or by someone in your organisation. Pertaining to the question - other people can make changes to the code but to their "own version" of it and their version generates their own installers. It doesn't affect the software that you are running from your provider (community 1).</span></p>
<p> </p>
<p><span style="font-size: 16px;"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni7.jpg" alt=""></img></span></p>
<p> </p>
<h5>Conclusion</h5>
<p><span style="font-size: 16px;">One of the goals of this publication is to reduce information asymmetry between software providers and nonprofits. There are a number of misconceptions about the open-source which are not in the interest of nonprofits. In fact, we believe that given the public nature of the work open source and nonprofits are naturally aligned with each other. Finally, if there are other topics/questions about open source that you would like us to write about, please do contact us.</span></p>
<p> </p>
<p> </p>
<p><span style="font-size: 16px;"><strong>Author</strong>: <a href="https://www.linkedin.com/in/vivek-singh-4535a61/" target="_blank" rel="noopener">Vivek Singh</a></span></p>
<p><span style="font-size: 16px;"><strong>Published On</strong>: 23-Dec-2020</span></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-16-avni6.png" length="93126" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2020-12-23T10:05:29+00:00</updated>
                            <dc:description><![CDATA[The term open source often invokes fear in nonprofit organisations about whether it implies a lack of control over data and software behaviour. It is mistaken with open data, open API, free-for-all software. In this article, we explain open-source software from basics from a customer experience standpoint.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Factors to consider when procuring mobile devices]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/factors-to-consider-when-procuring-mobile-devices" />
            <id>https://www.samanvayfoundation.org/resources/factors-to-consider-when-procuring-mobile-devices</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>Mobile devices get increasingly used by frontline workers which are procured by nonprofits and provided to them. These devices need to be procured in bulk and hence it becomes important that the right decision is made. Let's look at various factors we should consider.</p>
<p> </p>
<p>Perhaps this is obvious but better to get this out of our way. When we are discussing mobile devices it is implicit that it is an android device :-). In our experience, we have never seen anyone consider iOS devices because of the cost.</p>
<p> </p>
<h5>Form factor</h5>
<p>Usually, a large screen device of around 6 inches serves most needs of the frontline work. There may be scenarios where even higher form factor may be ideal - like showing videos to a group, performing complex work with maps etc.</p>
<p> </p>
<h5>Tablet or Mobile</h5>
<p>The answer overwhelmingly is to procure a mobile device. The fundamental reason being that android tablet market overall is very small compared to mobile. This has led to much better make quality and choices - for the price.</p>
<p><strong>Battery life</strong></p>
<p>The frontline worker is likely to use the device for work for 2-3 hours daily, hence one must choose devices with higher amp-hours battery.</p>
<p><strong>Pocket/Purse friendliness</strong></p>
<p>Pocket friendliness of mobile devices is quite an important factor from wear and tear perspective. Tablet devices being larger require a separate bag/box which is not only cumbersome to carry around (frontline work involves a lot of travel) but also prone to getting damaged during travel/movement. <span style="font-family: var(--font-family); font-size: var(--base-font-size);">Pocket/purse is the best place for convenience and long life of the device.</span></p>
<p> </p>
<h5 style="margin-bottom: var(--heading-margin-bottom); font-size: calc(var(--heading-ratio) * 1rem); font-weight: var(--h5-font-weight); line-height: var(--h5-line-height); letter-spacing: normal; font-family: Lato; text-shadow: var(--h5-shadow);">Personal device or work only device</h5>
<p>Should the frontline worker be expected to use the device for personal purposes or only for work? This is quite tricky to answer emphatically - hence we would only list down factors and let you make the decision.</p>
<ul><li>Mobile device with the Internet is such a promising instrument for human learning and development that restricting its use - feels criminal.</li>
<li>But, when the device is allowed to be used for personal reasons it can result in various issues like virus, excessive use (limiting its overall life), running out of mobile data quota. Allowing personal use can also result in the device not being available for the intended purpose itself - because of potential "misuse".</li>
</ul><p> </p>
<h5 style="margin-bottom: var(--heading-margin-bottom); font-size: calc(var(--heading-ratio) * 1rem); font-weight: var(--h5-font-weight); line-height: var(--h5-line-height); letter-spacing: normal; font-family: Lato; text-shadow: var(--h5-shadow);">Electricity</h5>
<p>If homes of frontline workers are plagued by long and regular power outages then we should choose a device which has fast charging facility. One can consider using power banks if electricity supply is even poorer.</p>
<p> </p>
<h5 style="margin-bottom: var(--heading-margin-bottom); font-size: calc(var(--heading-ratio) * 1rem); font-weight: var(--h5-font-weight); line-height: var(--h5-line-height); letter-spacing: normal; font-family: Lato; text-shadow: var(--h5-shadow);">Backup devices</h5>
<p>We have often found that an exact number of devices as the frontline workers are procured. When some frontline workers devices breakdown they switch back to the paper system. Such arrangements send mixed signals to the frontline workers - that paper system and digital system both must be maintained. This is sub-optimal and to some extent defeat the purpose of having a digital system.  We recommend that backup devices must be planned for and to be made available in case of breakages.</p>
<p> </p>
<p> </p>
<p><strong>Author</strong>: <a href="https://www.linkedin.com/in/vivek-singh-4535a61/" target="_blank" rel="noopener">Vivek Singh</a> and <a href="https://www.linkedin.com/in/arjun-khandelwal-41614b8/" target="_blank" rel="noopener">Arjun Khandelwal</a></p>
<p><strong>Published On</strong>: 11-Dec-2020</p>
<p> </p>
<p><em>Cover photo by <a href="https://pixnio.com/objects/electronics-devices/iphone-pictures/mobile-phone-gadget-technology-modern-telephone" target="_blank" rel="noopener">pics_pd</a> on <a href="https://pixnio.com/" target="_blank" rel="noopener">Pixnio</a></em></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-15-pixnio-273571-900x598.jpeg" length="132116" type="image/jpeg" />
                        <category term="Nonprofit and Software" />
            <updated>2020-12-11T08:21:01+00:00</updated>
                            <dc:description><![CDATA[As mobile devices get increasingly used by frontline workers the question of what is the best device for such usage gets frequently asked by nonprofits to technology advisers. In this article, we discuss various factors one should consider when procuring these devices for frontline workers.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Why it is difficult to implement a useful national personal health records system]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/why-it-is-difficult-to-implement-a-useful-national-personal-health-records-system-1" />
            <id>https://www.samanvayfoundation.org/resources/why-it-is-difficult-to-implement-a-useful-national-personal-health-records-system-1</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>I fully appreciate the value of having an integrated digital personal health record which I can use when I go to the doctor, monitor my own health, save money from repeated tests, carry papers, the anxiety of losing records, and so on — and do all of the same for my family members too. Creating this is a noble idea. But it is difficult to implement. It is difficult even for governments to do this. I would try to go into the details of why it is done so and make it useful. (I fully understand that there is a privacy, data exploitation aspect of this too — and am sure many people have written about it, I am not focussing on that here).</p>
<p> </p>
<h5>Where our important health records are stored?</h5>
<ul><li>Independent laboratories</li>
<li>Radiology (X-Ray, MRI, Ultrasound) centres</li>
<li>Clinics</li>
<li>Hospitals</li>
</ul><p>(in India pharmacies do not keep much health record of you as they are mostly like shops)</p>
<p> </p>
<p>Of these, laboratories and radiology centres, usually are technically geared up and they could email you a PDF file of results if you ask for it. Lab Information System and Radiology Information System are common and your diagnostic results are kept in structured &amp; digital form here.</p>
<p>Clinics are digitally least equipped. Well equipped ones may have an appointment system and billing system, but that's not what we are talking about here. All health records in clinics are in paper-pen form.</p>
<p>Hospitals are more complex places. One way to understand them is to consider them as a combination of lab, radiology and clinic plus few more like inpatient/critical-care wards, operation theatres and emergency. Now from a digital perspective, the following could be said about many hospitals in urban areas.</p>
<ul><li>Interestingly you do not readily get a PDF file from radiology and lab in a hospital. Unlike independent diagnostic centres, their business is not about producing this output (PDF file) as most of the times the output given to the doctors (who use paper records readily since it is a lot easier for them).</li>
<li>All the examination, assessment, diagnosis and treatment details are on paper. Primarily because the workload on doctors is way too high and EMR technology is not mature enough yet to solve this problem. I know this from personal experience of developing <a href="/design/http" target="_blank" rel="noopener">Bahmni</a> and is also well documented in the book <a href="https://www.goodreads.com/book/show/23131174-the-digital-doctor" target="_blank" rel="noopener">Digital Doctor</a> (highly recommended).</li>
<li>Good hospitals are great at doing operational things using technology (billing, inventory, appointment, registration, bed assignment and so on) since this has economic value. But when it comes to your clinical record, it is all paper. Some may keep scanned copies, but that's mostly to solve the archival problem, medical records do take up expensive real estate.</li>
</ul><p>I have purposefully painted a picture that is true for urban setup, then for rural or resource-poor setups, because I can imagine, rural hospitals replicating this over time — having done many of these myself, as part of <a href="https://bahmni.org" target="_blank" rel="noopener">Bahmni</a>. Government hospitals are more difficult because of resources, but it could be done in operational areas of the hospitals.</p>
<p> </p>
<h5>Let's examine the technology solution space</h5>
<p>Broadly…</p>
<ul><li>India luckily has had good IT capacity in the country leading to widespread implementation of software systems across the private eco-system (profit and non-profit) and to some extent in public too.</li>
<li>We perhaps have hundreds (touching maybe even thousands) of software vendors who have health information system business, having one or more products in the area.</li>
<li>If we count all the lab, radiology, clinic, hospitals systems we must have tens of thousands of distinct software running across the country (I mean unique software codebases). Sometimes even in a single large hospital, there are multiple software running e.g. different departments running their own specialised (or even non-specialised) software.</li>
<li>Almost all of them have been built without any agreed standard for storage and communication of medical records. The reason is simple if a hospital wants to shell out only 10–15 lakhs for software, the software vendor cannot find engineers and domain experts, who understand HL7, SNOMED, ICD10, and then implement it in the code (radiology images are an exception to this). In such competitive ecosystems (of hundreds of software vendors) this is expected. I do not blame the hospitals/clinics too, these standards make software expensive and economic value is non-existent.</li>
</ul><p> </p>
<h5>Realising the value of personal health records</h5>
<p>I have also been part of developing personal health records in the past, and I think that, developing a cloud-based, API based, secure, generic, extensible, downloadable — personal health record service is doable and fulfilling to develop. It is not very expensive to build it, especially when one is doing it for the whole country, the comparative fund for this is negligible.</p>
<p>But what happens after we have an API in the cloud? <em><strong>How does the data come into it, such that it is useful for citizens?</strong></em></p>
<ul><li>Obvious idea is that all these Labs, Radiology, Clinics and Hospitals must integrate with it. But this is not a one time work. <em><strong>Each one of these tens of thousands of the systems needs to be enhanced independently.</strong></em> There is no module that one can just stick into this software and they will simply integrate— remember they don’t talk in standards. Standards for data, metadata, data transfer, protocols — nothing. Who will pay for this? Once you start examining these systems, you would find all sorts of software — including ones developed by someone’s relative for free, who doesn’t write software anymore. Software integration requires better skills that writing applications.</li>
<li>The other idea is to take a few good software, that already integrates with the API and ask everyone to only use “certified” software. What would happen to the rest of the software vendors?  Who would pay for the replacement? This is not practical and cost-effective either.</li>
<li>Let's keep ideating. What about placing data entry persons in each hospital? They feed in data directly into the personal health records system. Even if we set aside the cost of salary of data entry person, which hospitals now need to bear — what would be the quality of such health records? Remember our health records are very technical to understand, plus not always very legible.</li>
</ul><p> </p>
<p>I have been involved in brainstorming this even for a network of hospitals dealing with Cancer, which is much smaller scale, but pulling this off seemed like a mammoth task — for the same set of reasons.</p>
<p>There are examples of other countries where this has been tried and we can learn from this (I would love it if it can be done, ensuring privacy issues are well taken off). But it is important to understand that <strong>we do not have <a href="http://leapfrog.cl/en/leapfrogging" target="_blank" rel="noopener">leapfrogging</a> advantage in this case</strong>, applicable in other infrastructure/technology rollouts. The fact that we have been successful at digitising our hospitals etc, is a disadvantage in this case, sadly. Many countries who do not have this advantage may be able to leapfrog*, but for India, it seems difficult, quite difficult.</p>
<p> </p>
<p><em>*Poorer countries have to decide whether to spend on personal health record systems or spend that limited fund for buying medicines, setting up hospitals, labs, paying doctors. The choice then becomes obvious.</em></p>
<p> </p>
<p> </p>
<p><strong>Published on</strong>: 18-Jul-2018</p>
<p><strong>Author</strong>: <a href="https://www.linkedin.com/in/vivek-singh-4535a61/" target="_blank" rel="noopener">Vivek Singh</a></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-11-nounmedical-records2312111.png" length="15225" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2020-11-19T10:21:40+00:00</updated>
                            <dc:description><![CDATA[Creating personal health records is a noble idea. But it is difficult to implement even for governments. We explain why is it difficult.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Technology architecture for public health service delivery and why designing system for PHC is difficult]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/articles/on-software-architecture/technology-architecture-for-public-health-service-delivery-and-why-designing-system-for-phc-is-difficult" />
            <id>https://www.samanvayfoundation.org/articles/on-software-architecture/technology-architecture-for-public-health-service-delivery-and-why-designing-system-for-phc-is-difficult</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>Health services are delivered in four kind of setups, illustrated by the following matrix — between resource availability and service team size (number of people working together to provide the service to their clients aka patients). It will become clear why I have chosen to highlight the number of people as a factor, because it is an important aspect of designing such systems, but not because of scale.</p>
<p> </p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/1pbjj7lpfvzcefzmvulsktw.jpg" alt=""></img></p>
<p>With this diagram, I am also trying to highlight that, resource availability takes a significant jump from secondary hospitals (running at district head-quarters) to tertiary hospitals in cities. As far as workload per staff is concerned, it is roughly the same throughout (or in the same order of magnitude).</p>
<p> </p>
<p><strong>What characterises a low resource setup though, from a technology rollout perspective?</strong></p>
<ul><li>Poor quality Internet (speed, latency, uptime, intermittency)</li>
<li>Low proficiency levels of (presumed) users</li>
<li>Low absolutely of IT support and administration personnel</li>
<li>Lack of funds for tech</li>
</ul><p>Since many systems have been designed for large organisations in abundant resource setups, I will not delve into the architectural characteristics of such systems— there is more than sufficient material on this. Also, to highlight an architectural blind spot, I will get into the Primary Health Centre last.</p>
<p> </p>
<p><strong>Why do we need software systems in health service delivery setups?</strong></p>
<ul><li>Management of the facilities' operations (hospital/clinic/centre)</li>
<li>Storage and retrieval of health records of the clients</li>
<li>Standardising the work</li>
<li>Improving the availability of data within the organisation</li>
<li>Work-schedule management (applicable to primary and frontline healthcare which is proactive in nature — e.g. screening, followup)</li>
</ul><p>Given this background of needs, context — let us try to examine the technical architecture constraints and options at each level.</p>
<p> </p>
<h5>Rural hospitals — District Hospital (DH) and Community Health Centres (CHC)</h5>
<p>All hospital systems need to be highly available (one cannot afford to make the patients wait or have long queues because “system is down or slow”). Rural hospitals of this type are at district headquarters or places like it. Most district headquarters in India are not so well connected to have a highly available Internet connection — essentially ruling out the possibility of running such systems off the Internet*. One needs to run the server in a local area network (LAN) so that the connectivity is good and response time is small.</p>
<p>Running server in a hospital requires a local IT team to support the server, application, network and the user devices/machines. If this has to be done in hundreds of hospitals (for state government, missionary hospital chains), it becomes expensive and dependent on human capacity.</p>
<p>This not to suggest that it is technically not possible, some motivated organisations have been able to do this (running local IT setup) and as we get richer as a country, more hospitals will be doing the same, but at the scale it is difficult. One important thing to note is that the health data of patients is available only from the internal network of the hospital and is not available to someone who is outside the hospital (for example doctors who consult remotely or want to provide an opinion in certain cases). There are a few options:</p>
<ul><li>Buy public IP and setup VPN (but poor Internet bandwidth and knowledge of how to connect via VPN acts as a barrier)</li>
<li>Publishing data centralised server is an option (the cost of the software and operating further increases the economic burden on non-profit or public hospital)</li>
</ul><p><em>* One can definitely run systems off-Internet that do not make patients wait if the Internet is down. e.g. Inventory management, periodic reporting system, etc.</em></p>
<p> </p>
<h5>Front line health workers</h5>
<p>On another extreme end of service delivery hierarchy are Frontline Health Workers (FHWs), who usually work by themselves in villages or in outposts alone, covering few villages. So, when one thinks of bringing digital technology to these workers, helping them in their work, the first thought is — well there is no Internet. But thankfully there are android devices — robust full-fledged computers with few GBs of storage.</p>
<p>First, let’s step back and understand the context of FHWs and their work. They are responsible for small areas. At sub-centre an ANM works alone. A sub-centre area is roughly five villages, i.e. around 5 thousand population — let’s call this their service area. Similarly, a village level worker, e.g. ASHA, is responsible for one village. ANM, ASHA and similar FHWs’ work require them to have historical primary health data of all the people in their service area, with them (i.e. without requiring Internet connection).</p>
<p>If we calculate how much data this really is, we would see that it is not all that much. At the rate of 25 KB per citizen, we are looking in the ballpark of 125 MB. Modern Android devices can handle this much data in databases like SQLite or Realm — in hands of good developers, providing great performance. Once this seems feasible, we have found a way out of Internet quality problems.</p>
<p>Each FHW can carry these android devices with work-app and complete database of their service area. Usually, this data is required by people in other parts of their organisation like medical officers, program designers, ministry. But this access though is not needed in real-time. In most scenarios, a delay of even a day is fine, in some scenarios even more. This allows for FHWs application to perform incremental sync (sync = send and receive data; incremental = any data not known to the other end) of the data with a central server, whenever Internet becomes available.</p>
<p>Few challenges still remain (but largely this is a viable and useful solution)</p>
<ul><li>Sometimes users want to keep a copy of data on paper, in case their device is not working then they cannot access the records to provide the service — even though this feels wasteful. But even in this scenario the fact that the FHW doesn’t have to travel miles to file monthly reports is a big plus — to name one.</li>
</ul><p> </p>
<h5>Primary Health Centres (PHCs)</h5>
<p>There is one primary health centre, per 5–6 sub-centres, so we are talking about roughly 30 villages now in a PHC area. The typical rural primary health centre has (rather is supposed to have) a doctor, a nurse, a small laboratory, a small pharmacy and a registration person.</p>
<p>When designing software systems for PHCs, usually it is approached from two ends i.e. either thinking of it as a smaller hospital or a collection of front line workers in a facility. But both of these are fallacious approach. Let us see why.</p>
<p>When PHC is considered a smaller hospital, one tries to put a server (even if smaller in specs or running in one user’s desktop) in each PHC — running an application server and a database. But, there way too many PHCs than District/Community Hospitals — multiplying all the operational challenges listed above for the district hospital. The operational expense for support is too high for it to be acceptable. Just the user by themselves, cannot support this server and network to connect to it.</p>
<p>The other approach is, to think of PHC as a collection of field health workers. Hence instead of hosting the server locally, it is put in the cloud, and each user has an app like FLW has, fully capable in offline mode. But this design is flawed technically, as it misses an important difference, i.e. in PHC, unlike field worker’s scenario, “continuous sharing of data captured by one user with other users” (in other words users collaborate among themselves to provide service to the patient). For example, the data captured at registration desk should be sent to the server and be pulled onto the doctor’s (or any other department’s) device before the patient physically moves from registration to the doctor. This is not guaranteed to happen if Internet is unstable. Soon there will be a lot of real-user downtimes. For the first few occasions, people may tolerate such downtimes, but over time, users are bound to get frustrated and junk such a system because they cannot depend on it.</p>
<p>Then there are ideas like peer to peer data synchronisation between the devices in PHC. As far as I know, there isn’t a mature general-purpose-database that run on android or web-browser that can do peer-to-peer-multi-node-data-replication**.</p>
<p><em>(Many a time, progressive web apps are thrown in as a solution, and ordinary consultants like me need to explain why PWA is no magic to solve no Internet problem, at the risk of coming across as someone who is not latest with one’s tech)</em></p>
<p>Overall, designing a system for PHC is tricky and requires making more tradeoffs. We do not have standard technical architectures to solve this because there are not many use cases like this. While FLW and Hospital use cases are standard, PHC sort of falls in the weird and interesting middle.</p>
<p>More on this in, other options that don’t work and how we can think of solving it, in another post.</p>
<blockquote>
<p>UPDATE (31/08/18): ** My colleagues at Samanvay pointed me to few databases that promise to be handy in solving this problem because they provide peer to peer replication—gundb, rxdb, orbitdb, couchbase lite. These indeed look promising, especially gundb.</p>
</blockquote>
<p> </p>
<p> </p>
<p>Published On: 28-Aug-2018</p>
<p>Author: <a href="https://www.linkedin.com/in/vivek-singh-4535a61/" target="_blank" rel="noopener">Vivek Singh</a></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-12-1pbjj7lpfvzcefzmvulsktw.png" length="106371" type="image/png" />
                        <category term="Software Architecture" />
            <updated>2020-11-19T10:16:36+00:00</updated>
                            <dc:description><![CDATA[Designing a system for PHC is tricky. We do not have standard technical architectures to solve this because there are not many use cases like this. While frontline health workers and hospitals can use standard architecture, PHC sort of falls in the software architectural blank space]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Creating a cost-effective multi-tenant platform]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/articles/on-software-architecture/creating-a-cost-effective-multi-tenant-platform" />
            <id>https://www.samanvayfoundation.org/articles/on-software-architecture/creating-a-cost-effective-multi-tenant-platform</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p><strong>Introduction</strong></p>
<p>Multitenant products have become quite commonplace nowadays. Any B2B product deployed on the cloud needs to have some kind of multitenancy. The exact kind depends on the business case and the product infrastructure and development team structure. You have a bunch of options, each with its reason to exist.</p>
<p>Multitenancy provides isolation of data or processing (or both) of one tenant from others. The purpose of this isolation could have multiple reasons. It could be for better debuggability, providing access to tenants to parts of the data/infrastructure they care about, differently allocating resources to tenants, or for invoicing.</p>
<p>In this post, we talk about the different areas of an application, and how multitenancy manifests itself in each one of them.</p>
<p> </p>
<h5>The frontend server</h5>
<p>Many workloads are frontend heavy. Such as e-commerce solution where each seller can Whitelabel their site. Hosted content-management solutions. If you are working on such a solution, then you have a few problems to deal with.</p>
<ol><li>Isolation of issues to specific tenants — You might not want high traffic on one site to disrupt others.</li>
<li>Provision for additional infrastructure for specific tenants — You might want to measure how much each tenant uses, or provide a better experience to paying customers.</li>
<li>Separate logging, which might need to be exposed to tenants directly.</li>
</ol><p> </p>
<p><strong>Usual patterns</strong></p>
<ol><li>One fat frontend — If you are not working on a frontend heavy workload, this is the best way to go. The one fat frontend means you still can scale (horizontally, or vertically based on what your preferences are).</li>
<li>One or more virtual machines per tenant — If all your tenants are decent sized to take up space of at least one virtual machine, have a lot of frontend customization, then providing virtual machines per tenant is a decent approach. Logs are automatically partitioned, machine stats are easy to debug per tenant, and billing is easy.</li>
<li>One or more containers per tenant — If you still need all the isolation that approximately equals a virtual machine, but have many small tenants, this might be a more attractive approach.</li>
</ol><p>In any of these cases, keeping user state out of the frontend is usually a good idea. This is true even without multitenancy.</p>
<p>Another point of interest here is that isolation is often necessary when the assets of each tenant are different. If they are all the same, returns on isolation are lower.</p>
<blockquote>
<p><span style="font-size: 16px;">Choose sophistication on the frontend based on requirements; Often, less is good.</span></p>
</blockquote>
<p> </p>
<h6>Database</h6>
<p>The next most important decision would be to decide how to isolate different tenants on the database. There are 3 approaches when it comes to relational databases.</p>
<p> </p>
<p>1. <strong>Single database per tenant</strong></p>
<p>If your tenants can pay for it, and the situation demands it (legal constraints etc), then this is the safest solution. It also happens to be the costliest. Why?</p>
<ul><li>10 databases are 10 times costly (well, roughly) to purchase on the cloud than one.</li>
<li>Multiple databases mean multiple migrations which increase product release times. Imagine a 1-minute migration taking place for 100 tenants.</li>
<li>Multiple databases potentially mean different versions of the software on each tenant. It is normal for each tenant to have their team managing their software, which can lead to the addition of new items on the schema (if you are not strict enough), differing software versions per tenant, eventually leading up to multiple deployments of the same software. This is just multiple deployments of the same software in adjacent hardware infrastructure, not multitenancy.</li>
</ul><p>There could be valid reasons to go this way but know that your deployment is getting costly.</p>
<blockquote>
<p><span style="font-size: 16px;">Database-per-tenant provides the highest isolation levels in data at the highest cost.</span></p>
</blockquote>
<p> </p>
<p>2. <strong>Single database, multiple schemas per tenant</strong></p>
<p>There are some minor differences between database-per-tenant and schema-per-tenant.</p>
<ul><li>Schemas are comparatively cheaper but do not offer the same levels of hardware isolation that database-per-tenant provide</li>
<li>Database versioning pains still exist</li>
<li>You can afford to keep the same connection pool. Remember that this brings some complexity within the middleware code. We will need to prefix every query with the schema corresponding to the tenant.</li>
</ul><p> </p>
<p>3. <strong>Single database with a discriminator column</strong></p>
<p>Here, a column (tenant_id) is present on every table of the database where there is tenant data. This provides the least isolation among the different solutions available. It also is the cheapest possible solution in the medium term.</p>
<p>You cannot have different versions of the software for every tenant if you use this approach (there are ways such as multiple deployments, but then you don’t call it multitenancy anymore).</p>
<blockquote>
<p>Consider having a single database with discriminator option if you can. It works well in the long term.</p>
</blockquote>
<p> </p>
<p>4. <strong>Single database with a hierarchical discriminator</strong></p>
<p>This is a slight twist on the regular discriminator column. If you have a lot of reference data that is common to many organisations, then it might make sense to have the ability to inherit that data. In this case, your tenant table will have a hierarchical structure, and your queries will start retrieving data belonging to you and your parent(s).</p>
<p> </p>
<p><span style="text-decoration: underline;">The case for hierarchical discriminators</span></p>
<p>Using hierarchical discriminators come with its troubles. Use with caution. At Avni, we were planning to have common metadata for programs that we hoped will be used by many tenants. To enable this, we started with hierarchical discriminators. Soon, this approach proved to be hard to maintain.</p>
<ul><li>Sharing of data between unrelated organisations is painful — First, we noticed that there were minor changes each tenant wanted on the base metadata. We tried to fix this problem by providing options to override. Providing options to override came with its maintenance problems. The base common metadata was hard to modify because each change needed to be tested on all tenants that use the metadata. Sometimes, it was easy to test, but we had to go to every tenant to verify if the change makes sense to their organisation.</li>
<li>Slicing of common metadata is hard — The other problem with hierarchical discriminators was to find out the right size to slice the base metadata. We were adding base metadata for multiple health programmes into one big tenant, but our tenants needed only one. We could not implement multiple-inheritance on the metadata, which means a lot of metadata each tenant received was not required for their operations.</li>
</ul><p> </p>
<p>Finally, we ended up using plain old discriminator-based multitenancy, with the option to copy over metadata to a tenant where necessary. We still have hierarchical discriminators, but for a different reason. We are also seeing customer that want to run a program through their partners where they decide the metadata. The partners need to see only the transactional data they generate. Hierarchical discriminators make sense in such a scenario.</p>
<blockquote>
<p><span style="font-size: 16px;">Different tenants MUST not share common metadata</span></p>
</blockquote>
<p> </p>
<h5>Middleware design</h5>
<p>If you are using discriminator column-based multitenancy, every query needs to be filtered using the tenant id. While it is possible to audit all your queries before deployment, it is an error-prone approach. All the more so when you have your ORM silently running queries on your behalf. The best way forward is to bake multitenancy at the design level of the server. All code assumes that there is just one tenant in the database.</p>
<p>If you use Hibernate, it provides options for switching databases when using database-level or schema-level multitenancy. It is comparatively simple.</p>
<blockquote>
<p><span style="font-size: 16px;">Isolate multitenancy functions of your middleware through design</span></p>
</blockquote>
<p> </p>
<h5>Multitenancy in Avni</h5>
<p>We now discuss a concrete implementation — <a href="https://avniproject.org" target="_blank" rel="noopener">Avni</a>.</p>
<p> </p>
<p><strong>Frontend</strong> — Avni has a fat frontend. This is because there are no tenant-specific modifications in either our API, admin app or our web-based data entry modules. We maintain the servers ourselves, and we don’t have a scaling problem yet. A fat frontend is sufficient for now.</p>
<p> </p>
<p><strong>Database</strong> — At the backend, we use a single database separating data using discriminators. This was primarily because our tenants mostly had low volume (10,000–100,000 transactions per annum), having multiple databases or schemas was unnecessary complexity.</p>
<p>We use the row-level security (RLS) feature available in Postgres. Each tenant gets their own Postgres role. All tables have RLS policies applied to ensure data does not leak between tenants. Now all that remains is to ensure that operations are performed using the role assigned to a tenant. The middleware takes care of this.</p>
<p> </p>
<p><strong>Middleware</strong> — Avni server identifies the user and their tenant from a JWT that comes from the client. This information is set at the thread level in a UserContext. The user context is then used by a tomcat JDBC interceptor to change the role of the database connection. The tomcat JDBC interceptor provides a hook at the connection level. This helps us keep all business logic free from the knowledge of multitenancy.</p>
<p>Before committing to the database, a hibernate JDBC interceptor ensures that all data inserted or updated by a user has their tenant_id. Once the request is serviced, we reset the role on the database connection.</p>
<p> </p>
<p><strong>Reports</strong> — Reporting servers identify each tenant as its database, with tenant-specific database user. This is not very efficient because Metabase collects database statistics on all the databases it has. This became a bottleneck because the number of tenants keeps increasing, adding to the load of the database. We switched Metabase statistics to manual. Metabase uses JDBC connection pool which provides control over the number of database connection per tenant.</p>
<p> </p>
<p><strong>The fat frontend</strong> — the web app and the android app are not multitenant aware. Nor are the queries for reporting or the business logic of the server. By containing multitenant behaviour to a small slow-moving area of the system, we can confidently work on newer features easily.</p>
<p> </p>
<p> </p>
<p><strong>Published On</strong>: 03-Feb-2020</p>
<p><strong>Author</strong>: <a href="https://www.linkedin.com/in/vinay-venu-93b64b8/" target="_blank" rel="noopener">Vinay Venu</a></p>]]>
            </summary>
                        <category term="Software Architecture" />
            <updated>2020-11-19T10:16:35+00:00</updated>
                            <dc:description><![CDATA[How multitenancy manifests itself in different areas of a software system and about multi-tenancy in Avni]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Schemaless platforms]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/articles/on-software-architecture/schemaless-platforms" />
            <id>https://www.samanvayfoundation.org/articles/on-software-architecture/schemaless-platforms</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>A lot has been written about schemaless databases, but not much on schemaless platforms, on how to make them, how to choose one for your own software project — while there are so many of them around us. CMS, Electronic medical record systems, ERP, CRM, and Forms utilities, to name a few in common domains. Each niche sectors/verticals have such platforms too — like in the social sector there is <a href="https://avniproject.org" target="_blank" rel="noopener">Avni</a>, <a href="https://www.dimagi.com/commcare/" target="_blank" rel="noopener">CommCare</a>, <a href="https://bahmni.org" target="_blank" rel="noopener">Bahmni</a>.</p>
<h6> </h6>
<p><strong>What are schemaless platforms?</strong></p>
<p>Schemaless databases allow you to perform data operations, without telling the database about the schema of your data. And they deliver good performance for such use cases.</p>
<p>Schemaless platforms, on the other hand, are designed to tackle the generic end-use cases in a domain and leave the specific parts for the user to define onto the platform. It is the second part (in design and tradeoffs) that this article deals with. At this point, it is important to delineate the term “user”. In most schemaless platforms there is a platform-user who defines their specific data model and an end-user who simply uses that solution. Consider Google Forms which is also a schemaless platform. The person who defines the form is a platform user and the one who fills the data in the form is an end-user. We will refer platform user as a user here.</p>
<p>Unlike Google Forms where the whole platform is about providing a schemaless facility, many products may have a schemaless platform embedded within the product. Such as — a health record management platform may provide features like registration, out-patient, in-patient, laboratory, etc. But within some of these modules, the user can define their own schema for data. For example —there could facility to define forms for different diseases within the out-patient/in-patient modules. The product maker makes a design choice that, it is best to leave some data modeling to the user.</p>
<p> </p>
<p><strong>Three types of schemaless platforms</strong></p>
<ol>
<li>Products where schemalessness is the defining feature of the product — like Google Forms, ODK, AirTable.</li>
<li>Products with an embedded schemaless facility in multiple parts of the system— electronic medical records, SalesForce.</li>
<li>Products that support the definition of custom fields, but they are not very powerful in what they allow — like multiple data types, skip logic, validations, calculated fields, schema migration, etc.</li>
</ol>
<p> </p>
<p><strong>Why are schemaless platforms important?</strong></p>
<p>Schemaless platforms offer an alternative to fully custom software in many scenarios — especially type 2 above. Type 2 schemaless platforms if done right are compelling because they solve a domain-specific problem and at the same time provide the user with the ability to customize as per their needs. We have also written about this <a href="https://avniproject.org/blog/2020-01-28-case-for-generic-open-source-products/" target="_blank" rel="noopener noreferrer">here</a>.</p>
<p>This article deals with 1 and 2 — because schemalessness is quite important to these products. We will get into broader technical issues here and go in detail of them in a subsequent article(s) in this series.</p>
<p> </p>
<hr></hr>
<p> </p>
<h5>Making schemaless platforms</h5>
<p><strong>Database for schemaless platforms</strong></p>
<p>Do I need to use NoSQL databases for creating schemaless platforms? Strictly speaking no, because there are ways to achieve schemalessness on relational databases as well. This can be done using one of the following approaches:</p>
<ul>
<li><strong>Entity Attribute Value (EAV) </strong>— In a nutshell, keep one row per field value. A key column that represents the name of the field and a column for storing the value. This is a <a href="https://inviqa.com/blog/understanding-eav-data-model-and-when-use-it" target="_blank" rel="noopener noreferrer">good article</a> that explains this pattern.</li>
<li><strong>Embedded schemaless facility</strong> within relational database products. For example <a href="https://www.postgresql.org/docs/12/datatype-json.html" target="_blank" rel="noopener noreferrer">support for JSONB within PostgreSQL</a>.</li>
<li><strong>User-defined database schema</strong> — Here the user can specify the schema, using which the platform creates database objects (tables, columns, index, etc) — providing a schema full structure when deployed. This is followed by <a href="https://strapi.io/" target="_blank" rel="noopener noreferrer">Strapi</a> and Drupal. One cannot do this if you want to use a single database schema for multiple customers who will all define their schema for themselves.</li>
<li><strong>Spare columns</strong> — The platform provides spare columns in the database tables, where it wants to provide support for user-defined fields. It can choose to represent all data types as a string or provide spare columns for multiple data types. Obviously in-elegant, but clever from a performance perspective, as we will see later. This can be further extended to have spare tables with spare columns.</li>
</ul>
<p> </p>
<p>If you are developing a schemaless platform of type 1 (above) then choosing a NoSQL database may make sense. NoSQL databases are diverse in how to model the data and allow querying of it, unlike relational database products which are quite similar to each other. The choice of the right NoSQL database is out of the scope of this article — but the checklist here applies to them as well.</p>
<p>While for the platform of type 2 you may need to make the decision based on how schemaless vs schema full you are required to be. That is, for what percentage of your product, is the schema known? We cannot prescribe but hope to provide enough details in this series to create a checklist that helps in making a decision.</p>
<p> </p>
<p><strong>Management of user schema</strong></p>
<p>While your platform is schemaless, it doesn’t imply that there is no schema. There is almost always a schema. It is with your user. Hence, all schemaless platforms need to provide the ability for the user to define their schema and for the platform to store and serve it. The success of schemaless platforms depends a lot on how simple one makes the process of defining and managing the user schema.</p>
<p>The user-defined schema consists of the same elements that software developers have always dealt with, except they are now in the realm of the users. In relational thinking it would be:</p>
<ul>
<li><strong>Entities/Tables</strong></li>
<li><strong>Fields</strong> (with name, data type, behavior)</li>
<li><strong>Relationships</strong> (one-to-one, one-to-many, many-to-many)</li>
</ul>
<p>Similarly, in document/object modeling, it will be — Aggregates, Objects, and Fields.</p>
<p>Elevating these concepts into the realm of the users where they can use them via a GUI, is a difficult design problem, which has not succeeded at scale. It is tackled in two ways, both of which are tradeoffs:</p>
<ul>
<li><strong>Service providers for schemaless platforms</strong>—They become the “users” and set up the solution for their customers. Most such products have an ecosystem of “product-implementers”.</li>
<li><strong>Less featured schemaless platforms</strong> make the tradeoff by keeping their platform anemic, by avoiding some features like entity relationships, field-level behavior. These are the most difficult concepts for a non-technical platform user.</li>
</ul>
<p> </p>
<p><strong>Lack of standards</strong> — Even though there are many schemaless platforms, this space has lacked standards for defining user schema. Perhaps there are not enough platforms, that will warrant an emergence of standards. The platform users need to learn to define their schema for a new product, every time. XForms is one such standard but it has not seen wider adoption and neither it provides a specification for everything in the schemaless platform world.</p>
<p> </p>
<p><strong>Promoting user schema through environments</strong></p>
<p>When you publish a Google Form you are basically deploying the solution from a “development environment” to the “production environment”. All schemaless platforms have to eventually support this process in their product. The more feature-rich user schema the platform supports, the more complex it is to implement the deployment. Products may also be required to support multiple logical environments like development, test, staging, and production — through which the user-schema can be promoted.</p>
<p>At the core of the solution to schema promotion, is the ability to maintain multiple versions of user schema (one per environment) and to merge one version onto the other. Anyone who has written code for merging objects, or version control systems :-), will appreciate the complexity. You can simplify a bit by supporting merge paths in only one direction, i.e. from development to production, and not paths like production to staging (for such scenarios one can simply implement a delete followed by copy).</p>
<p> </p>
<hr></hr>
<p> </p>
<h5>Technical tradeoffs in schemaless platforms</h5>
<p>Schemaless platforms, not surprisingly, are not a silver bullet. There is a price to be paid for going schemaless. Schemaless platforms succeed in scenarios where they keep this cost low. Let us look at the technical issues that emerge with schemaless platforms, to help to make the tradeoff. This section is not about, consumer-targeted platforms like Google Forms, but scenarios where custom development is a real option.</p>
<p> </p>
<p><strong>Reporting tools</strong></p>
<p>Relational databases schemas are quite standardized. This allows for reporting tools like Metabase, Tableau, and others to provide numerous features because they can decipher and create an internal model of the user’s schema, automatically by using metadata maintained by databases. With schemaless platforms, we lose these benefits. These reporting tools do not understand EAV, JSONB, and NoSQL very well (standardization could help here too). There are techniques that can be employed to get around some of these issues, as we will see later in this series — but they require additional work. Overall, schemaless data models lead to complex queries and worse performance comparatively.</p>
<p> </p>
<p><strong>Database level checks</strong></p>
<p>The database constraints like foreign-key, unique, not null and custom constraints cannot be taken for granted anymore. Depending on the approach taken one may have to give away one or more of these. For example — in EAV, JSONB you cannot implement null/not null and unique constraints for user-defined fields. In JSONB you cannot do foreign keys as well. You have to handle these in the code but they work less well because:</p>
<p>the database can also be updated directly (via migrations, and data fixes)</p>
<p>database checks are far more efficient</p>
<p>code can have defects in how it implements these checks</p>
<p> </p>
<p><strong>Data migration on schema change</strong></p>
<p>In schema full applications, the schema change and its associated re-arrangement of data are handled by the programmers using SQL (with flyway, Liquibase, etc). In schemaless platforms, supporting the change in user schema over time is simpler to implement but performing data migration to the new schema is tricky.</p>
<p>For example — adding a new field is simple. But adding a default value for that field (like column default) is complex to implement in a performant way. Similarly, scenarios like moving a field from one entity to all its children, keep getting more and more complex to implement. Most schemaless platforms shy away from implementing these features because they may have to implement complete SQL via GUI — which is a project in itself. So when required, such problems are resolved by contacting technical support.</p>
<p> </p>
<p> </p>
<p> </p>
<p><strong>Published On</strong>: 17-Feb-2020</p>
<p><strong>Author</strong>: <a href="https://www.linkedin.com/in/vivek-singh-4535a61/" target="_blank" rel="noopener">Vivek Singh</a></p>]]>
            </summary>
                        <category term="Software Architecture" />
            <updated>2020-11-19T10:16:32+00:00</updated>
                            <dc:description><![CDATA[Architectural considerations for products that allow their users to define their own data models]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Open-source products offer a technology evolution path and help avoid risks in technology projects]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/open-source-products-offer-a-technology-evolution-path-and-help-avoid-risks-in-technology-projects" />
            <id>https://www.samanvayfoundation.org/resources/open-source-products-offer-a-technology-evolution-path-and-help-avoid-risks-in-technology-projects</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>There are several uncertainties with technology endeavours of nonprofit organisations. They pose significant risks of wasted resources, inability to evolve with time, and obsolescence in the long term - to nonprofits. Open source products offer a sustainable path.</p>
<p> </p>
<p><strong>Uncertainties faced by non-profits</strong></p>
<ol><li>Beginning
<ul><li>To what extent can your organisation adopt technology sustainably?</li>
<li>If it is a public system (i.e. not to be used by the organisation's staff) - what would be the uptake of the system?</li>
</ul></li>
<li>Medium-term
<ul><li>The context in which you plan to use technology can change because of government decisions, the situation on the ground, etc?</li>
<li>Your own organisational uncertainties (e.g. funding outlook, attrition of key employees) can have an impact.</li>
<li>On scaling do some unforeseen risk come to the surface?</li>
</ul></li>
<li>Long term
<ul><li>What happens, even if one is successful with all of above but the technology becomes obsolete?</li>
</ul></li>
</ol><p>For an organisational leader to <span style="font-family: var(--font-family); font-size: var(--base-font-size);">make investments in technology so that one can reap benefits on the other side</span><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);"> - depending solely on organisational wisdom seems unsatisfactory. We believe that </span><span style="font-family: var(--font-family); font-size: var(--base-font-size);">open source* </span><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);">products</span><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);"> offer compelling tool against these uncertainties. So how does it do this? Let us see the key characteristics of open source products and how it helps in each of the distinct phases.</span></p>
<blockquote>
<p><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: 18px; font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);">But the core, may be counterintuitive, idea is to not worry about procuring the exact technology solution at the beginning so that one can continue using it in the distant future.</span></p>
</blockquote>
<p> </p>
<p><strong><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); letter-spacing: var(--p-letter-spacing);">Key characteristics of open source products</span></strong></p>
<ol><li><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); letter-spacing: var(--p-letter-spacing);"><span style="color: #353535;">Open source products are designed to provide the common functionality needed by the sector (and sub-sector) and allow for customisation of what is specific to one organisation in how it works.</span></span></li>
<li><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); letter-spacing: var(--p-letter-spacing);"><span style="color: #353535;">They are modularized such that certain components can be replaced with bespoke solutions while retaining the rest of the product. For example, Moodle allows one to replace the mobile app or the student-facing desktop app or reporting platform so on - while retaining the other components.</span></span></li>
<li><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); letter-spacing: var(--p-letter-spacing);"><span style="color: #353535;">Open source products track the sector and the technology evolution and evolve themselves continuously.</span></span></li>
<li><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); letter-spacing: var(--p-letter-spacing);"><span style="color: #353535;">They can be used by cloud providers or be self-hosted.</span></span></li>
</ol><blockquote>
<p><span style="font-size: 18px;">Open source products provide 90-100% of what you need out of the box</span></p>
</blockquote>
<p> </p>
<p><strong><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); letter-spacing: var(--p-letter-spacing);">Starting on a new technology project</span></strong></p>
<p><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);">In this phase, beginner's risk must be disproved - else a lot of invested resources could go waste (as it does often). Here open source allows you to get off the ground quickly and cheaply via customisation option - so that one can test out whether indeed it is a good idea. Even though the software can be evolved quite quickly, our intuition tells us that the first version must be really good and do everything. If we have such expectation then we will be disappointed - although there is no real reason to be since we are trying to uncover the risks.</span></p>
<p> </p>
<p><strong><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); letter-spacing: var(--p-letter-spacing);">Medium-term</span></strong></p>
<p><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);">As we have successfully demonstrated the value and feasibility - in the medium-term we would like to scale at the pace suitable to our organisation. This could imply that we may expand the scope of software or improve the user experience. If we want to expand the scope there are likely existing features and components in the open-source product which we were not using earlier now can be used. This is because other organisations in our sector may have also required the same. Additionally:</span></p>
<ul><li><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);">we would like the mobile app to be more specific to our use case so that it is easy to scale to a large number of users</span></li>
<li><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);">we may want to improve the user interface of a component to look specific to our needs or branded as per our organisation</span></li>
<li><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);">we may want to add a new component not available in the product</span></li>
</ul><p>The flexible, modular and extensible nature of the open-source product allows us to achieve this at a reasonable cost without having to rewrite everything.</p>
<p> </p>
<p><strong><span style="color: var(--p-color); font-family: var(--p-font-family); font-size: var(--p-font-size); letter-spacing: var(--p-letter-spacing);">Long term technology risk</span></strong></p>
<p>In the long run, new ways of using the software and mainstreaming of new capabilities may emerge - unforeseeable at the start of the project. What has happened in the last ten years namely mobile, social media, WhatsApp, the cloud, may continue in the future - with a voice interface, chatbots, AI, beneficiary facing software becoming ready to use widely.</p>
<p>If we take bespoke solutions route we will have to keep developing them in future as well. In the long run, bespoke solutions usually get thrown away and new ones are developed - because the software provider changes or no one can understand the software program to change it anymore. But open-source products keep evolving on their own without us having to do anything - since they cater to the wider sector and someone or other is looking for new things. e.g. When mobile app became mainstream <a href="https://moodle.org/" target="_blank" rel="noopener">moodle</a>** added this component to its portfolio.</p>
<blockquote>
<p><span style="font-size: 18px; font-style: italic;">Open source products protect you against technology obsolescence</span></p>
</blockquote>
<p> </p>
<p><strong>Conclusion</strong></p>
<p>The benefits of open source products can be seen in the short to long run. Note that it is in the economic interest of custom software solution providers to develop bespoke solutions for every customer as they are larger in the ticket size. But in our experience, it leaves non-profits worse-off in the long run and doesn't cover for risk in the short and medium-term.</p>
<p> </p>
<p><span style="font-weight: bold;"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni-1-16056942289973.jpg" alt=""></img></span></p>
<p> </p>
<p> </p>
<p><em>* most products with widespread use in the social sector are open source</em></p>
<p><em>** we have used moodle as an example but same can be said about <a href="https://dhis2.org/" target="_blank" rel="noopener">DHIS2</a>, <a href="https://openmrs.org/" target="_blank" rel="noopener">OpenMRS</a>, <a href="https://wordpress.org/" target="_blank" rel="noopener">WordPress</a>, <a href="https://opendatakit.org/" target="_blank" rel="noopener">ODK</a>, too.</em></p>
<p> </p>
<p><strong>Published</strong>: 18-Nov-2020</p>
<p><strong>Author</strong>: <a href="https://www.linkedin.com/in/vivek-singh-4535a61/" target="_blank" rel="noopener">Vivek Singh</a></p>
<p> </p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-7-avni-1.png" length="105053" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2020-11-18T10:11:27+00:00</updated>
                            <dc:description><![CDATA[Nonprofits face risks of wasted resources, inability to evolve with time, and obsolescence in the long term. Open source products offer a low-risk route allowing nonprofits to thrive in using technology.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Difference between software platform and bespoke solution. How to make the choice?]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/software-platform-and-bespoke-solution" />
            <id>https://www.samanvayfoundation.org/resources/software-platform-and-bespoke-solution</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>In the last few years, we have suddenly seen a spike in the usage of the term <em>software platform</em>. All types of <em>software applications</em> started getting called platforms. But the term platform has a specific meaning which differentiates it from technology/software applications. A platform enables other software applications to run on it, mostly to be used by end-users. In other words, we could say that a platform by itself is useless to the end-users unless it is programmed or customized for specific usage. WordPress, Moodle, Google Forms, ODK, Avni - they are all platforms. Google Docs, MS Paint are not platforms as they are mostly consumed directly by the end-users. Though the ease of customization can blur the lines between the user and the customizer and the same person may be playing both roles.</p>
<p> </p>
<p>It was important to establish this distinction so that we can answer the more relevant question - how should we decide when to use a platform and when to develop a bespoke software application? <em>Bespoke</em> means custom-made—made based on the specifications of the person ordering it, as in a bespoke suit (from dictionary.com). The diagram below shows two distinct scenarios.</p>
<p> </p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni-3-1.jpg" alt=""></img></p>
<p> </p>
<p>The essential tradeoff between these two options is cost, time, risk, and requirement match. A list of tradeoff involved are as follows:</p>
<p> </p>
<table style="border-collapse: collapse; width: 100%; height: 221px;" border="2" cellspacing="50" cellpadding="50">
<tbody>
<tr style="height: 44px;">
<td style="width: 8.27454%; height: 44px;"> </td>
<td style="width: 22.002%; text-align: center; height: 44px;"><span style="font-size: 18px;"><strong>Bespoke application</strong></span></td>
<td style="width: 29.7235%; text-align: center; height: 44px;"><span style="font-size: 18px;"><strong>Customization on platform</strong></span></td>
</tr>
<tr style="height: 65px;">
<td style="width: 8.27454%; height: 65px; text-align: left;"><strong> COST, TIME</strong></td>
<td style="width: 22.002%; height: 65px; text-align: center;"> <span style="color: #e03e2d;">Requires software development hence high costs, time</span></td>
<td style="width: 29.7235%; height: 65px; text-align: center;"> <span style="color: #2dc26b;">On the right platform, an order of magnitude is smaller compared to a bespoke application.</span></td>
</tr>
<tr style="height: 48px;">
<td style="width: 8.27454%; height: 48px; text-align: left;"><strong> RISK</strong></td>
<td style="width: 22.002%; height: 48px; text-align: center;">
<p><span style="color: #e03e2d;">Uncertainties in quality being poor, cost, and time overruns of the software development undertaking. Often getting all three right has been difficult for most projects.</span></p>
<p> </p>
<p><span style="color: #e03e2d;">Finding the right technology development organization (important to consider that <span style="text-decoration: underline;"><a href="https://www.samanvayfoundation.org/resources/domain-expertise-doesnt-travel-from-high-resource-to-a-low-resource-setup" target="_blank" rel="noopener noreferrer">domain expertise doesn't travel from high resource to low resource context</a></span>)</span></p>
</td>
<td style="width: 29.7235%; height: 48px;">
<p style="text-align: center;"> </p>
<p style="text-align: center;"><span style="color: #2dc26b;">Quality can be pre-determined.</span></p>
<p style="text-align: center;"><span style="color: #2dc26b;">Platform quality matures over time.</span></p>
<p style="text-align: center;"> </p>
<p style="text-align: center;"><span style="color: #e03e2d;">The extent of requirement fit offered by the platform has to be determined at the start itself, which </span><span style="color: #e03e2d;">could be technically challenging.</span></p>
<p style="text-align: center;"> </p>
<p style="text-align: center;">The roadmap of the platform is determined by the third party. Depending on the platform roadmap too much, could be a double-edged sword. On one hand, you get features for free. On the other, they may take longer to arrive than expected.</p>
</td>
</tr>
<tr style="height: 64px;">
<td style="width: 8.27454%; height: 64px; text-align: left;"><strong> Requirement Match</strong></td>
<td style="width: 22.002%; height: 64px; text-align: center;"><span style="color: #2dc26b;">The end solution will meet all your requirements.<br>In control of your destiny for subsequent development, albeit it will continue to require resources.</span></td>
<td style="width: 29.7235%; height: 64px; text-align: center;">
<p><span style="color: #e03e2d;">Cannot expect a 100% match, but one can aspire and achieve 90-95% in most situations.</span></p>
<p><span style="color: #e03e2d;">A solution developed on platforms, with the platform-provided user interface, may require higher levels of training for end-users.</span></p>
</td>
</tr>
</tbody>
</table>
<p> </p>
<p>Let us look a bit deeper into what this means more specifically for community and field programs. Such programs lack the following resources.</p>
<ul>
<li>Funds available to use for technology deployment</li>
<li>In-house technical skills to develop such solutions</li>
</ul>
<p>Hence the best solutions are those which require fewer funds and can be managed with technical skills available within the organization, while largely satisfying the requirements. With these key parameters of evaluation in mind let us see the matrix below which presents various scenarios and our recommendations.</p>
<p> </p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni-2.jpg" alt=""></img></p>
<p> </p>
<ul>
<li>Whenever our functional requirements are commonly shared by a large number of people in various disciplines - the widely available consumer platforms can serve such needs.</li>
<li>When additional features are required that are specific to the domain of work, we have two options. Either use a platform or get the software developed in-house (via a software development partner). Unless the features required are not present in the platforms available, going for bespoke software development incurs much higher cost - with the same result. Additionally, platforms afford you the ability to perform customizations in-house as they require much lesser software development skills. Hence you are less dependent on your software partner (for certain customizations one may still require a software vendor's help, but with good platforms, they are less and keep getting lesser over time).</li>
<li>When one finds oneself in a situation where only very few functionalities required are missing the platform - which is quite often the case. One can choose the bespoke application route or use the platform without the missing functionality. We have observed that there is an additional route available with open source platforms where one of the following may work out.
<ul>
<li>You may check the feature's availability in the product roadmap of the platform. Open source products share their roadmap publicly.</li>
<li>You should connect via the community route and work out a mechanism to add the functionality to the product roadmap or even get it done by paying a small amount (which may be still much lesser than developing a bespoke application).</li>
</ul>
</li>
</ul>
<p> </p>
<p><em>ps: Lastly, the question mark space may be of academic interest to some. Why does such a blank space exist? As we understand, it is difficult for platforms to move up the feature ladder without moving right in customization complexity as well (and vice-versa). Hence where a platform places itself is a strategic tradeoff made by the organization/people behind the platform. Overall one should always expect the blank space.</em></p>
<p> </p>
<p>Author: <a href="https://www.linkedin.com/in/vivek-singh-4535a61/" target="_blank" rel="noopener"><strong>Vivek Singh</strong></a></p>
<p>Published On: <strong>04 November 2020</strong></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-5-avni-2.png" length="108699" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2020-11-04T09:37:54+00:00</updated>
                            <dc:description><![CDATA[Choosing the right technology strategy is crucial especially for resource-constrained contexts. Software platforms are an important part of the strategy and one should choose the bespoke application route after eliminating the platform option first. The excessive and incorrect usage of the term platform has also not helped here. We get into all these issues here to help you make the right choice.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Why your field team procrastinates data reporting]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/why-your-field-team-procrastinates-data-reporting" />
            <id>https://www.samanvayfoundation.org/resources/why-your-field-team-procrastinates-data-reporting</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<h5><strong>Context</strong></h5>
<p><span style="font-family: var(--font-family); font-size: var(--base-font-size);">In most field programs there is a time lag between data collection and data reporting - since the reporting is expected only periodically. This collected data is compiled manually by the field staff at the end of the period and reported up in the hierarchy.</span><span style="font-family: var(--font-family); font-size: var(--base-font-size); color: var(--p-color); font-weight: var(--p-font-weight); letter-spacing: var(--p-letter-spacing);"> There are two types of compilation - aggregation and data filtering. Some examples of aggregation done are calculating the number of new houses registered, the number of people tested positive for a disease, so on. These aggregate data elements to be reported periodically may run into dozens. When the reporting formats are at the <a href="/resources/architecture-of-community-program-organisations-and-their-data-systems">intervention unit</a> level - e.g. name, age, gender, caste, religion, APL/BPL status of the newly registered. Here the field staff is essentially reporting sub-set of the fields s/he has collected for each intervention unit.</span></p>
<p> </p>
<p style="text-align: center;"><span style="font-family: var(--font-family); font-size: var(--base-font-size);"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni-24.jpg" alt=""></img><em>It is possible that the data entry is done by the field staff themselves at the end of the period</em></span></p>
<p> </p>
<h5><strong>Reason for procrastination</strong></h5>
<p>While, the field teams in the social sector enjoy working with their communities, servicing community members, meeting their own program targets - but they do not particularly like entering data into an excel, paper, or a data entry system (aka MIS) - the way it happens. Hence, it is not uncommon that one of the tasks of program coordinators is to followup with field team about data submission - at the end of their reporting period. On the other hand, the funders and senior leaders do want to know about the exact impact being created - and data has become the primary evidence and communication tool. So, nonprofit projects/programs face these two opposing forces, looking for solutions.</p>
<p>Before we think about potential solutions to this, we must look deeper into the issue itself, by asking a very simple and obvious question - why does the field team dislike entering data in the first place? The answer is not very difficult to discover. Some of the common root causes are as follows:</p>
<ol><li>The data compilation and entry is monotonous work and time-consuming.</li>
<li>The person performing above doesn't experience any benefit from it. As far as they are concerned the data compiled and submitted by them pretty much vanishes in ether, never to be heard about again.</li>
<li>He/she is stressed about making mistakes while doing such work. This is not good to experience which people want to go through - hence one instinctively tries to procrastinate such types of work, as long as they can.</li>
</ol><p>Our experience suggests that these issues are recognised by all level of field workers, not simply by the more skilled ones. Even community workers at village levels experience this, quite naturally. It’s just that in most cases, they hesitate in expressing their emotions (because of social hierarchy) - but upon genuine prodding in a safe-environment one can discover the same reasons at play, quite easily.</p>
<p>But if instead of empathising with these circumstances, if the organisation’s response is of economic reasoning, like:</p>
<ul><li>but funders need the data after all so what to do</li>
<li>without funds, there would not be any fieldwork in first place</li>
</ul><p>...then it creates a no-win situation and the status quo continues. Field team procrastinates, data is delayed, data is of poor quality, to cleanup data more time is spent - burning down everyone involved.</p>
<p> </p>
<blockquote>
<h4>As we can see from our root cause analysis that procrastination and its direct effects present only half the picture. The harm and underlying missed opportunities it hides are far more serious issues for our programs - worthy of our attention.</h4>
</blockquote>
<p> </p>
<h5><strong>Solution ideas</strong></h5>
<p>The root causes listed above themselves, point to the solution. In most cases, a "happier" system looks like the following.</p>
<ol><li>The data capture happening as part of the users’ workflow instead of being batched together in a separate activity, to be done later. <strong>The crux of the solution here is that 1 hour of data entry per day, gets broken down into 30 instances of 2 minutes each</strong>. These are for 30 clients which field worker is interacting with, on that day. The data capture work mixes and pleasantly disappears with other tasks one is doing (as elaborated <a href="/resources/architecture-of-community-program-organisations-and-their-data-systems">here</a> more).</li>
<li>The software has functionality that has direct benefits for the field user - unlike a black box system in which fieldworker only adds data but never gets back anything useful. e.g. community health workers can view critical medical information of their client from their history; in agriculture, community resource person can provide information to their client which are generated by calculating based on previous data about land/inputs/micro-plan. A few other sample benefits are (there are many):<br><ul><li>Software system maintains users work schedule based on their client data.</li>
<li>The software provides reports to the field user based on their work. e.g. the number of clients they have supported, outcomes achieved, and so on. This gives a sense of accomplishment which is highly important.</li>
</ul></li>
<li>The software aggressively validates data and performs computations for the user. One comes across numerous programs where the user is burdened with tasks that are much easier done by software. These software systems consider validation to be merely about mandatory, character size, number range etc. This is simply lack of imagination. The system can enforce much more useful validations like:
<ul><li>The client cannot be born before the date of their registration</li>
<li>A male client cannot be pregnant. A child cannot be older than his/her mother (or only 5 years younger).</li>
<li>One cannot produce more than certain kilos of wheat from an acre plot size.</li>
</ul></li>
<li>This may not be possible everywhere, but if the software system can go even further such that in monthly meetings (which is a common practice), the fieldworkers can present their data using the software itself - it can have quite an empowering effect. We have seen it in a few places, this needs to be tried more.</li>
</ol><p>We highly recommend doing 1 and 2, at a bare minimum. 3 is also important if you find yourself spending too much time in, what is referred to as a necessary activity, called "cleaning of data" or "validating data". In fact, these are unnecessary tasks and quite stressful because human beings are not good at these tasks.</p>
<p> </p>
<p><strong>In conclusion</strong></p>
<p>The fundamental idea that transforms from the state of procrastination to involvement is to make the fieldworkers productive and involve them fully in the data system. Most importantly it will improve the quality of service provided to clients. Finally, the resulting data flow looks rather unimpressive in the diagram :-). We also recommend reading <a href="/resources/designing-systems-that-use-paper-and-technology-together">this article</a> which covers issues around transitioning from paper to digital.</p>
<p> </p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni-29.png" alt=""></img></p>
<p style="margin-bottom: var(--p-margin-bottom); font-size: var(--p-font-size); font-weight: var(--p-font-weight); line-height: var(--p-line-height); letter-spacing: var(--p-letter-spacing); font-family: var(--p-font-family); text-shadow: var(--p-shadow);"> </p>
<p style="margin-bottom: var(--p-margin-bottom); font-size: var(--p-font-size); font-weight: var(--p-font-weight); line-height: var(--p-line-height); letter-spacing: var(--p-letter-spacing); font-family: var(--p-font-family); text-shadow: var(--p-shadow);"> </p>
<p style="margin-bottom: var(--p-margin-bottom); font-size: var(--p-font-size); font-weight: var(--p-font-weight); line-height: var(--p-line-height); letter-spacing: var(--p-letter-spacing); font-family: var(--p-font-family); text-shadow: var(--p-shadow);"><span style="font-weight: bold;">Author</span>: <a href="https://www.linkedin.com/in/vivek-singh-4535a61/" target="_blank" rel="noopener">Vivek Singh</a></p>
<p style="margin-bottom: var(--p-margin-bottom); font-size: var(--p-font-size); font-weight: var(--p-font-weight); line-height: var(--p-line-height); letter-spacing: var(--p-letter-spacing); font-family: var(--p-font-family); text-shadow: var(--p-shadow);"><span style="font-weight: bold;">Published</span>: 22-October-2020</p>
<p style="margin-bottom: var(--p-margin-bottom); font-size: var(--p-font-size); font-weight: var(--p-font-weight); line-height: var(--p-line-height); letter-spacing: var(--p-letter-spacing); font-family: var(--p-font-family); text-shadow: var(--p-shadow);"> </p>
<p style="margin-bottom: var(--p-margin-bottom); font-size: var(--p-font-size); font-weight: var(--p-font-weight); line-height: var(--p-line-height); letter-spacing: var(--p-letter-spacing); font-family: var(--p-font-family); text-shadow: var(--p-shadow);"><em><span style="color: #000000;">(Icons thanks to <a href="https://icons8.com/" target="_blank" rel="noopener">icons8</a>)</span></em></p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-4-photo.jpg" length="453976" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2020-10-22T06:47:23+00:00</updated>
                            <dc:description><![CDATA[Field teams in the social sector projects enjoy working with their communities, servicing community members, meeting their own program targets - but they do not particularly like the idea of entering data into an excel, paper, or a data entry system (aka MIS). Why and how to solve it?]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Designing systems that use paper and technology together]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/designing-systems-that-use-paper-and-technology-together" />
            <id>https://www.samanvayfoundation.org/resources/designing-systems-that-use-paper-and-technology-together</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>Many NGOs are thinking of adopting software technology for their data management and reporting (instead of paper) - for their community/field-based programs. When evaluating such projects usually there is a lingering doubt about the extent to which technology can be used in these programs. What is the anthropological and economic feasibility of doing so?</p>
<p> </p>
<p>In this article we have:</p>
<ul><li>created a checklist of issues to help you in doing an assessment of the profile of technology that can be rolled out.</li>
<li>done a classification of different data storage options</li>
<li>provided one example of how one can think about using hybrid approaches. Since almost all such technology solution deployments use multiple data storage options i.e. they are not fully digital or completely paper-less.</li>
</ul><p> </p>
<h5>Checklist of issues to consider</h5>
<ol><li>Infrastructure
<ul><li>Electricity availability - There is a bare minimum hour of electricity required so that the devices used can be charged. The minimum hours depends on the extent of usage you expect.</li>
<li>Electricity quality - The electricity should be such that it doesn’t harm the devices (via voltage spikes for example), requiring very frequent maintenance or replacement. Gathering anecdotal evidence from each cluster may be sufficient to determine this if one is not sure.</li>
</ul></li>
<li>Anthropological issues - Many of the village/slum or even higher level community workers are not fluent in using smartphone apps. They still don’t have a smartphone of their own. But before you get disappointed by this and make a decision, it is better to look deeper put people into four groups, look at the breakup, and then decide - based on what the breakup looks like.<br><ul><li>Community workers not literate in the reading/writing in the local language</li>
<li>literate in written language but not used to smartphone and probably not trainable yet</li>
<li>literate in written language, not used to smartphone and but trainable</li>
<li>literate in written language and use smartphone already</li>
</ul></li>
<li>Cost
<ul><li>What will be the total cost of mobile devices, data connections, repairs, and replacements?<br><ul><li>This can be easily calculated by using excel.</li>
</ul></li>
<li>If you will be dependent on the external trainer to train your staff in technology usage, then the induction of new staff will require training as well. In our assessment train-the-trainer approach works quite well and hence we feel that attrition/replacement is not an issue other than adding one more item to your training curriculum.</li>
<li>How much value you will derive by spending on technology per field worker? What is the percentage value of this cost compared to all other costs associated per field worker?</li>
</ul></li>
<li>Data strategy - Please note that you may be dealing with <a href="/resources/architecture-of-community-program-organisations-and-their-data-systems">different types of data</a> and your issues may not be relevant to all types of data.
<ul><li>Is it time-consuming to enter data into a mobile app? Yes, the speed at which data can be entered into mobile is slower compared to paper. But this tells only half the story. One should also factor in how much of the client interaction time for the community workers is in entering data versus talking, listening, thinking, travelling/switching between clients. Usually, it is a very small percentage and even a two-fold increase in data entry time has negligible impact on the overall client interaction time. In our view, you should not factor this point in your decision making - unless the data being entered is free-text notes. Free text notes, above tens of words, could start adding significantly to interaction time, also be quite error-prone, and frustrating for the user.</li>
<li>Should one keep backup of data that is entered in the mobile app in paper records - otherwise how would the fieldworker access data if the mobile app is unavailable because of mobile breakdown. Do consider the following factors:<br><ul><li>Do you have <a href="/resources/architecture-of-community-program-organisations-and-their-data-systems">beneficiary retained records</a>? If yes, do they serve as a backup in need?</li>
<li>How many outages of mobile phone are probable in a year?</li>
<li>How much service outage of the community worker, for their clients is realistic?</li>
</ul></li>
</ul></li>
</ol><p>We project that you may get a non-binary picture even after considering all of the above. But hopefully, now you have more concrete data to base your decisions on. To further deepen our understanding of the utility of the technology, let us compare various types of data storage and access mediums.</p>
<p> </p>
<hr></hr><p> </p>
<h5>Types of data storage</h5>
<p>There are three types of data storage options - paper, paper scanned (or unstructured digital), and structured digital. When thinking about data management, it is important to view paper and scanned paper also as a data tool so that we can do comparisons and understand tradeoffs.</p>
<p>The term structured is applied from the perspective of whether computers can fully understand the contents. Unstructured to structured is a spectrum not a binary as computer’s ability continue to improve. For the generally available “mainstream” technology, we would consider it to be binary though and assume that computers can tell us very little about the unstructured content in a practical sense (practical being the operative phrase here).</p>
<p> </p>
<p><strong>1. Paper</strong></p>
<p>Advantages</p>
<ul><li>Everyone in your organization knows how to use it. It is an implicit entry criterion to an organization which we don’t have to even think about.</li>
<li>Paper is flexible and efficient to use for large data-input and reading it. Beneficiaries record many a time have a lot of information like health record, agriculture plan. e.g. One of the main reason digital has not replaced health records is for this reason.</li>
<li>Paper has almost no upfront or one time costs.</li>
</ul><p> </p>
<p>Disadvantages of paper</p>
<ul><li>Mobility - Data on paper moves slowly, i.e. it has to be moved physically to another person for them to access. This restricts several useful applications of such data related to information sharing, speed of availability, timely action based on the information and so on.</li>
<li>Paper records cannot be "queried". One cannot ask a set of paper records any question and get an answer unlike digital. e.g. One cannot ask patient records room in a hospital “how many patients have diabetes and hypertension both” - and get a count as an answer!</li>
<li>Paper quality deteriorates over time. Paper records can get lost. One can get around both by making copies of the paper, though.</li>
</ul><p> </p>
<p><strong>2. Paper scanned</strong></p>
<p>This gets around two of the disadvantage of paper - mobility and quality deterioration. Mobile technology is good enough to perform scanning of paper and can be transmitted easily over data networks (though it does require slightly better networks than transferring structured digital records which are quite a size efficient).</p>
<p> </p>
<p><strong>3. Structured digital</strong></p>
<p>This does away with all the disadvantages of paper mentioned earlier. Although it has a few disadvantages of its own - which we have discussed in the checklist of issues in first section.</p>
<p> </p>
<p> </p>
<p><strong><span style="text-decoration: underline;"><span id="docs-internal-guid-e3364609-7fff-1a27-0ccc-06963c66094d">Example of a hybrid approach</span></span></strong></p>
<p>Most community programs that employ software use paper also. In a way, they are hybrid even when they are using technology extensively. Since you as a reader of this article may have already come across how mobile applications have been used in community programs, we restrict ourselves here to discuss one uncommon but an interesting approach which may help you think in creative ways about getting around the issues we discussed at the beginning.</p>
<h5> </h5>
<p>Paper records scanned but with associated structured digital metadata</p>
<p>Context</p>
<ul><li>Village water survey has to be conducted and submitted to the block level office.</li>
<li>Block-level office checks the survey and approves it.</li>
<li>This water survey record is of interest to the wider community.</li>
<li>There is no requirement to perform data analysis of the water surveys from different villages, except for a few data elements like village name, date of survey, duration of the survey, etc.</li>
</ul><p>A solution</p>
<ul><li>Village resource person (VRP) surveys using paper forms.</li>
<li>VRP scans the paper forms using mobile and submits into a software system.</li>
<li>Along with scan of paper VRP also fills a small structured form on the mobile app with information like date of survey etc mentioned above.</li>
</ul><p>The salience of this solution</p>
<ul><li>Our technology instinct will take the paper forms and create mobile forms and VRPs fill the mobile form with hundreds of data points. But in this particular case, there is not much value in having all the data points as structured data. Secondly, the user will use this app only once in a year hence getting trained in using a more complex app is not required.</li>
<li>Few key data points captured in the structured form allows for the basic analysis to be done. These structured data points will also allow for searching of the water surveys online. Once found, the scanned images of water surveys themselves can be viewed.</li>
</ul><p> </p>
<h5>Conclusion</h5>
<p>Ultimately, we use technology to solve problems. Deployment of technology without considering its feasibility and its impact on the problems is pointless and wasteful. At Samanvay we brainstorm with our nonprofit customers and come up with solutions that use paper and software together. As organisations and the context of use evolves, the solution usually evolves to using more software steadily.</p>
<p> </p>
<p><strong>Author</strong>: <a href="https://www.linkedin.com/in/vivek-singh-4535a61/" target="_blank" rel="noopener">Vivek Singh</a></p>
<p><strong>Date</strong>: 14-October-2020</p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-3-euf7nry492a.jpg" length="262760" type="image/jpeg" />
                        <category term="Nonprofit and Software" />
            <updated>2020-10-13T06:06:29+00:00</updated>
                            <dc:description><![CDATA[Community program using software technology are never fully paperless for cost, infrastructure and anthropological reasons. In this article, we discuss the issues related to designing systems focussed on solving problems and not with the goal of going paperless.]]></dc:description>
                    </entry>
            <entry>
            <title><![CDATA[Architecture of community program organisations and their data systems]]></title>
            <link rel="alternate" href="https://www.samanvayfoundation.org/resources/architecture-of-community-program-organisations-and-their-data-systems" />
            <id>https://www.samanvayfoundation.org/resources/architecture-of-community-program-organisations-and-their-data-systems</id>
            <author>
                <name><![CDATA[Vivek Singh]]></name>
                                    <email><![CDATA[petmongrels@gmail.com]]></email>
                            </author>
            <summary type="html">
                <![CDATA[<p>In this article, we create the foundations on which the rest of the publication can be developed. Some of the fundamental concepts are explained here in a generic form which will be referred to from the rest of the publication. It is also an attempt to develop a common vocabulary that hopefully makes us more efficient in communicating with each other.</p>
<p> </p>
<h4 style="text-align: left;"><span id="docs-internal-guid-7cf8ed53-7fff-02c1-721d-b196b3b456d9">About community program organisation and its beneficiaries</span></h4>
<p><strong>Unit of intervention</strong></p>
<p>This is the most fundamental unit towards which the activities of the social program are directed.</p>
<ul><li dir="ltr" role="presentation">Client</li>
<li dir="ltr" role="presentation">Household</li>
<li dir="ltr" role="presentation">Group (self-help group, village committee)</li>
<li dir="ltr" role="presentation">Facility (hospital, school, water source, farming polyhouse etc)</li>
<li dir="ltr" role="presentation">Location (village, block, cluster, etc)</li>
</ul><p>When the unit of intervention is facility or location the activities are aimed at improving them in such that its members ultimately benefit from it somehow.</p>
<p dir="ltr" style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;"> </p>
<p dir="ltr"><strong>Organisation levels in a community service intervention (or program)</strong></p>
<ol><li dir="ltr" role="presentation">
<p>Service or intervention target - Client, household, community, group</p>
</li>
<li dir="ltr" role="presentation">
<p>Community/field workers</p>
</li>
<li dir="ltr" role="presentation">
<p>Technical specialist</p>
</li>
<li dir="ltr" role="presentation">
<p>Field-based coordinators/facilitators/supervisors</p>
</li>
<li dir="ltr" role="presentation">
<p>Program coordinators/managers</p>
</li>
<li dir="ltr" role="presentation">
<p>Funding organization(s)</p>
</li>
</ol><p dir="ltr">Please note that 2-4 may not be the same as the legal organisation but that is not of much interest to us - in order to understand the logical structure of the community program organisations.</p>
<p dir="ltr">Let’s take two examples one from health and another from an education program and apply the above. The concepts explained above have been highlighted in bold in the diagrams.</p>
<p dir="ltr" style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;"> </p>
<p dir="ltr" style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/rszavni1.jpg" alt=""></img></p>
<p dir="ltr" style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;"> </p>
<p dir="ltr" style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;"><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/avni50.jpg" alt=""></img></p>
<p dir="ltr" style="line-height: 1.38; margin-top: 0pt; margin-bottom: 0pt;"> </p>
<p><span style="font-family: Lato; color: #000000;">In our attempt to develop this knowledge base we have generalised concepts for all sectors and all type of community programs. While this is consistent with 75- odd programs we have come across - we would welcome feedback if your program differs from the ones we have described here.</span></p>
<p><span style="font-family: Lato; color: #000000;">We would also like to state that we have excluded programs which perform periodic activities like health camps, disease screening, one time surveys, etc. Having said that most of the concepts discussed here and later, we believe, may still be of interest to you.</span></p>
<p> </p>
<hr></hr><p style="text-align: center;"> </p>
<h4 style="text-align: left;">Schema of data managed in community programs</h4>
<p> </p>
<h5>Input/source data</h5>
<p>Input data is the data which organisation members <strong>add</strong> to the system.</p>
<p> </p>
<p><strong>Longitudinal data</strong></p>
<p>When one or more service providers, collect information about a unit of intervention, over a time period - the entire dataset about the unit of intervention is also called longitudinal data. This type of data is of most interest to us. There are two types of longitudinal data we may have.</p>
<ul><li>Observational data - This could be for establishing the intervention units’ status at a point in time, e.g. baseline, midline, end-line data.</li>
<li>Service data - Data on service provisioning like individual’s health record, farmer’s agricultural activities/intervention record. The diagram below illustrates two such data examples.</li>
</ul><p> </p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot2020-10-12at80117pm50.png" alt=""></img></p>
<p> </p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/uploaded-media/screenshot-2020-10-12-at-80736-pm.jpg" alt=""></img></p>
<p><strong><span style="color: #000000;">Cross-sectional data</span></strong></p>
<p><span style="color: #000000;">It could be also referred to as survey data. It is the data collected about multiple entities (like intervention units) at the same point in time. Since they are collected at the same point in time, they are not multi-level and rich like longitudinal data. In the diagram above for the water body, if the desilting program and water quality program are absent and the organisation is performing only annual surveys on water bodies, in the month of April, in a district - then that would be like cross-sectional data.</span></p>
<p> </p>
<p><strong><span style="color: #000000;">Event data</span></strong></p>
<p><span style="color: #000000;">These are like longitudinal data generated over time but without belonging-to or applicable-to an intervention unit. This could be the activity data logged by the community service provider like transportation record, supply received, expense reports, so on.</span></p>
<p><span style="color: #000000;">Sometimes event data can be about the intervention unit but there is no established trusted identity of the intervention unit. This is usually either because establishing the identity is difficult, cost-prohibitive, or not useful. e.g. this could be the list of people who feel sick of Dengue in a given season, in a water and sanitation program which is more interested in the maintenance of water bodies (in epidemiology it is called line lists).</span></p>
<p> </p>
<p><span style="color: #000000;">Finally, in case you are wondering, we have not covered the structure of supporting data like master data and metadata (e.g. question-answer data, answer options, etc). These are generally well understood since they have very broad application and not just community programs.</span></p>
<p> </p>
<p><strong>Input data in an organisational context</strong></p>
<p><span style="color: #000000;">When the above data is overlapped with service providing organization then we can see the following classification of data.</span></p>
<ol><li><span style="color: #000000;"><em>Beneficiary retained record</em> (e.g. health card). This is a record which is maintained by the intervention units themselves and could be longitudinal in nature.</span></li>
<li><span style="color: #000000;"><em>Intervention unit service record</em>, maintained by community worker for each intervention unit (e.g. individual-level health record, student’s record, household’s livelihood data, water source monitoring record).</span></li>
<li><span style="color: #000000;"><em>Service monitoring record</em> could be same as intervention unit service record or could have fewer data elements based on relevance to the field coordination. This is for the purpose of project monitoring and execution planning.</span></li>
<li><span style="color: #000000;"><em>Service management record</em> could be maintained by any/all levels of the servicing organization. These records are not specific to any beneficiary, although they could be linked to multiple beneficiaries sometimes. e.g. transportation details of a community worker, allocation of certain assets to multiple intervention units, training sessions attended, etc. This is of type event data.</span>
<ul><li><span style="color: #000000;">It could also be data related to financial accounting which should not fall under this classification as they have independent standard structures.</span></li>
</ul></li>
</ol><p> </p>
<h5>Output data</h5>
<p><span style="color: #000000;">Output data can be completely generated from the input data. It is of three types.</span></p>
<ol><li><span style="color: #000000;"><em>Service indicators</em> consisting of derived indicators from the underlying data (1-4 above). They are derived and maintained against aggregation dimensions. E.g. number of children vaccinated (indicator) in a month (time-period) in a village (location) from the CSR XYZ fund (funding source).</span></li>
<li><span style="color: #000000;"><em>Outcome/output targets</em> created for assessing the intervention/project. These are for measuring achievement and not for service delivery. e.g. Target for number villages reached, self-help groups formed, total-patients-cured.</span></li>
<li><span style="color: #000000;"><em>Insight data</em> is gets created by running a domain-specific computation on the input data to derive some actionable insights. e.g. getting a list (or count) of children who are not gaining weight with age.</span></li>
</ol><p><span style="color: #000000;">The annual work plan which is maintained by program managers can be thought of as <strong>data sets</strong> consisting of service indicators by dimension and targets. Similarly, a comparison of service indicators against organisational or external standards is another type of data set used to evaluate output/outcomes of such programs.</span></p>
<p> </p>
<p><strong><span style="color: #000000;">Measurement dimensions of output data</span></strong></p>
<p><span style="color: #000000;">Social intervention programs capture the data to provide services and carry out their activities. Along with this, the input data is also important in understanding how their intervention is performing. This is usually done by tracking a set of indicators over certain dimensions. The indicators can be like, number of SHG’s formed, number of handpumps installed, so on. These are usually done along the following dimensions.</span></p>
<ol><li><span style="color: #000000;"><em>Location hierarchy</em> - e.g. village, block, district, etc.</span></li>
<li><span style="color: #000000;"><em>Period</em> - e.g. week, month, quarter, season, so on.</span></li>
<li><span style="color: #000000;"><em>Organisational entities</em> - Funding organisation, NGO Partner, Projects</span></li>
<li><span style="color: #000000;"><em>Intervention unit's attribute classification</em> - these dimensions are derived from the values of attributes of the intervention unit. e.g. age group, gender, caste, religion, water source type, school-level (primary, secondary etc).</span></li>
</ol><p><span style="color: #000000;">These are also usually additively rolled up the hierarchy, period, and entity - but not necessarily. The number of handpumps installed in the block is a sum of handpumps installed in villages under it. Similarly over period and entity. This, rolling up along the dimensions, is an important attribute of the output service indicators data.</span></p>
<p> </p>
<p><strong>Author</strong>: <a href="https://www.linkedin.com/in/vivek-singh-4535a61/" target="_blank" rel="noopener">Vivek Singh</a></p>
<p><strong>Published</strong>: 14-October-2020</p>
<p> </p>
<p><em><span style="color: #000000;">(Icons thanks to <a href="https://icons8.com/" target="_blank" rel="noopener">icons8</a>)</span></em></p>
<p> </p>]]>
            </summary>
                            <link rel="enclosure" href="https://static.ucraft.net/fs/ucraft/userFiles/samanvayfoundation/images/a-2-wordcloud-1.png" length="96313" type="image/png" />
                        <category term="Nonprofit and Software" />
            <updated>2020-10-13T06:05:32+00:00</updated>
                            <dc:description><![CDATA[The organisational architecture of community-based or field programs and the data managed in such programs.]]></dc:description>
                    </entry>
    </feed>
