Skip to content

gateak/ngram-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ngram-go

Overview

The ngram-go repository is a Go language project focused on implementing natural langauge processing algorithms and models. It currently features two primary files: ngram.go and lcsmatching.go, each offering unique functionalities in the realm of string matching and analysis.

Files

1. ngram.go

This file contains the implementation of N-gram generation and comparison algorithms. N-grams are a contiguous sequence of n items from a given sample of text or speech. The implementation in this file can be used for various applications such as text analysis, natural language processing, and pattern recognition.

Features

  • N-gram Generation: Functionality to generate n-grams from a given string.
  • N-gram Comparison: Tools for comparing sets of n-grams, useful in similarity assessments and other analyses.

2. lcsmatching.go

The lcsmatching.go file implements algorithms related to the Longest Common Subsequence (LCS). LCS is a classic algorithm used in text comparison, such as diff tools in version control systems.

Features

  • LCS Algorithm: Implementation of the LCS algorithm, providing a way to find the longest subsequence common to all sequences in a set of sequences.
  • String Matching: Useful for applications like text diff, plagiarism detection, and others where string matching is critical.

Getting Started

Prerequisites

  • Go (version 1.23 or later)

Installation

  1. Clone the repository:

git clone https://github.com/[username]/ngram-go.git

  1. Navigate to the repository:

cd ngram-go

Usage

  • ngram.go:

  • Import the package in your Go project.

  • Use the provided functions to generate and compare n-grams.

  • lcsmatching.go:

  • Import into your project.

  • Utilize the LCS functionality as required in your application.

Contributing

Contributions to ngram-go are welcome! Please read our contribution guidelines to get started.

License

This project is licensed under the MIT License - see the LICENSE file for details.

About

Experiments with NLP

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages