我正在使用housekeeping parameters。我想在不相关的文本示例上训练模型,例如:“猫是棕色的。它几点了?”
我为模型创建了以下输入:
[["The", "cat", "is", "brown"], ["What", "time", "is", "it"]]
,但是我想知道模型是否假设“棕色”和“什么”在同一个背景下。
试图在api中找到答案,但找不到它。
答案 0 :(得分:0)
The gensim API won't consider "brown" and "What" in the same context. Uneven windows are used near sentence boundaries. So, for your example, if the window size let's say is 1, the (context, target) pairs would look like as below:
([cat],The), ([The,is],cat), ([cat,brown],is), ([is],brown) ([time],What), ([What,is],time), ([time,it],is), ([is],it)
I hope this clears your doubt.