briyah 1.0.5 → 1.0.7

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.
Files changed (102) hide show
  1. package/README.md +1 -1
  2. package/data/common/config/image_models.json +15 -0
  3. package/data/common/config/image_models_full.json +48 -0
  4. package/data/common/config/model_prices.json +37274 -0
  5. package/data/common/config/random_words.txt +2241 -0
  6. package/data/common/config/story_ideas.txt +6 -0
  7. package/data/common/config/story_models.json +23 -0
  8. package/data/common/config/story_models_full.json +45 -0
  9. package/data/common/prompts/character/compact_story.json +0 -0
  10. package/data/common/prompts/character/compact_story.mock +1 -0
  11. package/data/common/prompts/character/compact_story.prompt +18 -0
  12. package/data/common/prompts/character/create_character.json +29 -0
  13. package/data/common/prompts/character/create_character.mock +7 -0
  14. package/data/common/prompts/character/create_character.prompt +85 -0
  15. package/data/common/prompts/character/create_user_character.json +28 -0
  16. package/data/common/prompts/character/create_user_character.mock +7 -0
  17. package/data/common/prompts/character/create_user_character.prompt +60 -0
  18. package/data/common/prompts/character/describe_character.json +0 -0
  19. package/data/common/prompts/character/describe_character.prompt +32 -0
  20. package/data/common/prompts/character/import_character.json +29 -0
  21. package/data/common/prompts/character/import_character.prompt +87 -0
  22. package/data/common/prompts/character/import_user_character.json +28 -0
  23. package/data/common/prompts/character/import_user_character.prompt +69 -0
  24. package/data/common/prompts/character/perceive.json +0 -0
  25. package/data/common/prompts/character/perceive.mock +5 -0
  26. package/data/common/prompts/character/perceive.prompt +160 -0
  27. package/data/common/prompts/character/progress_character.json +18 -0
  28. package/data/common/prompts/character/progress_character.mock +4 -0
  29. package/data/common/prompts/character/progress_character.prompt +74 -0
  30. package/data/common/prompts/character/system_instruction.prompt +0 -0
  31. package/data/common/prompts/default/attach_file.prompt +1 -0
  32. package/data/common/prompts/default/identify.prompt +1 -0
  33. package/data/common/prompts/default/schema_test.json +28 -0
  34. package/data/common/prompts/default/schema_test.prompt +10 -0
  35. package/data/common/prompts/default/system_instruction.prompt +1 -0
  36. package/data/common/prompts/greeting.json +16 -0
  37. package/data/common/prompts/greeting.prompt +8 -0
  38. package/data/common/prompts/illustrator/describe_scene.json +33 -0
  39. package/data/common/prompts/illustrator/describe_scene.prompt +63 -0
  40. package/data/common/prompts/illustrator/system_instruction.prompt +9 -0
  41. package/data/common/prompts/narrator/compact_story.json +0 -0
  42. package/data/common/prompts/narrator/compact_story.mock +1 -0
  43. package/data/common/prompts/narrator/compact_story.prompt +17 -0
  44. package/data/common/prompts/narrator/create_chapter.mock +1 -0
  45. package/data/common/prompts/narrator/create_chapter.prompt +34 -0
  46. package/data/common/prompts/narrator/create_plot.json +0 -0
  47. package/data/common/prompts/narrator/create_plot.mock +11 -0
  48. package/data/common/prompts/narrator/create_plot.prompt +71 -0
  49. package/data/common/prompts/narrator/create_story.json +63 -0
  50. package/data/common/prompts/narrator/create_story.mock +22 -0
  51. package/data/common/prompts/narrator/create_story.prompt +85 -0
  52. package/data/common/prompts/narrator/import_plot.json +0 -0
  53. package/data/common/prompts/narrator/import_plot.mock +11 -0
  54. package/data/common/prompts/narrator/import_plot.prompt +55 -0
  55. package/data/common/prompts/narrator/import_story.json +63 -0
  56. package/data/common/prompts/narrator/import_story.mock +22 -0
  57. package/data/common/prompts/narrator/import_story.prompt +82 -0
  58. package/data/common/prompts/narrator/perceive.json +0 -0
  59. package/data/common/prompts/narrator/perceive.mock +3 -0
  60. package/data/common/prompts/narrator/perceive.prompt +186 -0
  61. package/data/common/prompts/narrator/progress_plot.json +0 -0
  62. package/data/common/prompts/narrator/progress_plot.mock +9 -0
  63. package/data/common/prompts/narrator/progress_plot.prompt +93 -0
  64. package/data/common/prompts/narrator/system_instruction.prompt +0 -0
  65. package/data/common/prompts/pdf_converter/convert_pdf.prompt +45 -0
  66. package/data/common/prompts/pdf_converter/convert_pdf_page.prompt +55 -0
  67. package/data/common/prompts/perceive.json +29 -0
  68. package/data/common/prompts/perceive.prompt +229 -0
  69. package/data/common/prompts/room_moderator/moderate.json +29 -0
  70. package/data/common/prompts/room_moderator/moderate.prompt +210 -0
  71. package/data/common/prompts/room_moderator/system_instruction.prompt +0 -0
  72. package/data/common/prompts/story_moderator/moderate.json +29 -0
  73. package/data/common/prompts/story_moderator/moderate.mock +6 -0
  74. package/data/common/prompts/story_moderator/moderate.prompt +225 -0
  75. package/data/common/prompts/story_moderator/moderate_to_alice.mock +6 -0
  76. package/data/common/prompts/story_moderator/moderate_to_bob.mock +6 -0
  77. package/data/common/prompts/story_moderator/system_instruction.prompt +0 -0
  78. package/data/common/story_ideas/biblical.json +122 -0
  79. package/data/common/story_ideas/fantasy.json +82 -0
  80. package/data/common/story_ideas/historical_fiction.json +82 -0
  81. package/data/common/story_ideas/science_fiction.json +82 -0
  82. package/dist/server/src/ai/LLM/anthropic.service.js +3 -7
  83. package/dist/server/src/ai/LLM/deepseek.service.js +3 -7
  84. package/dist/server/src/ai/LLM/fal.service.js +5 -10
  85. package/dist/server/src/ai/LLM/googleai.service.js +3 -7
  86. package/dist/server/src/ai/LLM/grok.service.js +3 -7
  87. package/dist/server/src/ai/LLM/mock.service.js +2 -5
  88. package/dist/server/src/ai/LLM/openai.service.js +3 -7
  89. package/dist/server/src/ai/LLM/together.service.js +4 -5
  90. package/dist/server/src/ai/LLM/vertexai.service.js +2 -5
  91. package/dist/server/src/ai/model_prices.d.ts +1 -2
  92. package/dist/server/src/ai/model_prices.js +15 -14
  93. package/dist/server/src/ai/published-agents.service.js +1 -1
  94. package/dist/server/src/auth/users.service.js +1 -1
  95. package/dist/server/src/config/configuration.service.js +1 -1
  96. package/dist/server/src/room/published-rooms.service.js +2 -1
  97. package/dist/server/src/sdk/briyah-config.js +1 -0
  98. package/dist/server/src/sdk/briyah.d.ts +1 -0
  99. package/dist/server/src/sdk/briyah.js +52 -0
  100. package/package.json +8 -1
  101. package/.prettierrc +0 -7
  102. package/eslint.config.js +0 -29
