Jamster3000 / adventure-generator

1 stars 0 forks source link

Text generation #3

Open Jamster3000 opened 2 months ago

Jamster3000 commented 2 months ago

Use text generation which can generate NPC dialogues, lore, descriptions, etc.

Jamster3000 commented 2 months ago

from gradio_client import Client

client = Client("VinayHajare/MistralTalk")

while True: userInput = input(">>>")

result = client.predict(
        prompt=userInput,
        temperature=0.7,
        max_new_tokens=800,
        top_p=0.9,
        repetition_penalty=1.2,
        model="Mistral",
        enable_hinglish=False,
        api_name="/chat"
)
print(result)

This seems to be what I'm looking for to get this to work