for x = 0 to ubound(catagories)
for y = 0 to ubound(catagories(x).kwd)
if instr(catogories(x).kwd(y), inp) then
function = dokwdsearch(catogories(x).keywords, inp)
exit function
end if
next y
next x
Catagorisation Of inputs for a Chatbot
Currently i was thinking about turning polly into an information recall bot, but to do that it would need to catogorise questions, and turn it into a nice (computer-readable) little format.
Something which will turn:
how do u program in Directx
to
Cat:Question Action
Kwds:Program Directx
Where it can then look through the catagory "Question action" in its databace/datafile, and look until it finds something which has:
1. an entry with a 100% keyword match or
2. an entry which has the best keyword match.
It would then read off the answer listed (which may include a tag causing it to update a textbox with extra information, taken off an additional data field)
Is this a good cource of action/is this the "best" way to achieve this?
For my catagory search loop, would something like this suffice?
?
From,
Nice coder
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement