3

Program-O チャットボット用の AIML ファイルを作成していて、問題に直面しています。

私がやりたいことは、次から次へと質問することです。さらに、質問はランダムな順序である必要があります。これは学生向けの満足度評価テストで、従来の方法ではなくチャットボットを使用して開発を試みています。

これは私が考えている AIML 形式です。

サンプル.aiml

<category>
    <pattern>HELLO<bot/></pattern>
    <template>
        <random>
            <li><warm/>Hello there. Do you want to talk about your campus life?</li>
            <li><happy/>Hi. Do you want to talk about your campus life?</li>
            <li><happy/>Goodday. Do you want to talk about your campus life?</li>
        </random>
    </template>
</category>
<category>
    <pattern>*</pattern>
    <that>HELLO THERE. DO YOU WANT TO TALK ABOUT CAMPUS LIFE</that>
    <template>
        <random>
            <li>How were the classes?</li>
            <li>Does the teacher give a clear answer?</li>
            <li>Was the teacher come on time?</li>
        </random>
    </template>
</category>
<category>
    <pattern>*</pattern>
    <that>HOW WERE THE CLASSES</that>
    <template>
        <random>
            <li>Does the teacher give the full and clear explanation?</li>
            <li>What about the material used in the classes?</li>
            <li>What do you think about the courses content?</li>
        </random>
    </template>
</category>

問題は、* (アスタリスク) ワイルドカードがその述語でうまく機能しないことです。私の要件を満たすAIMLを構築する他の方法はありますか?

4

2 に答える 2

-1
string text = System.IO.File.ReadAllText(txt_filename.Text.ToString()).ToString();

        int length = (Int32)text.Length;
        txt_gbox.Text = length.ToString();

        LexicalAnalysis analyzer = new LexicalAnalysis();

        while (text !=)
        {
            text = text.Trim(' ', '\t');
            string token = analyzer.GetNextLexicalAtom(ref text);
            txt_gbox.Text = token;
        }

これらのトークンを txt_gbox であるリッチテキストボックスに表示したいのですが、ループプログラムが停止している間....

于 2017-01-09T18:31:32.460 に答える