0 Followers
0 Following
2 Posts
wish i was a baby; wish i was dead.

Yup, I’m wee bit of a Linux sysadmin kinda nerd and I do a lot of stuff in Perl, which is a very dense language that I wish I had never picked up, but hey, it is excellent at text processing.

The original idea went like this: save a template to a text file, read it, perform replacements, and then write that modified copy to the clipboard. The original version was just that, not too complicated. Off the top of my head, the meat of it is something like this (pseudocode):

copy=""; for line of readlines filename for key in table line=line.replace(/\b${key}\b/,table[key]); copy += line + "\n"

Basically, you find key within the template and expand it to the corresponding value in the table, which is just JSON, eg:

const table={ "--lighting":"text describing lighting" "--background":"text describing background" // and so on }

But then I realized that for a character, I would need more than one item. So that means this thing needs to work recursively, that is to say “–character” would have to be an object, which has to be converted into a string that can be put into the template…

Similar story if, for instance, one element references another. Maybe you replace “–background”, but the text for it contains a reference like say “–time-of-day” or something. So you have to do multiple passes, until there is nothing left to replace.

Anyway, I hacked it together in a very absent-minded kind of way without a clear plan so now it’s completely unmaintainable lmaooo.

It is OK as a prototype, the good thing it has is that once you define an object and save it to the “database” (in my case, just a bunch of text files saved on my disk), you can reference it anywhere else. I’ve been using it to write character sheets a lot, and that kinda bridged the gap between T2I and text gen, I just write a new object referencing other objects in the database (facial features, hair, clothing, personality traits, et cetera) and boom, that’s a fresh character I can insert into a scene.

Think of it like playing with dolls, maybe? You comb their hair, have them try out new clothes, and then give them a batmobile :DD and once you define what the batmobile looks like, you can place it anywhere else. Something like that.

I think that it’s a very good fit for Perchance, and since Javascript is more or less just a well-adjusted Perl the translation work isn’t too challenging. The only real concern is planning the project a little bit better so I don’t turn it into spaghetti twice.

Hmm, I don’t know, lots of weird stuff. I don’t trust out-of-nowhere crazy walls of text person, so I’ve removed their presence from my mental register.

But I worked out how to do photography, which is what most people seem to be complaining about, so here’s a short guide, hope it helps:

  • Use the default T2I.
  • Delete the negative prompt.
  • Set “style” to “NO STYLE”.

Then just play around with this template:

a low resolution photographic still frame from a cult 1980s b-movie, cinematic close-up portrait shot featuring a lonely wanderer, Jim. Background: Foggy streets of an antique gothic city. Midnight. Lit in ominous hues of purplish blue. Aesthetic: Dark fantasy. Photography Style: Modern avant garde cinema. Second millenium expressionist photography, professionally shot and composed. Natural Lighting: Exquisite strong blue lighting with dramatic deep red accents. Camera: 70mm IMAX MSM 9802. Jim walking through the streets.

Chose some pseudo LaserDisc mambo as baseline but you can change that around, obviously. And then you can keep going. Like say:

Jim walking through the streets. Face: describe Jim's face. Hair: describe Jim's hair. Eyes: same thing for the eyes... Body: idem Clothing: and so on and so on.

That template with a guidance scale of 11 has been working wonders for me, and it’s a simple enough pattern that you can easily modify it. I’m a weird case, because I have characters and style elements saved as JSON files, I just generate these things from an overcomplicated script (6000+ SLOC of spaghetti, should do a clean rewrite in Javascript and make it into a generator at this point…)

Anyway, I’m actually getting better results now than I was getting before the update, across the board. So, I’m sorry to folks having a bad time, but all the despair going around? Calling results useless and horrible and shit and all that? Man, that sounds like a skill issue. This entire situation only took me a wee bit of tinkering to solve, it was next to trivial. I mean, c’mon, people! You can do better! Or you can ask for help, maybe, now that would at least make this a more pleasant environment to be in.

OK OK I’ll stop now. Cheers! :)

AI Image Generator (free, no sign-up, unlimited)

A *fast*, unlimited, no login (ever!!!), AI image generator. Generate large *batches* of images all in just a few seconds. Generate AI art from text, completely free, online, no login or sign-up, no daily credit limits/restrictions/gimmicks, and it's fast. Other AI art generators often have annoying daily credit limits and require sign-up, or are slow - this one doesn't. Use this AI to generate high quality art, photos, cartoons, drawings, anime, thumbnails, pfps, and more. Create OCs, anime characters, AI villains, fanfic artwork, and pretty much anything else. It's an AI-based image generator - i.e. a text-to-image model. No watermark, no account needed, unlimited images. Type words, make pics.