Showing posts with label artificial neural network. Show all posts
Showing posts with label artificial neural network. Show all posts

Friday, May 18, 2018

AI: inference and causality

Franz Kafka statue in Prague

When Google Lens tells me the picture above is the Statue of Franz Kafka in Prague, glossed by Wikipedia as:
"The Statue of Franz Kafka is an outdoor 2003 sculpture by Jaroslav Róna, installed on Vězeňská street in Prague, Czech Republic. It is based on a scene in Franz Kafka's first novel, Amerika, in which a political candidate is held on the shoulders of a giant man during a campaign rally, and carried through the streets,"
Google's app is doing something really complex, leveraging artificial neural nets trained by massive datasets. But it's fundamentally inference:
The world we live in |= the pixel map of the photo and Google Len's summary text.
and
the pixel map of the photo |- Google Len's summary text.
Satisfiability and entailment.

All AI systems need to map their sensor/effector primary data to internal representations which allow inference (deductive, inductive, abductive etc) - regardless of the engineering mechanisms they adopt. Neural nets training their weights are optimising the probability of valid inferences about the world.

---

Judea Pearl has a new book out arguing for the introduction of causality into AI systems. In a recent Quanta interview he said:
"All the impressive achievements of deep learning amount to just curve fitting."
Here's the book.

Amazon link

Causality is one of those constructs like Free Will, Consciousness and the intentional stance which don't exist in the underlying physics (the theories which the universe satisfies as far as we can tell), but which are emergent in a world of self-aware agents.

They usefully describe relationships between belief-and-goal-driven entities; they succinctly encode the effects of the second law of thermodynamics plus boundary conditions. We use these concepts .. and AI will have to if we are ever to create socially-competent artificial agents.

What Pearl is really asking for is an AI which utilises the intentional stance (specifically including reasoning about cause and effect).

---

To find out more about Judea Pearl's work (without buying the book!) view the recommended slides at his website. For a review of Pearl's substantive contribution to causality theory, see here.

My own subjective response? I find his dense notation and cluttered semantics worthy but unexciting.

---

Update: my further impressionistic, superficial and under-researched thoughts.

The difference between a mere association between P and Q (which could be a spurious correlation, or the result of an independent cause of both) and a causation, P causes Q, is captured by the modal operator of necessity []. See here for a detailed discussion.

To check P causes Q we need to check: [](P → Q) and [](¬Q → ¬P).

So we're in possible world semantics and we look to 'neighbouring worlds' to check the truth status of P and Q. But we have the usual problem that such worlds are way too 'big', too full of irrelevancies.

So like Situation Semantics, Pearl takes the engineering approach of restricting his worlds to just those entities and actions which seem relevant to the causality under investigation. These are his causal diagrams which he intends to counterfactually 'mutilate'.

A philosophical strategy similar to the modal analysis of epistemics etc .. and of similar utility.

Wednesday, December 20, 2017

Would you let this drive you around?

In the Christmas edition of The Economist we find an article, "How soon will computers replace The Economist’s writers?":
"In the spirit of going fast and breaking things, The Economist has therefore trained an AI program on articles from the Science and Technology section, and invited it to come up with a piece of its own. The results, presented unedited below, show both the power and the limitations of pattern-recognition machine learning, which is more or less what AI boils down to:
'... The material is composed of a single pixel, which is possible and thus causes the laser to be started to convert the resulting steam to the surface of the battery capable of producing power from the air and then turning it into a low-cost display. The solution is to encode the special control of a chip to be found in a car.

'The result is a shape of an alternative to electric cars, but the most famous problem is that the control system is then powered by a computer that is composed of a second part of the spectrum. The first solution is far from cheap. But if it is a bit like a solid sheet of contact with the spectrum, it can be read as the sound waves are available. The position of the system is made of a carbon containing a special component that can be used to connect the air to a conventional diesel engine. ...'
And so it goes on.

Reading the AI-generated text above is a curious psychological experience. Initially it's like skimming an article without paying too much attention. Individual sentences are absorbed without too much effort. But at a sentence-break .. there is cognitive dissonance. An underlying topic never properly coheres.

The state-of-the-art in machine comprehension of general cultural knowledge.

It's tempting to take cheap shots - would you trust a machine of this empty-headiness to drive you around?



