Blog / Data
Analytics by design: how iti revolutionized the way it works, with help from data
The four pillars that guided how iti’s data platform was built, from the first data pipeline on Lambda to fraud models on every transaction.
In early 2019, we were given the mission of building a data platform for a new Itaú product that was still being conceived: iti, Itaú’s digital bank. It was created to transform people’s relationship with money, to make easy what is difficult and bureaucratic today, and to make the expensive affordable. Its main pillars and ambitions include simplicity and the democratization of financial services for the part of the population that lives on the margins of today’s financial system, whether by choice or not. At iti, we work to go far beyond what big banks and fintechs offer today: we want to serve, and understand in depth, customers who have no credit history, because we know the value these people bring to the economy and the difficulties they face. In this context, using data at scale plays an essential role in helping iti reach its goal of being a democratic financial platform.
As data engineers, passionate about technology and excited by this challenge, we started out by designing the best possible solution with every resource available: real-time processing, an MLOps pipeline, a sandbox for data scientists, scalable data pipelines, and so on. But we soon paused and asked ourselves: do we really need all of this from the start? The answer, confirmed now that we are more than a year and a half into the journey, was: no. We do not need all of that. We have managed to create a lot of value with very little, by following these pillars:
- 01Business-driven incremental deliveryevery release driven by a goal
- 02Analytics by design, built on a data‑driven culturedata is born with the feature
- 03Analytics is codethe same rigor as a backend
- 04Governance, privacy, and quality as valuesnon-negotiable, above any target
Business-driven incremental delivery
It’s no secret that every technology initiative should have a well-defined business goal and should evolve through incremental releases. What isn’t always clear to companies, or simply gets overlooked, is that the same logic must be applied, just as rigorously, to foundational initiatives such as building a data platform.
Every step in building and evolving the platform has to be guided by a business goal, and its releases should drive that goal’s results. In other words, you need to keep a close eye on the famous OKRs (objectives and key results): the data platform team should have objectives aligned with the business strategy and key results that make it possible to measure and track the progress of each release and the value it creates. Without a clear measure of the value created for the business, you run the risk of building technology for technology’s sake rather than something that actually pays off. Don’t make the mistake of setting goals for technical improvements that have nothing to do with the product strategy.
People who love technology often want to build elegant solutions that are as close as possible to the state of the art. That is great, and it should serve as a benchmark for ensuring quality releases, but the team cannot lose sight of what really matters (and OKRs help a lot here)—creating value for our customers. OKRs also help us avoid Big Design Up Front (BDUF): with six-month and annual goals, the platform build should focus on that horizon, rather than spending too much energy designing for a distant future.
Analytics by design, built on a data-driven culture
For any data initiative to succeed, you first need to create an environment where everyone understands the importance of data and recognizes the value of using it. So everyone should know the data journey, from conception to use.
The first step in building that environment must come from senior leadership: executive sponsorship and advocacy for this culture are essential for every area of the company to adopt it. And that sponsorship and advocacy must mean total commitment from senior leadership, expressed in actions, not just words.
With that in place, you have fertile ground for creating a data strategy and adopting the concept of analytics by design, in which the product features themselves are born integrated with the data platform, sending relevant information in a format that makes it usable for analytics. All of this is only possible with a mature data‑driven culture, in which product teams see value in using data and care about it, too.
Analytics is code
Data engineering and data science should be held to the same rigor as, say, the backend development of a transactional system. In other words: analytics is code like any other, and it must be treated as such. This means that building an ETL pipeline or creating a model cannot be treated as work that is handcrafted, one-off, slow, and impossible to replicate. On the contrary, pipelines and models need to be agile, replicable, and easy to develop.
For example, a mature data platform needs a DevOps and MLOps pipeline with all the gates you would expect of one, infrastructure as code, and a portfolio of development accelerators, such as building blocks and scaffolds. The goal is to reach the point where it is easy, fast, and safe to build on and for the platform.
Governance, privacy, and quality as values
Everything presented so far is enough for this endeavor to succeed, as long as we treat the platform’s data in a way that ensures its governance, privacy, and quality. We believe these points are so important that they should be treated as values, to the point that no business goal, for example, can override the safe and governed use of the platform and its data. As for quality, the maxim “garbage in, garbage out” speaks for itself: if you don’t know your data or can’t guarantee a minimum level of service, chances are high that it will create more problems than value.
That is why it is so important to have tools and processes that ensure these three values, right from the platform’s conception. And, of course, if the whole team does not recognize them as values, no tool or process will make this endeavor a success.
Using a data catalog, defining the products’ data schemas right at ingestion, and segregating data access at a granular level, along with traceability logs and data lineage, are some examples of features that help ensure adherence to these principles.
Sounds good, but what about in practice?
Now you might be asking yourself: how did we manage to apply all these pillars in practice, given all the difficulties and complexities of large technology initiatives?
When we started developing the data platform at iti, with these pillars already in mind, we made the following technical decisions: (1) go 100% serverless, using only what our cloud provider (AWS) had to offer; (2) do all development, without exception, with GitFlow, CI/CD, and infrastructure as code—in this case, GitLab, GitLab CI, and Terraform.
These technical decisions, and all the others we made afterward, were always guided by the goals defined for and by the data team. We built and validated those goals together with iti’s business team. For example, some of our goals were to increase the number of active customers and to expand our ability to offer credit to the part of the population that currently has no access to this kind of service. That way, the whole engineering team keeps coming back to one question: how can the data platform help achieve these goals?
Staying focused on incremental delivery and keeping an eye on our goals, we chose to run our first data pipeline on Lambda, with storage in S3, and to build all the surrounding tooling: Terraform modules, a GitLab CI pipeline, and Python building blocks. As a result, in less than a month, we had a first working version of the platform, with timely data pipelines and our users running queries in Athena.
As for culture, today it is safe to say that iti, both as a product and as a team, lives and breathes data: launching new features already integrated with the platform, running data analyses to shape strategy, and putting advanced analytics models to use. This level of maturity was reached, first of all, through the sponsorship and engagement of our business and technology leaders, who made sure from the very beginning that the data discipline was treated as a priority and an integral part of the product, not as “a service provider.”
With that backing, the data team was able to positively influence the entire iti team, for example by making integration with the data platform an acceptance criterion for every new feature: today, every feature sends us events designed for use on the platform. This allows a very short lead time between extraction and use, since the data was designed from the start for this use and integrated before the feature even went into production.
Two important strategies we have followed since the platform’s early days have kept us consistently aligned with our values of governance, privacy, and quality: defining event schemas and governance by exception. As another acceptance criterion, every event sent to the data platform must have its schema declared, not only with its layout and data types, but also with business descriptions of the fields and a flag for PII (personally identifiable information). This schema is used at three different stages: to register the event in our data catalog, to reconcile received vs. expected events, and, finally, to anonymize PII fields. The catalog ensures governance and one facet of quality by making our data easy to find and understand; reconciliation ensures the technical quality of the events; and anonymization ensures privacy, and governance too. Anonymization makes it possible to create a layer with all of the data, minus anything that identifies our customers, which allows safer and more controlled use of that data. We made this layer the starting point for exploration. And it is worth remembering that all data capture and every grant of access to the platform comply with Brazil’s General Data Protection Law (LGPD)—with its principle of minimization, the deletion and purging of data, and the requirement to justify any use with a stated reason and purpose.
Success stories
By now, you have seen how we put all of this into practice. Next, we will share a few examples that show how successful this strategy has been at iti, enabling the data team to deliver enormous value to our customers.
- Models in productionfrom customer activation and churn prediction to the onboarding experience
- Fraud preventionevery transaction scored by models, with minimal impact on customers
- Failures anticipatedan SRE engine that predicts failures in onboarding and transactions
Very early in our story, when our CI/CD pipeline only supported deploying Lambda functions, we created a process that packaged our lightest models so they could run inside them. This opened up a whole range of possibilities, and less than a month in, we had models in production, ranging from predicting customer activation and churn to models that customized our onboarding experience.
Today, with our platform mature, we support a number of critical areas at iti. One example is our financial transaction flow, in which every transaction is scored by our models to identify potential fraud. And the best part: with minimal impact on our customers. In addition, our SRE (site reliability engineering) team relies on an engine that, also using models, anticipates possible failures in our main flows, such as onboarding and transactions. That cuts our failures, and their impact, dramatically.
Conclusion
Today, the data platform offers a wide range of capabilities, such as a layered data lake, data marts, online and batch data pipelines with data quality checks, online and batch machine learning models, an MLOps pipeline, a sandbox for data scientists, and more. We are also constantly reviewing and realigning our goals and technical decisions. One example of this practice is that we no longer restrict our development to AWS services, and we are expanding into open‑source tools.
In short, by following this approach of incremental releases driven by business-aligned goals, with a strong data culture that underpins analytics by design, and by valuing governance, quality, and privacy, we have been able to create a great deal of value for iti. As a consequence, and not as an end in itself, we have built a cutting-edge data platform with advanced capabilities that we are very proud of today. It has been a challenging but deeply rewarding journey, one that involved the entire iti team. A journey of constant learning that is far from over. With all this in mind, we would like to leave you with one last thought: at iti, we are passionate about technology, technology that makes sense and creates value for our customers, technology that relies on a data‑driven culture to deliver services that just keep getting better!
Originally published in Portuguese on ititech (Medium), Dec 7, 2020.