GithubHelp home page GithubHelp logo

neph1 / llamatale Goto Github PK

View Code? Open in Web Editor NEW

This project forked from irmen/tale

116.0 116.0 4.0 6.35 MB

Giving the power of LLM's to a MUD lib.

Home Page: https://github.com/neph1/LlamaTale/wiki

License: GNU Lesser General Public License v3.0

Shell 0.08% JavaScript 2.35% Python 96.72% CSS 0.23% Makefile 0.02% HTML 0.54% Batchfile 0.06%
generative-ai interactive-fiction large-language-models llama llm mud roleplaying

llamatale's People

Contributors

irmen avatar neph1 avatar sils avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Forkers

1980dragon dkzdev

llamatale's Issues

Error after naming character in v0.9.0

Hey, I'm encountering this error right after naming my character after loading the prancing llama story.

   EXCEPTION: TypeError
   MESSAGE: ’set’ object is not subscriptable
   Extended stacktrace follows (most recent call last):
     —-

  File “A:\LlamaTale\LlamaTale\tale\driver_if.py”, line 275, in IFDriver.main_loop
  Source code:
      self._continue_dialog(conn, dialog, response)

     —-

  File “A:\LlamaTale\LlamaTale\tale\driver.py”, line 379, in IFDriver._continue_dialog
  Source code:
      why, what = dialog.send(message or None)

  Local values:
      conn = <tale.player.PlayerConnection object at 0x0000019DEDE82BC0>
      dialog = <generator object IFDriver._login_dialog_if at 0x0000019DEE3022D0>
      message = ’namegoeshere’
      self = <tale.driver_if.IFDriver object at 0x0000019DEDE431F0>
     —-

  File “A:\LlamaTale\LlamaTale\tale\driver_if.py”, line 186, in IFDriver._login_dialog_if
  Source code:
      name_info = yield from builder.build_character()

  Local values:
      builder = <tale.charbuilder.IFCharacterBuilder object at 0x0000019DEE32D4B0>
      conn = <tale.player.PlayerConnection object at 0x0000019DEDE82BC0>
      load_saved_game = None
      self = <tale.driver_if.IFDriver object at 0x0000019DEDE431F0>
     —-

  File “A:\LlamaTale\LlamaTale\tale\charbuilder.py”, line 76, in IFCharacterBuilder.build_character
  Source code:
      race = self.config.playable_races[0]

  Local values:
      self = <tale.charbuilder.IFCharacterBuilder object at 0x0000019DEE32D4B0>

   EXCEPTION HERE: TypeError: ’set’ object is not subscriptable
  ——————————————————-

  Please report this problem.

I've followed all the steps, kobold.cpp is working fine and I used the recommended model. Also retried this after rebooting my PC but no luck. Can you help?

oobabooga text gen api support?

CRASH OCCURRED! TIMESTAMP: 2023-11-16 18:31:49.883781
——————————————————-
EXCEPTION: JSONDecodeError
MESSAGE: Expecting value: line 1 column 1 (char 0)
Extended stacktrace follows (most recent call last):
—-

File “E:\etc\LlamaTale\tale\driver_if.py”, line 284, in IFDriver.main_loop
Source code:
self._continue_dialog(conn, dialog, response)

—-

File “E:\etc\LlamaTale\tale\driver.py”, line 385, in IFDriver._continue_dialog
Source code:
why, what = dialog.send(message or None)

Local values:
conn = <tale.player.PlayerConnection object at 0x00000191F989EAC0>
dialog = <generator object IFDriver._login_dialog_if at 0x00000191F9A7E9E0>
message = ’y’
self = <tale.driver_if.IFDriver object at 0x00000191F9817790>
—-

File “E:\etc\LlamaTale\tale\driver_if.py”, line 224, in IFDriver._login_dialog_if
Source code:
player.look(short=False) # force a ’look’ command to get our bearings

Local values:
builder = <tale.charbuilder.IFCharacterBuilder object at 0x00000191F9B09A60>
conn = <tale.player.PlayerConnection object at 0x00000191F989EAC0>
load_saved_game = False
loaded_player = None
name_info = <tale.charbuilder.PlayerNaming object at 0x00000191F9B09D00>
player = <Player 'tes' #54 @ 0x191f989ed60, privs:->
prompt = ’’
result = True
self = <tale.driver_if.IFDriver object at 0x00000191F9817790>
start_location = None
—-

File “E:\etc\LlamaTale\tale\player.py”, line 121, in Player.look
Source code:
self.tell(look_text, end=True, evoke=evoke)

