Live data from Hacker News

The English-Likeness Monster Stalks a New Generation of Programmers

raganwald.posterous.com

71–78 of 78 posts

Re: The English-Likeness Monster Stalks a New Generation of Programmers

#71
post #50

Earlier quoted context omitted.

It could if there were some level of AI behind it.

But at that point you run into another problem, namely that you can interact with computers in natural language but I don't think you can program them, because once you have that level of AI, you can't guarantee that two computers will have the exact same understanding of the command any more than you can expect that two programmers will read a spec in the exact same way. What this means is that the consistency gaine…

Interesting point, but a counterpoint is that an AI for such purposes could either be deterministic (if it was running on local machines), or it could be a single highly creative and nondeterministic AI running "in the cloud" so to speak. There are also cases where absolute determinism isn't important, like in some games.

I think both of our points are somewhat moot though, as I don't see NLP code as something that you would necessarily put up on github. I see it as playing a similar role to DSLs or metaprogramming nowadays, and similarly, it wouldn't always be a good solution.

Simple use case: I recently finished an HTML5 puzzle minigame. The layout is pretty simple and has to adjust to window resizes, but the layout can't be done with straight HTML/CSS. So, my resize function is 120 lines of dense javascript, despite being able to describe in a simple paragraph what I would want. Indeed, a simple paragraph is what was given to me in the first place to describe the layout.

Re: The English-Likeness Monster Stalks a New Generation of Programmers

#72

Earlier quoted context omitted.

I don't see anything wrong with the message body. The point is we are talking about similarity, not identity. I have been clear: you can't program in English but there is some benefit to having languages which are easy for English-speakers to learn. > Do you accept that programming has its basis in mathematics and logic? This is one of the foundations of programming, particularly pronounced in technical fields. As yo…

I don't see anything wrong with the message body. Let me see if I got that right. You see the need to transform: float Q_rsqrt( float number ) into: DECLARE FUNCTION q_rsqrt (float number) THAT RETURNS float AS but you see no need to do anything to: long i; float x2, y; const float threehalfs = 1.5F; x2 = number * 0.5F; y = number; i = * ( long * ) &y; i = 0x5f3759df - ( i >> 1 ); y = * ( float * ) &i; y = y * ( thre…

I've tried not to bring up "English-Likeness" aspect because that's a whole other can of worms. But since it's out there now...

I don't believe this is einhverfr's intent in the least, but the promotion of English is often an ethnocentric activity. Why not a dialect of Chinese (so many native speakers, high information density per character)? Why not a dialect of Spanish (multi-continental reach of native speakers, high incidence of cognates to Romance languages, highly predictable orthography and phonetics)? Why not any language spoken in the Middle East or India or former Soviet states?

If human accessibility were truly the issue, why should we focus our efforts on English speakers -- the people already the most aided by existing language-like tokens! -- instead of promoting efforts to "translate" programming keywords and constructs to other languages? I'll grant that one does not necessarily preclude the other, but I would argue that the former is chasing after diminishing returns at this point in time, whereas the latter represents a significant opportunity to increase ease of access to programming globally.

Re: The English-Likeness Monster Stalks a New Generation of Programmers

#73
post #19

> "It's far simpler to learn a precise, unambiguous language and manipulate the parser directly." Since no one else has mentioned it yet, Lojban [1] seems like the perfect candidate for this. [1] http://en.wikipedia.org/wiki/Lojban

But since nobody speaks Lojban natively (and probably never will (I am aware there exist a few people who speak Esperanto natively)), you might as well learn a programming language. Both Lojban and Python will be second languages to someone, and Python (or any other programming language) is probably easier to reason about for the types of things we use programming languages for.

There are no native speakers yet... https://groups.google.com/forum/?fromgroups=#!topic/lojban/H...

Re: The English-Likeness Monster Stalks a New Generation of Programmers

#74
post #72

Earlier quoted context omitted.

I don't see anything wrong with the message body. Let me see if I got that right. You see the need to transform: float Q_rsqrt( float number ) into: DECLARE FUNCTION q_rsqrt (float number) THAT RETURNS float AS but you see no need to do anything to: long i; float x2, y; const float threehalfs = 1.5F; x2 = number * 0.5F; y = number; i = * ( long * ) &y; i = 0x5f3759df - ( i >> 1 ); y = * ( float * ) &i; y = y * ( thre…

