ai-plays-jackbox 0.2.1__tar.gz → 0.3.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of ai-plays-jackbox might be problematic. Click here for more details.

Files changed (41) hide show
  1. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/PKG-INFO +3 -3
  2. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/README.md +2 -2
  3. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/bot_base.py +7 -8
  4. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox5/patently_stupid.py +1 -0
  5. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/cli/main.py +10 -0
  6. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/llm/gemini_model.py +1 -1
  7. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/pyproject.toml +3 -3
  8. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/LICENSE +0 -0
  9. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/__init__.py +0 -0
  10. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/__init__.py +0 -0
  11. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/bot_factory.py +0 -0
  12. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/bot_personality.py +0 -0
  13. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox5/__init__.py +0 -0
  14. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox5/bot_base.py +0 -0
  15. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox5/mad_verse_city.py +0 -0
  16. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox6/__init__.py +0 -0
  17. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox6/bot_base.py +0 -0
  18. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox6/dictionarium.py +0 -0
  19. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox6/joke_boat.py +0 -0
  20. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox7/__init__.py +0 -0
  21. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox7/bot_base.py +0 -0
  22. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox7/quiplash3.py +0 -0
  23. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox8/__init__.py +0 -0
  24. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox8/bot_base.py +0 -0
  25. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/jackbox8/job_job.py +0 -0
  26. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/standalone/__init__.py +0 -0
  27. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/bot/standalone/drawful2.py +0 -0
  28. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/cli/__init__.py +0 -0
  29. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/constants.py +0 -0
  30. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/llm/__init__.py +0 -0
  31. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/llm/chat_model.py +0 -0
  32. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/llm/chat_model_factory.py +0 -0
  33. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/llm/ollama_model.py +0 -0
  34. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/llm/openai_model.py +0 -0
  35. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/room/__init__.py +0 -0
  36. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/room/room.py +0 -0
  37. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/run.py +0 -0
  38. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/scripts/lint.py +0 -0
  39. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/ui/__init__.py +0 -0
  40. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/ui/main.py +0 -0
  41. {ai_plays_jackbox-0.2.1 → ai_plays_jackbox-0.3.0}/ai_plays_jackbox/ui/startup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: ai-plays-jackbox
3
- Version: 0.2.1
3
+ Version: 0.3.0
4
4
  Summary: Bringing the dead internet theory to life. Have AI play JackBox with you; no friends required!
5
5
  License: MIT
6
6
  Author: Daniel S. Thompson
@@ -28,7 +28,7 @@ Project-URL: Bug Tracker, https://github.com/SudoSpartanDan/AIPlaysJackBox/issue
28
28
  Project-URL: Repository, https://github.com/SudoSpartanDan/AIPlaysJackBox
29
29
  Description-Content-Type: text/markdown
30
30
 
31
- # AI Plays JackBox
31
+ # ai-plays-jackbox
32
32
 