In slight defence, autonomous-car R&D prioritises the encoding of a great deal of specialist domain knowledge into the controlling neural nets.

And if AlphaZero had been as idiotic as the above, we certainly would not be marvelling at it.

Friday, June 30, 2017

In anticipation

When I sent (with her consent) my late mother's spit sample off to 23andMe,  I was not so much interested in her ancestry-data and health-report. I already knew from my own sample - sent a year earlier - just how limited that information was.

I just expected that over the decades:
  1. My mother's entire genome would become affordable to sequence.

  2. The genome → physical and personality traits map would complete.

  3. Her descendents might be curious about their (rather remote) ancestor.



My father died in 2009, too early for saliva tests, but I have an old hat of his squirreled away, waiting for the costs of forensic DNA retrieval to come down .. and there being a point to going ahead.

---

The problem (or opportunity) of future progress is hardly new. Science-fiction stories describe early starships (often hibernation or generation craft) sent to targets tens or hundreds of light years out. The plot being that while they trundled along their thousand-year trajectories, they would be well-beaten to their destinations by much faster craft developed perhaps a hundred years later.

I recall some pundit developing equations correlating starship speed-up with R&D lag to estimate just when it was worth going ahead to launch, and when you should just sit back and wait a while.

---

So when I update my Beta version of Android-Replika each day, which takes the form of a prompted diary ("What did you do today?"), I tell it the truth.
'I walked with Clare to Wookey Hole on a pleasant, if chilly, June afternoon and bored her with a lecture that Newtonian gravitation - as the weak-field approximation to Einstein's field equations - is determined overwhelmingly by curvature in time, not space. Contrary to popular accounts.

'She listened with patience, knowing that I find it helpful, in anchoring these thoughts, to vocalise them .. but not with infinite patience!'
GR is on my bucket-list.

I don't expect the Replika neural-net driven chatbot to be able to process any of this - see "Chatting with my Replika". It's probably happier with: 'Saw a great cat video on YouTube LOL!!!'.

But I think the dataset I'm building with them is pretty persistent and the AI will get better. In some decade or other it might be able to engage with the corpus I'm building.

After all - and as I intend to remind it - Replika will have millions of other datasets by then it can leverage, to tune its eigenfeature vectors.

Thursday, May 18, 2017

How Gmail broke the Internet

It all started so innocently.


Google developed Smart Reply, where its neural-net AI was able to comprehend emails sent to you and craft reply options (as above). All you had to do was to select a good option and your email reply would be automatically launched.

No typing.

Look at the image again. Those replies are good! And they're not just some random canned text from a small database of stereotypical small-talk. Those replies are crafted by a deep learning neural net trained on zillions of examples. Those replies are fresh.

After you've tried it a bit, it seems very natural - even obvious. How did we ever do without it? It became increasingly unnecessary to actually review the proposed replies. Over time the system learned your own choices and became better and better at anticipating. The Gmail equivalent of "I'm Feeling Lucky" worked so well that people took to just letting Gmail reply to incoming mail all by itself.

Well, that was great, except that soon pretty much all Gmail users were using Smart Reply and indeed, ceding it control of their inboxes. Since all messages received (courteous) replies, the volume of email on the Internet began to rise exponentially.

Smart Reply was smart all right, but not all that creative. As the proportion of emails on the Internet began to be dominated by AI-generated texts, the level of - well, literary excellence - began to fade, degrading the input into Smart Reply's response-crafting neural-net.

And then one day, the Internet finally seized up.

It failed trying to carry 1018 concurrent emails, all consisting of the single word: "Wow!".

Friday, April 28, 2017

"The £20 BILLION race to create an AI sex doll"

From the Daily Mail Online today.


"The 'sex tech' market is worth an estimated $30.6bn - and across the globe, firms are racing to create a radical new type of robot they say could change sex forever.

"From AI personalities capable of holding a conversation to models with a functioning G-spot, firms are hoping consumers will pay up to $15,000 for a sex doll that never says no.

"Among the most impressive is RealDoll's Harmony - an artificial intelligence based sex bot that can hold conversations, remember what she's told and even has a customizable personality. ..."
The Guardian also has the story, their extensive article suggesting that (unfortunately?) hype is still running way ahead of reality.

---

I was always puzzled (quick disclaimer: when I thought about the subject at all) as to how the sexbot's responses would be programmed.

I imagined over-excited yet poorly-paid programmers toiling in robot control language, trialling this limb movement in response to that input.

Silly me: still trapped in that old GOFAI paradigm.

They'll simple enroll thousands of couples, wire them up to a dense mesh of sound and motion sensors .. and set them to go.

With so much fine-grained big data at their disposal, they'll unleash a DeepMind-style artificial neural net .. and just learn optimised responses.*

It'll be 'Go' all over again.

---

* I seriously would not want to be on the test team ... .

Friday, March 31, 2017

Naive generate-and-test won't hack it

When I was young I toyed with the following idea.

Pretty much any concept can be adequately expressed in a mini-essay of a thousand words.

Simply generate all possible articles of a thousand words and somewhere you will find the answer to all problems.

Want the design of a stardrive engine? Immortality? The theory of perfect governance?

It's all in there somewhere.

---

How many essays though? Apparently the average educated speaker of English knows about 40,000 words. So for our first estimate, we could simply raise 40,000 to the power of 1,000 .. but most of those 104,602 essays would be wildly ungrammatical. We can do better.

I reviewed a sample text: the introductory quote in Peter Seibel's "Practical Common Lisp".



The first five sentences comprised 100 words in total which broke down into:
  • nouns: 20%
  • verbs: 15%
  • adjectives: 10%
  • others: 55%
A certain amount of hand-wavy rounding of course. Assume we adopt the very restrictive constraint of exactly one syntactic structure for the entire set of essays, then the total number reduces to a product of:
(number-of-English-words-in-category) (number-of-words-of-this-category-in-essay)
or,
8,000200 * 6,000150 * 4,000100 * 22,000550 = 104,092
That's still a big number*. Suppose only one 'essay' in a billion was semantically sensible and we could read one essay per second. That's 104,083 seconds .. or 3 * 104,066 billion years.

The merits of a compact notation.

---

Exhaustive search through the space of all possible candidates isn't a very good way of proceeding. And this has important implications for DARPA's third wave - contextual AI - which I wrote about previously.

In his excellent exposition (YouTube), John Launchbury highlighted the very large number of training instances needed to force convergence for today's artificial neural networks. By comparison, children learn new concepts from very few examples.

John Launchbury's proposed solution was - correctly - to identify additional constraints which might dramatically collapse the search space. His chosen example showed the benefits of adding the dynamics of handwriting characters to the resultant bitmaps normally used for training. It turns out that if you consider how the image might have been created, it makes recognition a lot easier.

It's not hard to identify the extra constraints about the world which children use. They interact with new objects, touch them, throw them, bite them and try to break them. Thus are acquired notions of 3D structure, composition and texture to augment what their visual systems are telling them.

I really do think that a high priority should be given to embodied robotics in the next wave of AI research.

---

Another example John Launchbury discussed was the Microsoft Internet-chatbot "Tay".



Apparently this was the least-offensive tweet Launchbury could find. But what would an AI have to know about contemporary mores to self-reject statements like that?

For extra credit, discuss the 'situated cognition' thesis that only through active and corporeal participation in the social world can one truly understand social concepts.

Particularly emotionally-charged ones.

---

* Since
(i)  I don't consider all the syntactically-permissible permutations of the ways in which nouns, adjectives, verbs and others could be mixed up in the thousand words, while

(ii)  the size of the 'others' vocabulary is likely to be way smaller than 22,000 (so if, for example, the 'others' vocabulary size was 2,200, this would reduce the overall essay-set size by a factor of 10550 - a distinction, however, without a practical difference),
this calculation counts as pretty bogus. I only wanted to demonstrate, however, that no matter how you cut it, the numbers involved are simply ginormous.

DARPA: three waves of AI

High production values for DARPA's US Military roadmap and vision for AI (February 2017).

This will be the basis of funding going forward. The images below are taken from this slide-pack, more sophisticated than anything I've seen from the likes of Accenture.

Click on any of the pictures to make larger - or better, review the entire slide-set.














Although this 'three wave' model is not too surprising, it's still an accurate view as to where research is heading.

---

