Research Article

Device-Oriented Automatic Semantic Annotation in IoT

Algorithm 2

Annotation dictionary matching algorithm.
Input:
An annotation dictionary , a word frequency dictionary TF and a new non-function description .
Output:
A property division result , which contains three components, i.e., Pref, Inter and WorkCond. Those three components
are the contents about the performance, interface and working condition of our device description framework.
Step 1. Obtain a word sequence after segment .
Step 2. For each in :
If   in , the category that belongs to.
(i) find the position of in and , marked as and .
(ii) IF   has more than one, choose a which can maximize .
Else  .
Then obtain a position sequence .
Step 3. For each in :
(i) If , If  , add to the component of that belongs to.
(ii) If , add to .
(iii) If  , add to .
(iv) If  , add to .
Return: