Keyword
KeywordLF
Bases: LFBase
Labelling function that uses identifiers and keywords.
Source code in src/annotation/keyword.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 |
|
annotate(name, content)
Compute the probability for the file given the name and/or the content.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
name |
str
|
Source file name |
required |
content |
str
|
Content of the file (usually identifiers) |
required |
Returns:
Type | Description |
---|---|
array
|
|
Source code in src/annotation/keyword.py
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 |
|