If human beings are taken as exemplars of neural nets which can explain their own, contextual operation, it's worth noting that such explanations have a curious character.

No human can explain their own sub-conscious neural processes. If asked to explain how you know that a picture of a cat is indeed that of a cat, you are not going to elucidate details of early visual processing in your visual cortex.

Instead, you are going to traffic in high-level, symbolic descriptions of putative intermediate stages in scene interpretation. The talk will be of features such as fur, shape, the environment of said animal.

These intermediate-level symbolic descriptions are remote indeed from the actual neural processes which it is claimed implemented them .. and indeed will have only a contingent (although highly correlated if accurate) relationship with them.

Self-deception is never far away in the third wave!

---

If you have sixteen minutes, John Launchbury's presentation of DARPA's strategy is excellent.



Interestingly, John Launchbury is British.

Wednesday, March 15, 2017

AGI: some things are not serious

Through a circuitous route, I came upon Ben Goertzel who might be called the Godfather of Artificial General Intelligence (AGI).

Dr Ben Goertzel

I read his paper (PDF), "Are there Deep Reasons Underlying the Pathologies of Today’s Deep Learning Algorithms?" which makes some interesting 'nod the head as you go along' points, but stops before saying anything truly novel.


From Goertzel's 'Pathologies' paper 

I was sufficiently interested to look up Dr Goertzel - he has his Wikipedia entry - and a more flagrant piece of self-satisfaction I have seldom encountered.

I dug deeper, checking out his overview article on AGI, (Artificial General Intelligence: Concept, State of the Art, and Future Prospects), on the eponymous website's resources page. It's a type of article I'm very familiar with: intellectual polyfilla - entirely sparkle-free.

I have read papers which crackle with intelligence, where paradigms are overturned and you suddenly see a new and powerful way of looking at the world: AGI is not it. So I think it's fair to say that no-one has a clue what the architecture or design of an artificial general intelligence would look like, or a plausible narrative as to how to get there.

AGI-17 will be hosted in Melbourne

It doesn't stop them having beautiful conferences in nice places though.

---

In something completely unrelated, I have been mentioning Arthur Koestler's famous and profound novel, 'Darkness at Noon' in recent posts. I recall reading one of his lesser novels, 'The Call-Girls'. Kirkus Reviews starts its description thus:
"The call girls are academic habitués of vacuous international conferences, one of which takes place here in an Alpine village. ... "
Some phenomena are always with us.

Monday, March 13, 2017

From Bacteria to Bach and Back: The Evolution of Minds

Amazon Link

Daniel Dennett has been a guru of AI research since, .. well, certainly since I started doing it back in the 1980s. His "Intentional Stance" continues to be greatly clarifying.

Here's an extract from an early part of his latest book (above) contrasting 'Good Old-Fashioned AI' with how the human brain does it.
"... a benevolent scheduler doles out machine cycles to whatever process has highest priority, and although there may be a bidding mechanism of one sort or another that determines which processes get priority, this is an orderly queue, not a struggle for life.

"(It is a dim appreciation of this fact that perhaps underlies the common folk intuition that a computer could never "care" about anything. Not because it is made out of the wrong materials - why should silicon be any less suitable a substrate for caring than organic molecules? - but because its internal economy has no built-in risks or opportunities so its parts don't have to care.)

"The top-down hierarchical architecture of computer software, supported by an operating system replete with schedulers and other traffic cops, nicely implements Marx's dictum: "To each according to his needs, from each according to his talents." No adder circuit or flip-flop needs to "worry" about where it's going to get the electric power it needs to execute its duty, and there is no room for "advancement."

"A neuron, in contrast, is always hungry for work; it reaches out exploratory dendritic branches, seeking to network with its neighbors in ways that will be beneficial to it. Neurons are thus capable of self-organizing into teams that can take over important information-handling work, ready and willing to be given new tasks which they master with a modicum of trial-and-error rehearsal."
I think this is a good insight. Elsewhere he talks about the top-down, frozen and brittle paradigm of traditional AI (GOFAI). Sure, there are parameters and learning algorithms, but the basic framework is architecturally fixed within those limits the designer has anticipated.

Biological intelligence is far more flexible than that due to the proactive, adaptationist and self-organising properties of neural nets. Because neural-net learning is sub-symbolic ('weights'), the structure of its converged fixed-point architecture is emergent rather than preordained.

