https://github.com/olekscode/semanticclustering
Semantic clustering of source code of Pharo projects, packages, classes, and methods using TF-IDF and t-SNE
https://github.com/olekscode/semanticclustering
Last synced: about 2 months ago
JSON representation
Semantic clustering of source code of Pharo projects, packages, classes, and methods using TF-IDF and t-SNE
- Host: GitHub
- URL: https://github.com/olekscode/semanticclustering
- Owner: olekscode
- License: mit
- Created: 2019-08-23T14:22:45.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-08-29T12:46:46.000Z (over 6 years ago)
- Last Synced: 2025-04-05T14:43:42.553Z (11 months ago)
- Language: Smalltalk
- Size: 26.4 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# SemanticClustering
Semantic clustering of source code of Pharo projects, packages, classes, and methods using TF-IDF and t-SNE.
## Installation
To install SemanticClustering, go to the Playground (`Ctrl+OW`) in your fresh Pharo image and execute the following Metacello script (select it and press Do-it button or `Ctrl+D`):
```smalltalk
Metacello new
baseline: 'SemanticClustering';
repository: 'github://olekscode/SemanticClustering/src';
load.
```
## Training the Model
```Smalltalk
projects := #(Morphic Tool System Polymorph Calypso Kernel Athens Metacello OpalCompiler Fuel Monticello Collections Reflectivity OSWindow Rubric Graphics STON UnifiedFFI Zinc SUnit Epicea Refactoring Text Renraku AST Commander Network Keymapping Refactoring2 Regex Shift Debugger Ombu).
clusteringBuilder := SemanticClusteringBuilder new
projects: projects;
yourself.
"Some steps can take more than 30 min"
clusteringBuilder start.
```
## Loading the Trained Model
You can download the FUEL serialization of a trained `SemanticClustering` object: https://drive.google.com/file/d/1WJTeD8jRpDU7WyMz_FtybPujLMCJj5u-/view?usp=sharing.
```Smalltalk
clusteringBuilder := FLMaterializer materializeFromFileNamed: 'semanticClustering.fuel'.
```