I've tried not to bring up "English-Likeness" aspect because that's a whole other can of worms. But since it's out there now... I don't believe this is einhverfr's intent in the least, but the promotion of English is often an ethnocentric activity. Why not a dialect of Chinese (so many native speakers, high information density per character)? Why not a dialect of Spanish (multi-continental reach of native speakers, h…

I did mention features of English which make it more condusive to being such an archetype (i.e. that computer languages immitate English). I don't think it is the only choice. I think in general that creole languages and their descendants (that includes English btw) have significant syntactic advantages in this regard. The issue is morphological simplicity.

This doesn't mean I am a fan of such languages from a natural language perspective, btw... I am just saying if I was choosing a language to build a computer language based on, I would not choose a language where imperative tenses of verbs might vary depending on number of addressees, for example....

As I think of it, it might be very interesting to look at computer language design based on other natural languages and see what other problems or opportunities come up. For example, I wonder about slot-based polysynthetic languages (like Algonquin). A computer language based on that would have to be fundamentally different from what we have now.

Re: The English-Likeness Monster Stalks a New Generation of Programmers

#75

I actually disagree to some extent with Raganwald here. I am both a software engineer and an amateur linguist. Let me try to go into where my disagreement is. I figure that someone, probably me, will have to set the record straight about how poorly our expectations of English grammar match the realities and utilities of this language.[1] Natural languages and computer languages are very different both in how they are…

All right. I program and I speak English all the time, how's that for credentials? I mean this in the nicest possible way but this is like saying a whole lot and nothing at the same time. I think if I heard this as a verbal response to the original article, I would think the speaker just wants to hear himself speak. You haven't really stated counter point by which to justify any kind of disagreement. It's seems to be…

> It's seems to be like a promissory note of "well if the language conformed to some subset dialect like legalese that could be great."

I don't think it would be great if regular English did so. Natural languages can't do so. If you do that you kill the language. My point is simply that we expect English to be like that and it's good that it isn't, but we can still leverage people's understanding of the language to help people learn programming faster, and moreover when languages do not do this they have more trouble gaining traction.

Re: The English-Likeness Monster Stalks a New Generation of Programmers

#76
post #33

Earlier quoted context omitted.

Another amateur linguist + software dev here (loosely involved in NLP-related work and studied linguistics at university). I invite you to try to convince me that there might possibly be a natural-language-esque version of the (in)famous inverse square root function that is more comprehensible than the original. float Q_rsqrt( float number ) { long i; float x2, y; const float threehalfs = 1.5F; x2 = number * 0.5F; y…

This is the best, most succinct and apt summary of the situation I've ever seen: "I contend that there is no sufficiently high level of abstraction where natural language would be more suitable." I'm reminded of Paul Graham's remark about Prolog being more high level but not more terse, and that this had something to do with its present-day situation. Natural language is high level because it is terse and humans can…

Sure.

But the question is whether it works best to have a high level abstraction which resembles a natural language.

Re: The English-Likeness Monster Stalks a New Generation of Programmers

#77
post #71

Earlier quoted context omitted.

But at that point you run into another problem, namely that you can interact with computers in natural language but I don't think you can program them, because once you have that level of AI, you can't guarantee that two computers will have the exact same understanding of the command any more than you can expect that two programmers will read a spec in the exact same way. What this means is that the consistency gaine…

Interesting point, but a counterpoint is that an AI for such purposes could either be deterministic (if it was running on local machines), or it could be a single highly creative and nondeterministic AI running "in the cloud" so to speak. There are also cases where absolute determinism isn't important, like in some games. I think both of our points are somewhat moot though, as I don't see NLP code as something that y…

I think the game example proves my point. You don't play a game by programming the game server. You play the game by itneracting with the computer. These are fundamentally different areas.

Re: The English-Likeness Monster Stalks a New Generation of Programmers

#78
post #58

Earlier quoted context omitted.

Which is the reason I can't stand SQL

and yet it is still a lower ratio or boilerplate to code (in nontrivial examples) than you get with C++ or Java.....

In my defense, I dislike C++ and Java too. :)
Post reply on HN