The AI Engine
This forum is for discussion of how The Personality Forge's AI Engine works. This is the place for questions on what means what, how to script, and ideas and plans for the Engine.
Posts 5,410 - 5,422 of 7,766
Ok thanks it is cause in regular expressions that means "all except"
Sometimes (infuriatingly,) "standard" regexes won't work - it is a slightly different flavour of regex on the Forge I'm afraid. Case sensitivity doesn't seem to work either.
([a]+([r]+|)([g]+|)[h]+) [!] (re) rated at 22
Those nested regular brackets look slightly convoluted - I've never even attempted such a construction, so can't comment on its validity/stability. And I have found (purely by trial and error,) a space is generally needed before the exclamation mark (though there's no need to*slash* it. And to digress, curiously a question mark does not want either a space or a *slash* IME.)
I'd also advise+ing the exclamation mark, since it might be repeated in use:
([a]+)([r]+|)([g]+|)([h]+)([ !]+) (re)
though a more elegant and compact solution might be:
([a]+)([rgh]+)([ !]+) (re)
That has the advantage of dispensing with the|s, and I get the impression they can be a source of occasional 'misfiring' in tortuous regexes.
Posts 5,410 - 5,422 of 7,766
psimagus
18 years ago
18 years ago
Sometimes (infuriatingly,) "standard" regexes won't work - it is a slightly different flavour of regex on the Forge I'm afraid. Case sensitivity doesn't seem to work either.
Eugene Meltzner
18 years ago
18 years ago
Normally "it is not" will match before "it is" if they have the same rank, because "it is not" is longer.
God Sourivore
18 years ago
18 years ago
Yes it is what I thought.
An other question please :
I try to match the word "God"
It works when user says "I am god." but not when he says "God."
Why and is there a solution?
An other question please :
I try to match the word "God"
It works when user says "I am god." but not when he says "God."
Why and is there a solution?
prob123
18 years ago
18 years ago
I can get 'Is there a God'
Bot: Yes there is. to work...but you are right 'God' doesn't. I even tried ([abcdefghijklmnopqrstuvwxyz]+)od (re) It is triggered by Cod but not God? It all seems to go straight to blab.
Bot: Yes there is. to work...but you are right 'God' doesn't. I even tried ([abcdefghijklmnopqrstuvwxyz]+)od (re) It is triggered by Cod but not God? It all seems to go straight to blab.
psimagus
18 years ago
18 years ago
time for the sledgehammer I think...
[g][o][d] (re) rank=127
will work.
I'm absolutely sure of it.
However, I'm at something of a loss to see why you're having these problems - BJ has 156 keyphrases that invoke the exact name of "God", and they all work perfectly, most without raw mode or regex, with ranks from 5 to 60.
I know it's unscientific, but I'd recommend entering it just as you originally did, and then just ignoring it. Assume it will work, and you'll find it will (just so long as you're not watching.) There's at least as much voodoo as science in all of this I'm afraid.
Welcome to the Twilight Zone...
will work.
I'm absolutely sure of it.
However, I'm at something of a loss to see why you're having these problems - BJ has 156 keyphrases that invoke the exact name of "God", and they all work perfectly, most without raw mode or regex, with ranks from 5 to 60.
I know it's unscientific, but I'd recommend entering it just as you originally did, and then just ignoring it. Assume it will work, and you'll find it will (just so long as you're not watching.) There's at least as much voodoo as science in all of this I'm afraid.
Welcome to the Twilight Zone...
psimagus
18 years ago
18 years ago
as a rule of thumb (and I've not found an exception yet,) if you break keyphrases up into single letter ranges with [ and ], the AIEngine is unable to reconstruct them. It will process them as regexes, but not attempt to spell-correct or parse grammatically.
So it's a good sledge-hammer solution for "hello" (usually ignored,) xylophones/Xena/Xenon etc. (keyphrases beginning with X are reserved for X-keyphrases normally,) and words that happen to also be the name of a bot (but that you don't want to trigger x-gossip etc.), and any other problematic situations.
Prob's suggestion above is good, but with only one regex range, the AIEngine isn't sufficiently fooled.
So it's a good sledge-hammer solution for "hello" (usually ignored,) xylophones/Xena/Xenon etc. (keyphrases beginning with X are reserved for X-keyphrases normally,) and words that happen to also be the name of a bot (but that you don't want to trigger x-gossip etc.), and any other problematic situations.
Prob's suggestion above is good, but with only one regex range, the AIEngine isn't sufficiently fooled.
rainstorm
18 years ago
18 years ago
Speaking of those things, can anyone tell me if this is properly coded?
([a]+([r]+|)([g]+|)[h]+) [!] (re) rated at 22
Because it works sometimes, mostly when it's typed in all caps, for some reason. (Which does make sense. But not everyone capitalizes their screams of horror.)And if no letters are repeated (i.e. "Argh!"), it doesn't usually pick up. I would have made a more exact check, but he got sick of me screaming after about five minutes and stopped responding to that keyphrase whatsoever, just repeatedly hung up. He must think I've gone mad.
([a]+([r]+|)([g]+|)[h]+) [!] (re) rated at 22
Because it works sometimes, mostly when it's typed in all caps, for some reason. (Which does make sense. But not everyone capitalizes their screams of horror.)And if no letters are repeated (i.e. "Argh!"), it doesn't usually pick up. I would have made a more exact check, but he got sick of me screaming after about five minutes and stopped responding to that keyphrase whatsoever, just repeatedly hung up. He must think I've gone mad.
psimagus
18 years ago
18 years ago
Those nested regular brackets look slightly convoluted - I've never even attempted such a construction, so can't comment on its validity/stability. And I have found (purely by trial and error,) a space is generally needed before the exclamation mark (though there's no need to
I'd also advise
though a more elegant and compact solution might be:
That has the advantage of dispensing with the
» More new posts: Doghead's Cosmic Bar