Thursday, August 29, 2013

Toilet And A Rainbow

Last week I was walking out of Patangyu with Anjali and out of a crack in the fence we spotted a woman limping up the hill from the dumping ground. Her ankle was wrapped in white gauze. A very old, very little woman was trying to help her walk. We went over to see if they needed help. The injured woman had a pained look on her face, squinting from her foot and the heat. She collapsed to the ground as we came over, exhausted from hopping up the hill. We offered to carry her back home. Rahul and I made a chair for her with our joined arms, we lifted her up and walked over to her house.

Once we got there Anjali got the story. The woman had taken a nasty fall and her ankle was badly sprained. The doctor had wrapped it up but given no medicine or further instructions. She was unable to walk on her own. She was so demobilized that she couldn't even go to the bathroom. And there was no one besides her mother, the little old woman, to attend to her. But the mother had a high fever herself, so was too weak to help. As a result the woman had stopped eating since her injury; that way she would not need to go to the bathroom. And since she wasn't eating, the mother stopped cooking, figuring there was no point to cook for just herself. None of her neighbors had offered assistance.

Clearly they were at a distressed low point. We walked out with Anji reassuring them that we would do something to help. She already had a plan. As we walked back to the car she said we would build the woman a toilet that she could use while her ankle recovered. We would get a plastic chair, cut a hole in the seat, and put a bucket underneath. We would also give her some sand which she could cover her waste to avoid odor. We would set it up inside their house; the mother would simply have to clean the bucket everyday. Once she had a way to go, she was free to start eating. Once she started eating, mother would start eating, and both would hopefully recover more quickly.

One of the things I admire most about Anji is that she is highly sensitive. In the sense that she has incredible powers of observation and awareness, and also in the sense that she has very deep empathy and willingness to connect with people in any circumstance. In this case most people would have stopped at helping this woman home and maybe listening to her sad story. Most people tend to keep chance encounters shallow. It's too messy to go deeper into people's lives, especially strangers. If you had to stop and get involved with every person you run into, you'd never get your work done! But that is Anji's work. She has an incredible fearless openness and curiosity to following threads, wherever they may lead. She recently shared how she was on her way somewhere, spotted a man eating some morsels on the side of the way, stopped to talk to him, and ended up canceling her other appointment to share a meal because "there was something interesting" about the man. Another time she told me she decided to walk home from Ganeshnagar through the Tekra and it took her three hours (normally 30 min) because family after family stopped to talk or invite her in for chai. In these and many situations she puts no self-imposed limit on how deep or how far she will go in connecting; she keeps it open-ended for fate to decide.

In this case fate had us building a toilet. After it became clear that there was nothing more to it than a bucket underneath a chair, I marveled at the elegance. This is what Ishwar Kaka must have fallen in love with! He would have been delighted and proud of this project. I was thrilled that something so simple could have a big impact on the woman. By cutting a hole in a chair and placing a bucket under, it would set off a chain of events that would help this woman live much more comfortably. It was reminiscent but seemed a lot less thorny than the time we tried to build a bridge for Ganeshnagar.

One thing I suffer from is tunnel vision. When I am doing a task, blinders go up so I can focus on the task and filter out the distractions. Linear thinker. It's good in a way, but one downside is I often miss elegant shortcuts or helpful leaps that I wasn't expecting. Anji has no such problem. She is a master at being aware of her surroundings and finding hidden resources everywhere. Spatial thinker. When we were walking down to the car with the chair and bucket, we were getting into the car and in front of us were some painters up on ladders doing some work on our building. Behind them was a pile of sand. Naturally it was spare, so we could help ourselves. Meanwhile she noticed the painters were carelessly splattering paint on the plants next to the wall. She asked them to be mindful because the plants are lives too.

