this post was submitted on 22 Apr 2024
4 points (83.3% liked)

Perchance - Create a Random Text Generator

434 readers
11 users here now

⚄︎ Perchance

This is a Lemmy Community for perchance.org, a platform for sharing and creating random text generators.

Feel free to ask for help, share your generators, and start friendly discussions at your leisure :)

This community is mainly for discussions between those who are building generators. For discussions about using generators, especially the popular AI ones, the community-led Casual Perchance forum is likely a more appropriate venue.

See this post for the Complete Guide to Posting Here on the Community!

Rules

1. Please follow the Lemmy.World instance rules.

2. Be kind and friendly.

  • Please be kind to others on this community (and also in general), and remember that for many people Perchance is their first experience with coding. We have members for whom English is not their first language, so please be take that into account too :)

3. Be thankful to those who try to help you.

  • If you ask a question and someone has made a effort to help you out, please remember to be thankful! Even if they don't manage to help you solve your problem - remember that they're spending time out of their day to try to help a stranger :)

4. Only post about stuff related to perchance.

  • Please only post about perchance related stuff like generators on it, bugs, and the site.

5. Refrain from requesting Prompts for the AI Tools.

  • We would like to ask to refrain from posting here needing help specifically with prompting/achieving certain results with the AI plugins (text-to-image-plugin and ai-text-plugin) e.g. "What is the good prompt for X?", "How to achieve X with Y generator?"
  • See Perchance AI FAQ for FAQ about the AI tools.
  • You can ask for help with prompting at the 'sister' community Casual Perchance, which is for more casual discussions.
  • We will still be helping/answering questions about the plugins as long as it is related to building generators with them.

6. Search through the Community Before Posting.

  • Please Search through the Community Posts here (and on Reddit) before posting to see if what you will post has similar post/already been posted.

founded 1 year ago
MODERATORS
 

Right so, I have been wanting to make an image generator that you can type it’s prompt and pick different art generation types but since this type of developing is new to me I’m not sure what to do, I would have just codded a javascript or python one but I can’t use that code here any ideas on how I can make it?

top 3 comments
sorted by: hot top controversial new old
[–] [email protected] 2 points 6 months ago* (last edited 6 months ago) (1 children)

i came from Javascript and Kotlin and my path thru was to first see the t2i framework. here's an example of one using t2i. https://perchance.org/moonstones-wonderland i just made the tiniest edit to a t2i one like this to get my feet wet.

Then the next step seemed to be definitely to get it under finer control, which you will also want, than t2i. for that there is https://perchance.org/text-to-image-plugin and nearly any example that links off it is something good to look at and start with. My next step was to make all the inputs in my own HTML.

From there you can actually do nearly anything you want with JS. I personally had expected to stay away from Perchance Script as a snobby elitist, but, over the time of getting to that point had come to see some of it's power and ease of which variables can be lists and allow variation within single variables. I now find the ideal a happy medium of both Perchance and JS synergizing together.

https://perchance.org/beautiful-people here is my current generator and where I, eventually, for maximum control, create all my images programatically which, at minimum, is: if your import is image = {import:text-to-image-plugin}, would allow you to call function 'image' and pass it an object with at least a 'prompt' in it, like: image({prompt:'meow'}).evaluateItem

I basically forged my own way in the dark not knowing any of that. Now, knowing about the programmatic way, that is where I am focusing as it is highest potential and also where I would point you.

Also to take it slow with Perchance script and not write it off as worse than Javascript. It specifically is nice when you want to have variation in a variable, as I do in my prompts in beautiful people, and can fit seamlessly with javascript as a symbiotic friend. Everything helps if you believe it does.

And that's my intro. hope you make beautiful things :)

[–] [email protected] 2 points 6 months ago

@Alllo That's an answer I haven't been thinking before. I started learning Perchance and JS over 2 years ago, and just started tinkering with the plugin when it was just released. And yeah, there are many AI image generators that use the t2i framework, actually.

@AdministratorDude You can start simple, and then start exploring the boundaries of the text-to-image-plugin, the deep-in-down Perchance code, and maybe explore other generators that offer great possibilities Perchance has. 😊

[–] [email protected] 2 points 6 months ago* (last edited 6 months ago)

If you want minimal effort, then as allo said, the t2i-framework-plugin-v2 (which uses text-to-image-plugin under the hood) is a good place to start. I've just added a bunch more comments in the code here, so it should be fairly self-explanatory: https://perchance.org/ai-text-to-image-generator#edit It uses t2i-framework-plugin-v2, and gives you a starting point for the settings. Just Ctrl+F for "MTG Card" and edit it to your own style, and duplicate it to create more styles, then save it.

And, as allo said also, if you want more customization, you can go one level lower to https://perchance.org/text-to-image-plugin

Vionet has written extensively about the text-to-image-plugin in case you want to dive into a complete guide: https://perchance.org/learn-perchance-plugins-text-to-image