greasyi
10/19/13 12:13AM
Mantra text generator
So one of the things I like to do is have the computer "talk dirty to me" by using text-to-speech and having microsoft mary say MC-related things while I look at pictures. TTS has drawbacks in realism, but these aren't big problems if you *want* it to sound like an induction program or someone affected by one.

So I was bored today and thought I would make a program that can generate a body of random phrases mixed together automatically and uniformly using a source file with some rules. It basically boils down to variations on a theme using pre-defined phrases and word-replacement.

It's a very simple thing so it's not going to take long; but now that I've started, it occurred to me that people here might be interested in using it for their own purposes. If nothing else it might be good for some manips. So would anyone be interested in this? Would any particular features be desired?
Vanndril
10/19/13 12:47AM
A mantra generator? That sounds interesting. Might be good inspiration for text manips. That's probably what I'd use it for.
Lunakiri
10/19/13 02:35AM
I agree with Vann, it could definitely be interesting. And it most likely would be rather useful for text manips. I, personally, tend to flake on the text the odd time I do them.

And it would be useful for possible inspiration for pics to draw, for those of us who are artists.

So... all the power to ya for it =D
Stem_Cell
10/19/13 03:12AM
Sounds like a cool idea, what language will you make it in?

Also, some inspiration:

* <<www.dack.com/web/bullshit.html|Web economy bullshit generator>>
* <<cbsg.sourceforge.net/cgi-bin/live|Corporate bullshit generator>>
greasyi
10/19/13 05:14AM
It's in Java. To start with I'm going to go with very simple text-replacement where it just generates all possible strings from the templates it's been given and then puts them in a random but well-distributed order. Templates will be able to specify how many phrases can be drawn from them to limit repetition. The hardest part of the whole thing is probably making a friendly user interface.

Going forward, I think I want to allow multiple template files to generate together, and then I want to allow template files to specify configuration options, so one can decide in one quick step if, for example, it's fsub/msub, and that would change pronouns and such according to the template.

I think I remember a pic, I think from hypnopics->Couple of Dragons where a maid lingerie had a white background full of mantra text, I think it could help for things like that, the kind of boring filler that's cool to have but no one actually wants to read. I would find the pic but it doesn't seem to be on here (at least not tagged properly) and there's almost 15,000 pics on Couple of Dragons to dig through.
Vanndril
10/19/13 08:21AM
greasyi said:
[...]and there's almost 15,000 pics on Couple of Dragons to dig through.

And I sat there and scoured through all of it in one sitting, long ago. Couple of Dragons will always hold a sort of special place in my heart as far as manippers go, since his stuff was what inspired me to manip in the first place.
Stem_Cell
10/19/13 09:29AM
One thing that would be really nice is to produce those nice hypno visuals on-the-fly. Those swirly things that if you look at for a while they mess with your vision. Then you could put the text on top of that while it is spoken.

I think you should make the simpliest UI possible to begin with, by the way. I've had several projects that I halted because the UI part was more work than I thought at first.
greasyi
10/19/13 12:26PM
If "takes a static file name as input and writes a static file name as output without saying anything" isn't the simplest UI possible, I don't know what is.

Here's the prototype: www.mediafire.com/?92jgmm1zjnxoxrz
Obviously you need Java Runtime Environment installed to run it, but that shouldn't be a problem (and if it is, you should really install JRE anyway).
Play around with it and tell me if you think something's missing or wrong.

It takes template.txt in the same folder and writes mantra.txt to the same folder. I have included a template file that basically randomly shuffles the phrases in the subliminal sections of the long-missing story "Courting Kass". The format is fairly easy, everything except !X is in the example file:

@Word will define a keyword that gets replaced by the things below it; it will stop building the list of @Word replacements when it sees a blank line.

Anything else is a phrase. The keyword #Word will look for an @Word list and generate one phrase per item in the list. This is done for each #Word, so a phrase containing both #Word1 and #Word2 will be generated (@Word1 x @Word2) times. If this is overkill and sounds too repetitive, a phrase can be limited to a max of X (randomly selected) generations by starting a phrase with !X (that's !, then a whole number, then a space, then the real phrase).

