Live data from Hacker News

Betty – English-like interface for the command line

github.com

51–60 of 84 posts

Re: Betty – English-like interface for the command line

#51
post #43

Other than being fun; I can't quite see the benefit of making my shell more verbose. I'm sure I am not the only one who can get by with the regular commands through mnemonics. And to further my point; if this was such a good idea, then why has nobody aliased 'ls' to list , 'cp' to copy , (etc.)? Or, while we're at it, 'list files' , or 'list files in current directory' . Maybe someone has and I just didn't meet them…

It becomes interesting when you can tell Betty to do things you don't otherwise know how to do. (How do you tell iTunes to skip this song from the cmd line? I don't know, and I'm too lazy to look it up.)

Re: Betty – English-like interface for the command line

#52
That's great. However, I don't see an end to capture all the ambiguity of language and especially misspellings... can this be contained in a reasonably fast running script?

  ~/tmp betty my ip
  Betty: Sorry, I don't understand.
  ~/tmp betty my ip adress
  Betty: Sorry, I don't understand.
  ~/tmp betty whats my ip address
  Betty: Running curl ifconfig.me

Re: Betty – English-like interface for the command line

#53

Why are all computerized natural-language "assistants" all modeled as female? (Siri, Cortana, Betty...) A remnant of the view of women's role as "secretaries"? It's interesting to see that this applies to real-world products, which are still kind of "dumb" or single-minded (as in default voices for GPS navigation assistants), while in fiction, when computers are smarter than its owner (HAL, Jarvis) they more are ofte…

Well Siri isn't female (and "Siri" as a name isn't a girl or boy name per se), its voice gender varies depending on the country. Apple uses the highest quality voice they have as the default. If you ask Siri what's its gender, it famously replies "I haven't been assigned a gender".

Even then though, female voice usually wins for phone voice services. Why?

Turns out males voices are more "lossy" over plain-old-telephone-service and over tiny tinny speakers (like on the iPhone).

The frequency range of a female voice maps to less loss in this speaker/service range compared to a deep male voice, where the lower frequencies get lost. So female voices are easier to understand in such circumstances.

This explains in part why OSX has a male voice, because a Mac comes by default with much better speakers than a phone does. Even then deeper voices are still not preferred. The "in a time..." movie trailer voice isn't coming to an AI assistant any time soon.

As for Cortana, the basically nude Halo AI bimbo, you have a point there, awkward choice for a commercial product, but that's Microsoft's problem. They've always had awkward marketing/branding choices, so this fits in.

As for Betty, "Betty the secretary" reference is quite obvious, but as a personal project, I'd say he's forgiven.

Re: Betty – English-like interface for the command line

#54
post #13
post #2

I like this idea a lot. But why on earth it is written in ruby?! - I know the answer and it is "ok". But it is probably the reason why it won't never gain huge momentum, prove me wrong :)

I knew my reply will be heavily hammered by rubyists. There is nothing wrong in the language but I think that shell tools should be written in C or in some other low level language without complex dependencies over ruby or java or python etc. or any other non-default installation stuff

I'm afraid that ship has sailed a long time ago:

    $ for bin in /bin/* /usr/bin/* /usr/local/bin/*; do
    >     if [[ -f $bin && "$(cat $bin | head -c 2)" == "#!" ]];then
    >         echo $bin
    >     fi
    > done | wc -l

    544
I imagine most of these are written in Perl (though there's surely a fair amount of Python and shell scripting in there, too), but that's still a high-level language with a complex runtime and dependencies compared to C.

To be fair, there's still about twice as many compiled binaries on that box, but having system commands written in a non-C language is by no means an exception.

Re: Betty – English-like interface for the command line

#55
post #2

I like this idea a lot. But why on earth it is written in ruby?! - I know the answer and it is "ok". But it is probably the reason why it won't never gain huge momentum, prove me wrong :)

What language would you write it in?

http://www.alicebot.org/aiml.html

Re: Betty – English-like interface for the command line

#56

Really interesting program, although, as Andrew has said, seems kinda limited. That's not your fault at all; any early project will seem limited in scope. Given some popularity and extra effort, something like this could be the Siri of the command line. Which gets me thinking -- is stuff like Siri and Google Now really just like this? Core set of pre-set commands surrounded by regex magic to recognize said pre-set co…

Cortona was released with an API to external apps, and that only allows simple pattern matching, so that's similar. Obviously the built-in stuff is more complex. I've no idea about today, but the original Siri was mostly just chaining relationships together by keyword matching in an ontology.

You could probably train a system like this with a word alignment approach if you generated a training corpus. But ideally you'd want to be able to show the system a new manpage and have it map arguments correctly.

Also a false positive in a SPAM filter is bad, but `rm -rf`ing because of the vagaries of the English language is worse.

Re: Betty – English-like interface for the command line

#57
post #43

Other than being fun; I can't quite see the benefit of making my shell more verbose. I'm sure I am not the only one who can get by with the regular commands through mnemonics. And to further my point; if this was such a good idea, then why has nobody aliased 'ls' to list , 'cp' to copy , (etc.)? Or, while we're at it, 'list files' , or 'list files in current directory' . Maybe someone has and I just didn't meet them…

The whole point of this is when you don't remember the command which you are trying to achieve. (See the author's comment[1]: "Betty just grew out of my cheat sheet of commands. I was tired of repeatedly looking up things in my cheat sheet or Google, and decided to make this.")

It's faster than a google search.

[1] https://news.ycombinator.com/item?id=7696453

Re: Betty – English-like interface for the command line

#58
post #43

Other than being fun; I can't quite see the benefit of making my shell more verbose. I'm sure I am not the only one who can get by with the regular commands through mnemonics. And to further my point; if this was such a good idea, then why has nobody aliased 'ls' to list , 'cp' to copy , (etc.)? Or, while we're at it, 'list files' , or 'list files in current directory' . Maybe someone has and I just didn't meet them…

It becomes interesting when you can tell Betty to do things you don't otherwise know how to do. (How do you tell iTunes to skip this song from the cmd line? I don't know, and I'm too lazy to look it up.)

This is classically what `apropos` is there for, but I don't see any mention of iTunes in there.

Re: Betty – English-like interface for the command line

#59
post #48
post #43

Other than being fun; I can't quite see the benefit of making my shell more verbose. I'm sure I am not the only one who can get by with the regular commands through mnemonics. And to further my point; if this was such a good idea, then why has nobody aliased 'ls' to list , 'cp' to copy , (etc.)? Or, while we're at it, 'list files' , or 'list files in current directory' . Maybe someone has and I just didn't meet them…

http://www.computerhope.com/copyhlp.htm

Err, serves me right. Nonetheless, the bottom line of my post should hold true.

Re: Betty – English-like interface for the command line

#60
post #2

I like this idea a lot. But why on earth it is written in ruby?! - I know the answer and it is "ok". But it is probably the reason why it won't never gain huge momentum, prove me wrong :)

What language would you write it in?

Given that this program is mainly several regexp matches against the input string, perhaps perl or awk would be a perfect match here?
Post reply on HN