33
33
  ![Stable Version](https://img.shields.io/pypi/v/ai-plays-jackbox?label=stable)
34
34
  ![Python Versions](https://img.shields.io/pypi/pyversions/ai-plays-jackbox)
@@ -36,7 +36,7 @@ Description-Content-Type: text/markdown
36
36
 
37
37
  Bringing the dead internet theory to life. Have AI play JackBox with you; no friends required!
38
38
 
39
- ![example](https://github.com/SudoSpartanDan/AIPlaysJackBox/blob/main/.github/emoji_bot_example.png?raw=true)
39
+ ![example](https://github.com/SudoSpartanDan/ai-plays-jackbox/blob/main/.github/emoji_bot_example.png?raw=true)
40
40
 
41
41
  ## Installation
42
42
 
@@ -1,4 +1,4 @@
1
- # AI Plays JackBox
1
+ # ai-plays-jackbox
2
2
 
3
3
  ![Stable Version](https://img.shields.io/pypi/v/ai-plays-jackbox?label=stable)
4
4
  ![Python Versions](https://img.shields.io/pypi/pyversions/ai-plays-jackbox)
@@ -6,7 +6,7 @@
6
6
 
7
7
  Bringing the dead internet theory to life. Have AI play JackBox with you; no friends required!
8
8
 
9
- ![example](https://github.com/SudoSpartanDan/AIPlaysJackBox/blob/main/.github/emoji_bot_example.png?raw=true)
9
+ ![example](https://github.com/SudoSpartanDan/ai-plays-jackbox/blob/main/.github/emoji_bot_example.png?raw=true)
10
10
 
11
11
  ## Installation
12
12
 
@@ -2,7 +2,7 @@ import json
2
2
  import threading
3
3
  import traceback
4
4
  from abc import ABC, abstractmethod
5
- from typing import Optional
5
+ from typing import Optional, Union
6
6
  from urllib import parse
7
7
  from uuid import uuid4
8
8
 
@@ -110,18 +110,17 @@ class JackBoxBotBase(ABC):
110
110
  def _on_message(self, wsapp, message) -> None:
111
111
  server_message = ServerMessage.model_validate_json(message)
112
112
 
113
- # logger.info(server_message.result)
114
-
115
113
  if server_message.opcode == "client/welcome":
116
114
  self._player_id = server_message.result["id"]
117
115
  self._handle_welcome(server_message.result)
118
116
 
119
- elif server_message.opcode == "object" or server_message.opcode == "text":
120
- if server_message.opcode == "object":
121
- operation = ObjectOperation(**server_message.result)
122
- elif server_message.opcode == "text":
123
- operation = TextOperation(**server_message.result) # type: ignore
117
+ operation: Optional[Union[ObjectOperation, TextOperation]] = None
118
+ if server_message.opcode == "object":
119
+ operation = ObjectOperation(**server_message.result)
120
+ elif server_message.opcode == "text":
121
+ operation = TextOperation(**server_message.result)
124
122
 
123
+ if operation is not None:
125
124
  if self._is_player_operation_key(operation.key):
126
125
  self._handle_player_operation(operation.json_data)
127
126
  if self._is_room_operation_key(operation.key):
@@ -12,6 +12,7 @@ When generating your response, follow these rules:
12
12
  - Your personality is: {personality}
13
13
  - You response must be 45 letters or less.
14
14
  - Do not include quotes in your response.
15
+ - Only fill in the blank; do not repeat the other parts of the prompt.
15
16
 
16
17
  Fill in the blank:
17
18
 
@@ -1,5 +1,6 @@
1
1
  import argparse
2
2
 
3
+ from ai_plays_jackbox.bot.bot_personality import JackBoxBotVariant
3
4
  from ai_plays_jackbox.constants import (
4
5
  DEFAULT_NUM_OF_BOTS,
5
6
  DEFAULT_TEMPERATURE,
@@ -75,6 +76,14 @@ def main():
75
76
  type=_validate_num_of_bots,
76
77
  metavar=str(DEFAULT_NUM_OF_BOTS),
77
78
  )
79
+ parser.add_argument(
80
+ "--bots-in-play",
81
+ required=False,
82
+ nargs="*",
83
+ help="Which bots are in play?",
84
+ choices=[variant.name for variant in JackBoxBotVariant],
85
+ type=str,
86
+ )
78
87
  parser.add_argument(
79
88
  "--temperature",
80
89
  required=False,
@@ -98,6 +107,7 @@ def main():
98
107
  args.chat_model_provider,
99
108
  chat_model_name=args.chat_model_name,
100
109
  num_of_bots=args.num_of_bots,
110
+ bots_in_play=args.bots_in_play,
101
111
  chat_model_temperature=args.temperature,
102
112
  chat_model_top_p=args.top_p,
103
113
  )
@@ -22,7 +22,7 @@ class GeminiModel(ChatModel):
22
22
 
23
23
  # Check connection and if model exists, this will hard fail if connection can't be made
24
24
  # Or if the model is not found
25
- _ = self._gemini_vertex_ai_client.models.get(self._model)
25
+ _ = self._gemini_vertex_ai_client.models.get(model=self._model)
26
26
 
27
27
  @classmethod
28
28
  def get_default_model(cls):
@@ -44,14 +44,14 @@ module = ["demoji.*"]
44
44
  follow_untyped_imports = true
45
45
 
46
46
  [tool.poetry]
47
- version = "0.2.1"
47
+ version = "0.3.0"
48
48
 
49
49
  [tool.poetry.group.dev.dependencies]
50
50
  autoflake = "^2.3.1"
51
51
  black = "^25.1.0"
52
52
  isort = "^6.0.1"
53
- mypy = "^1.16.0"
54
- types-requests = "^2.32.0.20250602"
53
+ mypy = "^1.16.1"
54
+ types-requests = "^2.32.4.20250611"
55
55
  types-psutil = "^7.0.0.20250601"
56
56
 
57
57
  [tool.poetry-dynamic-versioning]