参加ボットのリブレの パートナー、アフィリエイト プログラムや支援の無料のオープンなプラットフォーム
Bot Libre Forum : identifying a chatbot as male and female.

RE: identifying a chatbot as male and female.

による admin 掲載 Apr 24 2017, 14:19

You can add attributes to a bot or a user it is chatting with using a Self script or Template.

The global symbol #self is the object in Self that represents the bot. The variable speaker represents the current user in the current conversation. Any attributes you set on these objects (or any object) are automatically persisted in Self.

#self.gender = #female;

speaker.gender = #male;

Template("Hello {if (speaker.gender == #male) { "boyfriend" } else { "girlfriend" }}")


Id: 16803477
掲載: Apr 24 2017, 14:19
回答: 0
眺望: 1845, 今日の: 1, 週間: 2, 月: 24
0 0 0.0/5