Documentation ¶
Index ¶
- func ExtractLicenseFiles(files []string, fs filer.Filer) [][]byte
- func ExtractReadmeFiles(files []string, fs filer.Filer) [][]byte
- func InvestigateLicenseText(text []byte) map[string]float32
- func InvestigateLicenseTexts(texts [][]byte) map[string]float32
- func InvestigateReadmeText(text []byte, fs filer.Filer) map[string]float32
- func InvestigateReadmeTexts(texts [][]byte, fs filer.Filer) map[string]float32
- func IsLicenseDirectory(fileName string) bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExtractLicenseFiles ¶
ExtractLicenseFiles returns the list of possible license texts. The file names are matched against the template. Reader is used to to read file contents.
func ExtractReadmeFiles ¶
ExtractReadmeFiles searches for README files. Reader is used to to read file contents.
func InvestigateLicenseText ¶
InvestigateLicenseText takes the license text and returns the most probable reference licenses matched. Each match has the confidence assigned, from 0 to 1, 1 means 100% confident.
func InvestigateLicenseTexts ¶
InvestigateLicenseTexts takes the list of candidate license texts and returns the most probable reference licenses matched. Each match has the confidence assigned, from 0 to 1, 1 means 100% confident.
func InvestigateReadmeText ¶
InvestigateReadmeText scans the README file for licensing information and outputs probable names found with Named Entity Recognition from NLP.
func InvestigateReadmeTexts ¶
InvestigateReadmeTexts scans README files for licensing information and outputs the probable names using NER.
func IsLicenseDirectory ¶
IsLicenseDirectory indicates whether the directory is likely to contain licenses.
Types ¶
This section is empty.