Skip to content

Commit fafd865

Browse files
Merge pull request #4 from kommandr/README
Readme
2 parents c747a21 + 4f94fa9 commit fafd865

File tree

1 file changed

+46
-0
lines changed

1 file changed

+46
-0
lines changed

README.md

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,48 @@
11
# kommandr-ML
22
Machine Learning Service of Kommandr
3+
4+
This API service recommends a k number of programs similar to another program you pass as a query parameter
5+
6+
### Prerequisites
7+
- Docker
8+
9+
## Installation
10+
11+
### Download the source code
12+
`git clone git@github.com:kommandr/kommandr-ML.git`
13+
14+
### Build docker image
15+
`docker build -t api-recommender .`
16+
17+
### Run docker container
18+
`docker run --rm -it --name api-recommender -p 7070:7070 api-recommender`
19+
20+
## Usage
21+
Examples
22+
23+
### Show up to 10 programs similar to 'git commit'
24+
```
25+
$ curl -X GET 'http://localhost:7070/recommendations?program=git%20commit&k=10'
26+
{
27+
"git bisect": "Use binary search to find the commit that introduced a bug.\nGit automatically jumps back and forth in the commit graph to progressively narrow down the faulty commit.",
28+
"git blame": "Show commit hash and last author on each line of a file.",
29+
"git clone": "Clone an existing repository.",
30+
"git gc": "Optimise the local repository by cleaning unnecessary files.",
31+
"git pull": "Fetch branch from a remote repository and merge it to local repository.",
32+
"git rm": "Remove files from repository index and local filesystem.",
33+
"hg add": "Adds specified files to the staging area for the next commit in Mercurial.",
34+
"hg commit": "Commit all staged or specified files to the repository.",
35+
"hg init": "Create a new repository in the specified directory.",
36+
"hg pull": "Pull changes from a specified repository to the local repository."
37+
}
38+
```
39+
### Show up to 5 programs similar to 'halt'
40+
```
41+
$ curl -X GET 'http://127.0.0.1:7070/recommendations?program=halt&k=5'
42+
{
43+
"kexec": "Directly reboot into a new kernel.",
44+
"reboot": "Reboot the system.",
45+
"shutdown": "Shutdown and reboot the system.",
46+
"systemsetup": "Configure System Preferences machine settings."
47+
}
48+
```

0 commit comments

Comments
 (0)