This project is a GUI-based application for language model analysis, designed with object-oriented programming principles for efficient document processing, vocabulary management, and language model prediction.
- Document Upload: Load and display a document.
- Processing Document: Enable processing with selected hash functions.
- Vocabulary Display: Show and sort word counts.
- Statistics Display: View detailed statistics.
- Language Model Analysis: Access advanced analysis features.
- Prediction: Predict the next 20 words based on input.
- Statistics: View model statistics.
- Navigation: Return to the Main Screen retaining data.
- Interfaces: For HashFunction and LinkedListObject.
- Encapsulation: Private variables with public methods.
- Inheritance: Hierarchical structure for HashFunction implementations.
- Polymorphism: Interchangeable hash functions in MyHashTable.
- Constructor: Initializes with word and count.
- Methods:
setWord(String w)
,getWordCount()
.
- First Letter Hash: Uses Unicode value of the first letter.
- Division Hash: Sums Unicode values of all characters.
- Encapsulation: Hides internal classes.
- Sorting: By descending frequency.
- Statistics: Unique words and word counts.
- Unigrams, Bigrams, Trigrams: Probability calculations.
- Predictions: Based on different n-gram models.
- Issues with Larger N-grams: Increased complexity and memory requirements.
-
Main Screen:
- Click "Load Document" to upload a document.
- Click "Process Document" to analyze the document.
- Use sorting and statistics options as needed.
- Click "Run Language Model Analysis" for advanced analysis.
-
Language Model Analysis Screen:
- Enter text for prediction and select a language model.
- Click "Predict" to see predicted words.
- Click "Show Statistics" for detailed analysis.
- Click "Main Page" to return to the main screen.
See the LICENSE file for details.
Feel free to reach out via the project's GitHub repository for any issues or contributions. Enjoy exploring Language Model Project!