Understanding AWS Cognito User Pools and Identity Pools

A gentle introduction to AWS’s authentication and access control service

This article was published on 7/12/2018 in The New Stack.

Cognito is AWS’s service for managing user authentication and access control. Although it was originally associated with AWS’s mobile backend-as-a-service offering (MBaaS), it has recently gained the attention of the serverless crowd, who are looking for ways to offload user management concerns to a service provider. Cognito solves this problem by providing a fully-managed, scalable and cost-effective sign-up/sign-in service—but at the cost of a steep learning curve. One of the reasons for this is because Cognito is actually comprised of two services—User Pools and Identity Pools (a.k.a. Federated Identities)—that are similar on the surface but different under-the-hood. These two services solve the same problem (i.e. authentication and authorization) but do so in very different ways. They can also be used separately or together, providing both flexibility and a source of confusion.

In this article, we’ll provide a gentle introduction to User Pools and Identity Pools, including the nuanced relationship between them. Before we dive into the explanation, however, we first need to explain two core security concepts: authentication vs. authorization and identity providers.

Read More

Get smart quickly about machine learning & marketing

5 practical tips for becoming a machine learning marketing ninja

The increasing prominence of machine learning in marketing is changing the way the industry operates. No doubt, this evolution is exciting, as it opens up new opportunities to connect with customers in ways that weren’t possible just a few years ago. But it is also terrifying, as the race between the data haves and have-nots intensifies, and marketing FOMO sets in. The good news is that while it may feel like everyone else has already become an AI marketing ninja, the truth is that the industry as a whole is still learning. According to a report by Salesforce, only 26% of business leaders have confidence in their organization’s ability to develop an AI strategy. And this statistic aligns with my own experience working with marketing clients across a range of industries: most companies are at the beginning stages of using data and machine learning in their marketing (but they are learning quickly).

The challenge for marketers right now is that the appetite for AI-infused marketing solutions is high, but the understanding of what AI actually does, is low. Unfortunately, this breeds an environment where vendors play fast-and-loose with the term “AI” and marketers are at-risk of being sold digital snake oil. As an engineer, this dynamic frustrates me. So, I’ve outlined five practical steps for getting smart about marketing with machine learning quickly, in an effort to help marketers become more informed buyers, whether they are evaluating AdTech solutions, interviewing agencies or building their own in-house data science teams.

Read More

Building Serverless Apps with AWS, Lambda, Python & Zappa

Popular open source Python framework Zappa eases the pain of serverless development

This article was published on 5/11/2018 in TechBeacon.

Serverless architecture has quickly emerged as the up-and-coming way to develop cloud-based applications. The benefits of serverless computing—zero server maintenance, out-of-the-box scalability, and ground-up support for asynchronous workflows—are just too good to ignore. It’s a developer’s dream.

But serverless architecture comes with a catch. These operational advantages carry a hefty price for developers: laborious configuration, immature frameworks, a lack of tooling, and a dearth of established design patterns. Until recently, going serverless meant throwing out decades of established tools and practices and starting over. In a nutshell, making serverless apps can be painful.

That’s why I selected the open-source Zappa as my serverless Python framework on a recent project for a dotcom start-up. I wanted to eliminate the burden of server maintenance for the young company and to design a cost-effective cloud architecture that was cheap when traffic was low, and would scale as the company grew. But I wanted these benefits without the unpleasant side effects that I’d encountered in the past when working on serverless apps. After doing the research, it became clear that Zappa embodied the culmination of the progress that serverless technology has made over the last 18 months. Here’s why.

Read More

Marketing and AI: Separating Fact from Fiction

How marketers can avoid getting duped by ‘faux AI’ vendors

This article was published on 4/3/2018 in VentureBeat.

As a software engineer whose clients are marketing professionals, I’ve gained a great deal of empathy for marketers over the years. Not because marketing technology is evolving so rapidly (which it is), but because the proliferation and misuse of buzzwords is so rampant, with the term “AI” leading the way. This is unfortunate because AI — or more accurately, machine learning (ML), a subset of AI — has huge potential for marketers. Making matters worse, when vendors combine buzzwords like AI with other buzzy, ill-defined technologies like “marketing automation,” the result is a buzzword soup of confusion. How can marketers separate reality from the fake marketing news?

It’s important for marketers to gain a high-level understanding of how ML works. If you don’t understand the basic concepts, it’s much easier to be taken for a ride. For ML newbies, I recommend Microsoft’s Data Science for Beginners. This video series provides an excellent non-technical overview of ML.

Read More

AI-Enabled Personalization is Easier Than You Think

Four ways to start incorporating AI and personalization into your marketing today

This article was published on 10/23/2017 in VentureBeat.

Since the invention of mass media, arguably, the primary focus of marketing has been to increase its level of personalization. Marketers constantly seek more targeted audiences, and strive to deliver messages that speak more directly to their diverse audiences. So, it's no surprise that AI and machine learning — with their ability to predict consumer behavior and make personalized recommendations on-the-fly — has captured the attention of the marketing world. But the elephant in the room is that advances in machine learning have far outpaced most marketers' ability to harness them

Unfortunately, this inability to personalize the customer experience is a huge missed opportunity. Customers now expect a tailored experience, including customized recommendations and a personal touch. And customers are willing to reward companies who provide it. According to Gartner, "By 2018, organizations that have fully invested in all types of personalization will outsell companies that have not by 20%." Even more alarming, customers are increasingly likely to dump brands that don't offer personalization. According to a 2016 Salesforce study: "… more than half (52%) of consumers are likely to switch brands if a company doesn't make an effort to personalize communications to them, 65% of business buyers say the same about vendor relationships."