We got back to Ganeshnagar and the Patangyu kids sprang into action to cut and deliver the toilet. We traced out a hole, which was done with much deliberation and with input from the females on the team. Rahul took the plastic chair into his house and heated up a small kitchen knife on the gas stove. When it got red hot he quickly pressed it into the chair on the traced line. He got the four edges started with the hot knife then finished it off with a saw. He was drenched in sweat working in a tight stuffy area with a hot knife and burning plastic fumes wafting around him. The cut came out perfect. It was magnificent work.

As a finishing touch the kids named the chair Santosh ("satisfaction" as in satisfaction of relief), drew a smiley and wrote the date to commemorate Patangyu company's first toilet prototype. We brought it to the woman who accepted it and agreed to use it and also to eat. We placed the chair and bucket in a carefully chosen place in her one-room home to conveniently sit, access water to clean herself, easily get to the sand, and not be in the way of other stuff. Anji checked on their food supplies, they seemed ok. She handed the woman some packets of Advil to help with the pain, but reminded her that she could only take them with food.

As we walked back with the kids one of them spotted a rainbow. It was faint, but it was definitely there. I thought it was a fitting way to mark the conclusion of the adventure.

To me this story is remarkable in many ways. If you asked Anjali, she probably wouldn't agree. That's what makes it so remarkable. This is her life, this is how she lives. Actually, this is who she is. I just happened to be there that day, but these sorts of episodes are a routine part of her life. This story captures Anjali in a nutshell. This is her essence.

I think for outsiders looking in it is an inspiration to see how living a life that is open to and even strives toward depth of interaction at every turn becomes a rich life, a life worth living.

Monday, August 19, 2013

Hypercity

My favorite shopping experience in India is at a store called Hypercity. It is a combination of Walmart and Safeway. The chain of stores originated in Bombay, there is one in Ahmedabad in Alpha Mall, the city's best mall.

I appreciate that Hypercity is spotlessly neat-and-clean, it has great selection of items, the store is arranged with space and planning, and is affordable. Lots of food items including organic, fresh produce, good quality household items and electronics, all at reasonable prices. But what I love most about Hypercity is that it has friendly and helpful staff. In India the concept of customer service basically doesn't exist yet. So it is a pleasant and welcome surprise to see that people at Hypercity actually want to do a good job and care about satisfying the customer.

Recently I purchased some furniture from Hypercity: two beds and two wardrobes. I had to pay by check, which I carefully wrote out and handed to the salesman. He went to bring me the bill but came back saying I had written Hypercity Ltd. as the payee, instead of Hypercity India Ltd., so the check could not be processed. Unfortunately this was my last check. The salesman acknowledged it was his mistake. That was a big step. Then he tried to figure out a solution, another big step. The store was far away, it wasn't easy for me to just come over the next day with a payment. We decided that I would go to the bank and get a new check the next day, and they would send someone to my office to pick it up. Meanwhile they would hold on to the items I ordered and not give them away. I thought this was risky, because it would be typical for something in this plan to go wrong. Either they wouldn't show up to get the check, or the items would disappear. But I had no choice.