Local values:
evoke = True
look_paragraphs = [’[Entrance]’, ’A room full of furry and snow-covered coats. Loud voices and roars of laughter can be heard from the main hall.’, “There’s a warm glow and loud, noisy conversations coming through a doorway to the north A biting wind reac …(truncated to 250)
look_text = “[Entrance]\nA room full of furry and snow-covered coats. Loud voices and roars of laughter can be heard from the main hall.\nThere’s a warm glow and loud, noisy conversations coming through a doorway to the north A biting wind reaches y …(truncated to 250)
self = <Player 'tes' #54 @ 0x191f989ed60, privs:->
short = False
—-

File “E:\etc\LlamaTale\tale\player.py”, line 81, in Player.tell
Source code:
msg, rolling_prompt = mud_context.driver.llm_util.evoke(self._output,

Local values:
class = <class 'tale.player.Player'>
alt_prompt = ’’
end = True
evoke = True
format = True
message = “[Entrance]\nA room full of furry and snow-covered coats. Loud voices and roars of laughter can be heard from the main hall.\nThere’s a warm glow and loud, noisy conversations coming through a doorway to the north A biting wind reaches y …(truncated to 250)
self = <Player 'tes' #54 @ 0x191f989ed60, privs:->
short_len = False
—-

File “E:\etc\LlamaTale\tale\llm\llm_utils.py”, line 79, in LlmUtil.evoke
Source code:
text = self.io_util.synchronous_request(request_body, prompt=prompt)

Local values:
alt_prompt = ’’
amount = 25
cached_look = ’’
message = “[Entrance]\nA room full of furry and snow-covered coats. Loud voices and roars of laughter can be heard from the main hall.\nThere’s a warm glow and loud, noisy conversations coming through a doorway to the north A biting wind reaches y …(truncated to 250)
output_template = ’Original:[ {message}] Generated:{text}’
player_io = <tale.player_utils.TextBuffer object at 0x00000191F98D7040>
prompt = “Below is an instruction that describes a task, paired with an input that provides further context. As an game keeper for an RPG, write a response that appropriately completes the request.[Story context: The final outpost high up in a cold, craggy mo …(truncated to 250)
request_body = {’stop_sequence’: ’\n\n\n’, ’max_length’: 750, ’max_context_length’: 4096, ’temperature’: 1.0, ’top_k’: 120, ’top_a’: 0.0, ’top_p’: 0.85, ’typical_p’: 1.0, ’tfs’: 1.0, ’rep_pen’: 1.2, ’rep_pen_range’: 256, ’sampler_order’: [6, 0, 1, 3, 4, 2, 5], ’see …(truncated to 250)
rolling_prompt = “[Entrance]\nA room full of furry and snow-covered coats. Loud voices and roars of laughter can be heard from the main hall.\nThere’s a warm glow and loud, noisy conversations coming through a doorway to the north A biting wind reaches y …(truncated to 250)
self = <tale.llm.llm_utils.LlmUtil object at 0x00000191F9817580>
short_len = False
skip_history = True
text_hash_value = -2607203395444595668
trimmed_message = “[Entrance]\nA room full of furry and snow-covered coats. Loud voices and roars of laughter can be heard from the main hall.\nThere’s a warm glow and loud, noisy conversations coming through a doorway to the north A biting wind reaches y …(truncated to 250)
—-

File “E:\etc\LlamaTale\tale\llm\llm_io.py”, line 38, in IoUtil.synchronous_request
Source code:
parsed_response = self._parse_kobold_result(response.text)

Local values:
prompt = “Below is an instruction that describes a task, paired with an input that provides further context. As an game keeper for an RPG, write a response that appropriately completes the request.[Story context: The final outpost high up in a cold, craggy mo …(truncated to 250)
request_body = {’stop_sequence’: ’\n\n\n’, ’max_length’: 750, ’max_context_length’: 4096, ’temperature’: 1.0, ’top_k’: 120, ’top_a’: 0.0, ’top_p’: 0.85, ’typical_p’: 1.0, ’tfs’: 1.0, ’rep_pen’: 1.2, ’rep_pen_range’: 256, ’sampler_order’: [6, 0, 1, 3, 4, 2, 5], ’see …(truncated to 250)
response = <Response [404]>
self = <tale.llm.llm_io.IoUtil object at 0x00000191F9834DF0>
—-

File “E:\etc\LlamaTale\tale\llm\llm_io.py”, line 87, in IoUtil._parse_kobold_result
Source code:
return json.loads(result)[’results’][0][’text’]

Local values:
result = ’\n\n \n \n <title>Error response</title>\n \n …(truncated to 250)
self = <tale.llm.llm_io.IoUtil object at 0x00000191F9834DF0>
—-

File “E:\etc\Anaconda\lib\json_init_.py”, line 346, in loads
Source code:
return _default_decoder.decode(s)

Local values:
cls = None
kw = {}
object_hook = None
object_pairs_hook = None
parse_constant = None
parse_float = None
parse_int = None
s = ’\n\n \n \n <title>Error response</title>\n \n …(truncated to 250)
—-

File “E:\etc\Anaconda\lib\json\decoder.py”, line 337, in JSONDecoder.decode
Source code:
obj, end = self.raw_decode(s, idx=_w(s, 0).end())

Local values:
_w = <built-in method match of re.Pattern object at 0x00000191F708D9F0>
s = ’\n\n \n \n <title>Error response</title>\n \n …(truncated to 250)
self = <json.decoder.JSONDecoder object at 0x00000191F709BB80>
—-

File “E:\etc\Anaconda\lib\json\decoder.py”, line 355, in JSONDecoder.raw_decode
Source code:
raise JSONDecodeError(“Expecting value”, s, err.value) from None

Local values:
idx = 0
s = ’\n\n \n \n <title>Error response</title>\n \n …(truncated to 250)
self = <json.decoder.JSONDecoder object at 0x00000191F709BB80>

EXCEPTION HERE: JSONDecodeError: Expecting value: line 1 column 1 (char 0)

’IFDriver’ object has no attribute ’loaded_character’

I can't seem to get t to createa new character or load a character. It gives this error everytime. Koboldcpp is working, and running on port 5001, however it doesn't seem as if anything is being passed to it. Any advice?


Do you want to load a saved game (’n’ will start a new game)? n

  • internal error (please report this):

——————————————————-
CRASH OCCURRED! TIMESTAMP: 2023-08-09 09:19:00.243085
——————————————————-
EXCEPTION: AttributeError
MESSAGE: ’IFDriver’ object has no attribute ’loaded_character’
Extended stacktrace follows (most recent call last):
—-

File “C:\Users\Badgids\AI\LlamaTale\tale\driver_if.py”, line 271, in IFDriver.main_loop
Source code:
self._continue_dialog(conn, dialog, response)

 —-

File “C:\Users\Badgids\AI\LlamaTale\tale\driver.py”, line 378, in IFDriver._continue_dialog
Source code:
why, what = dialog.send(message or None)

Local values:
conn = <tale.player.PlayerConnection object at 0x000001AA5D984790>
dialog = <generator object IFDriver._login_dialog_if at 0x000001AA5E584E40>
message = False
self = <tale.driver_if.IFDriver object at 0x000001AA5D893AC0>
—-

File “C:\Users\Badgids\AI\LlamaTale\tale\driver_if.py”, line 163, in IFDriver._login_dialog_if
Source code:
if self.loaded_character:

Local values:
conn = <tale.player.PlayerConnection object at 0x000001AA5D984790>
load_saved_game = None
self = <tale.driver_if.IFDriver object at 0x000001AA5D893AC0>

EXCEPTION HERE: AttributeError: ’IFDriver’ object has no attribute ’loaded_character’
——————————————————-

Please report this problem.

internal error MESSAGE: ’results’

Having the following issue while running on koboldcpp.

* internal error (please report this):


——————————————————-
 CRASH OCCURRED! TIMESTAMP: 2024-01-06 19:59:41.891651
——————————————————-
 EXCEPTION: KeyError
 MESSAGE: ’results’
 Extended stacktrace follows (most recent call last):
   —-

File “D:\AI Generative\LlamaTale\tale\driver_if.py”, line 285, in IFDriver.main_loop
Source code:
    self._continue_dialog(conn, dialog, response)

   —-

File “D:\AI Generative\LlamaTale\tale\driver.py”, line 394, in IFDriver._continue_dialog
Source code:
    why, what = dialog.send(message or None)

Local values:
    conn = <tale.player.PlayerConnection object at 0x0000021ADD4482D0>
    dialog = <generator object IFDriver._login_dialog_if at 0x0000021ADD316F80>
    message = ’The Chronicles of Eldoria’
    self = <tale.driver_if.IFDriver object at 0x0000021ADD402B50>
   —-

File “D:\AI Generative\LlamaTale\tale\driver_if.py”, line 176, in IFDriver._login_dialog_if
Source code:
    start_location = story_build.apply_to_story(self.story, self.llm_util)

Local values:
    conn = <tale.player.PlayerConnection object at 0x0000021ADD4482D0>
    load_saved_game = False
    self = <tale.driver_if.IFDriver object at 0x0000021ADD402B50>
    start_location = None
    story_build = <tale.story_builder.StoryBuilder object at 0x0000021ADD8C17D0>
    story_info = <tale.story_builder.StoryInfo object at 0x0000021ADD8C1810>
   —-

File “D:\AI Generative\LlamaTale\tale\story_builder.py”, line 80, in StoryBuilder.apply_to_story
Source code:
    story.config.context = llm_util.generate_story_background(world_info=story.config.world_info,

Local values:
    llm_util = <tale.llm.llm_utils.LlmUtil object at 0x0000021ADD402910>
    self = <tale.story_builder.StoryBuilder object at 0x0000021ADD8C17D0>
    story = <story.Story object at 0x0000021ADD40C450>
   —-

File “D:\AI Generative\LlamaTale\tale\llm\llm_utils.py”, line 174, in LlmUtil.generate_story_background
Source code:
    return self._story_building.generate_story_background(world_mood, world_info, story_type)

Local values:
    self = <tale.llm.llm_utils.LlmUtil object at 0x0000021ADD402910>
    story_type = ’A high-fantasy open-world adventure’
    world_info = “Eldoria is a magical and diverse world filled with lush forests, fiery volcanoes, towering mountains, shifting deserts, and ever-changing islands. It’s home to numerous cities, ancient ruins, and mystical creatures. With its rich history and enchant   …(truncated to 250)
    world_mood = 3
   —-

File “D:\AI Generative\LlamaTale\tale\llm\story_building.py”, line 21, in StoryBuilding.generate_story_background
Source code:
    return self.io_util.synchronous_request(request_body, prompt=prompt)

Local values:
    prompt = “[USER_START] For an RPG described as A high-fantasy open-world adventure set in a world described as  very friendly, Eldoria is a magical and diverse world filled with lush forests, fiery volcanoes, towering mountains, shifting deserts, and ever-cha   …(truncated to 250)
    request_body = {’stop_sequence’: ’\n\n\n\n’, ’max_length’: 750, ’max_context_length’: 4096, ’temperature’: 0.5, ’top_k’: 120, ’top_a’: 0.0, ’top_p’: 0.85, ’typical_p’: 1.0, ’tfs’: 1.0, ’rep_pen’: 1.2, ’rep_pen_range’: 256, ’sampler_order’: [6, 0, 1, 3, 4, 2, 5], ’s   …(truncated to 250)
    self = <tale.llm.story_building.StoryBuilding object at 0x0000021ADBF264D0>
    story_type = ’A high-fantasy open-world adventure’
    world_info = “Eldoria is a magical and diverse world filled with lush forests, fiery volcanoes, towering mountains, shifting deserts, and ever-changing islands. It’s home to numerous cities, ancient ruins, and mystical creatures. With its rich history and enchant   …(truncated to 250)
    world_mood = 3
   —-

File “D:\AI Generative\LlamaTale\tale\llm\llm_io.py”, line 44, in IoUtil.synchronous_request
Source code:
    parsed_response = self._parse_kobold_result(response.text)

Local values:
    prompt = “[USER_START] For an RPG described as A high-fantasy open-world adventure set in a world described as  very friendly, Eldoria is a magical and diverse world filled with lush forests, fiery volcanoes, towering mountains, shifting deserts, and ever-cha   …(truncated to 250)
    request_body = {’stop_sequence’: ’\n\n\n\n’, ’max_length’: 750, ’max_context_length’: 4096, ’temperature’: 0.5, ’top_k’: 120, ’top_a’: 0.0, ’top_p’: 0.85, ’typical_p’: 1.0, ’tfs’: 1.0, ’rep_pen’: 1.2, ’rep_pen_range’: 256, ’sampler_order’: [6, 0, 1, 3, 4, 2, 5], ’s   …(truncated to 250)
    response = <Response [503]>
    self = <tale.llm.llm_io.IoUtil object at 0x0000021ADD444810>
   —-

File “D:\AI Generative\LlamaTale\tale\llm\llm_io.py”, line 95, in IoUtil._parse_kobold_result
Source code:
    return json.loads(result)[’results’][0][’text’]

Local values:
    result = ’{“detail”: {“msg”: “Server is busy; please try again later.”, “type”: “service_unavailable”}}’
    self = <tale.llm.llm_io.IoUtil object at 0x0000021ADD444810>

 EXCEPTION HERE: KeyError: ’results’
——————————————————-


Please report this problem.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.