If there's one city in the world where it's hard to find a place to buy or rent, it's Sydney. And if you've tried to find a home here recently, you're familiar with the problem. Every time you walk into an open house, you get some information about what's out there and what's on the market, but every time you walk out, you're running the risk of the very best place passing you by. So how do you know when to switch from looking to being ready to make an offer?
Se existe uma cidade no mundo onde é difícil comprar ou alugar uma casa, essa cidade será Sydney. Se já tentaram encontrar uma casa por estas bandas, então já sabem o que vos espera. Sempre que entramos numa imobiliária encontramos informações sobre os imóveis disponíveis e os que estão no mercado. Porém, ao sair de lá aquela casa mesmo boa para nós pode já não estar disponível! Então, como poderemos saber quando podemos passar da procura e estamos prontos para fazer uma oferta?
This is such a cruel and familiar problem that it might come as a surprise that it has a simple solution. 37 percent.
Isto é um problema tão cruel e familiar, que quando vos disser que há uma solução simples, ficarão admirados: É 37%.
(Laughter)
(Risos)
If you want to maximize the probability that you find the very best place, you should look at 37 percent of what's on the market, and then make an offer on the next place you see, which is better than anything that you've seen so far. Or if you're looking for a month, take 37 percent of that time -- 11 days, to set a standard -- and then you're ready to act.
Para maximizar a probabilidade de encontrar a melhor casa, devem procurar em 37% do que existe no mercado e depois, façam uma proposta para a segunda melhor casa que encontraram até aí. Caso tenham procurado durante um mês, usem 37% desse tempo — 11 dias, como padrão — e aí, estarão prontos para agir.
We know this because trying to find a place to live is an example of an optimal stopping problem. A class of problems that has been studied extensively by mathematicians and computer scientists.
Sabemos isso porque encontrar um lugar para viver é um exemplo de um problema de paragem otimizada. Uma classe de problemas que têm sido estudados intensivamente por matemáticos e por cientistas de informática.
I'm a computational cognitive scientist. I spend my time trying to understand how it is that human minds work, from our amazing successes to our dismal failures. To do that, I think about the computational structure of the problems that arise in everyday life, and compare the ideal solutions to those problems to the way that we actually behave. As a side effect, I get to see how applying a little bit of computer science can make human decision-making easier.
Sou um cientista de cognição computacional. Passo o tempo a tentar compreender como funciona a mente humana dos nossos sucessos extraordinários aos terríveis fracassos. Para isso, penso nas estruturas computacionais dos nossos problemas diários comparando as soluções ideais para esses problemas com os nossos comportamentos. Num efeito colateral consigo ver como a aplicação da ciência informática ajuda a tornar mais fáceis as nossas decisões diárias.
I have a personal motivation for this. Growing up in Perth as an overly cerebral kid ...
Eu tenho uma motivação pessoal para isto. Fui criado em Perth, como um jovem excessivamente cerebral.
(Laughter)
(Risos)
I would always try and act in the way that I thought was rational, reasoning through every decision, trying to figure out the very best action to take. But this is an approach that doesn't scale up when you start to run into the sorts of problems that arise in adult life. At one point, I even tried to break up with my girlfriend because trying to take into account her preferences as well as my own and then find perfect solutions --
Sempre procurei a forma mais racional de agir, ponderando cada decisão para tentar descobrir a melhor ação a tomar. Contudo, esta é uma abordagem que não evolui quando tentamos tratar de todos os tipos de problemas que aparecem na idade adulta. A certa altura, até tentei acabar com a minha namorada porque, tentar ter em conta tanto as preferências delas como as minhas e procurar as soluções ideais
(Laughter)
(Risos)
was just leaving me exhausted.
estava a deixar-me exausto.
(Laughter)
(Risos)
She pointed out that I was taking the wrong approach to solving this problem -- and she later became my wife.
Ela fez notar que aquela não era a abordagem adequada para a resolução deste problema e acabou por ser a minha mulher.
(Laughter)
(Risos)
(Applause)
(Aplausos)
Whether it's as basic as trying to decide what restaurant to go to or as important as trying to decide who to spend the rest of your life with, human lives are filled with computational problems that are just too hard to solve by applying sheer effort. For those problems, it's worth consulting the experts: computer scientists.
Quer seja tão básico como decidir a que restaurante ir ou tão importante quanto tentar decidir com quem passar o resto da vida, a vida humana está cheia de problemas informáticos que são complicados demais para resolver, usando o puro empenho. Para esses problemas, vale a pena consultar os especialistas: os cientistas informáticos.
(Laughter)
(Risos)
When you're looking for life advice, computer scientists probably aren't the first people you think to talk to. Living life like a computer -- stereotypically deterministic, exhaustive and exact -- doesn't sound like a lot of fun. But thinking about the computer science of human decisions reveals that in fact, we've got this backwards. When applied to the sorts of difficult problems that arise in human lives, the way that computers actually solve those problems looks a lot more like the way that people really act.
Quando procuramos um conselho para a vida, os cientistas informáticos não serão os primeiros com quem pensamos falar. Viver a vida como um computador, — estereotipadamente determinista, exaustivo e exato — não parece muito divertido. Mas pensar na ciência informática das decisões humanas, revela que entendemos isto de forma errada. Quando aplicado aos vários tipos de problemas difíceis que surgem na vida humana, o modo como os computadores resolvem esses problemas parece-se muito com a forma como as pessoas agem de facto.
Take the example of trying to decide what restaurant to go to. This is a problem that has a particular computational structure. You've got a set of options, you're going to choose one of those options, and you're going to face exactly the same decision tomorrow. In that situation, you run up against what computer scientists call the "explore-exploit trade-off." You have to make a decision about whether you're going to try something new -- exploring, gathering some information that you might be able to use in the future -- or whether you're going to go to a place that you already know is pretty good -- exploiting the information that you've already gathered so far. The explore/exploit trade-off shows up any time you have to choose between trying something new and going with something that you already know is pretty good, whether it's listening to music or trying to decide who you're going to spend time with. It's also the problem that technology companies face when they're trying to do something like decide what ad to show on a web page. Should they show a new ad and learn something about it, or should they show you an ad that they already know there's a good chance you're going to click on?
Vejam o exemplo de tentar decidir a que restaurante ir. Este é um problema que tem uma estrutura informática particular. Temos um leque de opções, vamos escolher uma dessas opções, e vamos encarar a mesma decisão amanhã. Nessa situação, vamos contra aquilo a que os cientistas chamam "escolha entre explorar ou aproveitar". Temos de tomar uma decisão sobre se vamos experimentar algo novo — explorando, reunindo algumas informações que poderemos usar no futuro — ou se vamos a um local que já sabemos que é bom — aproveitando as informações que já reunimos até aqui. A "escolha entre explorar e aproveitar" acontece sempre que temos de escolher entre algo novo ou algo que já sabemos que é bom, quer seja ouvir música ou decidir com quem vamos passar o tempo. Isso também é um problema que as empresas tecnológicas têm quando tentam decidir algo como qual o anúncio a mostrar num "site". Devemos publicar um novo anúncio e aprender algo com isso, ou devemos publicar um anúncio que já sabemos que tem uma boa hipótese de obter cliques?
Over the last 60 years, computer scientists have made a lot of progress understanding the explore/exploit trade-off, and their results offer some surprising insights. When you're trying to decide what restaurant to go to, the first question you should ask yourself is how much longer you're going to be in town. If you're just going to be there for a short time, then you should exploit. There's no point gathering information. Just go to a place you already know is good. But if you're going to be there for a longer time, explore. Try something new, because the information you get is something that can improve your choices in the future. The value of information increases the more opportunities you're going to have to use it.
Nos últimos 60 anos, os cientistas da informática fizeram grandes progressos compreendendo a "escolha entre explorar ou aproveitar", e os resultados oferecem visões surpreendentes. Quando estamos a tentar decidir a que restaurante ir, a primeira pergunta que devem fazer é: durante quanto tempo mais ficarão na cidade. Se lá vão ficar apenas durante um curto período de tempo, devem aproveitar. Não há vantagem em procurar novas informações. Vão a um local que já sabem que é bom. Mas, se forem permanecer durante muito tempo, explorem. Tentem algo de novo, porque as informações que conseguirem podem melhorar as vossas escolhas futuras. O valor dessas informações aumenta quanto mais oportunidades tiverem de as usar.
This principle can give us insight into the structure of a human life as well. Babies don't have a reputation for being particularly rational. They're always trying new things, and you know, trying to stick them in their mouths. But in fact, this is exactly what they should be doing. They're in the explore phase of their lives, and some of those things could turn out to be delicious. At the other end of the spectrum, the old guy who always goes to the same restaurant and always eats the same thing isn't boring -- he's optimal.
Este princípio também pode dar-nos a visão da estrutura duma vida humana. Os bebés não têm uma reputação de serem particularmente racionais. Estão sempre a tentar coisas novas. E a tentar metê-las na boca. Mas, de facto, isso é exatamente o que eles devem fazer. Eles estão na fase exploradora da vida, e algumas dessas coisas podem revelar-se deliciosas. Na outra ponta do espetro, o idoso que vai sempre ao mesmo restaurante e come sempre a mesma coisa não é chato, está otimizado.
(Laughter)
(Risos)
He's exploiting the knowledge that he's earned through a lifetime's experience. More generally, knowing about the explore/exploit trade-off can make it a little easier for you to sort of relax and go easier on yourself when you're trying to make a decision. You don't have to go to the best restaurant every night. Take a chance, try something new, explore. You might learn something. And the information that you gain is going to be worth more than one pretty good dinner.
Está a explorar os conhecimentos que já adquiriu durante a vida inteira. Mais genericamente, conhecer a "escolha entre explorar e aproveitar" pode ajudar-vos a relaxar e ajudar-vos a tomar uma decisão. Não precisam de ir ao melhor restaurante todas as noites. Experimentem, tentem algo de novo, explorem. Vão aprender algo. As informações que adquirirem vão valer mais do que um bom jantar.
Computer science can also help to make it easier on us in other places at home and in the office. If you've ever had to tidy up your wardrobe, you've run into a particularly agonizing decision: you have to decide what things you're going to keep and what things you're going to give away. Martha Stewart turns out to have thought very hard about this --
A ciência da informática também pode facilitar-nos a vida noutros lugares, em casa e no escritório. Se um dia precisarmos de organizar o nosso guarda-roupa, temos de tomar uma decisão particularmente angustiante: precisamos de decidir quais as coisas que vamos manter e quais as coisas que vamos dar. Acontece que Martha Stewart pensou muito nisso
(Laughter)
(Risos)
and she has some good advice. She says, "Ask yourself four questions: How long have I had it? Does it still function? Is it a duplicate of something that I already own? And when was the last time I wore it or used it?" But there's another group of experts who perhaps thought even harder about this problem, and they would say one of these questions is more important than the others. Those experts? The people who design the memory systems of computers. Most computers have two kinds of memory systems: a fast memory system, like a set of memory chips that has limited capacity, because those chips are expensive, and a slow memory system, which is much larger. In order for the computer to operate as efficiently as possible, you want to make sure that the pieces of information you want to access are in the fast memory system, so that you can get to them quickly. Each time you access a piece of information, it's loaded into the fast memory and the computer has to decide which item it has to remove from that memory, because it has limited capacity.
e tem bons conselhos a dar-nos: "Faça quatro perguntas a si mesmo: "Há quanto tempo eu tenho isto? "Isto continua a ser usado? "Isto é uma repetição de algo que eu já tenha? "Quando foi a última vez que eu vesti ou usei isto?" Mas há um outro grupo de especialistas que talvez tenha pensado ainda mais neste problema, e eles diriam que uma destas perguntas é mais importante do que as outras. Quem são esses especialistas? As pessoas que desenvolveram o sistema de memória dos computadores. Os computadores têm dois sistemas de memória: uma memória rápida do sistema, como uma série de "chips" com capacidade limitada, porque esses "chips" são caros, e o sistema de memória lenta, que é muito maior. Para o computador funcionar da forma mais eficiente possível, queremos assegurar que as informações a que queremos aceder estão na memória rápida do sistema, para podermos aceder-lhes rapidamente. Sempre que acedemos a um pedaço de informação, ele é carregado na memória rápida e o computador tem de decidir qual o item que tem de retirar da memória, porque tem uma capacidade limitada.
Over the years, computer scientists have tried a few different strategies for deciding what to remove from the fast memory. They've tried things like choosing something at random or applying what's called the "first-in, first-out principle," which means removing the item which has been in the memory for the longest. But the strategy that's most effective focuses on the items which have been least recently used. This says if you're going to decide to remove something from memory, you should take out the thing which was last accessed the furthest in the past. And there's a certain kind of logic to this. If it's been a long time since you last accessed that piece of information, it's probably going to be a long time before you're going to need to access it again. Your wardrobe is just like the computer's memory. You have limited capacity, and you need to try and get in there the things that you're most likely to need so that you can get to them as quickly as possible. Recognizing that, maybe it's worth applying the least recently used principle to organizing your wardrobe as well. So if we go back to Martha's four questions, the computer scientists would say that of these, the last one is the most important.
Com o passar dos anos, os informáticos tentaram algumas estratégias diferentes para decidir o que remover da memória rápida. Tentaram coisas como escolher aleatoriamente ou aplicar o princípio do "primeiro a entrar, primeiro a sair," ou seja, remover o item que está na memória há mais tempo. Mas a estratégia que é mais eficaz concentra-se nos itens menos usados mais recentemente. Ela diz que, se decidimos tirar algo da memória, devemos tirar a coisa a que acedemos pela última vez há mais tempo. E há um certo tipo de lógica nisso. Se já passou muito tempo que acedemos a esse pedaço de informação, provavelmente vai passar muito tempo antes de precisarmos de voltar a aceder-lhe. O nosso guarda-roupa é igual à memória do computador. Temos uma capacidade limitada, e precisamos de manter ali as coisas de que mais precisamos para as ter à mão o mais rápido possível. Reconhecendo isso, talvez valha a pena usar o princípio de "o usado há mais tempo" para organizar também o guarda-roupa. Se voltarmos às quatro perguntas da Martha, os cientistas informáticos dirão que, de todas elas, a última é a mais importante.
This idea of organizing things so that the things you are most likely to need are most accessible can also be applied in your office. The Japanese economist Yukio Noguchi actually invented a filing system that has exactly this property. He started with a cardboard box, and he put his documents into the box from the left-hand side. Each time he'd add a document, he'd move what was in there along and he'd add that document to the left-hand side of the box. And each time he accessed a document, he'd take it out, consult it and put it back in on the left-hand side. As a result, the documents would be ordered from left to right by how recently they had been used. And he found he could quickly find what he was looking for by starting at the left-hand side of the box and working his way to the right.
Esta ideia de organizar as coisas de forma a que as coisas de que mais precisamos estejam mais à mão também podem ser aplicadas no nosso escritório. O economista japonês Yukio Noguchi inventou um sistema de arquivos que tem exatamente esta propriedade. Começou com uma caixa de cartão, e pôs os documentos dentro da caixa, da esquerda para a direita. Sempre que adicionava um documento, movia o que lá estava lá e adicionava esse documento do lado esquerdo da caixa. Sempre que acedia a um documento, tirava-o, consultava-o e voltava a pô-lo do lado esquerdo. Assim, os documentos ficavam ordenados da esquerda para a direita pela ordem da altura em que tinham sido usados. Assim, achava rapidamente o que estava a procurar começando pelo lado esquerdo da caixa e avançando para a direita.
Before you dash home and implement this filing system --
Antes de correrem para casa e implementarem este sistema de arquivo,
(Laughter)
(Risos)
it's worth recognizing that you probably already have.
vale a pena reconhecer que provavelmente já o têm.
(Laughter)
(Risos)
That pile of papers on your desk ... typically maligned as messy and disorganized, a pile of papers is, in fact, perfectly organized --
Aquela pilha de papéis na secretária... habitualmente caluniada como desarrumada e desorganizada, uma pilha de papéis que, na verdade, está perfeitamente organizada,
(Laughter)
desde que, quando tiramos um papel,
as long as you, when you take a paper out, put it back on the top of the pile, then those papers are going to be ordered from top to bottom by how recently they were used, and you can probably quickly find what you're looking for by starting at the top of the pile.
o coloquemos de volta no topo da pilha, esses papéis estão organizados de cima para baixo pela ordem da altura em que foram usados e, provavelmente, conseguem encontrar rapidamente o que procuram, começando pelo topo da pilha.
Organizing your wardrobe or your desk are probably not the most pressing problems in your life. Sometimes the problems we have to solve are simply very, very hard. But even in those cases, computer science can offer some strategies and perhaps some solace. The best algorithms are about doing what makes the most sense in the least amount of time. When computers face hard problems, they deal with them by making them into simpler problems -- by making use of randomness, by removing constraints or by allowing approximations. Solving those simpler problems can give you insight into the harder problems, and sometimes produces pretty good solutions in their own right.
Organizar o nosso guarda-roupa ou a nossa secretária provavelmente não são os problemas mais urgentes da nossa vida. Às vezes os problemas que temos de resolver são muito, muito difíceis. Mas mesmo nesses casos, a ciência informática pode oferecer algumas estratégias e, quem sabe, algum consolo. Os melhores algoritmos são sobre fazer o que tem mais sentido no menor espaço de tempo. Quando um computador encara problemas difíceis, lida com eles transformando-os em problemas mais simples, usando a aleatoriedade, removendo restrições ou permitindo aproximações. Resolver esses problemas mais simples, pode dar-nos ideias para os problemas mais difíceis, e, às vezes, por si só aparecem boas soluções.
Knowing all of this has helped me to relax when I have to make decisions. You could take the 37 percent rule for finding a home as an example. There's no way that you can consider all of the options, so you have to take a chance. And even if you follow the optimal strategy, you're not guaranteed a perfect outcome. If you follow the 37 percent rule, the probability that you find the very best place is -- funnily enough ...
Saber tudo isso tem-me ajudado a relaxar quando tenho de tomar decisões. Podemos pegar na regra de 37% para achar uma casa, como exemplo. Não há forma de considerarmos todas as opções, por isso precisamos de arriscar. E, mesmo que sigamos a estratégia ideal, não temos a garantia de um resultado perfeito. Se seguirmos a regra dos 37%, a probabilidade de acharmos o melhor lugar curiosamente
(Laughter)
(Risos)
37 percent. You fail most of the time. But that's the best that you can do.
é de 37%. Falhamos na maioria das vezes. Mas é o melhor que podemos fazer.
Ultimately, computer science can help to make us more forgiving of our own limitations. You can't control outcomes, just processes. And as long as you've used the best process, you've done the best that you can. Sometimes those best processes involve taking a chance -- not considering all of your options, or being willing to settle for a pretty good solution. These aren't the concessions that we make when we can't be rational -- they're what being rational means.
Em última instância, a ciência informática pode ajudar-nos a perdoarmos as nossas limitações. Não podemos controlar resultados, só processos. E desde que usemos o melhor processo, fizemos o melhor que podíamos. Às vezes esses processos melhores envolvem correr riscos, sem considerar todas as opções, ou estando dispostos a aceitar uma boa solução. Estas não são concessões que fazemos quando não conseguimos ser racionais, — são o que significa ser racional.
Thank you.
Obrigado.
(Applause)
(Aplausos)