Read More

Machine Learning Comes to the Masses

How a new wave of machine learning will impact today’s enterprise

This article was published on 7/17/2017 in VentureBeat.

Advances in deep learning and other machine learning algorithms are currently causing a tectonic shift in the technology landscape. Technology behemoths like Google, Microsoft, Amazon, Facebook and Salesforce are engaged in an artificial intelligence (AI) arms race, gobbling up machine learning talent and start-ups at an alarming pace. They are building AI technology war chests in an effort to develop an insurmountable competitive advantage.

While AI and machine learning are not new, the current momentum behind AI is distinctly different today, for several reasons. First, advances in computing technology (GPU chips and cloud computing, in particular) are enabling engineers to solve problems in ways that weren’t possible before. These advances have a broader impact than just the development of faster, cheaper processors, however. The low cost of computation and the ease of accessing cloud-managed clusters have democratized AI in a way that we’ve never seen before. In the past, building a computer cluster to train a deep neural network would have required access to deep pockets or a university research facility. You would have also needed someone with a Ph.D. in mathematics who could understand the academic research papers on subjects like convolutional neural networks.

Read More

AWS Serverless Architecture In Practice

Five key takeaways for designing, building and deploying serverless applications in the real world

This article was published on 4/3/2017 in VentureBeat.

The term “serverless architecture” is a recent addition to the technology lexicon, coming into common use within the last year or so, following the launch of AWS Lambda in 2014. The term is both quizzical and provocative. Case in point: while explaining the concept of serverless architecture to a seasoned systems engineer recently, he literally stopped me mid-sentence—worried that I had gone insane—and asked: “You realize there is actual hardware up there in the cloud, right?” Not wanting to sound crazy, I said yes. But secretly I thought to myself: “Yet, if my team doesn’t have to worry about server failures, then for all practical purposes, hardware doesn’t exist in the cloud—it might as well be unicorn fairy dust.” And that, in a nutshell, is the appeal of serverless architecture: the ability to write code on clouds of cotton candy, without a concern for the dark dungeons of server administration.

But is the reality as sweet as the magical promise? At POP, we put this question to the test when we recently deployed an app in production utilizing a serverless architecture for one of our clients. However, before we review the results, let’s dissect what serverless architecture is.

Read More

The Sisyphean Challenge of Senior Technology Leadership

Technology managers find themselves between a rock and a hard place, forced to choose between focusing on technical depth or leadership excellence. A potential solution comes from an unlikely source.

This article was published on 11/6/2016 in VentureBeat.

A workplace dynamic I’ve always found fascinating is the instinctual need for people to size up the technical depth of a technology leader upon first introduction. The hands-on technologists in the room want to determine if the manager understands what they do on a day-to-day basis. The non-technical people want to asses if she’ll be able to communicate clearly, or if she speaks in technical gibberish.

This social dynamic is a natural side effect of the dual nature of the senior technology leadership role. On the one hand, technology managers must create and operate code and infrastructure, which requires detailed, technical knowledge. On the other hand, they must translate technical concepts into business strategy and manage a team, which requires communication and leadership skills.

The challenge for senior technology leaders is that we can’t do both perfectly. Therefore, the goal of the CTO and other senior technology leaders is to strike the right balance between technical depth and business leadership, based on the size and focus of the company. However, this is easier said that done.

Read More

The Algorithm Behind the Curtain: Building an Artificial Brain with Neural Networks (4 of 5)

Neural Networks form the foundation for Deep Learning, the technique AlphaGo used with Reinforcement Learning (RL) to beat a Go master. In this article, we’ll explain how the basics of neural networks work.

The focus of this series is to dissect the methods used by DeepMind to develop AlphaGo, the machine learning program that shocked the world by defeating a worldwide Go master. By peeking under the hood of DeepMind’s algorithm, we hope to demystify Machine Learning (ML) and help people understand that ML is merely a computational tool, not a dark art destined to bring about the robot apocalypse. In the earlier articles we discussed why AlphaGo’s victory represents a breakthrough, and we explained the concepts and algorithms behind reinforcement learning—a key component of DeepMind’s program. In this article, we’ll explore artificial neural networks. Neural networks form the foundation of deep learning, the technique that enabled DeepMind’s reinforcement learning algorithm to solve extremely large and complex problems like Go. Deep learning is an advanced form an artificial neural network. So, before we dive into deep learning in the next article, we’ll first explore how a neural network operates.

Read More

The Algorithm Behind the Curtain: Understanding How Machines Learn with Q-Learning (3 of 5)

Reinforcement Learning (RL) is the driving algorithm behind AlphaGo, the machine the beat a Go master. In this article, we explore how the components of an RL system come together in an algorithm that is able to learn.

Our goal in this series is to gain a better understanding of how DeepMind constructed a learning machine — AlphaGo — that was able beat a worldwide Go master. In the first article, we discussed why AlphaGo’s victory represents a breakthrough in computer science. In the the second article, we attempted to demystify machine learning (ML) in general, and reinforcement learning (RL) in particular, by providing a 10,000-foot view of traditional ML and unpacking the main components of an RL system. We discussed how RL agents operate in a flowchart-like world represented by a Markov Decision Process (MDP), and how they seek to optimize their decisions by determining which action in any given state yields the most cumulative future reward. We also defined two important functions, the state-value function (represented mathematically as V) and the action-value function (represented as Q), that RL agents use to guide their actions. In this article, we’ll put all the pieces together to explain how a self-learning algorithm works.

Read More