Sentencegator - small tool that give you sentences based on your WK level

That’s neat, thank you! 8D I tried it on Notepad++ and looks great.

Well, shoot. I can’t try this at home on my Mac, but I will give it a shot the next time I’m on a Windows computer. Thanks again. Looking forward to using it soon!

Edit:

Segmelsian said…
Its worth noting that if you have the GO tools
installed on your system you can run it using go run main.go
–apik=$APIKEY
This at least works in Max OSX 10.9, and thus I’m assuming would work similarly for whatever distributions are supported by Go.
That being said this looks great thanks :slight_smile:
 Thank you for the heads up, Segmelsian! I will give this a try when I have some time to learn a bit more about how it works.

dlemay said... I opened it using Notepad++. I would also recommend opening it with Excel. Import the data as tab delimited values so it will split Japanese and English in separate cells. Putting it in a spreadsheet also allows you to create an Anki deck with those sentences.
 Can this be used to mass add items on memrise?

My life would be complete. :0

Ahh, I would love to see a Mac version of this! It seems very helpful. 

Edit: Actually, I see from the comments that people are working around this issue, but I’m totally lost on how they’re doing it hahaa. 

I second the request for a Mac version. I can only imagine how it would help my grammar. 

Ok so steps for compiling and running a Mac version (as people seem to want it)

1. Download Go tools: (I used 10.8 version but also works for my 10.9)
https://code.google.com/p/go/downloads/list?q=OpSys-OSX+Type-Installer
2. Install package (Double click and follow steps)
3. Open terminal
4. type cd $PATH_TO_UNZIPPED_SOURCE, where the path is something like /Users/Segmelsian/Downloads/Sentencegator-0.1a (or wherever you saved it and obviously your name instead of Segmelsian)
5. Type go run main.go --apik=$API, where $API is your API key
6. results.txt should now be in the Sentencegator folder

Optionally if you wish to make separate files for english / Japanese you can type:
cut -f1 -s result.txt > japaneseOnly.txt
cut -f2 -s result.txt > englishOnly.txt

Which could be useful for something I guess, at the very least means you won’t see the answers for everything all the time

yako500 said...
dlemay said... I opened it using Notepad++. I would also recommend opening it with Excel. Import the data as tab delimited values so it will split Japanese and English in separate cells. Putting it in a spreadsheet also allows you to create an Anki deck with those sentences.
 Can this be used to mass add items on memrise?

My life would be complete. :0
 OK SO I CAN DEFINITELY IMPORT TO MEMRISE! :0

Is there anyway I can get the sentences for each level? Then I could make a course with everything by level for each wanikani level and that would be awesome :0

Nice work! I might see about making a fast version with a few more flags at some point (in Scala or Haskell) :slight_smile:

28112 sentences…  This will take a while

yako500 said...Is there anyway I can get the sentences for each level? Then I could make a course with everything by level for each wanikani level and that would be awesome :0
 Added this feature =)

Use --levels flag.

Sorry, tech inept here - how do you use the level flag?

http://www.memrise.com/course/168291/kanji-sentences/

Still adding the rest of the levels but ya, this. :smiley:

really nice!

mello said... Sorry, tech inept here - how do you use the level flag?
 For example --levels=3 or --levels=1,2,3,5,50

Woo, this was really needed, thanks =) I’ll give it a try when I’m home tonight.

I finished the memrise course, but it only has 5264 items for some reason :confused: but ya, feel free to use ! :slight_smile:

This sounds really nice but ofc I can’t get it to work…
This is what I wrote: %D:\1 DET MESTA\WK API\Sentencegator-0.2b%/Sentencegator --apik=%c1c501bfbcd67089ba270d0c1fd4c837% [–levels=i[,j,k]]
And I get a msg that says: Cannot find the file %D:\1. Check if you wrote the right name and try again. (translated it from swedish so might not say exactly this in eng).
When I open Sentancegator I get the same problem as Gabriel: When I open Sentencegator.exe, it seems to load the sentences and all, but then it just closes, and the result.txt is blank.
Plz help =)




aleccookies said... This sounds really nice but ofc I can't get it to work..
This is what I wrote: %D:\1 DET MESTA\WK API\Sentencegator-0.2b%/Sentencegator --apik=%c1c501bfbcd67089ba270d0c1fd4c837% [--levels=i[,j,k]]
And I get a msg that says: Cannot find the file %D:\1. Check if you wrote the right name and try again. (translated it from swedish so might not say exactly this in eng).
When I open Sentancegator I get the same problem as Gabriel: When I open Sentencegator.exe, it seems to load the sentences and all, but then it just closes, and the result.txt is blank.
Plz help =)




 Take out the "%"

C://Users/Yahya/Desktop/Sentencegator-0.2b/Sentencegator --apik=53fe2b69380258b355e506ead564ee69 --levels=1


That's exactly what I type in, and that gives me the level 1 sentences.

If I wanted all up to my level, I would just take that last part out, so
C://Users/Yahya/Desktop/Sentencegator-0.2b/Sentencegator --apik=53fe2b69380258b355e506ead564ee69

ya, use that as reference

EDIT: Okay, yako500 was faster than me.

aleccookies said…
This sounds really nice but ofc I can’t get it to work…
This is what I wrote: %D:\1 DET MESTA\WK API\Sentencegator-0.2b%/Sentencegator --apik=%c1c501bfbcd67089ba270d0c1fd4c837% [–levels=i[,j,k]]
And I get a msg that says: Cannot find the file %D:\1. Check if you wrote the right name and try again. (translated it from swedish so might not say exactly this in eng).
When I open Sentancegator I get the same problem as Gabriel: When I open Sentencegator.exe, it seems to load the sentences and all, but then it just closes, and the result.txt is blank.
Plz help =)

You shouldn’t have any % in your file path or API key. You have to replace the whole “%PATH%” by the path to the folder where you unzipped the application, and the whole “%API_KEY%” by your API key.
Also, the “[–levels=i[,j,k]]” is a technic way to say that you may include an optional “–levels” option followed by one or more numbers. You probably don’t need it.

Try:
D:\1 DET MESTA\WK API\Sentencegator-0.2b\Sentencegator --apik=c1c501bfbcd67089ba270d0c1fd4c837
I don’t know if the path is correct though. You may want to check that.

Wow, I think even my mom can use the command line to the extent of browsing directories and starting applications… but then, I forced her to use Ubuntu to save some money :slight_smile: