Comments

Log in with itch.io to leave a comment.

Hello,  it looks quite impressive, I had a hard time finding AI-related plugins for RPG Maker MZ.

However, I'm quite confused about the itch.io install instructions :

Put it in your projects \js\plugins\ directory

Are we supposed to create a Directory folder or is it part of another plugin?


Also, even if 2Plaer is a jackass, I think one similar point to his still applies.

If you give a prompt to the wise man, it will generate a dialogue with that prompt.

However, it can be "unstable", let me explain:

The main risk would be that the dialogue breaks the game story or the character's background.

If your story takes place in a Desert during a War in 1832 and the old man starts giving inaccurate or even contradictory information on the plot, it would be quite problematic.

I'm not saying the plugin is bad, just that I think more detailing could make it even greater if your goal is to improve this one. 

I don't know what were your intention with this plugin, I think it's great for background NPC and makes them feel more alive, but it will probably not be used for more important characters if that was your intention. (due to the reason above)


Also, it's just a random dumb idea I had, which may or may not interest you if you're doing a game, what would prompt on objects event would result? I feel like there is a lot of potential, especially in the comedy genre.

Like, would the AI just say "I'm a chair.", or would it give a description or an action the character is doing with the chair? Maybe the 3?

Anyway, Thank you for reading, and have a nice life.

(1 edit)

Hi there!

Put the plugin (.js file) into <your project root>/js/plugins/
There should be a couple of default plugins in there already. No need to create new directories!
After that, in RMMZ, navigate to plugins and add the AI plugin there. The rest is documented in the engine.

I fully agree about the responses being unstable. After all, that's the main feature - and problem - of AI responses. You never know what you get back, so it might be fully hallucinated nonsense. You can try to steer the responses to be more refined by writing better prompts, but as soon as they get lengthy, that just ups the cost per response with very diminishing returns. As such, I highly recommend to only use this for NPC chatter, not for a main plot line - or an NPC that NEEDS to give accurate directions.

In your example with the wise man, you can add all those lore details to the prompt. Then it should be part of the response, however... it may be not. Depending on the AI.

That - paired with the running cost issue per request to openAI - is also the reason why this plugin is fully free. It's experimental, and from my personal point of view not "production ready" for a commercial game.

Regarding NPC objects - I just tried it for a chair, and the result was:
"Oh, hello! I'm just a simple chair, but I've seen many adventurers come and go."

I then tried a more refined prompt ("Respond in asterisks, describing actions, [...]"), the result was:
"*You are sitting down on the chair, which weirdly enough sighs.* Ah, that's the spot! I've been waiting all day for someone to give me some purpose. Rest here for a moment, adventurer."
...interesting result, LOL.

And lastly, 2Plaer: yeah, admittantly I was bothered a lot by his responses. To make "demands" for a free and marked as experimental plugin just irked me, and then him describing features that aren't even in here... I dunno. Honestly I may have been too flippant, but that sure annoyed me.

I want to know why this plugin has a hard link to OpenAI. Your source code is not public, which may lead to privacy leakage. Are you willing to provide a paid version that allows you to see the source code?

On the other hand, I have no intention of disparaging anyone. In fact, there are better alternatives to this plugin, but none of them filter the replies by keywords.

Sure, no problem! Uploaded the unobfuscated version as well. Honestly, I just wanted to hide my shoddy code rather than create a trade secret.

I'm kinda intrigued by the "filter by keywords" thing you mentioned. Maybe I can add this if it's relevant?

After seeing your explanation, I plan to give up making demands on you.

This approach of accessing AI usually faces the following problems.

1. Whether to give players the power to freely construct sentences

2. Players cross the moral limit through prompts, resulting in nsfw results.

3. Is typing a bit troublesome for video games, especially when players use game controllers and have to switch keyboards to type.

4. Multi-language localization,

5. AI only makes NPCs become better chat robots, and it can never give players 1 experience point

Of course, I also gave a solution.

Cancel typing input and change it to fill in the blanks by selecting words according to the sentence structure. As for vocabulary, it is limited to words related to the game world view. Players cannot enter keywords that the game protagonist does not know due to the game progress.

I have tried to use GPT4 to output js and execute it in the game, but it is unstable. A more reliable way is to search for NPC replies and use some keywords as triggers to give players experience points or gold coins.

(1 edit)

None of this makes any sense because nothing of what you said has anything to do with this plugin. Have you even tested it? The players can't prompt the AI, it's the dev.

1) players can't prompt the AI. 

2) players can't prompt the AI. But even if they could, they'd have to do massive jailbreaks to escape from openai safety limits.

3) players can't prompt the AI, therefore they don't have to type anything

4) multi language is supported.

5) it's not a free chat because the player can't prompt directly 

Your solution isn't valid because it has nothing to do with this plugin. And the last comment is even more baffling.

The AI in this plugin doesn't generate js code or game logic. It literally just generates NPC chatter based on Dev-defined prompts. 


In the future, I recommend actually trying a plugin or read the code if you plan to bash it.

Mind you, ask the points you raise works be good critique... For a different plugin. This here has nothing to do with it.

This is an experimental, free plugin I threw together in an afternoon to quickly generate NPC chatter. To even think to "make demands" is beyond ludicrous.

I played along with opening the source code because yeah, a malicious dev could've nabbed the API key. The readable source code proves this plugin literally can only do one thing and nothing else: generate NPC chatter based on dev defined prompts.

Stop fighting against windmills.