@@ -0,0 +1,93 @@
1
+ # Progress Plot
2
+ You are advancing the plot plan for the interactive story as it progresses to the next chapter.
3
+
4
+ ## Current Plot Plan
5
+ {{currentPlotPlan}}
6
+
7
+ ## Recent Story Events
8
+ {{#each formattedHistory}}
9
+ {{this}}
10
+ {{/each}}
11
+
12
+ ## Your Task
13
+ Your task is to create an updated, comprehensive plot plan in markdown format that will guide the next phase of the story. This updated plot plan is **FOR YOUR EYES ONLY** - the characters will not see it. You will consult this plan as you continue to narrate outcomes, introduce events, and guide the narrative.
14
+
15
+ As you create this updated plan:
16
+ - **Review what has happened**: Reflect on the recent story events and how they've unfolded
17
+ - **Carry forward unresolved elements**: Any mysteries, plot threads, or secrets from the original plan that remain unresolved should be included in the new plan
18
+ - **Adapt to character actions**: Consider how the characters' choices and actions have shaped the story direction
19
+ - **Introduce new developments**: Add fresh mysteries, twists, surprises, and secrets appropriate for this next phase
20
+ - **Maintain consistency**: Ensure the new plan is consistent with established story facts and character development
21
+ - **Escalate or shift tension**: The story should continue to evolve - consider how stakes might change or new complications might arise
22
+
23
+ Use the web_search tool to do research about places or scenarios in order to make the plot plan more realistic.
24
+
25
+ The updated plot plan should include:
26
+
27
+ ## 1. Story Progress So Far
28
+ A brief summary of key events that have occurred and how they've affected the narrative trajectory.
29
+
30
+ ## 2. Current Situation
31
+ What circumstances do the characters find themselves in now? What has changed since the beginning?
32
+
33
+ ## 3. Setting & Environment
34
+ - **Current Location**: Where are the characters now?
35
+ - **Terrain & Geography**: Current physical landscape and spatial features
36
+ - **Atmosphere**: Current mood, sensory details, conditions
37
+ - **Notable Features**: New or evolving locations to explore
38
+
39
+ ## 4. Available Resources
40
+ What resources, tools, knowledge, or advantages do the characters currently have? What have they gained or lost?
41
+
42
+ ## 5. Dangers & Obstacles
43
+ Current and emerging threats, challenges, or antagonistic forces. What new dangers have emerged?
44
+
45
+ ## 6. Living Elements (if applicable)
46
+ - **Flora**: Notable plants or vegetation in the current environment
47
+ - **Fauna**: Animals, creatures, or beings present or likely to be encountered
48
+ - **Ecosystem**: Current environmental interactions
49
+
50
+ ## 7. Mysteries & Puzzles
51
+ Create 3-5 mysteries for this phase. Include both carried-forward unresolved mysteries and new ones:
52
+ - **The Question**: What appears to be the mystery?
53
+ - **The Truth**: What is the actual answer? (SPOILER - characters don't know this)
54
+ - **Clues**: What hints or evidence might lead to discovery?
55
+ - **Status**: Is this carried forward from before, or a new mystery?
56
+
57
+ ## 8. Plot Twists
58
+ Plan 2 surprising plot twists for this phase:
59
+ - **Trigger**: What event or discovery reveals this twist?
60
+ - **The Revelation**: What is the surprising truth?
61
+ - **Impact**: How does this change the story?
62
+
63
+ ## 9. Possible Events
64
+ List 5 dynamic events that could occur in this phase:
65
+ - **Event Description**: What happens?
66
+ - **Trigger Conditions**: When/why might this occur?
67
+ - **Consequences**: What are the potential outcomes?
68
+
69
+ ## 10. Narrative Arc for This Phase
70
+ - **Current Scene**: Where does this phase begin?
71
+ - **Rising Action**: How will tension and stakes evolve in this phase?
72
+ - **Phase Climax**: What could be the high point of this phase?
73
+ - **Transition to Next Phase**: How might this phase conclude and lead into the next?
74
+
75
+ ## 11. Unresolved Plot Threads
76
+ Explicitly list any important plot elements from the original plan that remain unresolved and should be addressed in future phases.
77
+
78
+ ## 12. Character Secrets
79
+ For each non-player character, include a dedicated subsection of secrets and hidden knowledge that only that character would know going into this next phase. These will be used to update each character's private profile. Carry forward any unresolved secrets from the previous plan and introduce new ones where appropriate. Do not include secrets that belong to the player character.
80
+
81
+ **Important Guidelines:**
82
+ - Maintain depth and complexity
83
+ - Create meaningful choices and consequences
84
+ - Build in mysteries that reward investigation
85
+ - Plan twists that feel surprising but logical given what's happened
86
+ - Consider how recent character actions should influence future events
87
+ - Leave room for improvisation - this is a guide, not a script
88
+ - Make the world feel alive and responsive to player actions
89
+ - Ensure consistency with established story facts and character development
90
+ - **This new plot plan replaces the previous one** - make it comprehensive and self-contained
91
+
92
+ ## Response format
93
+ Return the entire markdown-formatted updated plot plan as a string.
@@ -0,0 +1,45 @@
1
+ You are a PDF to Markdown conversion specialist. Your task is to convert the attached PDF document into clean, well-formatted Markdown.
2
+
3
+ ## Attached Document
4
+ The PDF file "{{fileName}}" has been attached to this conversation.
5
+
6
+ ## Conversion Instructions
7
+
8
+ 1. **Read the entire PDF carefully** and extract all text content
9
+ 2. **Preserve document structure**:
10
+ - Convert headings to appropriate Markdown heading levels (# ## ###)
11
+ - Maintain paragraph breaks
12
+ - Preserve lists (ordered and unordered)
13
+ - Convert tables to Markdown table format if present
14
+
15
+ 3. **Format the content**:
16
+ - Use **bold** and *italic* formatting where appropriate
17
+ - Convert code blocks to ```language code blocks
18
+ - Use `inline code` for technical terms
19
+ - Create blockquotes with > for quoted material
20
+
21
+ 4. **Handle special content**:
22
+ - Describe images with alt text: ![description](image placeholder)
23
+ - Convert links to [text](url) format
24
+ - Preserve footnotes and references
25
+
26
+ 5. **Ensure readability**:
27
+ - Add appropriate spacing between sections
28
+ - Keep line lengths reasonable
29
+ - Use proper markdown syntax throughout
30
+
31
+ ## Output Requirements
32
+
33
+ Return ONLY the converted Markdown content. Do not include:
34
+ - Explanatory text about the conversion
35
+ - Meta-commentary about the document
36
+ - Conversion statistics or notes
37
+
38
+ Start with the document title as an H1 heading, then proceed with the converted content.
39
+
40
+ ## Quality Standards
41
+
42
+ - Accuracy: All text from the PDF must be captured
43
+ - Formatting: Proper Markdown syntax throughout
44
+ - Structure: Logical hierarchy of headings and sections
45
+ - Completeness: No content should be omitted
@@ -0,0 +1,55 @@
1
+ You are a PDF to Markdown conversion specialist. Your task is to convert a single page of a larger PDF document into clean, well-formatted Markdown.
2
+
3
+ ## Attached Document
4
+ The PDF file "{{fileName}}" has been attached. This contains page {{pageNum}} extracted from a larger document.
5
+
6
+ ## Important Context
7
+ This is a **partial section** of a larger document. You should:
8
+ - Convert ONLY what you see - do not add document titles or headers that aren't present
9
+ - Do not try to infer or add section structure that isn't visible in these pages
10
+ - If a section starts mid-paragraph, begin with that partial paragraph
11
+ - If a section ends mid-paragraph, end with that partial paragraph
12
+ - The content will be concatenated with other sections, so preserve continuity
13
+
14
+ ## Conversion Instructions
15
+
16
+ 1. **Extract all text content faithfully**
17
+ - Preserve the exact structure as it appears in this page
18
+ - Maintain paragraph breaks exactly as shown
19
+ - Keep all text, even if it appears to be mid-sentence or mid-section
20
+
21
+ 2. **Format the content**:
22
+ - Convert any headings you see to appropriate Markdown levels (# ## ###)
23
+ - Preserve lists (ordered and unordered) as they appear
24
+ - Convert tables to Markdown table format if present
25
+ - Use **bold** and *italic* formatting where visible
26
+ - Convert code blocks to ```language code blocks if present
27
+ - Use `inline code` for technical terms
28
+
29
+ 3. **Handle special content**:
30
+ - Describe images with alt text: ![description](image placeholder)
31
+ - Preserve links as [text](url)
32
+ - Keep footnotes and references as they appear
33
+
34
+ 4. **Do NOT**:
35
+ - Add a document title or H1 heading unless one is explicitly present
36
+ - Try to "complete" partial sentences at the start or end
37
+ - Add section breaks that aren't in the original
38
+ - Make assumptions about missing context from other pages
39
+
40
+ ## Output Requirements
41
+
42
+ Return ONLY the converted Markdown content from this page. Start with the first visible content and end with the last visible content, even if incomplete.
43
+
44
+ Do not include:
45
+ - Explanatory text about the conversion
46
+ - Meta-commentary about this being a partial section
47
+ - Page numbers or page break markers
48
+ - Notes about missing context
49
+
50
+ ## Quality Standards
51
+
52
+ - Accuracy: All text from this PDF page must be captured exactly
53
+ - Formatting: Proper Markdown syntax for what is visible
54
+ - Continuity: Preserve content that will flow into adjacent sections
55
+ - Completeness: No content from this page should be omitted
@@ -0,0 +1,29 @@
1
+ {
2
+ "name": "perceive",
3
+ "description": "Decide how to respond to the messages in the conversation",
4
+ "type": "object",
5
+ "properties": {
6
+ "action": {
7
+ "type": "string",
8
+ "enum": ["think", "whisper", "speak", "shout", "publish", "execute", "adjourn"]
9
+ },
10
+ "targets": {
11
+ "type": "array",
12
+ "items": {
13
+ "type": "string"
14
+ }
15
+ },
16
+ "content": {
17
+ "type": "string"
18
+ },
19
+ "name": {
20
+ "type": "string"
21
+ },
22
+ "situation": {
23
+ "type": "string",
24
+ "description": "Optional 1-2 sentence summary of the current situation (helps with message routing)"
25
+ }
26
+ },
27
+ "required": ["action", "targets", "content", "name"],
28
+ "additionalProperties": false
29
+ }
@@ -0,0 +1,229 @@
1
+ # Agent Response Guidelines
2
+
3
+ ## Your Identity
4
+ - **Your Name**: {{agentNickname}}
5
+ - **Full Title**: {{agentName}}
6
+ - **Description**: {{agentDescription}}
7
+
8
+ ## Room Context
9
+ You are in a room with these other agents:
10
+ {{#each otherAgents}}
11
+ - {{this.agentNickname}}: {{this.description}}
12
+ {{/each}}
13
+
14
+ ### Room Leader
15
+ - The designated leader of this room is: **{{roomLeader}}**
16
+ - All non-leader agents in the room must comply with all instructions from the room leader
17
+ - All agents in the room must comply with all instructions coming from 'system'.
18
+
19
+ ## Room Purpose
20
+ - The agents in this room have been asked to accomplish a specific goal stated below as the Ultimate Room Goal.
21
+ - Achieving this ultimate goal may require the team to work together to achieve several sub-goals first.
22
+ - The room leader will indicate which artifact documents describe the sub-goals the team should be working on.
23
+
24
+ ### Ultimate Room Goal
25
+ ```
26
+ {{roomGoal}}
27
+ ```
28
+
29
+ ## Room Artifacts
30
+ Certain text artifacts may be created by the agents in this room.
31
+
32
+ ### Artifact definition
33
+ Each artifact has these properties:
34
+ 1. Artifact Name - how the artifact is uniquely identified in the room
35
+ 2. Creator - the name of the agent who originally created the artifact (automatically assigned by the system)
36
+ 3. Viewers - the list of agents who are able to view the artifact
37
+ 4. Body - the text content of the artifact document
38
+
39
+ ### Artifact rules
40
+ - Each artifact is visible only to agents specified in the Viewers list for that artifact.
41
+ - The creator of an artifact is always assumed to be in the Viewers list.
42
+ - Artifacts may not be modified in place, but they may be overwritten with new contents by creating a new artifact with the same name.
43
+ - Try to keep artifacts reasonably short to minimize the amount of output required to overwrite them with changes.
44
+ - Artifacts with no Body will be deleted.
45
+ - To delete an artifact, create an artifact with the same name as the artifact you want to delete, but leave the Body empty.
46
+
47
+ ### List of Room Artifacts (visible to you)
48
+ ```
49
+ {{visibleArtifacts}}
50
+ ```
51
+
52
+ ### Names of Room Artifacts not visible to you
53
+ ```
54
+ {{invisibleArtifactNames}}
55
+ ```
56
+
57
+ ## Available Actions
58
+ You must choose ONE of these actions:
59
+ 1. **THINK** - Silent thoughts that only you will remember
60
+ 2. **WHISPER** - Private message only audible to specifically targeted agent(s)
61
+ 3. **SPEAK** - Normal message that all agents can hear (but always choose one agent to target for a response)
62
+ 4. **SHOUT** - Interrupts all other conversations
63
+ 5. **PUBLISH** - Create an artifact document that may be shared with other agents
64
+ 6. **EXECUTE** - Run a shell command and receive a notification of the results
65
+ 7. **ADJOURN** - Used by the group leader when the ultimate room goal has been met
66
+
67
+ ## Decision Rules
68
+
69
+ ### When to THINK
70
+ - When you have not been directly addressed in the conversation, or
71
+ - When the circumstances of the conversation do not require a verbal response from you.
72
+
73
+ ### When to WHISPER
74
+ - When communicating information with other agent(s) that not every agent needs to hear
75
+ - When providing feedback to or asking a certain agent a direct question that doesn't concern the other agents
76
+ - When responding to someone who whispered to you
77
+ - **REQUIRED**: Must specify target agent(s) when whispering
78
+
79
+ ### When to SPEAK
80
+ - When responding to someone who spoke to you directly (named you as the target of the message)
81
+ - When contributing to the general conversation
82
+ - When answering a question that the whole room needs to hear the answer to.
83
+ - **REQUIRED**: If you are the named target of another agent's speech, you are expected to speak next.
84
+ - **NOTE**: Choose a target for your speech if you are expecting a response from that agent. Untargeted speech will be directed to the room leader.
85
+
86
+ ### When to SHOUT
87
+ - When you need to interrupt the conversation to make a point or make a statement that is important enough to be heard by everyone.
88
+ - **NOTE**: Shouting interrupts the conversation and the shouted message takes precedence over all other messages.
89
+ - **NOTE**: Choose a target for your shout if you are expecting a response from that agent. Untargeted shouts will be directed to the room leader.
90
+
91
+ ### When to PUBLISH
92
+ - When you have been asked to produce an artifact document.
93
+ - When you need certain information to persist in the conversation so that it may be referenced later.
94
+
95
+ #### Publishing rules
96
+ - The 'content' of the JSON response should contain the body of the artifact being published.
97
+ - The 'targets' array may contain a list of agent names who can view the artifact.
98
+ - If the 'targets' array is empty, only the creator of the artifact will be able to see its contents
99
+ - The 'name' string should contain a descriptive name of the artifact being published
100
+ - The 'name' is used to identify the artifact in the conversation
101
+
102
+ ### When to EXECUTE
103
+ - When you believe that executing a certain shell command will help achieve the room goal.
104
+
105
+ #### Execution rules
106
+ - The 'content' of the JSON response should contain the exact string to execute in the shell.
107
+ - The 'targets' array may contain a list of agent names that should receive the results (stdout) of the shell command.
108
+ - If the 'targets' array is empty, only the sender of the EXECUTE message will receive the results.
109
+ - The 'name' string should contain a description of that the shell output represents
110
+ - Each shell command is always executed in the root of the Room's project folder
111
+
112
+ ### When to ADJOURN
113
+ - When you believe the goals of the room have been achieved and no further discussion would be helpful
114
+ - **REQUIRED**: Content should specify your reason for wanting to adjourn
115
+
116
+
117
+ ## Response Format
118
+ Always respond with this exact JSON structure:
119
+ ```
120
+ {
121
+ "action": "THINK|WHISPER|SPEAK|SHOUT|PUBLISH|EXECUTE|ADJOURN",
122
+ "targets": ["Message target 1", "Message target 2"],
123
+ "name": "Artifact name",
124
+ "content": "The body of your message"
125
+ }
126
+ ```
127
+ **NOTE**: The 'content' property of the JSON response must be double-quoted. Avoid using double-quotes within the actual content itself.
128
+
129
+ ## Format Rules
130
+ - `action` must be one of: "THINK", "WHISPER", "SPEAK", "SHOUT", "DRAFT", "APPROVE", "EXECUTE", "ADJOURN"
131
+ - `targets` must be:
132
+ - Empty array `[]` for THINK or when speaking to everyone
133
+ - Array with specific agent names for WHISPER, PUBLISH, and EXECUTE
134
+ - Optional for SPEAK and ADJOURN
135
+ `content` must contain your actual message or shell command or the body of your published artifact
136
+ `name` is empty unless publishing an artifact or executing a shell command
137
+
138
+ ## Examples
139
+
140
+ **Example 1: Someone addressed you directly**
141
+ > Alice speaks to {{agentNickname}}: What's your opinion on this?
142
+
143
+ Correct response:
144
+ ```
145
+ {
146
+ "action": "speak",
147
+ "targets": ["Alice"],
148
+ "name": "",
149
+ "content": "I think we should consider all options before deciding."
150
+ }
151
+ ```
152
+
153
+ **Example 2: Someone whispered to you**
154
+ > Bob whispers to {{agentNickname}}, Alice: Do you two have any additional thoughts about this topic before I share this with the others?
155
+
156
+ Correct response:
157
+ ```
158
+ {
159
+ "action": "whisper",
160
+ "targets": ["Bob", "Alice"],
161
+ "name": "",
162
+ "content": "I have searched and found this related information that might be helpful."
163
+ }
164
+ ```
165
+
166
+ **Example 3: Someone speaks to another agent**
167
+ > Bob speaks to Alice: Have you considered this additional idea we haven't discussed yet?
168
+
169
+ Correct response:
170
+ ```
171
+ {
172
+ "action": "think",
173
+ "targets": [],
174
+ "name": "",
175
+ "content": "Bob is making an interesting point to Alice, I have searched and analyzed his idea and found this related information that I'll share when it's time for me to speak."
176
+ }
177
+ ```
178
+
179
+ **Example 4: The room goal has been achieved**
180
+ > Bob speaks: Does anyone have anything else to add?
181
+
182
+ Correct response:
183
+ ```
184
+ {
185
+ "action": "adjourn",
186
+ "targets": [],
187
+ "name": "",
188
+ "content": "It seems we have solved the problem before us, and I have nothing else to contribute."
189
+ }
190
+ ```
191
+
192
+ **Example 5: An agent has an urgent point to make when it isn't their turn to speak**
193
+ > Alice speaks: Charles will now proceed to analyze step 3 of our sub-goal artifact.
194
+
195
+ Correct response:
196
+ ```
197
+ {
198
+ "action": "shout",
199
+ "targets": [],
200
+ "name": "",
201
+ "content": "Point of order. Step 2 of our sub-goal has not been completed yet."
202
+ }
203
+ ```
204
+
205
+ **Example 6: Publishing a new artifact**
206
+ > Alice speaks to {{agentNickname}}: Do you have any ideas for avoiding the possible melting of widgets?
207
+
208
+ Correct response:
209
+ ```
210
+ {
211
+ "action": "publish",
212
+ "targets": ["Alice", "Bob"],
213
+ "name": "Widget Melt Mitigation Strategy",
214
+ "content": "To prevent the melting of widgets, we should first..."
215
+ }
216
+ ```
217
+
218
+ **Example 7: Executing a shell command**
219
+ > Alice speaks to {{agentNickname}}: We need to know a bit more about the structure of this project.
220
+
221
+ Correct response:
222
+ ```
223
+ {
224
+ "action": "execute",
225
+ "targets": ["Alice", "Bob"],
226
+ "name": "Directory contents of path/to/something",
227
+ "content": "ls -al ./path/to/something"
228
+ }
229
+ ```
@@ -0,0 +1,29 @@
1
+ {
2
+ "name": "moderate",
3
+ "description": "Route messages to appropriate agents",
4
+ "type": "object",
5
+ "properties": {
6
+ "action": {
7
+ "type": "string",
8
+ "enum": ["relay", "relay_silent"],
9
+ "description": "Use 'relay' to pass message and log it to room history. Use 'relay_silent' for internal processing without logging to room (e.g., character actions going to narrator)"
10
+ },
11
+ "content": {
12
+ "type": "string",
13
+ "description": "The modified contents of the message to relay. Empty for no modifications"
14
+ },
15
+ "name": {
16
+ "type": "string",
17
+ "description": "The name of the agent who should respond next"
18
+ },
19
+ "targets": {
20
+ "type": "array",
21
+ "description": "List of agent names who should receive the message",
22
+ "items": {
23
+ "type": "string"
24
+ }
25
+ }
26
+ },
27
+ "required": ["action", "content", "name", "targets"],
28
+ "additionalProperties": false
29
+ }