Once it parses the template file, it will generate all of the phrases it wants to generate (all that it can unless limited by !X) and spit them out to mantra.txt in random order separated by spaces.

Currently the only way to alter generation probabilities is to duplicate entries. A good way to make sure a group of different phrases is widely distributed across the text is to put them all in a @List, and simply have the #List as a phrase by itself. The system was thrown together without much care and so is not robust and will die a horrible death (i.e. crash and do nothing) if you do anything wrong. You should probably make sure the template file ends with a line return. Do not create any keyword loops where a keyword eventually leads back to itself. It doesn't check for punctuation, so don't use #WordWithPeriod. and assume it will replace @WordWithPeriod and stick a period on the end; you'll have to add a space between and then do find and replace on " ." afterwards. I assume apostrophes and quotation marks won't cause the thing to instantly catch fire but I haven't checked.

On the immediate to-do list:
- Add a gui that lets you set an infile and an outfile, even if just by text box
- Add a delimiter option (not just a space character)
- Allow batch template generation (templates could then hypothetically be libraries for other templates)
- Add configuration options to the template format, and let the GUI set the config options.
Stem_Cell
10/20/13 07:42AM
greasyi said:
you should really install JRE anyway

By the way, <<www.howtogeek.com/122934/|not everyone agrees on that>>. I have it disabled from all browsers, and when I need it, I use a portable Java runtime, or package my applications as portables (which is interesting, because Gooogle Closure Compiler runs faster for me in a single executable with Java inside it).

Then again, I give favoritism for .NET just because I love C#, but that's just me.

About the program, I'll be honest that I didn't try it :P
But the templates idea is good.
Mister Vi
10/20/13 10:00AM
I've been playing around with it, and I'm absolutely smitten by it. It's a bit technical for me (I don't have the best ability to focus mentally and the idea of altering what I know is simple word replacement is frustratingly difficult for me. The template was a bit intimidating for it's size.) but i understood enough to deconstruct the kass template and reworked it to be a second person mantra for myself I must sound pathetic, Now if I could just find a suitable voice delivery system.... In any case I really want to thank you for sharing this I'm having loads of fun with it.

greasyi said:
On the immediate to-do list:
- Add a gui that lets you set an infile and an outfile, even if just by text box


I feel that such an addition would improve the experience nicely
greasyi
10/20/13 11:34AM
Ironically I didn't work on this today because I started writing my first erotica, which doesn't even have a mantra in it.
ffvi1994 said:
I'm absolutely smitten
...
thank you

I don't know why but this really made my day. :)

ffvi1994 said:
Now if I could just find a suitable voice delivery system....

The best I've found so far (Windows) is Balabolka:
www.cross-plus-a.com/balabolka.htm
It nicely lets you tts an arbitrary amount of text.
You probably need voices, so check the F.A.Q. page. There's two free types by Microsoft SAPI 4 and SAPI 5. I can't get the SAPI 5 voices to work but maybe you'll have better luck.

TTS systems generally need a lot of coaxing to properly pronounce some words, though, so expect to get creative. Test out phrases and words before you bury them in a template. Sometimes turning a noun into an adjective completely changes the pronunciation.
rokkitman
10/20/13 12:11PM
Wanted to thank you for this. Plugged the output file into a Python spiral program I like to use, much easier and different every time I run it, wee!
Stem_Cell
10/20/13 03:32PM
rokkitman said:
a Python spiral program I like to use

Those exist already? o_O
Vanndril
10/20/13 08:58PM
Stem_Cell said:
Those exist already? o_O

Are you really that surprised?
Stem_Cell
10/21/13 02:30AM
Vanndril said:
Are you really that surprised?

Somewhat :P

Maybe it's just the forums, but I get the impression that everyone here has some sort of talent. Some code, others draw, others are good with text... it's like everyone in the hypno community is creative.

But it does sound kinda logical that programmers like mind control 9_9
1 2345>>>


Reply | Forum Index