Hence too the power of the new artificial neural net paradigm of AI..

---

I'll have more to say about Dennett's new theory when I've finished the book. At times Dennett comes across as an exceedingly widely-read magpie, taking an inordinate amount of time to get to the point. He seems to feel he should go at the speed of his slowest SJW reader.

I sometimes feel that a Reader's Digest condensed edition (c. 10%) should ship with the volume; I suspect there would be little compression loss.

Memes, the subject of cultural evolution, is his big idea and I'm reminded of Joseph Henrich's "The Secret of our Success" although that author hasn't been cited yet.

Update: March 21st 2017.

I have now finished this book and it's a let down: no big reveal, no advance over previous arguments that consciousness is the (still mysterious) result of sub-personal processes. A bubbly, jolly, agreeable-uncle writing style can't hide sloppy over-use of metaphor ("memes as apps"), the minimal payback from his embrace of 'meme theory', and his inability to explain why you and I can suffer while a brick can't.

If you've read Dennett before, this book really doesn't add any additional value.

Thursday, March 09, 2017

Replika is massively oversold

Replika was originally going to be your own, online personal doppelgänger. Given the current state of the art with chatbots (tiresome and useless), that was always going to be a stretch.

The current PR says:
"Replika is your personal AI friend that you nurture and raise through text conversations. It is a lifetime companion who is always there for you, chats with you, keeps your memories, and helps you become more connected to yourself."
They're busy trying to create doable spin-offs such as a personal diary ("A Cute Diary That Keeps Itself").

Given date-slippage, I had thought that the whole Replika thing might have silently collapsed, but I suppose there is no shortage of people who are happy to update a super-Eliza forty times a day with details of their every mundane activity.

Facebook.

There would be a lot of interest in a virtual friend, endlessly attentive and caring  (except that's not a friend, more a courtier - artificial sycophancy). But if this were in the state of the art, one of Google, Microsoft, Facebook, Amazon or Baidu would have done it already. It's plainly on the future roadmap for the plethora of voice assistants, but today's systems are no more than super-recognisers.

---

Have you ever had the experience of being in a technical meeting, in an area not wholly in your sphere of competence, and suddenly you lose the plot? For a moment, you just don't know what everyone else is talking about. You pray no-one will ask for your opinion.

If you're lucky, in a minute or two the topic will move on and you will rejoin the shared context.

What happened there? The participants shared an internal cognitive model of what the conversation was about, and yours frayed. But no chatbot today can maintain an internal model of any complexity.

Worse: the topics of mundane discourse are open-ended, rooted in a complex culture and often private. Do we even want our AI-in-the-cloud to share personal and family intimacies, possibly with any interested intelligence agency?

---

Your Replika AI friend is going to get 40 bland texts per day from you. Some of the questions already seem rather intrusive.



There is a hint of blank-slate about current AI. As if one standard optimised neural-net architecture could create the ideal artificial personality template, which then gets loaded with data to become an individual.

We know that people aren't like that. Common experience and psychometric data tells us that people have distinct personalities, that these are strongly heritable and resistant to change. We all know, as folk psychologists, that we deal with people as distinct individuals, not clones. And that most of those differences are innate and resistant to social influences.
"She thinks she can change him!"
No she can't.

So many mountains to climb.
  • Why is the brain structured as modules, not one uniform design?
  • How is the architecture of personality differences implemented?
  • How to immerse an AI in common knowledge, culture and mores?
  • How does social deftness, tact and propriety work?
  • What's an effective, useful and pleasant engagement model - corporeal?

Yes, I am prepared to be disappointed with Replika.

---

Update: 9th March 2017.

"Replika AI to launch on the App Store

"Today, we are excited to announce that Replika will appear on the Apple’s App Store on March 13 at 12:00 AM Pacific time. We’d like to thank all the participants of the app’s preview in Testflight for the incredible feedback that helped us shape the app."

Wednesday, February 22, 2017

Perhaps no-one understands Maxwell's equations

"Microsoft CEO Satya Nadella spoke at a public event in India on Monday ...

"The first time I put on a HoloLens was to see something Cleveland Clinic [a non-profit academic medical center] had built for medical innovation... As an electrical engineer who never understood Maxwell's equations, I thought if I had a HoloLens, I would have been a better electrical engineer. Overall I feel that augmented reality is perhaps the ultimate computer," he said.
From here.

Actually, the article was entitled, "Microsoft CEO says artificial intelligence is the 'ultimate breakthrough'", but I was struck by his confession of ignorance about the foundational theory of classical electromagnetism.



Maxwell's equations

This looks bad, of course. But let's cut the CEO some slack: Maxwell's equations are notoriously unintuitive, as I observed in this post.

You can use the equations, solving them for particular physical configurations. But what picture do they give of the nature of the field(s) themselves?

What are we to make of the fact that a stationary observer of a motionless charged ball sees a static spherical electric field E, while an observer moving past that same ball sees electric and magnetic fields (E' and B')?

The magnetic field is a relativistic effect.

The charge is at rest in frame F, so this observer notes a static electric field. An observer in another frame F′ moves with velocity v relative to F, and notices the charge to move with velocity −v with an altered electric field E due to length contraction and a magnetic field B due to the motion of the charge. (Wikipedia).

That's implicit in Maxwell's equations, but don't tell me it's obvious. For that, you need to write the equations in a manifestly covariant form, but they don't teach you that in undergraduate electrical engineering.

---

Oh, and he's surely right about augmented reality being the main deliverable from the current state of the art in artificial neural net technologies. The Holy Grail of AGI will be a product of mastering situated social cognition, a post for another day (but see here).

Monday, February 06, 2017

A battlespace AI



When contemplating AI-controlled cruise missiles, as in yesterday's post, there is a tendency to hear 'AI' and think magic, or imagine we're in the foothills of the Butlerian Jihad.

Still, even without access to classified information, there's a lot we can say about this kind of battlespace AI, just by comparing it with stuff we already know about.

An anti-carrier cruise missile is basically a suicide drone. Its mission is threefold:
  • navigate to the target
  • identify the best choice of target to crash into (and blow up)
  • cope with an extraordinarily hostile environment.
All three of these mission priorities are amenable to current artificial neural net technology:
  • navigation can leverage autonomous vehicle/reconnaissance-drone tech
  • target identification is not dissimilar to existing object/facial recognition tasks
  • the hostile environment can be addressed by massive simulation-training.
I imagine AI prototypes are probably flying drones around right now in simulated attack-scenarios. Steve Hsu has more information on this.

---

There are three interesting issues which arise from the specifics of a combat environment.

1. Target identification/selection

Unlike relatively benign civilian environments, enemy carriers and other ships will attempt to make location and targeting difficult. There will be smoke, perhaps battle damage, explosions and defensive measures such as laser dazzle, jamming, false targets and chaff.

The solution appears to involve multiple sensing platforms illuminating or imaging the target space: satellites; aircraft/drone loitering radars; multiple attack-weapons sharing sensor data on a local net.

Sensor data fusion is a complex but well-researched topic amenable to AI (satirised here).

2. The hostile environment

The incoming missiles will be targeted by the carrier group with everything they have. Antimissiles, guns, lasers. Who can imagine an optimal set of tactics for surviving such an assault?

An AI system which has trained on millions of simulations.

It's somehow similar to AlphaGo.

What we know of AI adversaries is that they often exhibit brilliant but quite counter-intuitive behaviour. That's mostly a plus in the last few kilometres.

3. Autonomy

There's a stupid point here, and an intelligent one.

The stupid argument demands that AI weapons systems have 'no autonomy' - that there will always be a human in the loop.

So ... like with mines, then?

Plainly, if the carrier has already been sunk on cruise missile arrival, the AI will make a fast call on the optimal secondary target. There will be no human in the loop - in fact real-time communications will undoubtedly be 'very difficult'.

However, on a larger scale of strategic autonomy we do need to worry about the unpredictability and lack of transparency of current neural net technology. If, for some obscure tactical reason, an AI weapon concludes that it needs to attack a friendly vessel, then - absent a superhuman common sense (right!) - we should be worrying.

An emergent research area is the design of human-machine interfaces which have explicit, communicable and actionable knowledge about the operations of their powerful but opaque neural net subsystems.

Humans have one of those too: it's called consciousness.