[mercury-users] Mercury applications, AI, backtracking
Randall Helzerman
rahelzer at ichips.intel.com
Wed Sep 16 05:27:51 AEST 1998
> On 14-Sep-1998, Don Smith <dsmith at cs.waikato.ac.nz> wrote:
> > Hi,
> >
> > I am wondering: is it reasonable to expect Mercury to succeed as a
> > _mainstream_ programming language when the vast majority of
> > conventional applications would seem to involve little or no
> > backtracking? (But see below.)
Instead of asking
"Do a lot of mainstream applications require backtracking?"
I think the question should be:
"Can the declarative approach be used in mainstream programming?"
The promise of logic programming is that we specify what we want, not
how to get it. There are many mainstream applications which could benefit
from this; I'll just mention two:
1. Parsing/file filters/etc.
Prolog's ability to just specify a grammar and automatically have a
parser for it is wonderful here. The current champ in this area
is perl, which is great if you are just parsing a regular language,
but if you are parsing a non-regular language, perl is no better than
any other language--you still have to hand-write your own recursive-
decent parser. I see real potential for a declarative scripting
language. Here at Intel, we've got about 400 people whose full-time
job is to maintain perl scripts which manage data communication
between various CAD tools. If we had a scripting language which
made a programmer even 2% more productive, we could redeploy
8 programmers and save over US$1 million per year.
2. Databases
There is no application which is more mainstream than databases, and
databases should be the killer-ap of logic programming. Every
company needs a database, and its just not that large of conceptual
leap for a sql programmer to become a prolog programmer. And mercury's
type system already is rich enough to encompass all of the recent
work in object/relational databases.
More information about the users
mailing list