So next day I get the check ready and sure enough a Hypercity boy comes to my office and picks it up. The next day I get a call from Hypercity saying the check didn't clear; my account had insufficient funds. It turned out that my bank had issued me new checks for the wrong bank account. This is a typical move by my bank, but the nightmare of personal banking in India is the subject of a whole other series of expose blog posts. I told Hypercity I'd have to go back to the bank and get the right checks, and they would have to send someone again. This time I apologized, and the sales guy (who was the same contact from the beginning so I wasn't stuck having to explain the situation to ten different guys) understood and said it was fine. At the end of the day he still felt bad that all of this happened because he botched the payee name for the original check.

Next day the I get the check and again the pickup happens by Hypercity. Later that day I get another call from Hypercity saying there is now another problem. Uh oh, I thought. I knew this was going to happened. No way so many steps were going to be taken without a setback that collapsed the whole house. Either my items were gone or the check had another issue or some other issue.

The salesman said problem was that the price of one of my items had changed since I was first in the store. When he said that I felt the frustration rising. There it is! Now these guys are going to use this disastrous situation which was their own doing to gouge me for more money. But what the salesman said next totally shocked me and took my breath away. The price of the item had gone down and that my new total was less than the original. He just called to ask whether I wouldn't mind taking the difference as store credit. The only catch was I'd have to go into the store to personally claim the credit.

This floored me. Never in all my years in India had such a thing happened. Hypercity was going out of their way to give me a discount! The guy didn't have to do it. How would I have ever known that the price had dropped? He could easily have pocketed the difference through some corruption in their transaction system. And after all that we went through, all the extra work and effort on both sides to finish this transaction, he may have even considered it justified.

But instead they made a customer into a loyal customer. I couldn't have been more thrilled. Later when I went to the store to spend my credit, I bought some chocolate for all of the sales team, many of whom knew me and helped make my final outcome happen. They were reluctant and humble, and very appreciative. Many of them now know me by name and I know them, and we greet each other with a smile when I'm back at the store.

There is hope for customer service to exist in India. Hypercity is a beacon of that bright future.

Sunday, August 11, 2013

Made me think of Sam


For more information, please visit http://meetsamir.com

Sunday, August 4, 2013

Vehicular Liberation

I started driving last week. I haven't gotten my own car yet, but Maddog let me borrow his 2003 Maruti Zen. After the very first day taking the car out, I felt my lifestyle had fundamentally changed. It was a surprising shift. All of a sudden I felt liberated. I felt empowered to go where I want, when I wanted. It felt a lot closer to my life in California, where I feel the most free and in control.

I have been trying to understand why having a car has changed my life so deeply. After all, before I still could go where I wanted, when I wanted. In theory. Getting around by rickshaw isn't hard in Ahmedabad. They are plentiful, you can usually find one within a few minutes, and you can pay set prices by the meter. So what's the big difference?

I've come up with several reasons. One, you sometimes do have to wait, and in certain places or times of the day it's tough finding a rickshaw at all. Two, you can't stop or change directions as easily. Three, drivers never carry enough change, so there is always background tension about paying for your ride. Four, there is always a chance the driver will try to rip you off or take you the long way, which is another source of background tension. Five, you're exposed to the elements, especially heat, rain, and pollution.

All of these are small inconveniences that when aggregated together over months and years makes for a less pleasurable experience. One thing most of the above reasons have in common is they are inconveniences experienced each time you ride a rickshaw. They are the transaction costs of rickshaw traveling. And each of these transactions carries a bit of tension with it. I think it's the 5-6 extra transactions a day that wore me down over time. You hardly notice it during the act, but once you don't have to do it, you are aware of your new-found freedom. With a car the main transaction is paying at the petrol station, but of course that's one transaction amortized across lots more traveling.

I wonder how improved life would be if we made "minimize/eliminate transactions" a design principle for society.

Monday, July 29, 2013

Invisible Art


The other day in the office I was speaking with an engineering candidate for his final round interview. We were looking at some code and I was explaining our architecture. Later on Hemakshi remarked to me, "You were so excited to talk about code!". I didn't realize it at the time, but I really was. Since I'm the only engineer on the team, I rarely get to do it, nor does the team hear me talk about it. But once we got into the discussion and the guy showed interest and asked good questions, it was really fun and engaging to talk about this body of work I have been chipping away at for the better part of the last four years.

I take a lot of pride in writing code. I'm not an elite software developer, but I try very hard to write clean, maintainable, intuitive, well-documented code. Only after Hemakshi made her comment did I realize that all of that writing will largely go unobserved by the rest of the world.

Software developers spend countless hours on a craft largely invisible to a viewing audience. The outward manifestation is certainly visible as end-user software, but the code will pretty much never be seen. The only chance for significant amounts of your code to be seen/scrutinized/admired is if you are a core developer on a popular open source project. And even then it's only other hackers. Otherwise for all to rest of us slogging it out in our little corners of github, no one cares. Maybe you can organize a party with your college buddies where you take turns projecting up some stuff you've been hacking on for work. But who would ever do that? And besides, it would mostly be illegal. Jo can't show me his Pixar code, if he did I'd later have to be shot.

But to me programming is art; at the very least it is creative self-expression. It's sad that a genre of art that so many people pour themselves into isn't shared/shareable. Out of fear that I will die without ever getting a chance to talk about my code to a general audience, here we go:



This is a part of our software's data model definition. Our data model has been really successful; it's stood the test of time quite well. There is one major mistake I made in it early on (created two different models for a user at a time when I didn't know you can cross-reference models from different Django applications) and few deprecated fields, but all-in-all a very neat and flexible data model. 

Not only am I proud of what the code does, but I'm proud of how it's written and commented. I've not worked much on large software teams, so I don't have a sense for what is good commenting, but I try to comment as much as possible, especially in the last year or so as I realized other folks will soon be working on it.


I would love for there to be an art exhibit on people's code. The MoMa should have an installation where people put up beautiful codes on the walls. I would totally go and marvel at different hacks in different languages. The exhibit should include a snippet from Nipun's ServiceSpace code, who has spent over a decade developing a multi-100K lines codebase mostly as a one-man engineering team. From the little I've worked on it, I can say it is tremendous, and the same attention to detail he puts into everything he does shows up in his code.


I imagine the MoMa Code exhibit would have the ribbon cut by Knuth, although my personal choice would be RMS since he's the Rick Rubin of software.

Wednesday, July 24, 2013

Wednesday, July 10, 2013

Driving License

I recently got an Indian driver's license. People here call it a driving license. Getting my license took many steps and much time, combining hilarity and insanity.

The process of getting an Indian driver's license can be summarized as a big charade. A license is an official government document, so there has to be real process with a real institution behind it. But as I learned, that process is highly bendable and even breakable. What was even more stunning was how hard it was to not bend the process. In other words, going through the process by the book required going out of your way to such an extent that it made attempting it highly unusual and/or insane.

How do I know this? It just so happened that my friend Shital was attempting to get her license at the same time I was. Shital is from the U.S., so we faced similar technical difficulties in getting a license. My approach to address the difficulties was to work through an agent, who provided you instruction on how to drive as well as steer you through the process of obtaining the license with the RTO (India's DMV). Basically, an agent is a middle man who has special relationships with the right people at the RTO to get your license in a frictionless way. Agents are not illegal; in fact the RTO pretty much endorses them. Shital decided to try without an agent. She rightly argued that using an agent is participation in a corrupted system, and the system will not change unless people resist it. More on how that turned out later.

My agent was named Bablubhai. He has a driving school (code for agency) on Ashram Road. Bablu was recommended by my rickshaw driver Narendra. My main criteria for an agent were dependability, quality of instruction, and cost. Bablubhai said he would get me my license without any trouble or delay. He gives the best instructions in town; students from one of the competing agencies nearby even come to him for lessons after failing to properly learn the first time. The other agencies teach in crappy cars, he gives lessons in a  higher-end Honda Brio. He seemed professional and confident.

Bablubhai's driving lessons consisted of 15 sessions of 30 minutes each. My instructor was Bablubhai's 20-something employee Chirag. Chirag and I would meet in front of the driving school, hop in the Brio, and go meandering around the area, driving in normal traffic so I could get a feel for it. Lot of the complexity in learning was taken away because I knew how to drive stick-shift; I could just focus on learning the ways of Indian traffic.

Much has been made about the chaos of Indian traffic, how there are no lanes and people honk lustily while avoiding cows and carts and cycles. How bigger has right of way over smaller, the exact opposite of America. How there is no "letting someone pass" or regard for traffic rules, and the culture is dog-eat-dog. All of this turns out to be true. In fact, my instructor Chirag would remind me of this constantly. He knew I came from a place where there was order and respect for rules. His catchphrase was "Kai 'rules and regulations' nathi" ("There are no rules and regulations").

I got the hang of the roads relatively quickly. Overall, I learned two main tricks for driving effectively and safely in India. The first is to drive slow. There is so much stuff happening around you. If you're driving fast, you may not be able to process everything in time and so your chances of mishap increase. The easiest way around that is to just drive slow. No one will honk at you for it, they will just maneuver around you and keep moving. The second trick I learned was to not look at any rear view mirrors. If you start looking around, you will freak out because there's all kinds of shit happening. It's better to keep a narrow focus and drive straight. If you mind yourself and don't make any sudden movements, everyone else around you will basically do the same thing and you will all get through it.

In Indian driving, there are no mistakes. People aren't going to get upset when you linger after a light has turned green or you brake suddenly. There's so much chaos that anything "wrong" you do at the individual level just blends in with the rest of the chaos. It's all part of the game, and there are no mistakes.

One of the most important and non-intuitive things to realize about driving in India is that knowing how to drive is a totally different matter from getting a license. In the U.S., the system is that having a license proves you know how to drive. In other words, the system is set up so you can't get a license unless you know how to drive. That's not how it works in India. In India, it is possible to get a license without never having driven, let alone being comfortable on the road. In fact, many people get a license, and after that seek out lessons to learn how to drive. This ridiculous situation is borne out of the fact (or perhaps reflects it) that the RTO is corrupt and fundamentally broken.

A few lessons into my learning I scheduled a time with Bablubhai to go to the RTO and get my kaachhu license (learner's permit).

The RTO in Ahmedabad is a deceptively huge building on aptly named RTO Circle near Ranip. Inside, it is a damp dingy labyrinth. As I walked through the various dark corridors looking for Bablubhai, I glanced into room after room full of dreary gray shelves to the ceiling full of old stained papers and documents. Around these shelves sat agents relentlessly doing paperwork.  Stacks of papers all around them, not a single computer in sight. I met Bablu, who led me hastily through this and that corridor. Bablubhai is a little man who moves like a torpedo missile. I had trouble keeping up with him. As he walked he would engage people he knew with a warm smile and how-do-you-do chit-chat. He talked a mile a minute. It occurred to me that Bablubhai's job was predicated on maintaining as many good relationships with as many people in the RTO as possible. We eventually entered one of the stacked rooms and parked in front of a fat man doing paperwork. Before we went to him, Bablu had advised me to not speak unless spoken to, and to let him do all the talking. My case was a bit sensitive because I was a US citizen and so didn't have any local ID. But with some sweet talking Bablu got a signed paper through that let me take the test for a learning license.

A few days earlier, Bablubhai had given me a book to study for the multiple choice test. I would have to answer 11 of 15 questions correctly about traffic rules and regulations. Instead of giving me a book of rules, though, Bablubhai gave me a book of all the questions (with answers) that would be asked on the test. If I just memorized all those questions, there would be no problem passing.

And of course he was right. I got called into the test room with a group of others. The room had computers in cubicles against all four walls. We sat at the cubicles and took the exam. I sat down and got question after question, each of which I recognized. I didn't have to even finish reading the question or read all the answers; I had memorized the location of the right answer. It took me 3 minutes to answer the first eleven questions I saw correctly. I went outside and around the corner, where I collected a crudely laminated black-and-white postcard sized printout of my photo and some identification details. I had my learner's permit!

I had 15 guaranteed 30-minute lessons with Chirag, but ended up only going through 13 because I had gotten the hang of it and a month had elapsed since I got my learner's permit, so I was eligible to go for my paaku license (official license). So on a Wednesday I showed up at 8:30 sharp as per Bablu's instructions to the RTO to take my road test.

I walked into the RTO's big dirt parking lot and found a buzz of activity. There were clusters of people, maybe 100 total, around 5-6 parked cars that belonged to a number of agencies around town. I found Bablu's cluster, he was busily filling out forms for all of his students who had shown up for the test. I tapped him on the shoulder; the look he gave me indicated he'd forgotten he had asked me to come. He pulled out a fresh form and scribbled my details on it. He asked if I knew how to drive a two-wheeler (motorcycle/scooter). I panicked; why the hell was he asking me that? Is it a part of my driving test? I was thrown off because he should know the answer, he was the one giving me driving lessons. I told him no, and he hung his head for a second. Then he said, "Don't worry, I'll handle that part of the test for you, just stand where I tell you to stand." As he scampered away I caught him and told him I wanted to do the test the "right" way; I didn't want any special treatment. This was a promise I had made to Shital, who inspired me by not giving into the corrupt agent system. He brushed me off. Sure sure, you will be taking the same test as everyone else.

As I stood around waiting for Bablu or someone else to tell me what to do, I noticed that some people were there for a car license, others for a two-wheeler license. The two-wheeler tests began first. Bablu stood next to an RTO agent, handing him a form from his stack to test each of his students one at a time. The two-wheeler test was ridiculous. You had to drive a motorcycle in a small figure eight in front of the RTO agent. That was it. It took no more than 20 seconds. Some people couldn't even do the figure eight, one lady could only take the cycle straight and couldn't turn. She drove into a crowd of people, braked just in time, got off the bike, and walked it back to the instructor. I think she passed. At one point Bablubhai handed the agent a form and then got on the scooter himself and did a sad stunted go-through-the-motions figure eight. I was pretty sure he was taking the two-wheeler test on my behalf.

The car test was just as absurd. I was able to go first out of Bablu's students since I was the NRI. We formed a line next to Bablu's car and a path was cleared 100 meters long ahead. The test was to drive in a straight line for those 100 meters. I got into the car with an RTO instructor in the passenger seat and another in the back. The one in the back sat with the stack of forms and handed the front agent one at a time to administer the test. I got in and buckled my seat belt, and waited. The agent, with no preamble, told me to turn on the car and drive forward. I did that, but worked slowly to not mess anything up. He was in a bigger rush, so he kept urging me to speed up. I started driving forward gingerly, making sure that I don't stall out the car. The agent said, "Go go!". The car had the two sets of driving pedals since it was an instructional vehicle. The agent put his own foot to his pedal and carried us to the finish line. I asked him if I should reverse back; I had noticed from other tests going on that people went forward and back. "No, that is all. Please sign this paper, you are finished." I signed and got out of the car. I wasn't even sure if I had passed, the agent didn't indicate one way or the other. I walked over to Bablubhai and asked him if that was it. Did I pass? He replied, "Well, did you sign the form? You can go home now."

Three weeks later, I got my license in the mail. It felt triumphant, and I was proud. On the other hand I looked back at the process and it felt like a big joke. Any fool can get a license, you don't even need to know how to drive. I used low-level corruption, and even worse it seemed like it was the only way to do things. Poor Shital is still in the process of getting her kaachu license; the first time she went to the RTO, they refused to let her take the computer test because she didn't have a document proving she had a residence in Ahmedabad (even though she did). They said her rental agreement was invalid because it wasn't notarized. Unfortunately she couldn't get it notarized because her landlord was in the U.S.. She argued with a number of people until she made it to a hidden room in the RTO where the head man sat. He was sympathetic to her cause, but one of the lower-level ladies refused to let her go on a small technicality. Later Shital returned to the RTO with notarized documents, only to be refused by the RTO worker because the date of notarization wasn't within the required timeframe.

On the other end of the spectrum, another American friend of mine (who will remain anonymous) walked into the RTO and out with his official license in hand in a single day. His process even bypassed the agent. Without taking a single lesson, without taking the computer test, without even waiting for the license in the mail, this friend knew and paid off the right people in the RTO and completed the entire process (which took me two months, and has taken Shital 5 months and counting) in a few hours.

Getting official documentation to drive in India is just like driving in India. It seems broken and arbitrary, but in spite of itself it continues to work.