briyah 1.3.4 → 1.4.0

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 (254) hide show
  1. package/README.md +689 -619
  2. package/data/common/artifacts/dnd5e/campaign_designer-setting.md +112 -0
  3. package/data/common/artifacts/dnd5e/character_creator-basics.md +40 -0
  4. package/data/common/artifacts/dnd5e/class-barbarian.md +64 -0
  5. package/data/common/artifacts/dnd5e/class-bard.md +63 -0
  6. package/data/common/artifacts/dnd5e/class-cleric.md +60 -0
  7. package/data/common/artifacts/dnd5e/class-druid.md +56 -0
  8. package/data/common/artifacts/dnd5e/class-fighter.md +53 -0
  9. package/data/common/artifacts/dnd5e/class-monk.md +77 -0
  10. package/data/common/artifacts/dnd5e/class-paladin.md +66 -0
  11. package/data/common/artifacts/dnd5e/class-ranger.md +73 -0
  12. package/data/common/artifacts/dnd5e/class-rogue.md +62 -0
  13. package/data/common/artifacts/dnd5e/class-sorcerer.md +67 -0
  14. package/data/common/artifacts/dnd5e/class-warlock.md +83 -0
  15. package/data/common/artifacts/dnd5e/class-wizard.md +51 -0
  16. package/data/common/artifacts/dnd5e/dungeon_master-procedure.md +348 -0
  17. package/data/common/artifacts/dnd5e/manifest.json +95 -0
  18. package/data/common/config/comfyui-workflows/flux-kontext.edit.json +98 -0
  19. package/data/common/config/comfyui-workflows/flux-kontext.t2i.json +80 -0
  20. package/data/common/config/comfyui-workflows/flux2-dev.edit.json +125 -0
  21. package/data/common/config/comfyui-workflows/flux2-dev.t2i.json +96 -0
  22. package/data/common/config/image_models_full.json +186 -99
  23. package/data/common/config/markup +1 -1
  24. package/data/common/config/model_prices.json +1250 -237
  25. package/data/common/prompts/campaign_designer/defaults_config.json +16 -0
  26. package/data/common/prompts/campaign_designer/perceive.json +29 -0
  27. package/data/common/prompts/campaign_designer/perceive.prompt +345 -0
  28. package/data/common/prompts/campaign_designer/system_instruction.prompt +0 -0
  29. package/data/common/prompts/character_creator/defaults_config.json +31 -0
  30. package/data/common/prompts/character_creator/perceive.json +29 -0
  31. package/data/common/prompts/character_creator/perceive.prompt +621 -0
  32. package/data/common/prompts/character_creator/system_instruction.prompt +0 -0
  33. package/data/common/prompts/dnd_player/defaults_config.json +5 -0
  34. package/data/common/prompts/dnd_player/perceive.json +29 -0
  35. package/data/common/prompts/dnd_player/perceive.prompt +312 -0
  36. package/data/common/prompts/dnd_player/system_instruction.prompt +0 -0
  37. package/data/common/prompts/dnd_room_moderator/defaults_config.json +9 -0
  38. package/data/common/prompts/dnd_room_moderator/moderate.json +34 -0
  39. package/data/common/prompts/dnd_room_moderator/moderate.prompt +291 -0
  40. package/data/common/prompts/dnd_room_moderator/system_instruction.prompt +0 -0
  41. package/data/common/prompts/dungeon_master/compact_agent.prompt +24 -0
  42. package/data/common/prompts/dungeon_master/defaults_config.json +29 -0
  43. package/data/common/prompts/dungeon_master/perceive.json +33 -0
  44. package/data/common/prompts/dungeon_master/perceive.prompt +757 -0
  45. package/data/common/prompts/dungeon_master/system_instruction.prompt +0 -0
  46. package/data/common/prompts/room_moderator/moderate.json +34 -29
  47. package/data/common/prompts/room_moderator/moderate.prompt +230 -210
  48. package/data/common/prompts/story_moderator/moderate.prompt +5 -2
  49. package/data/common/prompts/story_moderator/moderate_to_alice.mock +6 -6
  50. package/data/common/prompts/story_moderator/moderate_to_bob.mock +6 -6
  51. package/dist-sdk/server/src/ai/LLM/anthropic.service.d.ts +2 -0
  52. package/dist-sdk/server/src/ai/LLM/anthropic.service.js +34 -22
  53. package/dist-sdk/server/src/ai/LLM/base-ai.service.d.ts +2 -0
  54. package/dist-sdk/server/src/ai/LLM/base-ai.service.js +8 -3
  55. package/dist-sdk/server/src/ai/LLM/comfyui-client.d.ts +29 -0
  56. package/dist-sdk/server/src/ai/LLM/comfyui-client.js +142 -0
  57. package/dist-sdk/server/src/ai/LLM/comfyui-workflow.d.ts +19 -0
  58. package/dist-sdk/server/src/ai/LLM/comfyui-workflow.js +217 -0
  59. package/dist-sdk/server/src/ai/LLM/comfyui.module.d.ts +2 -0
  60. package/dist-sdk/server/src/ai/LLM/comfyui.module.js +21 -0
  61. package/dist-sdk/server/src/ai/LLM/comfyui.service.d.ts +26 -0
  62. package/dist-sdk/server/src/ai/LLM/comfyui.service.js +191 -0
  63. package/dist-sdk/server/src/ai/LLM/mock.service.d.ts +1 -0
  64. package/dist-sdk/server/src/ai/LLM/mock.service.js +3 -0
  65. package/dist-sdk/server/src/ai/LLM/self-hosted.module.d.ts +2 -0
  66. package/dist-sdk/server/src/ai/LLM/self-hosted.module.js +21 -0
  67. package/dist-sdk/server/src/ai/LLM/self-hosted.service.d.ts +13 -0
  68. package/dist-sdk/server/src/ai/LLM/self-hosted.service.js +205 -0
  69. package/dist-sdk/server/src/ai/agent-config.d.ts +1 -0
  70. package/dist-sdk/server/src/ai/agent-store.service.js +6 -4
  71. package/dist-sdk/server/src/ai/agent.d.ts +7 -0
  72. package/dist-sdk/server/src/ai/agent.js +33 -2
  73. package/dist-sdk/server/src/ai/ai-factory.module.js +4 -0
  74. package/dist-sdk/server/src/ai/ai-factory.service.d.ts +5 -1
  75. package/dist-sdk/server/src/ai/ai-factory.service.js +16 -2
  76. package/dist-sdk/server/src/ai/artifact.service.d.ts +2 -0
  77. package/dist-sdk/server/src/ai/artifact.service.js +29 -1
  78. package/dist-sdk/server/src/ai/pack-artifacts.d.ts +7 -0
  79. package/dist-sdk/server/src/ai/pack-artifacts.js +155 -0
  80. package/dist-sdk/server/src/app/stripe.controller.js +5 -0
  81. package/dist-sdk/server/src/app.controller.d.ts +18 -18
  82. package/dist-sdk/server/src/app.controller.js +249 -25
  83. package/dist-sdk/server/src/app.service.d.ts +30 -17
  84. package/dist-sdk/server/src/app.service.js +304 -36
  85. package/dist-sdk/server/src/auth/auth.controller.js +3 -2
  86. package/dist-sdk/server/src/auth/owner-only.decorator.d.ts +1 -0
  87. package/dist-sdk/server/src/auth/owner-only.decorator.js +8 -0
  88. package/dist-sdk/server/src/auth/twilio.service.d.ts +5 -1
  89. package/dist-sdk/server/src/auth/twilio.service.js +5 -3
  90. package/dist-sdk/server/src/config/user-paths.service.d.ts +2 -0
  91. package/dist-sdk/server/src/config/user-paths.service.js +8 -0
  92. package/dist-sdk/server/src/room/artifact-store.service.js +10 -2
  93. package/dist-sdk/server/src/room/artifact.d.ts +1 -0
  94. package/dist-sdk/server/src/room/message.d.ts +2 -1
  95. package/dist-sdk/server/src/room/message.js +5 -4
  96. package/dist-sdk/server/src/room/room-config.d.ts +3 -0
  97. package/dist-sdk/server/src/room/room-store.service.d.ts +4 -2
  98. package/dist-sdk/server/src/room/room-store.service.js +46 -12
  99. package/dist-sdk/server/src/room/room.d.ts +29 -3
  100. package/dist-sdk/server/src/room/room.js +390 -122
  101. package/dist-sdk/server/src/sdk/briyah.js +21 -3
  102. package/dist-sdk/server/src/sdk/index.d.ts +4 -1
  103. package/dist-sdk/server/src/sdk/index.js +9 -1
  104. package/dist-sdk/server/src/story/story.service.js +21 -12
  105. package/dist-sdk/server/src/tools/native-tool.types.d.ts +31 -0
  106. package/dist-sdk/server/src/tools/packs/dnd5e/data/backgrounds.d.ts +22 -0
  107. package/dist-sdk/server/src/tools/packs/dnd5e/data/backgrounds.js +59 -0
  108. package/dist-sdk/server/src/tools/packs/dnd5e/data/feats.d.ts +24 -0
  109. package/dist-sdk/server/src/tools/packs/dnd5e/data/feats.js +11 -0
  110. package/dist-sdk/server/src/tools/packs/dnd5e/data/gear.d.ts +5 -0
  111. package/dist-sdk/server/src/tools/packs/dnd5e/data/gear.generated.d.ts +1 -0
  112. package/dist-sdk/server/src/tools/packs/dnd5e/data/gear.generated.js +154 -0
  113. package/dist-sdk/server/src/tools/packs/dnd5e/data/gear.js +9 -0
  114. package/dist-sdk/server/src/tools/packs/dnd5e/data/magic-items.d.ts +20 -0
  115. package/dist-sdk/server/src/tools/packs/dnd5e/data/magic-items.generated.d.ts +2 -0
  116. package/dist-sdk/server/src/tools/packs/dnd5e/data/magic-items.generated.js +1824 -0
  117. package/dist-sdk/server/src/tools/packs/dnd5e/data/magic-items.js +6 -0
  118. package/dist-sdk/server/src/tools/packs/dnd5e/data/monsters.d.ts +44 -0
  119. package/dist-sdk/server/src/tools/packs/dnd5e/data/monsters.generated.d.ts +2 -0
  120. package/dist-sdk/server/src/tools/packs/dnd5e/data/monsters.generated.js +17293 -0
  121. package/dist-sdk/server/src/tools/packs/dnd5e/data/monsters.js +5 -0
  122. package/dist-sdk/server/src/tools/packs/dnd5e/data/races.d.ts +41 -0
  123. package/dist-sdk/server/src/tools/packs/dnd5e/data/races.js +250 -0
  124. package/dist-sdk/server/src/tools/packs/dnd5e/data/spells.d.ts +16 -0
  125. package/dist-sdk/server/src/tools/packs/dnd5e/data/spells.generated.d.ts +2 -0
  126. package/dist-sdk/server/src/tools/packs/dnd5e/data/spells.generated.js +3760 -0
  127. package/dist-sdk/server/src/tools/packs/dnd5e/data/spells.js +12 -0
  128. package/dist-sdk/server/src/tools/packs/dnd5e/data/srd.d.ts +63 -0
  129. package/dist-sdk/server/src/tools/packs/dnd5e/data/srd.js +449 -0
  130. package/dist-sdk/server/src/tools/packs/dnd5e/data/weapons.d.ts +23 -0
  131. package/dist-sdk/server/src/tools/packs/dnd5e/data/weapons.js +88 -0
  132. package/dist-sdk/server/src/tools/packs/dnd5e/engine/backgrounds.d.ts +20 -0
  133. package/dist-sdk/server/src/tools/packs/dnd5e/engine/backgrounds.js +109 -0
  134. package/dist-sdk/server/src/tools/packs/dnd5e/engine/bestiary.d.ts +30 -0
  135. package/dist-sdk/server/src/tools/packs/dnd5e/engine/bestiary.js +329 -0
  136. package/dist-sdk/server/src/tools/packs/dnd5e/engine/campaign-items.d.ts +9 -0
  137. package/dist-sdk/server/src/tools/packs/dnd5e/engine/campaign-items.js +100 -0
  138. package/dist-sdk/server/src/tools/packs/dnd5e/engine/character.d.ts +117 -0
  139. package/dist-sdk/server/src/tools/packs/dnd5e/engine/character.js +1057 -0
  140. package/dist-sdk/server/src/tools/packs/dnd5e/engine/coerce.d.ts +13 -0
  141. package/dist-sdk/server/src/tools/packs/dnd5e/engine/coerce.js +147 -0
  142. package/dist-sdk/server/src/tools/packs/dnd5e/engine/dice.d.ts +27 -0
  143. package/dist-sdk/server/src/tools/packs/dnd5e/engine/dice.js +263 -0
  144. package/dist-sdk/server/src/tools/packs/dnd5e/engine/encumbrance.d.ts +26 -0
  145. package/dist-sdk/server/src/tools/packs/dnd5e/engine/encumbrance.js +129 -0
  146. package/dist-sdk/server/src/tools/packs/dnd5e/engine/feats.d.ts +22 -0
  147. package/dist-sdk/server/src/tools/packs/dnd5e/engine/feats.js +127 -0
  148. package/dist-sdk/server/src/tools/packs/dnd5e/engine/items.d.ts +33 -0
  149. package/dist-sdk/server/src/tools/packs/dnd5e/engine/items.js +137 -0
  150. package/dist-sdk/server/src/tools/packs/dnd5e/engine/races.d.ts +26 -0
  151. package/dist-sdk/server/src/tools/packs/dnd5e/engine/races.js +182 -0
  152. package/dist-sdk/server/src/tools/packs/dnd5e/engine/rules.d.ts +48 -0
  153. package/dist-sdk/server/src/tools/packs/dnd5e/engine/rules.js +344 -0
  154. package/dist-sdk/server/src/tools/packs/dnd5e/engine/sheet.d.ts +98 -0
  155. package/dist-sdk/server/src/tools/packs/dnd5e/engine/sheet.js +456 -0
  156. package/dist-sdk/server/src/tools/packs/dnd5e/engine/spells.d.ts +27 -0
  157. package/dist-sdk/server/src/tools/packs/dnd5e/engine/spells.js +123 -0
  158. package/dist-sdk/server/src/tools/packs/dnd5e/engine/weapons.d.ts +23 -0
  159. package/dist-sdk/server/src/tools/packs/dnd5e/engine/weapons.js +201 -0
  160. package/dist-sdk/server/src/tools/packs/dnd5e/index.d.ts +3 -0
  161. package/dist-sdk/server/src/tools/packs/dnd5e/index.js +35 -0
  162. package/dist-sdk/server/src/tools/packs/dnd5e/tools/check.tool.d.ts +2 -0
  163. package/dist-sdk/server/src/tools/packs/dnd5e/tools/check.tool.js +323 -0
  164. package/dist-sdk/server/src/tools/packs/dnd5e/tools/dice.tools.d.ts +3 -0
  165. package/dist-sdk/server/src/tools/packs/dnd5e/tools/dice.tools.js +117 -0
  166. package/dist-sdk/server/src/tools/packs/dnd5e/tools/item.tool.d.ts +2 -0
  167. package/dist-sdk/server/src/tools/packs/dnd5e/tools/item.tool.js +122 -0
  168. package/dist-sdk/server/src/tools/packs/dnd5e/tools/monster.tool.d.ts +2 -0
  169. package/dist-sdk/server/src/tools/packs/dnd5e/tools/monster.tool.js +157 -0
  170. package/dist-sdk/server/src/tools/packs/dnd5e/tools/shared.d.ts +32 -0
  171. package/dist-sdk/server/src/tools/packs/dnd5e/tools/shared.js +203 -0
  172. package/dist-sdk/server/src/tools/packs/dnd5e/tools/sheet.tools.d.ts +4 -0
  173. package/dist-sdk/server/src/tools/packs/dnd5e/tools/sheet.tools.js +465 -0
  174. package/dist-sdk/server/src/tools/packs/dnd5e/tools/spell.tool.d.ts +2 -0
  175. package/dist-sdk/server/src/tools/packs/dnd5e/tools/spell.tool.js +116 -0
  176. package/dist-sdk/server/src/tools/packs/dnd5e/tools/state.tools.d.ts +4 -0
  177. package/dist-sdk/server/src/tools/packs/dnd5e/tools/state.tools.js +234 -0
  178. package/dist-sdk/server/src/tools/packs/dnd5e/tools/world.tools.d.ts +6 -0
  179. package/dist-sdk/server/src/tools/packs/dnd5e/tools/world.tools.js +616 -0
  180. package/dist-sdk/server/src/tools/packs/index.d.ts +7 -0
  181. package/dist-sdk/server/src/tools/packs/index.js +45 -0
  182. package/dist-sdk/server/src/tools/tool-execution.service.d.ts +2 -2
  183. package/dist-sdk/server/src/tools/tool-execution.service.js +7 -6
  184. package/dist-sdk/shared/types/app.types.d.ts +63 -0
  185. package/docs/assets/hierarchy.js +1 -1
  186. package/docs/assets/navigation.js +1 -1
  187. package/docs/assets/search.js +1 -1
  188. package/docs/classes/Agent.html +51 -15
  189. package/docs/classes/Briyah.html +14 -14
  190. package/docs/classes/BriyahConfigService.html +5 -5
  191. package/docs/classes/NativeToolRegistry.html +21 -0
  192. package/docs/classes/Room.html +79 -29
  193. package/docs/classes/RoomMessage.html +32 -15
  194. package/docs/enums/MessageAction.html +3 -3
  195. package/docs/functions/availableToolPacks.html +2 -0
  196. package/docs/functions/dnd5eTools.html +5 -0
  197. package/docs/functions/enabledToolPacks.html +2 -0
  198. package/docs/functions/registerToolPacks.html +6 -0
  199. package/docs/hierarchy.html +1 -1
  200. package/docs/index.html +47 -3
  201. package/docs/interfaces/AgentInfo.html +17 -2
  202. package/docs/interfaces/AgentMessagesResponse.html +2 -2
  203. package/docs/interfaces/AppService.html +230 -181
  204. package/docs/interfaces/Artifact.html +15 -3
  205. package/docs/interfaces/ArtifactMetadata.html +5 -2
  206. package/docs/interfaces/ArtifactWriteOptions.html +21 -0
  207. package/docs/interfaces/AttachDocumentResponse.html +2 -2
  208. package/docs/interfaces/BriyahConfigOptions.html +9 -9
  209. package/docs/interfaces/ChapterInfo.html +2 -2
  210. package/docs/interfaces/Character.html +2 -2
  211. package/docs/interfaces/CreateAgentResponse.html +2 -2
  212. package/docs/interfaces/CreateRoomResponse.html +2 -2
  213. package/docs/interfaces/CreateStoryResponse.html +2 -2
  214. package/docs/interfaces/FileList.html +2 -2
  215. package/docs/interfaces/FileMetadata.html +3 -3
  216. package/docs/interfaces/IConfigService.html +3 -3
  217. package/docs/interfaces/LoggingOptions.html +6 -6
  218. package/docs/interfaces/Message.html +2 -2
  219. package/docs/interfaces/ModelInfo.html +2 -2
  220. package/docs/interfaces/NativeToolDefinition.html +11 -7
  221. package/docs/interfaces/PreparedPromptResponse.html +2 -2
  222. package/docs/interfaces/ProcessTextResponse.html +2 -2
  223. package/docs/interfaces/PromptFile.html +2 -2
  224. package/docs/interfaces/PromptFileContent.html +2 -2
  225. package/docs/interfaces/PromptFilesResponse.html +2 -2
  226. package/docs/interfaces/PromptFolder.html +2 -2
  227. package/docs/interfaces/PromptFoldersResponse.html +2 -2
  228. package/docs/interfaces/RoomDetails.html +15 -2
  229. package/docs/interfaces/RoomInfo.html +3 -2
  230. package/docs/interfaces/RoomMessageUpdate.html +2 -2
  231. package/docs/interfaces/RoomMessagesResponse.html +2 -2
  232. package/docs/interfaces/SendMessageResult.html +2 -2
  233. package/docs/interfaces/StoryErrorEvent.html +3 -3
  234. package/docs/interfaces/StoryIdea.html +2 -2
  235. package/docs/interfaces/StoryInfo.html +3 -3
  236. package/docs/interfaces/StoryIntroduceCharacterEvent.html +3 -3
  237. package/docs/interfaces/StoryProgressChapterEvent.html +3 -3
  238. package/docs/interfaces/StoryState.html +5 -5
  239. package/docs/interfaces/StoryStateEvent.html +3 -3
  240. package/docs/interfaces/ToolArtifact.html +8 -0
  241. package/docs/interfaces/ToolCaller.html +8 -0
  242. package/docs/interfaces/ToolDefinition.html +2 -2
  243. package/docs/interfaces/ToolHelpers.html +7 -3
  244. package/docs/interfaces/ToolParameter.html +2 -2
  245. package/docs/interfaces/ToolRoomAccess.html +51 -0
  246. package/docs/interfaces/ToolSummary.html +3 -2
  247. package/docs/interfaces/ToolsResponse.html +2 -2
  248. package/docs/interfaces/Transaction.html +2 -2
  249. package/docs/interfaces/TransactionHistoryResponse.html +2 -2
  250. package/docs/modules.html +1 -1
  251. package/docs/types/PromptScope.html +1 -1
  252. package/docs/types/ToolContext.html +2 -2
  253. package/docs/types/ToolRunResult.html +1 -1
  254. package/package.json +7 -4
@@ -1,4 +1,4 @@
1
- <!DOCTYPE html><html class="default" lang="en" data-base="../"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>AppService | Briyah SDK - v1.3.4</title><meta name="description" content="Documentation for Briyah SDK"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => window.app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><a href="../index.html" class="title">Briyah SDK - v1.3.4</a><div id="tsd-toolbar-links"><a href="https://github.com/your-org/briyah">GitHub</a><a href="https://www.npmjs.com/package/briyah">npm</a></div><button id="tsd-search-trigger" class="tsd-widget" aria-label="Search"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-search"></use></svg></button><dialog id="tsd-search" aria-label="Search"><input role="combobox" id="tsd-search-input" aria-controls="tsd-search-results" aria-autocomplete="list" aria-expanded="true" autocapitalize="off" autocomplete="off" placeholder="Search the docs" maxLength="100"/><ul role="listbox" id="tsd-search-results"></ul><div id="tsd-search-status" aria-live="polite" aria-atomic="true"><div>Preparing search index...</div></div></dialog><a href="#" class="tsd-widget menu" id="tsd-toolbar-menu-trigger" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb" aria-label="Breadcrumb"><li><a href="" aria-current="page">AppService</a></li></ul><h1>Interface AppService</h1></div><div class="tsd-signature"><span class="tsd-signature-keyword">interface</span> <span class="tsd-kind-interface">AppService</span> <span class="tsd-signature-symbol">{</span><br/>    <span class="tsd-signature-keyword">get</span> <a class="tsd-kind-get-signature" href="#userauthoredtoolsenableduserauthoredtoolsenabled">userAuthoredToolsEnabled</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#addbalance-1">addBalance</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">amount</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#attachartifacttoagent-1">attachArtifactToAgent</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#attachdocument-1">attachDocument</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fileData</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AttachDocumentResponse.html" class="tsd-signature-type tsd-kind-interface">AttachDocumentResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#compactagentconversation-1">compactAgentConversation</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#compactstory-1">compactStory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">details</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">message</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">success</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#convertuserartifact-1">convertUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">pdfBuffer</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createagent-1">createAgent</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">aiServiceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">agentName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">agentNickname</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">description</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">aiModel</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">promptName</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">controlledByHuman</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">reasoningEffort</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">&quot;low&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;medium&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;high&quot;</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">maxOutputTokens</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">beginInstruction</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="../classes/Agent.html" class="tsd-signature-type tsd-kind-class">Agent</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createpromptfolder-1">createPromptFolder</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createroom-1">createRoom</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">roomName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">goal</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">agentIds</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="CreateRoomResponse.html" class="tsd-signature-type tsd-kind-interface">CreateRoomResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createstory-1">createStory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">idea</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">userCharacterDesc</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">otherCharactersDesc</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">illustrateStory</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">storyModel</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">isImport</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">imageModelName</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">skipDetailedPlot</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createtool-1">createTool</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tool</span><span class="tsd-signature-symbol">:</span> <a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createuserartifact-1">createUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#declinecharacter-1">declineCharacter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deleteagent-1">deleteAgent</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deleteattachedfile-1">deleteAttachedFile</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deleteattachedfilebyid-1">deleteAttachedFileById</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">documentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletechapter-1">deleteChapter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletecharacterfromstory-1">deleteCharacterFromStory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletepromptfile-1">deletePromptFile</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletepromptfolder-1">deletePromptFolder</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deleteroom-1">deleteRoom</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletestory-1">deleteStory</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletetool-1">deleteTool</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deleteuserartifact-1">deleteUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#detachartifactfromagent-1">detachArtifactFromAgent</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#downloadstorymarkdown-1">downloadStoryMarkdown</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#editroom-1">editRoom</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">roomName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">goal</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">baseRoomDir</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">agentIds</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#ensureagentstatecallback-1">ensureAgentStateCallback</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#ensureroomstatecallback-1">ensureRoomStateCallback</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#exportstorydata-1">exportStoryData</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">filename</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">stream</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Readable</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getagentdetails-1">getAgentDetails</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getagenthistory-1">getAgentHistory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getagentmessageemitter-1">getAgentMessageEmitter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getagentmessages-1">getAgentMessages</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">AgentMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getaiservicenames-1">getAiServiceNames</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getbalance-1">getBalance</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getbalancemessageemitter-1">getBalanceMessageEmitter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">userId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getchapter-1">getChapter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../classes/RoomMessage.html" class="tsd-signature-type tsd-kind-class">RoomMessage</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getcharacter-1">getCharacter</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getcharacterinventory-1">getCharacterInventory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getplotplan-1">getPlotPlan</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getpromptfile-1">getPromptFile</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFileContent.html" class="tsd-signature-type tsd-kind-interface">PromptFileContent</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getpublishedinstances-1">getPublishedInstances</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getpublishedroominstances-1">getPublishedRoomInstances</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getrandomstoryidea-1">getRandomStoryIdea</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="StoryIdea.html" class="tsd-signature-type tsd-kind-interface">StoryIdea</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getrandomstoryideabygenre-1">getRandomStoryIdeaByGenre</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">genreName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="StoryIdea.html" class="tsd-signature-type tsd-kind-interface">StoryIdea</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getroomartifacts-1">getRoomArtifacts</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">artifacts</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getroombyid-1">getRoomById</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../classes/Room.html" class="tsd-signature-type tsd-kind-class">Room</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getroomdetails-1">getRoomDetails</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomDetails.html" class="tsd-signature-type tsd-kind-interface">RoomDetails</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getroommessageemitter-1">getRoomMessageEmitter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getroommessages-1">getRoomMessages</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">includeThoughts</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">RoomMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstoryartifact-1">getStoryArtifact</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ArrayBufferLike</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstoryinfo-1">getStoryInfo</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstorymessageemitter-1">getStoryMessageEmitter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstorymessages-1">getStoryMessages</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">RoomMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstoryprogressemitter-1">getStoryProgressEmitter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstorystate-1">getStoryState</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryState.html" class="tsd-signature-type tsd-kind-interface">StoryState</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#gettransactionbypaymentid-1">getTransactionByPaymentId</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Transaction.html" class="tsd-signature-type tsd-kind-interface">Transaction</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#gettransactions-1">getTransactions</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">limit</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">offset</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="TransactionHistoryResponse.html" class="tsd-signature-type tsd-kind-interface">TransactionHistoryResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getuserartifact-1">getUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ArrayBufferLike</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getuserpreferences-1">getUserPreferences</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getuserpromptsdir-1">getUserPromptsDir</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#importstoryfromzip-1">importStoryFromZip</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">zipBuffer</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#interruptstory-1">interruptStory</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#introducecharactertostory-1">introduceCharacterToStory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">description</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">storyModel</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fromNarratorSuggestion</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listagentartifacts-1">listAgentArtifacts</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listagents-1">listAgents</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listaimodels-1">listAiModels</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">aiServiceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ModelInfo.html" class="tsd-signature-type tsd-kind-interface">ModelInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listattachedfiles-1">listAttachedFiles</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="FileList.html" class="tsd-signature-type tsd-kind-interface">FileList</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listchapters-1">listChapters</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">chapters</span><span class="tsd-signature-symbol">:</span> <a href="ChapterInfo.html" class="tsd-signature-type tsd-kind-interface">ChapterInfo</a><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listcharacters-1">listCharacters</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Character.html" class="tsd-signature-type tsd-kind-interface">Character</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listimagemodels-1">listImageModels</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ImageModelOption</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listnativetoolsummaries-1">listNativeToolSummaries</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="ToolSummary.html" class="tsd-signature-type tsd-kind-interface">ToolSummary</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listpromptfiles-1">listPromptFiles</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="FileList.html" class="tsd-signature-type tsd-kind-interface">FileList</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listpromptfileswithscope-1">listPromptFilesWithScope</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFilesResponse.html" class="tsd-signature-type tsd-kind-interface">PromptFilesResponse</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listpromptfolders-1">listPromptFolders</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listpromptfolderswithscope-1">listPromptFoldersWithScope</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">scope</span><span class="tsd-signature-symbol">?:</span> <a href="../types/PromptScope.html" class="tsd-signature-type tsd-kind-type-alias">PromptScope</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFoldersResponse.html" class="tsd-signature-type tsd-kind-interface">PromptFoldersResponse</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listprompts-1">listPrompts</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listpublishedagents-1">listPublishedAgents</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listrooms-1">listRooms</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#liststories-1">listStories</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#liststoryartifacts-1">listStoryArtifacts</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#liststorygenres-1">listStoryGenres</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#liststorymodels-1">listStoryModels</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ModelInfo.html" class="tsd-signature-type tsd-kind-interface">ModelInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listtools-1">listTools</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listuserartifacts-1">listUserArtifacts</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#pauseroom-1">pauseRoom</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#processtext-1">processText</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">text</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ProcessTextResponse.html" class="tsd-signature-type tsd-kind-interface">ProcessTextResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#progressstory-1">progressStory</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#publishagentinstance-1">publishAgentInstance</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">instanceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">publicUrl</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#publishartifact-1">publishArtifact</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">creator</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">body</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">viewers</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#publishroom-1">publishRoom</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">publishedName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">userId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#recordtransaction-1">recordTransaction</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">amount</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">status</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">&quot;pending&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;succeeded&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;failed&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;cancelled&quot;</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Transaction.html" class="tsd-signature-type tsd-kind-interface">Transaction</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#reloadagent-1">reloadAgent</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#renameuserartifact-1">renameUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">newName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resetpublishedinstance-1">resetPublishedInstance</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resetpublishedroominstance-1">resetPublishedRoomInstance</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resetroom-1">resetRoom</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resetstory-1">resetStory</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#respondtostory-1">respondToStory</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resumepausedstories-1">resumePausedStories</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resumeroom-1">resumeRoom</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#revertstorychapter-1">revertStoryChapter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#runpreparedprompt-1">runPreparedPrompt</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">promptName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">variables</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="PreparedPromptResponse.html" class="tsd-signature-type tsd-kind-interface">PreparedPromptResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#savechapter-1">saveChapter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#savecharacter-1">saveCharacter</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#savecharacterinventory-1">saveCharacterInventory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#saveplotplan-1">savePlotPlan</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#savepromptfile-1">savePromptFile</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fileType</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#saveuserpreferences-1">saveUserPreferences</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">preferences</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#sendroommessage-1">sendRoomMessage</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">sender</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">action</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">targets</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">clearQueue</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">context</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">unknown</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="SendMessageResult.html" class="tsd-signature-type tsd-kind-interface">SendMessageResult</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#setroomleader-1">setRoomLeader</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">agentNickname</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#testtool-1">testTool</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">args</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Record</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../types/ToolRunResult.html" class="tsd-signature-type tsd-kind-type-alias">ToolRunResult</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#updateagent-1">updateAgent</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">updates</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{</span><br/>            <span class="tsd-kind-property">agentNickname</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>            <span class="tsd-kind-property">allowSearch</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>            <span class="tsd-kind-property">beginInstruction</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>            <span class="tsd-kind-property">description</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>            <span class="tsd-kind-property">isControlledByHuman</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>            <span class="tsd-kind-property">maxOutputTokens</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">;</span><br/>            <span class="tsd-kind-property">modelName</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>            <span class="tsd-kind-property">reasoningEffort</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">&quot;low&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;medium&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;high&quot;</span><span class="tsd-signature-symbol">;</span><br/>            <span class="tsd-kind-property">toolNames</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>        <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#updatetool-1">updateTool</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">tool</span><span class="tsd-signature-symbol">:</span> <a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#updatetransactionstatus-1">updateTransactionStatus</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">status</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">&quot;pending&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;succeeded&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;failed&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;cancelled&quot;</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#updateuserartifact-1">updateUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/><span class="tsd-signature-symbol">}</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L67">server/src/app.service.ts:67</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><details class="tsd-index-content tsd-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h5 class="tsd-index-heading uppercase">Index</h5></summary><div class="tsd-accordion-details"><section class="tsd-index-section"><h3 class="tsd-index-heading">Accessors</h3><div class="tsd-index-list"><a href="#userauthoredtoolsenabled" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Accessor"><use href="../assets/icons.svg#icon-262144"></use></svg><span>user<wbr/>Authored<wbr/>Tools<wbr/>Enabled</span></a>
1
+ <!DOCTYPE html><html class="default" lang="en" data-base="../"><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>AppService | Briyah SDK - v1.4.0</title><meta name="description" content="Documentation for Briyah SDK"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => window.app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><a href="../index.html" class="title">Briyah SDK - v1.4.0</a><div id="tsd-toolbar-links"><a href="https://github.com/your-org/briyah">GitHub</a><a href="https://www.npmjs.com/package/briyah">npm</a></div><button id="tsd-search-trigger" class="tsd-widget" aria-label="Search"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-search"></use></svg></button><dialog id="tsd-search" aria-label="Search"><input role="combobox" id="tsd-search-input" aria-controls="tsd-search-results" aria-autocomplete="list" aria-expanded="true" autocapitalize="off" autocomplete="off" placeholder="Search the docs" maxLength="100"/><ul role="listbox" id="tsd-search-results"></ul><div id="tsd-search-status" aria-live="polite" aria-atomic="true"><div>Preparing search index...</div></div></dialog><a href="#" class="tsd-widget menu" id="tsd-toolbar-menu-trigger" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb" aria-label="Breadcrumb"><li><a href="" aria-current="page">AppService</a></li></ul><h1>Interface AppService</h1></div><div class="tsd-signature"><span class="tsd-signature-keyword">interface</span> <span class="tsd-kind-interface">AppService</span> <span class="tsd-signature-symbol">{</span><br/>    <span class="tsd-signature-keyword">get</span> <a class="tsd-kind-get-signature" href="#userauthoredtoolsenableduserauthoredtoolsenabled">userAuthoredToolsEnabled</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#addbalance-1">addBalance</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">amount</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#attachartifacttoagent-1">attachArtifactToAgent</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#attachdocument-1">attachDocument</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fileData</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AttachDocumentResponse.html" class="tsd-signature-type tsd-kind-interface">AttachDocumentResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#compactagentconversation-1">compactAgentConversation</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#compactstory-1">compactStory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">details</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">message</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">success</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#convertuserartifact-1">convertUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">pdfBuffer</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createagent-1">createAgent</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">aiServiceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">agentName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">agentNickname</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">description</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">aiModel</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">promptName</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">controlledByHuman</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">reasoningEffort</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">&quot;low&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;medium&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;high&quot;</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">maxOutputTokens</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">beginInstruction</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">options</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">AgentCreationOptions</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="../classes/Agent.html" class="tsd-signature-type tsd-kind-class">Agent</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createpromptfolder-1">createPromptFolder</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createroom-1">createRoom</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">roomName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">goal</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">agentIds</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">roomLeader</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">turnMode</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">RoomTurnMode</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">moderator</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="CreateRoomResponse.html" class="tsd-signature-type tsd-kind-interface">CreateRoomResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createroomagent-1">createRoomAgent</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">request</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">CreateAgentRequest</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="CreateAgentResponse.html" class="tsd-signature-type tsd-kind-interface">CreateAgentResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createstory-1">createStory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">idea</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">userCharacterDesc</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">otherCharactersDesc</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">illustrateStory</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">storyModel</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">isImport</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">imageModelName</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">skipDetailedPlot</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createtool-1">createTool</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tool</span><span class="tsd-signature-symbol">:</span> <a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#createuserartifact-1">createUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#declinecharacter-1">declineCharacter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deleteagent-1">deleteAgent</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deleteattachedfile-1">deleteAttachedFile</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deleteattachedfilebyid-1">deleteAttachedFileById</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">documentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletechapter-1">deleteChapter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletecharacterfromstory-1">deleteCharacterFromStory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletepromptfile-1">deletePromptFile</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletepromptfolder-1">deletePromptFolder</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deleteroom-1">deleteRoom</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletestory-1">deleteStory</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deletetool-1">deleteTool</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#deleteuserartifact-1">deleteUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#detachartifactfromagent-1">detachArtifactFromAgent</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#downloadstorymarkdown-1">downloadStoryMarkdown</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#editroom-1">editRoom</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">roomName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">goal</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">baseRoomDir</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">agentIds</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">roomLeader</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">turnMode</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">RoomTurnMode</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">moderator</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#ensureagentstatecallback-1">ensureAgentStateCallback</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#ensureroomstatecallback-1">ensureRoomStateCallback</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#exportstorydata-1">exportStoryData</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">filename</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">stream</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Readable</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getagentdetails-1">getAgentDetails</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getagenthistory-1">getAgentHistory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getagentmessageemitter-1">getAgentMessageEmitter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getagentmessages-1">getAgentMessages</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">AgentMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getaiservicenames-1">getAiServiceNames</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getbalance-1">getBalance</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getbalancemessageemitter-1">getBalanceMessageEmitter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">userId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getchapter-1">getChapter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../classes/RoomMessage.html" class="tsd-signature-type tsd-kind-class">RoomMessage</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getcharacter-1">getCharacter</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getcharacterinventory-1">getCharacterInventory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getplotplan-1">getPlotPlan</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getpromptfile-1">getPromptFile</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFileContent.html" class="tsd-signature-type tsd-kind-interface">PromptFileContent</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getpromptfolderdefaults-1">getPromptFolderDefaults</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">PromptFolderDefaultsResponse</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getpublishedinstances-1">getPublishedInstances</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getpublishedroominstances-1">getPublishedRoomInstances</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getrandomstoryidea-1">getRandomStoryIdea</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="StoryIdea.html" class="tsd-signature-type tsd-kind-interface">StoryIdea</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getrandomstoryideabygenre-1">getRandomStoryIdeaByGenre</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">genreName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="StoryIdea.html" class="tsd-signature-type tsd-kind-interface">StoryIdea</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getroomartifacts-1">getRoomArtifacts</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">artifacts</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getroombyid-1">getRoomById</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../classes/Room.html" class="tsd-signature-type tsd-kind-class">Room</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getroomdetails-1">getRoomDetails</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomDetails.html" class="tsd-signature-type tsd-kind-interface">RoomDetails</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getroommessageemitter-1">getRoomMessageEmitter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getroommessages-1">getRoomMessages</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">includeThoughts</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">RoomMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstoryartifact-1">getStoryArtifact</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ArrayBufferLike</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstoryinfo-1">getStoryInfo</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstorymessageemitter-1">getStoryMessageEmitter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstorymessages-1">getStoryMessages</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">RoomMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstoryprogressemitter-1">getStoryProgressEmitter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getstorystate-1">getStoryState</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryState.html" class="tsd-signature-type tsd-kind-interface">StoryState</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#gettransactionbypaymentid-1">getTransactionByPaymentId</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Transaction.html" class="tsd-signature-type tsd-kind-interface">Transaction</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#gettransactions-1">getTransactions</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">limit</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">offset</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="TransactionHistoryResponse.html" class="tsd-signature-type tsd-kind-interface">TransactionHistoryResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getuserartifact-1">getUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ArrayBufferLike</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getuserpreferences-1">getUserPreferences</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#getuserpromptsdir-1">getUserPromptsDir</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#importstoryfromzip-1">importStoryFromZip</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">zipBuffer</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#interruptstory-1">interruptStory</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#introducecharactertostory-1">introduceCharacterToStory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">description</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">storyModel</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fromNarratorSuggestion</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listagentartifacts-1">listAgentArtifacts</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listagents-1">listAgents</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">includeRoomAgents</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listaimodels-1">listAiModels</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">aiServiceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ModelInfo.html" class="tsd-signature-type tsd-kind-interface">ModelInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listattachedfiles-1">listAttachedFiles</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="FileList.html" class="tsd-signature-type tsd-kind-interface">FileList</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listchapters-1">listChapters</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">chapters</span><span class="tsd-signature-symbol">:</span> <a href="ChapterInfo.html" class="tsd-signature-type tsd-kind-interface">ChapterInfo</a><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listcharacters-1">listCharacters</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Character.html" class="tsd-signature-type tsd-kind-interface">Character</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listimagemodels-1">listImageModels</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ImageModelOption</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listnativetoolsummaries-1">listNativeToolSummaries</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="ToolSummary.html" class="tsd-signature-type tsd-kind-interface">ToolSummary</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listpromptfiles-1">listPromptFiles</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="FileList.html" class="tsd-signature-type tsd-kind-interface">FileList</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listpromptfileswithscope-1">listPromptFilesWithScope</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFilesResponse.html" class="tsd-signature-type tsd-kind-interface">PromptFilesResponse</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listpromptfolders-1">listPromptFolders</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listpromptfolderswithscope-1">listPromptFoldersWithScope</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">scope</span><span class="tsd-signature-symbol">?:</span> <a href="../types/PromptScope.html" class="tsd-signature-type tsd-kind-type-alias">PromptScope</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFoldersResponse.html" class="tsd-signature-type tsd-kind-interface">PromptFoldersResponse</a><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listprompts-1">listPrompts</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listpublishedagents-1">listPublishedAgents</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listpublishedrooms-1">listPublishedRooms</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listrooms-1">listRooms</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#liststories-1">listStories</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#liststoryartifacts-1">listStoryArtifacts</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#liststorygenres-1">listStoryGenres</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#liststorymodels-1">listStoryModels</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ModelInfo.html" class="tsd-signature-type tsd-kind-interface">ModelInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listtools-1">listTools</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#listuserartifacts-1">listUserArtifacts</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#pauseroom-1">pauseRoom</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#processtext-1">processText</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">text</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ProcessTextResponse.html" class="tsd-signature-type tsd-kind-interface">ProcessTextResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#progressstory-1">progressStory</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#publishagentinstance-1">publishAgentInstance</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">instanceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">publicUrl</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#publishartifact-1">publishArtifact</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">creator</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">body</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">viewers</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#publishroom-1">publishRoom</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">publishedName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">userId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#recordtransaction-1">recordTransaction</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">amount</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">status</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">&quot;pending&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;succeeded&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;failed&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;cancelled&quot;</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Transaction.html" class="tsd-signature-type tsd-kind-interface">Transaction</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#reloadagent-1">reloadAgent</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#removeroomagent-1">removeRoomAgent</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#renameuserartifact-1">renameUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">newName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resetpublishedinstance-1">resetPublishedInstance</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resetpublishedroominstance-1">resetPublishedRoomInstance</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resetroom-1">resetRoom</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resetstory-1">resetStory</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#respondtostory-1">respondToStory</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resumepausedstories-1">resumePausedStories</a><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#resumeroom-1">resumeRoom</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#revertstorychapter-1">revertStoryChapter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#runpreparedprompt-1">runPreparedPrompt</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">promptName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">variables</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="PreparedPromptResponse.html" class="tsd-signature-type tsd-kind-interface">PreparedPromptResponse</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#savechapter-1">saveChapter</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#savecharacter-1">saveCharacter</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#savecharacterinventory-1">saveCharacterInventory</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#saveplotplan-1">savePlotPlan</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#savepromptfile-1">savePromptFile</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">fileType</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#saveuserpreferences-1">saveUserPreferences</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">preferences</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#sendroommessage-1">sendRoomMessage</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">sender</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">action</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">targets</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">clearQueue</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">context</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">unknown</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="SendMessageResult.html" class="tsd-signature-type tsd-kind-interface">SendMessageResult</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#setroomleader-1">setRoomLeader</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">agentNickname</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#testtool-1">testTool</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">args</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Record</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../types/ToolRunResult.html" class="tsd-signature-type tsd-kind-type-alias">ToolRunResult</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#updateagent-1">updateAgent</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">updates</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">UpdateAgentRequest</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#updatetool-1">updateTool</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">tool</span><span class="tsd-signature-symbol">:</span> <a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#updatetransactionstatus-1">updateTransactionStatus</a><span class="tsd-signature-symbol">(</span><br/>        <span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>        <span class="tsd-kind-parameter">status</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">&quot;pending&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;succeeded&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;failed&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;cancelled&quot;</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">;</span><br/>    <a class="tsd-kind-call-signature" href="#updateuserartifact-1">updateUserArtifact</a><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/><span class="tsd-signature-symbol">}</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L108">server/src/app.service.ts:108</a></li></ul></aside><section class="tsd-panel-group tsd-index-group"><section class="tsd-panel tsd-index-panel"><details class="tsd-index-content tsd-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h5 class="tsd-index-heading uppercase">Index</h5></summary><div class="tsd-accordion-details"><section class="tsd-index-section"><h3 class="tsd-index-heading">Accessors</h3><div class="tsd-index-list"><a href="#userauthoredtoolsenabled" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Accessor"><use href="../assets/icons.svg#icon-262144"></use></svg><span>user<wbr/>Authored<wbr/>Tools<wbr/>Enabled</span></a>
2
2
  </div></section><section class="tsd-index-section"><h3 class="tsd-index-heading">Methods</h3><div class="tsd-index-list"><a href="#addbalance" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Balance</span></a>
3
3
  <a href="#attachartifacttoagent" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>attach<wbr/>Artifact<wbr/>To<wbr/>Agent</span></a>
4
4
  <a href="#attachdocument" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>attach<wbr/>Document</span></a>
@@ -8,6 +8,7 @@
8
8
  <a href="#createagent" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Agent</span></a>
9
9
  <a href="#createpromptfolder" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Prompt<wbr/>Folder</span></a>
10
10
  <a href="#createroom" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Room</span></a>
11
+ <a href="#createroomagent" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Room<wbr/>Agent</span></a>
11
12
  <a href="#createstory" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Story</span></a>
12
13
  <a href="#createtool" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Tool</span></a>
13
14
  <a href="#createuserartifact" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>User<wbr/>Artifact</span></a>
@@ -41,6 +42,7 @@
41
42
  <a href="#getcharacterinventory" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Character<wbr/>Inventory</span></a>
42
43
  <a href="#getplotplan" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Plot<wbr/>Plan</span></a>
43
44
  <a href="#getpromptfile" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Prompt<wbr/>File</span></a>
45
+ <a href="#getpromptfolderdefaults" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Prompt<wbr/>Folder<wbr/>Defaults</span></a>
44
46
  <a href="#getpublishedinstances" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Published<wbr/>Instances</span></a>
45
47
  <a href="#getpublishedroominstances" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Published<wbr/>Room<wbr/>Instances</span></a>
46
48
  <a href="#getrandomstoryidea" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Random<wbr/>Story<wbr/>Idea</span></a>
@@ -78,6 +80,7 @@
78
80
  <a href="#listpromptfolderswithscope" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompt<wbr/>Folders<wbr/>With<wbr/>Scope</span></a>
79
81
  <a href="#listprompts" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompts</span></a>
80
82
  <a href="#listpublishedagents" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Published<wbr/>Agents</span></a>
83
+ <a href="#listpublishedrooms" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Published<wbr/>Rooms</span></a>
81
84
  <a href="#listrooms" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Rooms</span></a>
82
85
  <a href="#liststories" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Stories</span></a>
83
86
  <a href="#liststoryartifacts" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Story<wbr/>Artifacts</span></a>
@@ -93,6 +96,7 @@
93
96
  <a href="#publishroom" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>publish<wbr/>Room</span></a>
94
97
  <a href="#recordtransaction" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>record<wbr/>Transaction</span></a>
95
98
  <a href="#reloadagent" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reload<wbr/>Agent</span></a>
99
+ <a href="#removeroomagent" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Room<wbr/>Agent</span></a>
96
100
  <a href="#renameuserartifact" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>rename<wbr/>User<wbr/>Artifact</span></a>
97
101
  <a href="#resetpublishedinstance" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reset<wbr/>Published<wbr/>Instance</span></a>
98
102
  <a href="#resetpublishedroominstance" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reset<wbr/>Published<wbr/>Room<wbr/>Instance</span></a>
@@ -118,16 +122,16 @@
118
122
  <a href="#updateuserartifact" class="tsd-index-link"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>User<wbr/>Artifact</span></a>
119
123
  </div></section></div></details></section></section><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Accessors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Accessors</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="userauthoredtoolsenabled"><span>user<wbr/>Authored<wbr/>Tools<wbr/>Enabled</span><a href="#userauthoredtoolsenabled" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li><div class="tsd-signature" id="userauthoredtoolsenableduserauthoredtoolsenabled"><span class="tsd-signature-keyword">get</span> <span class="tsd-kind-get-signature">userAuthoredToolsEnabled</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Whether this deployment permits users to author and run their own tools.
120
124
  Native (host-registered) tools are always available regardless.</p>
121
- </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1785">server/src/app.service.ts:1785</a></li></ul></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Methods</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="addbalance"><span>add<wbr/>Balance</span><a href="#addbalance" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="addbalance-1"><span class="tsd-kind-call-signature">addBalance</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">amount</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#addbalance-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Adds funds to the user's balance.</p>
125
+ </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2338">server/src/app.service.ts:2338</a></li></ul></aside></div></li></ul></section></section></details><details class="tsd-panel-group tsd-member-group tsd-accordion" open><summary class="tsd-accordion-summary" data-key="section-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h2>Methods</h2></summary><section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="addbalance"><span>add<wbr/>Balance</span><a href="#addbalance" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="addbalance-1"><span class="tsd-kind-call-signature">addBalance</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">amount</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#addbalance-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Adds funds to the user's balance.</p>
122
126
  <p>Use this to credit a user after a payment is processed by your application.</p>
123
127
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">amount</span>: <span class="tsd-signature-type">number</span></span><div class="tsd-comment tsd-typography"><p>Dollar amount to add (must be positive)</p>
124
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2887">server/src/app.service.ts:2887</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="attachartifacttoagent"><span>attach<wbr/>Artifact<wbr/>To<wbr/>Agent</span><a href="#attachartifacttoagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="attachartifacttoagent-1"><span class="tsd-kind-call-signature">attachArtifactToAgent</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#attachartifacttoagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Attaches a user artifact to an agent so the agent can read its content in prompts.</p>
128
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3441">server/src/app.service.ts:3441</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="attachartifacttoagent"><span>attach<wbr/>Artifact<wbr/>To<wbr/>Agent</span><a href="#attachartifacttoagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="attachartifacttoagent-1"><span class="tsd-kind-call-signature">attachArtifactToAgent</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#attachartifacttoagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Attaches a user artifact to an agent so the agent can read its content in prompts.</p>
125
129
  <p>The attachment is persisted immediately via <code>agent.save()</code>. The artifact content
126
130
  is injected into the agent's context on each subsequent call.</p>
127
131
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
128
132
  </div></li><li><span><span class="tsd-kind-parameter">artifactId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The artifact's ID (from <a href="#listuserartifacts" class="tsd-kind-method">listUserArtifacts</a>)</p>
129
133
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws">Throws<a href="#throws" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the agent or artifact does not exist</p>
130
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L3336">server/src/app.service.ts:3336</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="attachdocument"><span>attach<wbr/>Document</span><a href="#attachdocument" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="attachdocument-1"><span class="tsd-kind-call-signature">attachDocument</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fileData</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AttachDocumentResponse.html" class="tsd-signature-type tsd-kind-interface">AttachDocumentResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#attachdocument-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Attaches a document to an agent so it can reference the file's contents in prompts.</p>
134
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3890">server/src/app.service.ts:3890</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="attachdocument"><span>attach<wbr/>Document</span><a href="#attachdocument" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="attachdocument-1"><span class="tsd-kind-call-signature">attachDocument</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fileData</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AttachDocumentResponse.html" class="tsd-signature-type tsd-kind-interface">AttachDocumentResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#attachdocument-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Attaches a document to an agent so it can reference the file's contents in prompts.</p>
131
135
  <p>The file is stored on disk and uploaded to the AI provider if required
132
136
  (e.g. OpenAI file uploads, Grok file uploads). The agent state is persisted after attachment.</p>
133
137
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
@@ -135,17 +139,17 @@ is injected into the agent's context on each subsequent call.</p>
135
139
  </div></li><li><span><span class="tsd-kind-parameter">fileData</span>: <span class="tsd-signature-type">Buffer</span></span><div class="tsd-comment tsd-typography"><p>Raw file bytes as a <code>Buffer</code></p>
136
140
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AttachDocumentResponse.html" class="tsd-signature-type tsd-kind-interface">AttachDocumentResponse</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Object containing a <code>documentId</code> that can be used with <a href="#deleteattachedfilebyid" class="tsd-kind-method">deleteAttachedFileById</a></p>
137
141
  <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-1">Throws<a href="#throws-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
138
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L403">server/src/app.service.ts:403</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="compactagentconversation"><span>compact<wbr/>Agent<wbr/>Conversation</span><a href="#compactagentconversation" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="compactagentconversation-1"><span class="tsd-kind-call-signature">compactAgentConversation</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#compactagentconversation-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Compacts an agent's conversation history into a single summary message.
142
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L464">server/src/app.service.ts:464</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="compactagentconversation"><span>compact<wbr/>Agent<wbr/>Conversation</span><a href="#compactagentconversation" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="compactagentconversation-1"><span class="tsd-kind-call-signature">compactAgentConversation</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#compactagentconversation-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Compacts an agent's conversation history into a single summary message.
139
143
  Uses the <code>compact_agent</code> prompt (role folder first, common-root as fallback).</p>
140
144
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
141
145
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-2">Throws<a href="#throws-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
142
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2023">server/src/app.service.ts:2023</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="compactstory"><span>compact<wbr/>Story</span><a href="#compactstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="compactstory-1"><span class="tsd-kind-call-signature">compactStory</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">details</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">message</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">success</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#compactstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Summarizes and compresses agent conversation histories to reduce token usage.</p>
146
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2577">server/src/app.service.ts:2577</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="compactstory"><span>compact<wbr/>Story</span><a href="#compactstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="compactstory-1"><span class="tsd-kind-call-signature">compactStory</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">details</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">message</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">success</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#compactstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Summarizes and compresses agent conversation histories to reduce token usage.</p>
143
147
  <p>Uses story-specific prompts: the narrator summarizes plot events,
144
148
  characters summarize their relationships and experiences. The original
145
149
  messages are replaced with a compact summary block.</p>
146
150
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
147
151
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">details</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">message</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">success</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with <code>success</code> flag, optional <code>message</code>, and compaction <code>details</code></p>
148
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2565">server/src/app.service.ts:2565</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="convertuserartifact"><span>convert<wbr/>User<wbr/>Artifact</span><a href="#convertuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="convertuserartifact-1"><span class="tsd-kind-call-signature">convertUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">pdfBuffer</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><a href="#convertuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates an artifact from a PDF by converting it to Markdown, running the
152
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3119">server/src/app.service.ts:3119</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="convertuserartifact"><span>convert<wbr/>User<wbr/>Artifact</span><a href="#convertuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="convertuserartifact-1"><span class="tsd-kind-call-signature">convertUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">pdfBuffer</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><a href="#convertuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates an artifact from a PDF by converting it to Markdown, running the
149
153
  conversion in the background.</p>
150
154
  <p>Returns the artifact ID immediately with placeholder content. The artifact
151
155
  content is replaced with the converted Markdown when the background job
@@ -157,7 +161,7 @@ PDFs with more than 10 pages are converted page-by-page concurrently.</p>
157
161
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">name</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Display name for the artifact</p>
158
162
  </div></li><li><span><span class="tsd-kind-parameter">pdfBuffer</span>: <span class="tsd-signature-type">Buffer</span></span><div class="tsd-comment tsd-typography"><p>Buffer containing the raw PDF data</p>
159
163
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span></h4><p>The new artifact's ID (content is a placeholder until conversion completes)</p>
160
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L3021">server/src/app.service.ts:3021</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createagent"><span>create<wbr/>Agent</span><a href="#createagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createagent-1"><span class="tsd-kind-call-signature">createAgent</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">aiServiceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">agentName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">agentNickname</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">description</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">aiModel</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">promptName</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">controlledByHuman</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">reasoningEffort</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">&quot;low&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;medium&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;high&quot;</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">maxOutputTokens</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">beginInstruction</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="../classes/Agent.html" class="tsd-signature-type tsd-kind-class">Agent</a><a href="#createagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new AI agent and registers it in memory.</p>
164
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3575">server/src/app.service.ts:3575</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createagent"><span>create<wbr/>Agent</span><a href="#createagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createagent-1"><span class="tsd-kind-call-signature">createAgent</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">aiServiceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">agentName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">agentNickname</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">description</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">aiModel</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">promptName</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">controlledByHuman</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">reasoningEffort</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">&quot;low&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;medium&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;high&quot;</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">maxOutputTokens</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">beginInstruction</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">options</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">AgentCreationOptions</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="../classes/Agent.html" class="tsd-signature-type tsd-kind-class">Agent</a><a href="#createagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new AI agent and registers it in memory.</p>
161
165
  <p>The agent is immediately findable by ID but <strong>not</strong> persisted to disk.
162
166
  Call <code>agent.save()</code> when you want to write it to storage.</p>
163
167
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">aiServiceName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Provider name (e.g. <code>'Anthropic'</code>, <code>'OpenAI'</code>). Use <a href="#getaiservicenames" class="tsd-kind-method">getAiServiceNames</a> for valid values.</p>
@@ -170,25 +174,30 @@ Call <code>agent.save()</code> when you want to write it to storage.</p>
170
174
  </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">reasoningEffort</span>: <span class="tsd-signature-type">&quot;low&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;medium&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;high&quot;</span></span><div class="tsd-comment tsd-typography"><p>Extended-thinking effort level for models that support it (e.g. Claude 3.7 Sonnet, o1/o3). Pass <code>null</code> to disable. Defaults to <code>undefined</code> (model default).</p>
171
175
  </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">maxOutputTokens</span>: <span class="tsd-signature-type">number</span></span><div class="tsd-comment tsd-typography"><p>Override the model's default maximum output token limit</p>
172
176
  </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">beginInstruction</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Optional prompt stored with the agent and sent when the host app triggers a &quot;Begin&quot; action (e.g. <code>'Begin by reading the attached documents and asking the user the first question.'</code>)</p>
177
+ </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">options</span>: <span class="tsd-signature-type">AgentCreationOptions</span></span><div class="tsd-comment tsd-typography"><p>Everything else an agent can be created with: tool grants, private context, prompt cache TTL, search, the history window and the small-model override. Add new settings here rather than as further positional parameters.</p>
173
178
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="../classes/Agent.html" class="tsd-signature-type tsd-kind-class">Agent</a></h4><p>The newly created <a href="../classes/Agent.html" class="tsd-kind-class">Agent</a> instance</p>
174
179
  <div class="tsd-comment tsd-typography"><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example">Example<a href="#example" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-6">const</span><span class="hl-1"> </span><span class="hl-7">agent</span><span class="hl-1"> = </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">createAgent</span><span class="hl-1">(</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;Anthropic&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;AI Assistant&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;James&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;A helpful AI assistant&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;claude-haiku-4-5&#39;</span><span class="hl-1">,</span><br/><span class="hl-1">);</span><br/><span class="hl-3">if</span><span class="hl-1"> (!</span><span class="hl-4">agent</span><span class="hl-1">.</span><span class="hl-4">id</span><span class="hl-1">) </span><span class="hl-3">throw</span><span class="hl-1"> </span><span class="hl-6">new</span><span class="hl-1"> </span><span class="hl-0">Error</span><span class="hl-1">(</span><span class="hl-2">&#39;Agent creation failed&#39;</span><span class="hl-1">);</span><br/><span class="hl-4">agent</span><span class="hl-1">.</span><span class="hl-0">save</span><span class="hl-1">(); </span><span class="hl-5">// persist to disk</span>
175
180
  </code><button type="button">Copy</button></pre>
176
181
 
177
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L298">server/src/app.service.ts:298</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createpromptfolder"><span>create<wbr/>Prompt<wbr/>Folder</span><a href="#createpromptfolder" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createpromptfolder-1"><span class="tsd-kind-call-signature">createPromptFolder</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#createpromptfolder-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new prompt folder in the user prompts directory.</p>
182
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L340">server/src/app.service.ts:340</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createpromptfolder"><span>create<wbr/>Prompt<wbr/>Folder</span><a href="#createpromptfolder" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createpromptfolder-1"><span class="tsd-kind-call-signature">createPromptFolder</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#createpromptfolder-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new prompt folder in the user prompts directory.</p>
178
183
  <p>An empty <code>system_instruction.prompt</code> file is created inside the folder so that
179
184
  it is immediately usable as a prompt source for agents.</p>
180
185
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">folderName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Name of the folder to create</p>
181
186
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-3">Throws<a href="#throws-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If a folder with that name already exists</p>
182
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1686">server/src/app.service.ts:1686</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createroom"><span>create<wbr/>Room</span><a href="#createroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createroom-1"><span class="tsd-kind-call-signature">createRoom</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">roomName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">goal</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">agentIds</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="CreateRoomResponse.html" class="tsd-signature-type tsd-kind-interface">CreateRoomResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#createroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new room and populates it with the specified agents.</p>
183
- </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Display name for the room</p>
184
- </div></li><li><span><span class="tsd-kind-parameter">goal</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Description of the room's purpose or objective, shared with all agents</p>
185
- </div></li><li><span><span class="tsd-kind-parameter">agentIds</span>: <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>IDs of the agents to add to the room</p>
186
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="CreateRoomResponse.html" class="tsd-signature-type tsd-kind-interface">CreateRoomResponse</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Object containing the new <code>roomId</code></p>
187
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-4">Throws<a href="#throws-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If any agent ID does not exist</p>
188
- </div><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-1">Example<a href="#example-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-6">const</span><span class="hl-1"> { </span><span class="hl-7">roomId</span><span class="hl-1"> } = </span><span class="hl-3">await</span><span class="hl-1"> </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">createRoom</span><span class="hl-1">(</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;Research Session&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;Analyze the provided documents and produce a summary&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> [</span><span class="hl-4">analystId</span><span class="hl-1">, </span><span class="hl-4">writerAgentId</span><span class="hl-1">],</span><br/><span class="hl-1">);</span>
189
- </code><button type="button">Copy</button></pre>
190
-
191
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L676">server/src/app.service.ts:676</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createstory"><span>create<wbr/>Story</span><a href="#createstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createstory-1"><span class="tsd-kind-call-signature">createStory</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">idea</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">userCharacterDesc</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">otherCharactersDesc</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">illustrateStory</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">storyModel</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">isImport</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">imageModelName</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">skipDetailedPlot</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><a href="#createstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new interactive story with AI-driven characters.</p>
187
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2227">server/src/app.service.ts:2227</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createroom"><span>create<wbr/>Room</span><a href="#createroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createroom-1"><span class="tsd-kind-call-signature">createRoom</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">roomName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">goal</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">agentIds</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">roomLeader</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">turnMode</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">RoomTurnMode</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">moderator</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="CreateRoomResponse.html" class="tsd-signature-type tsd-kind-interface">CreateRoomResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#createroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomName</span>: <span class="tsd-signature-type">string</span></span></li><li><span><span class="tsd-kind-parameter">goal</span>: <span class="tsd-signature-type">string</span></span></li><li><span><span class="tsd-kind-parameter">agentIds</span>: <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span></span></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">roomLeader</span>: <span class="tsd-signature-type">string</span></span></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">turnMode</span>: <span class="tsd-signature-type">RoomTurnMode</span></span></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">moderator</span>: <span class="tsd-signature-type">string</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="CreateRoomResponse.html" class="tsd-signature-type tsd-kind-interface">CreateRoomResponse</a><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L840">server/src/app.service.ts:840</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createroomagent"><span>create<wbr/>Room<wbr/>Agent</span><a href="#createroomagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createroomagent-1"><span class="tsd-kind-call-signature">createRoomAgent</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">request</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">CreateAgentRequest</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="CreateAgentResponse.html" class="tsd-signature-type tsd-kind-interface">CreateAgentResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#createroomagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates an agent that belongs to a room and adds it to that room.</p>
188
+ <p>This is the only way an agent joins a room. The agent is owned by it: it is
189
+ left out of <a href="#listagents" class="tsd-kind-method">listAgents</a> and deleted with the room, so a room is a
190
+ self-contained cast rather than a set of references to a shared pool.</p>
191
+ <p><code>request.agentName</code> is the bare name. It is stored prefixed with the room's
192
+ name, while the nickname is derived from the bare name — otherwise every
193
+ agent in the room would be addressed by the room's first word.</p>
194
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room the agent will belong to</p>
195
+ </div></li><li><span><span class="tsd-kind-parameter">request</span>: <span class="tsd-signature-type">CreateAgentRequest</span></span><div class="tsd-comment tsd-typography"><p>The same fields <a href="#createagent" class="tsd-kind-method">createAgent</a> takes</p>
196
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="CreateAgentResponse.html" class="tsd-signature-type tsd-kind-interface">CreateAgentResponse</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Object containing the new <code>agentId</code></p>
197
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-4">Throws<a href="#throws-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
198
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-5">Throws<a href="#throws-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room is a published instance, or another
199
+ agent in the room already answers to the same nickname</p>
200
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1036">server/src/app.service.ts:1036</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createstory"><span>create<wbr/>Story</span><a href="#createstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createstory-1"><span class="tsd-kind-call-signature">createStory</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">idea</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">userCharacterDesc</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">otherCharactersDesc</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">illustrateStory</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">storyModel</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">isImport</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">imageModelName</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">skipDetailedPlot</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><a href="#createstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new interactive story with AI-driven characters.</p>
192
201
  <p>When this method returns, the story is <strong>immediately playable</strong>: brief character
193
202
  backgrounds and the opening scene have already been generated. A background job
194
203
  then generates the detailed plot plan and full character profiles; subscribe to
@@ -203,162 +212,171 @@ but there is no need to wait for it before letting the player interact.</p>
203
212
  </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">imageModelName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Optional image model name from image_models.json (supplies both the generation and editing models)</p>
204
213
  </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">skipDetailedPlot</span>: <span class="tsd-signature-type">boolean</span></span><div class="tsd-comment tsd-typography"><p>Set <code>true</code> to generate a simple plot scenario instead of a detailed plot plan with secrets, twists, and events. Default <code>false</code>.</p>
205
214
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Story metadata including the new <code>id</code> - story is ready to play immediately</p>
206
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-2">Example<a href="#example-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-5">// Story is playable as soon as createStory returns</span><br/><span class="hl-6">const</span><span class="hl-1"> </span><span class="hl-7">story</span><span class="hl-1"> = </span><span class="hl-3">await</span><span class="hl-1"> </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">createStory</span><span class="hl-1">(</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;The Lost Kingdom&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;A medieval fantasy adventure&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;A young knight seeking redemption&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;A wise wizard and a cunning rogue&#39;</span><span class="hl-1">,</span><br/><span class="hl-1">);</span><br/><br/><span class="hl-5">// Optionally listen for background completion (plot plan + detailed profiles)</span><br/><span class="hl-6">const</span><span class="hl-1"> </span><span class="hl-7">emitter</span><span class="hl-1"> = </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">getStoryProgressEmitter</span><span class="hl-1">(</span><span class="hl-4">story</span><span class="hl-1">.</span><span class="hl-4">id</span><span class="hl-1">);</span><br/><span class="hl-4">emitter</span><span class="hl-1">?.</span><span class="hl-0">on</span><span class="hl-1">(</span><span class="hl-2">&#39;progress&#39;</span><span class="hl-1">, ({ </span><span class="hl-4">step</span><span class="hl-1">, </span><span class="hl-4">message</span><span class="hl-1"> }) </span><span class="hl-6">=&gt;</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-3">if</span><span class="hl-1"> (</span><span class="hl-4">step</span><span class="hl-1"> === </span><span class="hl-2">&#39;complete&#39;</span><span class="hl-1">) </span><span class="hl-4">console</span><span class="hl-1">.</span><span class="hl-0">log</span><span class="hl-1">(</span><span class="hl-2">&#39;Background setup finished&#39;</span><span class="hl-1">);</span><br/><span class="hl-1">});</span>
215
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-1">Example<a href="#example-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-5">// Story is playable as soon as createStory returns</span><br/><span class="hl-6">const</span><span class="hl-1"> </span><span class="hl-7">story</span><span class="hl-1"> = </span><span class="hl-3">await</span><span class="hl-1"> </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">createStory</span><span class="hl-1">(</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;The Lost Kingdom&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;A medieval fantasy adventure&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;A young knight seeking redemption&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">&#39;A wise wizard and a cunning rogue&#39;</span><span class="hl-1">,</span><br/><span class="hl-1">);</span><br/><br/><span class="hl-5">// Optionally listen for background completion (plot plan + detailed profiles)</span><br/><span class="hl-6">const</span><span class="hl-1"> </span><span class="hl-7">emitter</span><span class="hl-1"> = </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">getStoryProgressEmitter</span><span class="hl-1">(</span><span class="hl-4">story</span><span class="hl-1">.</span><span class="hl-4">id</span><span class="hl-1">);</span><br/><span class="hl-4">emitter</span><span class="hl-1">?.</span><span class="hl-0">on</span><span class="hl-1">(</span><span class="hl-2">&#39;progress&#39;</span><span class="hl-1">, ({ </span><span class="hl-4">step</span><span class="hl-1">, </span><span class="hl-4">message</span><span class="hl-1"> }) </span><span class="hl-6">=&gt;</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-3">if</span><span class="hl-1"> (</span><span class="hl-4">step</span><span class="hl-1"> === </span><span class="hl-2">&#39;complete&#39;</span><span class="hl-1">) </span><span class="hl-4">console</span><span class="hl-1">.</span><span class="hl-0">log</span><span class="hl-1">(</span><span class="hl-2">&#39;Background setup finished&#39;</span><span class="hl-1">);</span><br/><span class="hl-1">});</span>
207
216
  </code><button type="button">Copy</button></pre>
208
217
 
209
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2207">server/src/app.service.ts:2207</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createtool"><span>create<wbr/>Tool</span><a href="#createtool" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createtool-1"><span class="tsd-kind-call-signature">createTool</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tool</span><span class="tsd-signature-symbol">:</span> <a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">&gt;</span><a href="#createtool-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new user-authored tool.</p>
218
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2761">server/src/app.service.ts:2761</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createtool"><span>create<wbr/>Tool</span><a href="#createtool" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createtool-1"><span class="tsd-kind-call-signature">createTool</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">tool</span><span class="tsd-signature-symbol">:</span> <a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">&gt;</span><a href="#createtool-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new user-authored tool.</p>
210
219
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">tool</span>: <a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a></span><div class="tsd-comment tsd-typography"><p>The tool definition to create</p>
211
220
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">&gt;</span></h4><p>The created tool definition</p>
212
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-5">Throws<a href="#throws-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If authoring is disabled or the name already exists</p>
213
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1820">server/src/app.service.ts:1820</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createuserartifact"><span>create<wbr/>User<wbr/>Artifact</span><a href="#createuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createuserartifact-1"><span class="tsd-kind-call-signature">createUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><a href="#createuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new named artifact and returns its ID.</p>
221
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-6">Throws<a href="#throws-6" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If authoring is disabled or the name already exists</p>
222
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2374">server/src/app.service.ts:2374</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="createuserartifact"><span>create<wbr/>User<wbr/>Artifact</span><a href="#createuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="createuserartifact-1"><span class="tsd-kind-call-signature">createUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><a href="#createuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a new named artifact and returns its ID.</p>
214
223
  <p>The artifact is persisted immediately. Use the returned ID to attach it to
215
224
  agents (<a href="#attachartifacttoagent" class="tsd-kind-method">attachArtifactToAgent</a>) or reference it in room messages.</p>
216
225
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">name</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Human-readable display name for the artifact</p>
217
226
  </div></li><li><span><span class="tsd-kind-parameter">content</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Initial text content (typically Markdown)</p>
218
227
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span></h4><p>The new artifact's ID</p>
219
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2989">server/src/app.service.ts:2989</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="declinecharacter"><span>decline<wbr/>Character</span><a href="#declinecharacter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="declinecharacter-1"><span class="tsd-kind-call-signature">declineCharacter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#declinecharacter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Records that the player declined a narrator-suggested character introduction.</p>
228
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3543">server/src/app.service.ts:3543</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="declinecharacter"><span>decline<wbr/>Character</span><a href="#declinecharacter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="declinecharacter-1"><span class="tsd-kind-call-signature">declineCharacter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#declinecharacter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Records that the player declined a narrator-suggested character introduction.</p>
220
229
  <p>Prevents the narrator from suggesting the same character again in this story.</p>
221
230
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
222
231
  </div></li><li><span><span class="tsd-kind-parameter">characterName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The character name that was declined</p>
223
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2679">server/src/app.service.ts:2679</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deleteagent"><span>delete<wbr/>Agent</span><a href="#deleteagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deleteagent-1"><span class="tsd-kind-call-signature">deleteAgent</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deleteagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Permanently deletes an agent and all its stored data.</p>
232
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3233">server/src/app.service.ts:3233</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deleteagent"><span>delete<wbr/>Agent</span><a href="#deleteagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deleteagent-1"><span class="tsd-kind-call-signature">deleteAgent</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deleteagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Permanently deletes an agent and all its stored data.</p>
224
233
  <p>If the agent is a published instance, its entry is also removed from the
225
234
  published agents mapping.</p>
226
235
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
227
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-6">Throws<a href="#throws-6" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
228
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1047">server/src/app.service.ts:1047</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deleteattachedfile"><span>delete<wbr/>Attached<wbr/>File</span><a href="#deleteattachedfile" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deleteattachedfile-1"><span class="tsd-kind-call-signature">deleteAttachedFile</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deleteattachedfile-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Removes a file from an agent by its file name.</p>
236
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-7">Throws<a href="#throws-7" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
237
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1468">server/src/app.service.ts:1468</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deleteattachedfile"><span>delete<wbr/>Attached<wbr/>File</span><a href="#deleteattachedfile" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deleteattachedfile-1"><span class="tsd-kind-call-signature">deleteAttachedFile</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deleteattachedfile-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Removes a file from an agent by its file name.</p>
229
238
  <p>Deletes the file from storage and updates the agent's metadata.
230
239
  Use <a href="#deleteattachedfilebyid" class="tsd-kind-method">deleteAttachedFileById</a> if you have the document ID instead.</p>
231
240
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
232
241
  </div></li><li><span><span class="tsd-kind-parameter">fileName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Name of the file to remove (e.g. <code>'report.pdf'</code>)</p>
233
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-7">Throws<a href="#throws-7" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the agent or file is not found</p>
234
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1909">server/src/app.service.ts:1909</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deleteattachedfilebyid"><span>delete<wbr/>Attached<wbr/>File<wbr/>By<wbr/>Id</span><a href="#deleteattachedfilebyid" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deleteattachedfilebyid-1"><span class="tsd-kind-call-signature">deleteAttachedFileById</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">documentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deleteattachedfilebyid-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Removes an attached file by its document ID (as returned by <a href="#attachdocument" class="tsd-kind-method">attachDocument</a>).</p>
242
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-8">Throws<a href="#throws-8" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the agent or file is not found</p>
243
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2463">server/src/app.service.ts:2463</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deleteattachedfilebyid"><span>delete<wbr/>Attached<wbr/>File<wbr/>By<wbr/>Id</span><a href="#deleteattachedfilebyid" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deleteattachedfilebyid-1"><span class="tsd-kind-call-signature">deleteAttachedFileById</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">documentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deleteattachedfilebyid-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Removes an attached file by its document ID (as returned by <a href="#attachdocument" class="tsd-kind-method">attachDocument</a>).</p>
235
244
  <p>Searches all agents to locate the owner, removes the file from storage,
236
245
  and updates the agent's metadata.</p>
237
246
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">documentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The <code>documentId</code> returned by <a href="#attachdocument" class="tsd-kind-method">attachDocument</a></p>
238
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-8">Throws<a href="#throws-8" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no file with the given ID exists</p>
239
- </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-9">Throws<a href="#throws-9" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If deletion fails</p>
240
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1937">server/src/app.service.ts:1937</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletechapter"><span>delete<wbr/>Chapter</span><a href="#deletechapter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletechapter-1"><span class="tsd-kind-call-signature">deleteChapter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#deletechapter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Deletes a chapter checkpoint from a story.</p>
247
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-9">Throws<a href="#throws-9" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no file with the given ID exists</p>
248
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-10">Throws<a href="#throws-10" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If deletion fails</p>
249
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2491">server/src/app.service.ts:2491</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletechapter"><span>delete<wbr/>Chapter</span><a href="#deletechapter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletechapter-1"><span class="tsd-kind-call-signature">deleteChapter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#deletechapter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Deletes a chapter checkpoint from a story.</p>
241
250
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
242
251
  </div></li><li><span><span class="tsd-kind-parameter">chapterIndex</span>: <span class="tsd-signature-type">number</span></span><div class="tsd-comment tsd-typography"><p>The chapter number to delete</p>
243
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-10">Throws<a href="#throws-10" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the chapter does not exist</p>
244
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2742">server/src/app.service.ts:2742</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletecharacterfromstory"><span>delete<wbr/>Character<wbr/>From<wbr/>Story</span><a href="#deletecharacterfromstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletecharacterfromstory-1"><span class="tsd-kind-call-signature">deleteCharacterFromStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deletecharacterfromstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Removes a character's agent from the story while preserving their profile file.</p>
252
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-11">Throws<a href="#throws-11" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the chapter does not exist</p>
253
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3296">server/src/app.service.ts:3296</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletecharacterfromstory"><span>delete<wbr/>Character<wbr/>From<wbr/>Story</span><a href="#deletecharacterfromstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletecharacterfromstory-1"><span class="tsd-kind-call-signature">deleteCharacterFromStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deletecharacterfromstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Removes a character's agent from the story while preserving their profile file.</p>
245
254
  <p>The character can be reintroduced later via <a href="#introducecharactertostory" class="tsd-kind-method">introduceCharacterToStory</a>
246
255
  and their profile will be available.</p>
247
256
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
248
257
  </div></li><li><span><span class="tsd-kind-parameter">characterName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The character's name</p>
249
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2692">server/src/app.service.ts:2692</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletepromptfile"><span>delete<wbr/>Prompt<wbr/>File</span><a href="#deletepromptfile" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletepromptfile-1"><span class="tsd-kind-call-signature">deletePromptFile</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#deletepromptfile-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Deletes a prompt file from the user prompts directory.</p>
258
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3246">server/src/app.service.ts:3246</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletepromptfile"><span>delete<wbr/>Prompt<wbr/>File</span><a href="#deletepromptfile" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletepromptfile-1"><span class="tsd-kind-call-signature">deletePromptFile</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#deletepromptfile-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Deletes a prompt file from the user prompts directory.</p>
250
259
  <p>Removes both the <code>.prompt</code> and <code>.json</code> variants if they exist.
251
260
  This is a no-op if neither file is present.</p>
252
261
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">folderName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Prompt folder name, or <code>'shared'</code> for the root prompts directory</p>
253
262
  </div></li><li><span><span class="tsd-kind-parameter">fileName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Base name of the file to delete (without extension)</p>
254
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1603">server/src/app.service.ts:1603</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletepromptfolder"><span>delete<wbr/>Prompt<wbr/>Folder</span><a href="#deletepromptfolder" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletepromptfolder-1"><span class="tsd-kind-call-signature">deletePromptFolder</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#deletepromptfolder-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Deletes a prompt folder and all its contents from the user prompts directory.</p>
263
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2144">server/src/app.service.ts:2144</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletepromptfolder"><span>delete<wbr/>Prompt<wbr/>Folder</span><a href="#deletepromptfolder" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletepromptfolder-1"><span class="tsd-kind-call-signature">deletePromptFolder</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#deletepromptfolder-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Deletes a prompt folder and all its contents from the user prompts directory.</p>
255
264
  <p>Only user-owned folders can be deleted; common folders are not affected.</p>
256
265
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">folderName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Name of the folder to delete</p>
257
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-11">Throws<a href="#throws-11" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If <code>folderName</code> is <code>'shared'</code></p>
258
- </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-12">Throws<a href="#throws-12" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the folder does not exist in the user prompts directory</p>
259
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1711">server/src/app.service.ts:1711</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deleteroom"><span>delete<wbr/>Room</span><a href="#deleteroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deleteroom-1"><span class="tsd-kind-call-signature">deleteRoom</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deleteroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Permanently deletes a room and all its data.</p>
266
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-12">Throws<a href="#throws-12" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If <code>folderName</code> is <code>'shared'</code></p>
267
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-13">Throws<a href="#throws-13" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the folder does not exist in the user prompts directory</p>
268
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2252">server/src/app.service.ts:2252</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deleteroom"><span>delete<wbr/>Room</span><a href="#deleteroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deleteroom-1"><span class="tsd-kind-call-signature">deleteRoom</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deleteroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Permanently deletes a room and all its data.</p>
260
269
  <p>If the room is a template, all of its published instances are deleted first.
261
- All attached files and published room mappings are also cleaned up.</p>
270
+ The agents the room owns, its attached files and its published room mapping
271
+ are also cleaned up.</p>
262
272
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
263
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-13">Throws<a href="#throws-13" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
264
- </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-14">Throws<a href="#throws-14" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If deletion fails</p>
265
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1209">server/src/app.service.ts:1209</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletestory"><span>delete<wbr/>Story</span><a href="#deletestory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletestory-1"><span class="tsd-kind-call-signature">deleteStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deletestory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Permanently deletes a story, its room, all characters, chapters, and artifacts.</p>
273
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-14">Throws<a href="#throws-14" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
274
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-15">Throws<a href="#throws-15" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If deletion fails</p>
275
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1633">server/src/app.service.ts:1633</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletestory"><span>delete<wbr/>Story</span><a href="#deletestory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletestory-1"><span class="tsd-kind-call-signature">deleteStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deletestory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Permanently deletes a story, its room, all characters, chapters, and artifacts.</p>
266
276
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
267
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2551">server/src/app.service.ts:2551</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletetool"><span>delete<wbr/>Tool</span><a href="#deletetool" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletetool-1"><span class="tsd-kind-call-signature">deleteTool</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deletetool-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Deletes a user-authored tool. Agents granted the tool keep the (now dangling)
277
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3105">server/src/app.service.ts:3105</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deletetool"><span>delete<wbr/>Tool</span><a href="#deletetool" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deletetool-1"><span class="tsd-kind-call-signature">deleteTool</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#deletetool-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Deletes a user-authored tool. Agents granted the tool keep the (now dangling)
268
278
  grant; the room silently drops missing tools from their prompts.</p>
269
279
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">name</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The tool's name</p>
270
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-15">Throws<a href="#throws-15" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the tool does not exist</p>
271
- </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-16">Throws<a href="#throws-16" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If authoring is disabled</p>
272
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1855">server/src/app.service.ts:1855</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deleteuserartifact"><span>delete<wbr/>User<wbr/>Artifact</span><a href="#deleteuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deleteuserartifact-1"><span class="tsd-kind-call-signature">deleteUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#deleteuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Permanently deletes a user artifact.</p>
280
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-16">Throws<a href="#throws-16" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the tool does not exist</p>
281
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-17">Throws<a href="#throws-17" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If authoring is disabled</p>
282
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2409">server/src/app.service.ts:2409</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="deleteuserartifact"><span>delete<wbr/>User<wbr/>Artifact</span><a href="#deleteuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="deleteuserartifact-1"><span class="tsd-kind-call-signature">deleteUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#deleteuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Permanently deletes a user artifact.</p>
273
283
  <p>Any agents that have the artifact attached will lose access to it after deletion.</p>
274
284
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">artifactId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The artifact's ID (from <a href="#listuserartifacts" class="tsd-kind-method">listUserArtifacts</a>)</p>
275
285
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><p><code>true</code> on success, <code>false</code> if no artifact with that ID exists</p>
276
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L3264">server/src/app.service.ts:3264</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="detachartifactfromagent"><span>detach<wbr/>Artifact<wbr/>From<wbr/>Agent</span><a href="#detachartifactfromagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="detachartifactfromagent-1"><span class="tsd-kind-call-signature">detachArtifactFromAgent</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#detachartifactfromagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Removes an artifact attachment from an agent.</p>
286
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3818">server/src/app.service.ts:3818</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="detachartifactfromagent"><span>detach<wbr/>Artifact<wbr/>From<wbr/>Agent</span><a href="#detachartifactfromagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="detachartifactfromagent-1"><span class="tsd-kind-call-signature">detachArtifactFromAgent</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#detachartifactfromagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Removes an artifact attachment from an agent.</p>
277
287
  <p>The artifact itself is not deleted - only the link between the agent and the artifact
278
288
  is removed. Changes are persisted immediately via <code>agent.save()</code>.</p>
279
289
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
280
290
  </div></li><li><span><span class="tsd-kind-parameter">artifactId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The artifact's ID to detach</p>
281
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-17">Throws<a href="#throws-17" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
282
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L3362">server/src/app.service.ts:3362</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="downloadstorymarkdown"><span>download<wbr/>Story<wbr/>Markdown</span><a href="#downloadstorymarkdown" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="downloadstorymarkdown-1"><span class="tsd-kind-call-signature">downloadStoryMarkdown</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span><a href="#downloadstorymarkdown-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Generates the full story as a single markdown document.</p>
291
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-18">Throws<a href="#throws-18" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
292
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3916">server/src/app.service.ts:3916</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="downloadstorymarkdown"><span>download<wbr/>Story<wbr/>Markdown</span><a href="#downloadstorymarkdown" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="downloadstorymarkdown-1"><span class="tsd-kind-call-signature">downloadStoryMarkdown</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span><a href="#downloadstorymarkdown-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Generates the full story as a single markdown document.</p>
283
293
  <p>Combines all chapters and room messages in narrative order.</p>
284
294
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
285
295
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The complete story formatted as markdown text</p>
286
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2827">server/src/app.service.ts:2827</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="editroom"><span>edit<wbr/>Room</span><a href="#editroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="editroom-1"><span class="tsd-kind-call-signature">editRoom</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">roomName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">goal</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">baseRoomDir</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">agentIds</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#editroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates the name, goal, and/or agent membership of an existing room.</p>
296
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3381">server/src/app.service.ts:3381</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="editroom"><span>edit<wbr/>Room</span><a href="#editroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="editroom-1"><span class="tsd-kind-call-signature">editRoom</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">roomName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">goal</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">baseRoomDir</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">agentIds</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">roomLeader</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">turnMode</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">RoomTurnMode</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">moderator</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#editroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates the name, goal, and/or agent membership of an existing room.</p>
287
297
  <p>Published room instances cannot be edited - edit the template instead.</p>
288
298
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
289
299
  </div></li><li><span><span class="tsd-kind-parameter">roomName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>New display name</p>
290
300
  </div></li><li><span><span class="tsd-kind-parameter">goal</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>New goal description</p>
291
301
  </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">baseRoomDir</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Optional override for the room's base storage directory</p>
292
- </div></li><li><span><span class="tsd-kind-parameter">agentIds</span>: <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> = []</span></span><div class="tsd-comment tsd-typography"><p>Replacement list of agent IDs (replaces current membership entirely)</p>
293
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-18">Throws<a href="#throws-18" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
294
- </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-19">Throws<a href="#throws-19" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If attempting to edit a published room instance</p>
295
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L721">server/src/app.service.ts:721</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="ensureagentstatecallback"><span>ensure<wbr/>Agent<wbr/>State<wbr/>Callback</span><a href="#ensureagentstatecallback" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="ensureagentstatecallback-1"><span class="tsd-kind-call-signature">ensureAgentStateCallback</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#ensureagentstatecallback-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Ensures the real-time state callback is registered for an agent.</p>
302
+ </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">agentIds</span>: <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span></span><div class="tsd-comment tsd-typography"><p>Replacement list of agent IDs (replaces current membership
303
+ entirely). Omit to leave membership unchanged, which is what the client
304
+ does: membership is managed through <a href="#createroomagent" class="tsd-kind-method">createRoomAgent</a> and
305
+ <a href="#removeroomagent" class="tsd-kind-method">removeRoomAgent</a>, not by re-sending the roster with every rename.</p>
306
+ </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">roomLeader</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Nickname (or name) of the member agent to lead the room.
307
+ Omit to leave the current leader unchanged.</p>
308
+ </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">turnMode</span>: <span class="tsd-signature-type">RoomTurnMode</span></span><div class="tsd-comment tsd-typography"><p>How the room chooses who responds. Omit to leave unchanged.
309
+ See RoomTurnMode.</p>
310
+ </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">moderator</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Nickname of the moderator agent. Omit to leave unchanged.</p>
311
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-19">Throws<a href="#throws-19" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
312
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-20">Throws<a href="#throws-20" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If attempting to edit a published room instance</p>
313
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L911">server/src/app.service.ts:911</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="ensureagentstatecallback"><span>ensure<wbr/>Agent<wbr/>State<wbr/>Callback</span><a href="#ensureagentstatecallback" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="ensureagentstatecallback-1"><span class="tsd-kind-call-signature">ensureAgentStateCallback</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#ensureagentstatecallback-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Ensures the real-time state callback is registered for an agent.</p>
296
314
  <p>Normally called automatically by <a href="#processtext" class="tsd-kind-method">processText</a> and <a href="#getagentmessages" class="tsd-kind-method">getAgentMessages</a>.
297
315
  Call this explicitly when connecting a new SSE client to an agent that was
298
316
  loaded from disk (not yet touched in this session).</p>
299
317
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
300
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2372">server/src/app.service.ts:2372</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="ensureroomstatecallback"><span>ensure<wbr/>Room<wbr/>State<wbr/>Callback</span><a href="#ensureroomstatecallback" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="ensureroomstatecallback-1"><span class="tsd-kind-call-signature">ensureRoomStateCallback</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#ensureroomstatecallback-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Ensures the real-time state callback is registered for a room.</p>
318
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2926">server/src/app.service.ts:2926</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="ensureroomstatecallback"><span>ensure<wbr/>Room<wbr/>State<wbr/>Callback</span><a href="#ensureroomstatecallback" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="ensureroomstatecallback-1"><span class="tsd-kind-call-signature">ensureRoomStateCallback</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#ensureroomstatecallback-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Ensures the real-time state callback is registered for a room.</p>
301
319
  <p>Normally called automatically. Call this explicitly when connecting a new
302
320
  SSE client to a room that was loaded from disk (not yet touched in this session).</p>
303
321
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
304
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2444">server/src/app.service.ts:2444</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="exportstorydata"><span>export<wbr/>Story<wbr/>Data</span><a href="#exportstorydata" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="exportstorydata-1"><span class="tsd-kind-call-signature">exportStoryData</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">filename</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">stream</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Readable</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#exportstorydata-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Exports the complete story data as a downloadable zip archive.</p>
322
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2998">server/src/app.service.ts:2998</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="exportstorydata"><span>export<wbr/>Story<wbr/>Data</span><a href="#exportstorydata" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="exportstorydata-1"><span class="tsd-kind-call-signature">exportStoryData</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">filename</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">stream</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Readable</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#exportstorydata-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Exports the complete story data as a downloadable zip archive.</p>
305
323
  <p>The archive can be re-imported via <a href="#importstoryfromzip" class="tsd-kind-method">importStoryFromZip</a>.</p>
306
324
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
307
325
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">filename</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">stream</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Readable</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with a <code>stream</code> (readable zip stream) and <code>filename</code> for the download</p>
308
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2839">server/src/app.service.ts:2839</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getagentdetails"><span>get<wbr/>Agent<wbr/>Details</span><a href="#getagentdetails" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getagentdetails-1"><span class="tsd-kind-call-signature">getAgentDetails</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">&gt;</span><a href="#getagentdetails-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns detailed metadata for a specific agent.</p>
326
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3393">server/src/app.service.ts:3393</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getagentdetails"><span>get<wbr/>Agent<wbr/>Details</span><a href="#getagentdetails" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getagentdetails-1"><span class="tsd-kind-call-signature">getAgentDetails</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">&gt;</span><a href="#getagentdetails-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns detailed metadata for a specific agent.</p>
309
327
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
310
328
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Agent metadata object, or <code>null</code> if no agent with the given ID exists</p>
311
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L626">server/src/app.service.ts:626</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getagenthistory"><span>get<wbr/>Agent<wbr/>History</span><a href="#getagenthistory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getagenthistory-1"><span class="tsd-kind-call-signature">getAgentHistory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#getagenthistory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the formatted conversation history for a specific character in a story.</p>
329
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L692">server/src/app.service.ts:692</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getagenthistory"><span>get<wbr/>Agent<wbr/>History</span><a href="#getagenthistory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getagenthistory-1"><span class="tsd-kind-call-signature">getAgentHistory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#getagenthistory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the formatted conversation history for a specific character in a story.</p>
312
330
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
313
331
  </div></li><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The character agent's ID</p>
314
332
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with <code>content</code> containing the formatted history text</p>
315
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2850">server/src/app.service.ts:2850</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getagentmessageemitter"><span>get<wbr/>Agent<wbr/>Message<wbr/>Emitter</span><a href="#getagentmessageemitter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getagentmessageemitter-1"><span class="tsd-kind-call-signature">getAgentMessageEmitter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><a href="#getagentmessageemitter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns a Node.js <code>EventEmitter</code> that fires whenever this agent's state changes
333
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3404">server/src/app.service.ts:3404</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getagentmessageemitter"><span>get<wbr/>Agent<wbr/>Message<wbr/>Emitter</span><a href="#getagentmessageemitter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getagentmessageemitter-1"><span class="tsd-kind-call-signature">getAgentMessageEmitter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><a href="#getagentmessageemitter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns a Node.js <code>EventEmitter</code> that fires whenever this agent's state changes
316
334
  (new message, token count update, etc.).</p>
317
335
  <p>Useful for building real-time UIs. Subscribe to the <code>'update'</code> event to receive
318
336
  agent state payloads without polling.</p>
319
337
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
320
338
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span></h4><p><code>EventEmitter</code> that emits <code>'update'</code> events with agent state payloads</p>
321
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-3">Example<a href="#example-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-6">const</span><span class="hl-1"> </span><span class="hl-7">emitter</span><span class="hl-1"> = </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">getAgentMessageEmitter</span><span class="hl-1">(</span><span class="hl-4">agent</span><span class="hl-1">.</span><span class="hl-4">id</span><span class="hl-1">);</span><br/><span class="hl-4">emitter</span><span class="hl-1">.</span><span class="hl-0">on</span><span class="hl-1">(</span><span class="hl-2">&#39;update&#39;</span><span class="hl-1">, (</span><span class="hl-4">state</span><span class="hl-1">) </span><span class="hl-6">=&gt;</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-4">console</span><span class="hl-1">.</span><span class="hl-0">log</span><span class="hl-1">(</span><span class="hl-2">&#39;New message:&#39;</span><span class="hl-1">, </span><span class="hl-4">state</span><span class="hl-1">.</span><span class="hl-4">latestMessage</span><span class="hl-1">);</span><br/><span class="hl-1">});</span>
339
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-2">Example<a href="#example-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-6">const</span><span class="hl-1"> </span><span class="hl-7">emitter</span><span class="hl-1"> = </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">getAgentMessageEmitter</span><span class="hl-1">(</span><span class="hl-4">agent</span><span class="hl-1">.</span><span class="hl-4">id</span><span class="hl-1">);</span><br/><span class="hl-4">emitter</span><span class="hl-1">.</span><span class="hl-0">on</span><span class="hl-1">(</span><span class="hl-2">&#39;update&#39;</span><span class="hl-1">, (</span><span class="hl-4">state</span><span class="hl-1">) </span><span class="hl-6">=&gt;</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-4">console</span><span class="hl-1">.</span><span class="hl-0">log</span><span class="hl-1">(</span><span class="hl-2">&#39;New message:&#39;</span><span class="hl-1">, </span><span class="hl-4">state</span><span class="hl-1">.</span><span class="hl-4">latestMessage</span><span class="hl-1">);</span><br/><span class="hl-1">});</span>
322
340
  </code><button type="button">Copy</button></pre>
323
341
 
324
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2359">server/src/app.service.ts:2359</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getagentmessages"><span>get<wbr/>Agent<wbr/>Messages</span><a href="#getagentmessages" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getagentmessages-1"><span class="tsd-kind-call-signature">getAgentMessages</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">AgentMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#getagentmessages-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns an agent's conversation history starting from a given index.</p>
342
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2913">server/src/app.service.ts:2913</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getagentmessages"><span>get<wbr/>Agent<wbr/>Messages</span><a href="#getagentmessages" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getagentmessages-1"><span class="tsd-kind-call-signature">getAgentMessages</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">AgentMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#getagentmessages-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns an agent's conversation history starting from a given index.</p>
325
343
  <p>Pass the <code>messageIndex</code> from a previous response as <code>fromIndex</code> to
326
344
  retrieve only new messages since the last poll.</p>
327
345
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
328
346
  </div></li><li><span><span class="tsd-kind-parameter">fromIndex</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> = 0</span></span><div class="tsd-comment tsd-typography"><p>Zero-based index to start from (default <code>0</code> returns all messages)</p>
329
347
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">AgentMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with the messages array and cumulative token/cost totals.
330
348
  Returns empty messages with zero counts if the agent is not found.</p>
331
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L885">server/src/app.service.ts:885</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getaiservicenames"><span>get<wbr/>Ai<wbr/>Service<wbr/>Names</span><a href="#getaiservicenames" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getaiservicenames-1"><span class="tsd-kind-call-signature">getAiServiceNames</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><a href="#getaiservicenames-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the names of all available AI service providers.</p>
349
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1296">server/src/app.service.ts:1296</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getaiservicenames"><span>get<wbr/>Ai<wbr/>Service<wbr/>Names</span><a href="#getaiservicenames" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getaiservicenames-1"><span class="tsd-kind-call-signature">getAiServiceNames</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><a href="#getaiservicenames-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the names of all available AI service providers.</p>
332
350
  <p>Only providers that have a configured API key are included.</p>
333
351
  </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span></h4><p>Array of provider names (e.g. <code>'Anthropic'</code>, <code>'OpenAI'</code>, <code>'GoogleAI'</code>)</p>
334
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L102">server/src/app.service.ts:102</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getbalance"><span>get<wbr/>Balance</span><a href="#getbalance" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getbalance-1"><span class="tsd-kind-call-signature">getBalance</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><a href="#getbalance-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the user's current credit balance in dollars.</p>
352
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L143">server/src/app.service.ts:143</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getbalance"><span>get<wbr/>Balance</span><a href="#getbalance" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getbalance-1"><span class="tsd-kind-call-signature">getBalance</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><a href="#getbalance-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the user's current credit balance in dollars.</p>
335
353
  <p>The balance is decremented automatically after each AI call based on token usage
336
354
  and any configured markup. Calls that would exceed the balance throw
337
355
  <code>InsufficientBalanceError</code> before the request is sent.</p>
338
356
  </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">number</span></h4><p>Current balance in dollars</p>
339
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2876">server/src/app.service.ts:2876</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getbalancemessageemitter"><span>get<wbr/>Balance<wbr/>Message<wbr/>Emitter</span><a href="#getbalancemessageemitter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getbalancemessageemitter-1"><span class="tsd-kind-call-signature">getBalanceMessageEmitter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">userId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><a href="#getbalancemessageemitter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns a Node.js <code>EventEmitter</code> that fires whenever the user's balance changes.</p>
357
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3430">server/src/app.service.ts:3430</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getbalancemessageemitter"><span>get<wbr/>Balance<wbr/>Message<wbr/>Emitter</span><a href="#getbalancemessageemitter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getbalancemessageemitter-1"><span class="tsd-kind-call-signature">getBalanceMessageEmitter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">userId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><a href="#getbalancemessageemitter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns a Node.js <code>EventEmitter</code> that fires whenever the user's balance changes.</p>
340
358
  <p>Subscribe to the <code>'update'</code> event to push real-time balance updates to a connected
341
359
  client (e.g. via SSE) without polling.</p>
342
360
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">userId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The user's ID (typically the same ID used with <code>getAppService</code>)</p>
343
361
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">EventEmitter</span></h4><p><code>EventEmitter</code> that emits <code>'update'</code> events with the new balance value</p>
344
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2432">server/src/app.service.ts:2432</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getchapter"><span>get<wbr/>Chapter</span><a href="#getchapter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getchapter-1"><span class="tsd-kind-call-signature">getChapter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../classes/RoomMessage.html" class="tsd-signature-type tsd-kind-class">RoomMessage</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#getchapter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the messages from a specific chapter checkpoint.</p>
362
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2986">server/src/app.service.ts:2986</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getchapter"><span>get<wbr/>Chapter</span><a href="#getchapter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getchapter-1"><span class="tsd-kind-call-signature">getChapter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../classes/RoomMessage.html" class="tsd-signature-type tsd-kind-class">RoomMessage</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#getchapter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the messages from a specific chapter checkpoint.</p>
345
363
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
346
364
  </div></li><li><span><span class="tsd-kind-parameter">chapterIndex</span>: <span class="tsd-signature-type">number</span></span><div class="tsd-comment tsd-typography"><p>The chapter number (1-based, as returned by <a href="#listchapters" class="tsd-kind-method">listChapters</a>)</p>
347
365
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../classes/RoomMessage.html" class="tsd-signature-type tsd-kind-class">RoomMessage</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of room messages from that chapter</p>
348
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2716">server/src/app.service.ts:2716</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getcharacter"><span>get<wbr/>Character</span><a href="#getcharacter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getcharacter-1"><span class="tsd-kind-call-signature">getCharacter</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#getcharacter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the profile for a specific character.</p>
366
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3270">server/src/app.service.ts:3270</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getcharacter"><span>get<wbr/>Character</span><a href="#getcharacter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getcharacter-1"><span class="tsd-kind-call-signature">getCharacter</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#getcharacter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the profile for a specific character.</p>
349
367
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
350
368
  </div></li><li><span><span class="tsd-kind-parameter">characterName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The character's name</p>
351
369
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with <code>content</code> containing the character profile markdown</p>
352
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2766">server/src/app.service.ts:2766</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getcharacterinventory"><span>get<wbr/>Character<wbr/>Inventory</span><a href="#getcharacterinventory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getcharacterinventory-1"><span class="tsd-kind-call-signature">getCharacterInventory</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#getcharacterinventory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the inventory for a specific character.</p>
370
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3320">server/src/app.service.ts:3320</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getcharacterinventory"><span>get<wbr/>Character<wbr/>Inventory</span><a href="#getcharacterinventory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getcharacterinventory-1"><span class="tsd-kind-call-signature">getCharacterInventory</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#getcharacterinventory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the inventory for a specific character.</p>
353
371
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
354
372
  </div></li><li><span><span class="tsd-kind-parameter">characterName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The character's name</p>
355
373
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with <code>content</code> containing the inventory markdown</p>
356
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2789">server/src/app.service.ts:2789</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getplotplan"><span>get<wbr/>Plot<wbr/>Plan</span><a href="#getplotplan" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getplotplan-1"><span class="tsd-kind-call-signature">getPlotPlan</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#getplotplan-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the story's plot plan.</p>
374
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3343">server/src/app.service.ts:3343</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getplotplan"><span>get<wbr/>Plot<wbr/>Plan</span><a href="#getplotplan" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getplotplan-1"><span class="tsd-kind-call-signature">getPlotPlan</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#getplotplan-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the story's plot plan.</p>
357
375
  <p>The plot plan is a room artifact generated by the narrator at story creation
358
376
  and updated as the story progresses.</p>
359
377
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
360
378
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with <code>content</code> containing the plot plan markdown</p>
361
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2814">server/src/app.service.ts:2814</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getpromptfile"><span>get<wbr/>Prompt<wbr/>File</span><a href="#getpromptfile" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getpromptfile-1"><span class="tsd-kind-call-signature">getPromptFile</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFileContent.html" class="tsd-signature-type tsd-kind-interface">PromptFileContent</a><a href="#getpromptfile-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Reads a prompt file, applying the 4-level fallback resolution:
379
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3368">server/src/app.service.ts:3368</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getpromptfile"><span>get<wbr/>Prompt<wbr/>File</span><a href="#getpromptfile" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getpromptfile-1"><span class="tsd-kind-call-signature">getPromptFile</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFileContent.html" class="tsd-signature-type tsd-kind-interface">PromptFileContent</a><a href="#getpromptfile-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Reads a prompt file, applying the 4-level fallback resolution:
362
380
  <code>user/{folder}</code> --&gt; <code>user/root</code> --&gt; <code>common/{folder}</code> --&gt; <code>common/root</code>.</p>
363
381
  <p>The returned object includes a <code>scope</code> field (<code>'user'</code> or <code>'common'</code>) indicating
364
382
  which directory the file was found in. Returns <code>{ content: '' }</code> if the file
@@ -366,40 +384,52 @@ does not exist in any location.</p>
366
384
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">folderName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Prompt folder name, or <code>'shared'</code> for the root prompts directory</p>
367
385
  </div></li><li><span><span class="tsd-kind-parameter">fileName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Base name of the prompt file (with or without <code>.prompt</code>/<code>.json</code> extension)</p>
368
386
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="PromptFileContent.html" class="tsd-signature-type tsd-kind-interface">PromptFileContent</a></h4><p><code>{ content, scope }</code> where <code>scope</code> is omitted when the file is not found</p>
369
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1505">server/src/app.service.ts:1505</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getpublishedinstances"><span>get<wbr/>Published<wbr/>Instances</span><a href="#getpublishedinstances" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getpublishedinstances-1"><span class="tsd-kind-call-signature">getPublishedInstances</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#getpublishedinstances-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all published instances created from a template agent.</p>
387
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1948">server/src/app.service.ts:1948</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getpromptfolderdefaults"><span>get<wbr/>Prompt<wbr/>Folder<wbr/>Defaults</span><a href="#getpromptfolderdefaults" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getpromptfolderdefaults-1"><span class="tsd-kind-call-signature">getPromptFolderDefaults</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">PromptFolderDefaultsResponse</span><a href="#getpromptfolderdefaults-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Reads a prompt folder's <code>defaults_config.json</code> — the agent settings the create-agent
388
+ form pre-fills when that folder is chosen.</p>
389
+ <p>Resolved through the same 4-level fallback as any other prompt file, so a user copy
390
+ overrides the shipped one and a file at the prompts root supplies defaults for every
391
+ folder that has none of its own.</p>
392
+ <p>A missing file and an unparseable one both return <code>{ defaults: {} }</code>: defaults are a
393
+ convenience, and a folder must stay usable when its config is broken. Unparseable is
394
+ logged; missing is not, since most folders have no config at all.</p>
395
+ <p>Every field is coerced to its declared type and unknown keys are dropped, so a typo
396
+ in a hand-edited file cannot ride through to the create-agent request.</p>
397
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">folderName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Prompt folder name, or <code>'shared'</code> for the root prompts directory</p>
398
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">PromptFolderDefaultsResponse</span></h4><p>The declared defaults, and the scope the file was read from</p>
399
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2010">server/src/app.service.ts:2010</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getpublishedinstances"><span>get<wbr/>Published<wbr/>Instances</span><a href="#getpublishedinstances" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getpublishedinstances-1"><span class="tsd-kind-call-signature">getPublishedInstances</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#getpublishedinstances-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all published instances created from a template agent.</p>
370
400
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">templateId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>ID of the template agent</p>
371
401
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of agent metadata objects for each published instance</p>
372
402
  <div class="tsd-comment tsd-typography"><div class="tsd-tag-see"><h4 class="tsd-anchor-link" id="see">See<a href="#see" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p><a href="#publishagentinstance" class="tsd-kind-method">publishAgentInstance</a></p>
373
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1110">server/src/app.service.ts:1110</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getpublishedroominstances"><span>get<wbr/>Published<wbr/>Room<wbr/>Instances</span><a href="#getpublishedroominstances" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getpublishedroominstances-1"><span class="tsd-kind-call-signature">getPublishedRoomInstances</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#getpublishedroominstances-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all published instances created from a template room.</p>
403
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1531">server/src/app.service.ts:1531</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getpublishedroominstances"><span>get<wbr/>Published<wbr/>Room<wbr/>Instances</span><a href="#getpublishedroominstances" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getpublishedroominstances-1"><span class="tsd-kind-call-signature">getPublishedRoomInstances</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#getpublishedroominstances-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all published instances created from a template room.</p>
374
404
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">templateId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>ID of the template room</p>
375
405
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of room summary objects for each published instance</p>
376
406
  <div class="tsd-comment tsd-typography"><div class="tsd-tag-see"><h4 class="tsd-anchor-link" id="see-1">See<a href="#see-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p><a href="#publishroom" class="tsd-kind-method">publishRoom</a></p>
377
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1284">server/src/app.service.ts:1284</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getrandomstoryidea"><span>get<wbr/>Random<wbr/>Story<wbr/>Idea</span><a href="#getrandomstoryidea" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getrandomstoryidea-1"><span class="tsd-kind-call-signature">getRandomStoryIdea</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="StoryIdea.html" class="tsd-signature-type tsd-kind-interface">StoryIdea</a><a href="#getrandomstoryidea-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns a random story idea from a randomly selected genre.</p>
407
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1728">server/src/app.service.ts:1728</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getrandomstoryidea"><span>get<wbr/>Random<wbr/>Story<wbr/>Idea</span><a href="#getrandomstoryidea" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getrandomstoryidea-1"><span class="tsd-kind-call-signature">getRandomStoryIdea</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="StoryIdea.html" class="tsd-signature-type tsd-kind-interface">StoryIdea</a><a href="#getrandomstoryidea-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns a random story idea from a randomly selected genre.</p>
378
408
  </div><h4 class="tsd-returns-title">Returns <a href="StoryIdea.html" class="tsd-signature-type tsd-kind-interface">StoryIdea</a></h4><p>A random <code>StoryIdea</code> object, or <code>null</code> if no genres/ideas are available</p>
379
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L253">server/src/app.service.ts:253</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getrandomstoryideabygenre"><span>get<wbr/>Random<wbr/>Story<wbr/>Idea<wbr/>By<wbr/>Genre</span><a href="#getrandomstoryideabygenre" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getrandomstoryideabygenre-1"><span class="tsd-kind-call-signature">getRandomStoryIdeaByGenre</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">genreName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="StoryIdea.html" class="tsd-signature-type tsd-kind-interface">StoryIdea</a><a href="#getrandomstoryideabygenre-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns a random story idea from the specified genre.</p>
409
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L294">server/src/app.service.ts:294</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getrandomstoryideabygenre"><span>get<wbr/>Random<wbr/>Story<wbr/>Idea<wbr/>By<wbr/>Genre</span><a href="#getrandomstoryideabygenre" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getrandomstoryideabygenre-1"><span class="tsd-kind-call-signature">getRandomStoryIdeaByGenre</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">genreName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="StoryIdea.html" class="tsd-signature-type tsd-kind-interface">StoryIdea</a><a href="#getrandomstoryideabygenre-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns a random story idea from the specified genre.</p>
380
410
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">genreName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Genre name as returned by <a href="#liststorygenres" class="tsd-kind-method">listStoryGenres</a> (e.g. <code>'fantasy'</code>)</p>
381
411
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="StoryIdea.html" class="tsd-signature-type tsd-kind-interface">StoryIdea</a></h4><p>A random <code>StoryIdea</code> object, or <code>null</code> if the genre file is empty</p>
382
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-20">Throws<a href="#throws-20" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the genre does not exist</p>
383
- </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-21">Throws<a href="#throws-21" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the genre file cannot be read</p>
384
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L217">server/src/app.service.ts:217</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getroomartifacts"><span>get<wbr/>Room<wbr/>Artifacts</span><a href="#getroomartifacts" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getroomartifacts-1"><span class="tsd-kind-call-signature">getRoomArtifacts</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">artifacts</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#getroomartifacts-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all artifacts published in a room.</p>
412
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-21">Throws<a href="#throws-21" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the genre does not exist</p>
413
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-22">Throws<a href="#throws-22" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the genre file cannot be read</p>
414
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L258">server/src/app.service.ts:258</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getroomartifacts"><span>get<wbr/>Room<wbr/>Artifacts</span><a href="#getroomartifacts" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getroomartifacts-1"><span class="tsd-kind-call-signature">getRoomArtifacts</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">artifacts</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#getroomartifacts-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all artifacts published in a room.</p>
385
415
  <p>Artifacts are collaborative documents created by agents via the <code>'publish'</code> action.</p>
386
416
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
387
417
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">artifacts</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with an <code>artifacts</code> array. Returns <code>{ artifacts: [] }</code> if the room is not found.</p>
388
418
  <div class="tsd-comment tsd-typography"><div class="tsd-tag-see"><h4 class="tsd-anchor-link" id="see-2">See<a href="#see-2" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p><a href="#publishartifact" class="tsd-kind-method">publishArtifact</a></p>
389
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1628">server/src/app.service.ts:1628</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getroombyid"><span>get<wbr/>Room<wbr/>By<wbr/>Id</span><a href="#getroombyid" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getroombyid-1"><span class="tsd-kind-call-signature">getRoomById</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../classes/Room.html" class="tsd-signature-type tsd-kind-class">Room</a><span class="tsd-signature-symbol">&gt;</span><a href="#getroombyid-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the raw <code>Room</code> object for a given ID.</p>
419
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2169">server/src/app.service.ts:2169</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getroombyid"><span>get<wbr/>Room<wbr/>By<wbr/>Id</span><a href="#getroombyid" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getroombyid-1"><span class="tsd-kind-call-signature">getRoomById</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../classes/Room.html" class="tsd-signature-type tsd-kind-class">Room</a><span class="tsd-signature-symbol">&gt;</span><a href="#getroombyid-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the raw <code>Room</code> object for a given ID.</p>
390
420
  <p>Use <a href="#getroomdetails" class="tsd-kind-method">getRoomDetails</a> for a plain metadata object. This method exposes
391
421
  the full <code>Room</code> instance, which is useful for advanced operations.</p>
392
422
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
393
423
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../classes/Room.html" class="tsd-signature-type tsd-kind-class">Room</a><span class="tsd-signature-symbol">&gt;</span></h4><p>The <code>Room</code> instance, or <code>null</code> if not found</p>
394
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L813">server/src/app.service.ts:813</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getroomdetails"><span>get<wbr/>Room<wbr/>Details</span><a href="#getroomdetails" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getroomdetails-1"><span class="tsd-kind-call-signature">getRoomDetails</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomDetails.html" class="tsd-signature-type tsd-kind-interface">RoomDetails</a><span class="tsd-signature-symbol">&gt;</span><a href="#getroomdetails-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns full details for a room, including the metadata of each member agent.</p>
424
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1224">server/src/app.service.ts:1224</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getroomdetails"><span>get<wbr/>Room<wbr/>Details</span><a href="#getroomdetails" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getroomdetails-1"><span class="tsd-kind-call-signature">getRoomDetails</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomDetails.html" class="tsd-signature-type tsd-kind-interface">RoomDetails</a><span class="tsd-signature-symbol">&gt;</span><a href="#getroomdetails-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns full details for a room, including the metadata of each member agent.</p>
395
425
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
396
426
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomDetails.html" class="tsd-signature-type tsd-kind-interface">RoomDetails</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Room details object, or <code>null</code> if no room with the given ID exists</p>
397
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L775">server/src/app.service.ts:775</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getroommessageemitter"><span>get<wbr/>Room<wbr/>Message<wbr/>Emitter</span><a href="#getroommessageemitter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getroommessageemitter-1"><span class="tsd-kind-call-signature">getRoomMessageEmitter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><a href="#getroommessageemitter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns a Node.js <code>EventEmitter</code> that fires whenever a new message arrives in the room.</p>
427
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1180">server/src/app.service.ts:1180</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getroommessageemitter"><span>get<wbr/>Room<wbr/>Message<wbr/>Emitter</span><a href="#getroommessageemitter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getroommessageemitter-1"><span class="tsd-kind-call-signature">getRoomMessageEmitter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><a href="#getroommessageemitter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns a Node.js <code>EventEmitter</code> that fires whenever a new message arrives in the room.</p>
398
428
  <p>Subscribe to the <code>'update'</code> event to receive room message payloads in real time
399
429
  without polling.</p>
400
430
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
401
431
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span></h4><p><code>EventEmitter</code> that emits <code>'update'</code> events with room message payloads</p>
402
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2419">server/src/app.service.ts:2419</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getroommessages"><span>get<wbr/>Room<wbr/>Messages</span><a href="#getroommessages" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getroommessages-1"><span class="tsd-kind-call-signature">getRoomMessages</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">includeThoughts</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">RoomMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#getroommessages-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns messages from a room's conversation log starting from a given index.</p>
432
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2973">server/src/app.service.ts:2973</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getroommessages"><span>get<wbr/>Room<wbr/>Messages</span><a href="#getroommessages" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getroommessages-1"><span class="tsd-kind-call-signature">getRoomMessages</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">includeThoughts</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">RoomMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#getroommessages-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns messages from a room's conversation log starting from a given index.</p>
403
433
  <p>Pass the index of the last message you received as <code>fromIndex</code> to poll for
404
434
  new messages only.</p>
405
435
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
@@ -408,14 +438,14 @@ new messages only.</p>
408
438
  normally hidden (agents' internal reasoning). Default <code>false</code>.</p>
409
439
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">RoomMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with the messages array and total cost across all agents.
410
440
  Returns empty messages with zero cost if the room is not found.</p>
411
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L849">server/src/app.service.ts:849</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstoryartifact"><span>get<wbr/>Story<wbr/>Artifact</span><a href="#getstoryartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstoryartifact-1"><span class="tsd-kind-call-signature">getStoryArtifact</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ArrayBufferLike</span><span class="tsd-signature-symbol">&gt;</span><a href="#getstoryartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the content of a specific story artifact.</p>
441
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1260">server/src/app.service.ts:1260</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstoryartifact"><span>get<wbr/>Story<wbr/>Artifact</span><a href="#getstoryartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstoryartifact-1"><span class="tsd-kind-call-signature">getStoryArtifact</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ArrayBufferLike</span><span class="tsd-signature-symbol">&gt;</span><a href="#getstoryartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the content of a specific story artifact.</p>
412
442
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
413
443
  </div></li><li><span><span class="tsd-kind-parameter">artifactId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The artifact's ID (from <a href="#liststoryartifacts" class="tsd-kind-method">listStoryArtifacts</a>)</p>
414
444
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ArrayBufferLike</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The artifact content as a string or Buffer, or <code>null</code> if not found</p>
415
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L3298">server/src/app.service.ts:3298</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstoryinfo"><span>get<wbr/>Story<wbr/>Info</span><a href="#getstoryinfo" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstoryinfo-1"><span class="tsd-kind-call-signature">getStoryInfo</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><a href="#getstoryinfo-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns metadata for a specific story.</p>
445
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3852">server/src/app.service.ts:3852</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstoryinfo"><span>get<wbr/>Story<wbr/>Info</span><a href="#getstoryinfo" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstoryinfo-1"><span class="tsd-kind-call-signature">getStoryInfo</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><a href="#getstoryinfo-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns metadata for a specific story.</p>
416
446
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
417
447
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Story metadata, or <code>undefined</code> if not found</p>
418
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2611">server/src/app.service.ts:2611</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstorymessageemitter"><span>get<wbr/>Story<wbr/>Message<wbr/>Emitter</span><a href="#getstorymessageemitter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstorymessageemitter-1"><span class="tsd-kind-call-signature">getStoryMessageEmitter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><a href="#getstorymessageemitter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the <code>EventEmitter</code> for real-time story updates.</p>
448
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3165">server/src/app.service.ts:3165</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstorymessageemitter"><span>get<wbr/>Story<wbr/>Message<wbr/>Emitter</span><a href="#getstorymessageemitter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstorymessageemitter-1"><span class="tsd-kind-call-signature">getStoryMessageEmitter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><a href="#getstorymessageemitter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the <code>EventEmitter</code> for real-time story updates.</p>
419
449
  <p>The emitter fires four named events. Each payload includes a <code>timestamp</code> field.</p>
420
450
  <hr>
421
451
  <p><strong><code>'story-state'</code></strong> - <a href="StoryStateEvent.html" class="tsd-kind-interface">StoryStateEvent</a>
@@ -455,11 +485,11 @@ Check <code>event.errorType === 'InsufficientBalanceError'</code> for balance fa
455
485
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
456
486
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span></h4><p><code>EventEmitter</code> emitting <code>'story-state'</code>, <code>'suggest-introduce-character'</code>,
457
487
  <code>'suggest-progress-chapter'</code>, and <code>'story-error'</code> events</p>
458
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2337">server/src/app.service.ts:2337</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstorymessages"><span>get<wbr/>Story<wbr/>Messages</span><a href="#getstorymessages" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstorymessages-1"><span class="tsd-kind-call-signature">getStoryMessages</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">RoomMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#getstorymessages-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Gets messages from a story's room starting from a specific index</p>
488
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2891">server/src/app.service.ts:2891</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstorymessages"><span>get<wbr/>Story<wbr/>Messages</span><a href="#getstorymessages" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstorymessages-1"><span class="tsd-kind-call-signature">getStoryMessages</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fromIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">RoomMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#getstorymessages-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Gets messages from a story's room starting from a specific index</p>
459
489
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story ID</p>
460
490
  </div></li><li><span><span class="tsd-kind-parameter">fromIndex</span>: <span class="tsd-signature-type">number</span></span><div class="tsd-comment tsd-typography"><p>The index to start from (0-based)</p>
461
491
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomMessagesResponse.html" class="tsd-signature-type tsd-kind-interface">RoomMessagesResponse</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of indexed messages and total story cost</p>
462
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L915">server/src/app.service.ts:915</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstoryprogressemitter"><span>get<wbr/>Story<wbr/>Progress<wbr/>Emitter</span><a href="#getstoryprogressemitter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstoryprogressemitter-1"><span class="tsd-kind-call-signature">getStoryProgressEmitter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><a href="#getstoryprogressemitter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the <code>EventEmitter</code> for tracking background story work.</p>
492
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1326">server/src/app.service.ts:1326</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstoryprogressemitter"><span>get<wbr/>Story<wbr/>Progress<wbr/>Emitter</span><a href="#getstoryprogressemitter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstoryprogressemitter-1"><span class="tsd-kind-call-signature">getStoryProgressEmitter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><a href="#getstoryprogressemitter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the <code>EventEmitter</code> for tracking background story work.</p>
463
493
  <p>Subscribe to the <code>'progress'</code> event. Each event payload is
464
494
  <code>{ step: string, message: string, timestamp: number }</code>.</p>
465
495
  <p><strong><code>step</code> values emitted after <a href="#createstory" class="tsd-kind-method">createStory</a> returns:</strong></p>
@@ -492,39 +522,39 @@ in real time. After <code>'ready'</code>, a background job continues:</p>
492
522
  so this method returns <code>undefined</code> once a terminal step has fired.</p>
493
523
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
494
524
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">EventEmitter</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span></h4><p><code>EventEmitter</code> emitting <code>'progress'</code> events, or <code>undefined</code> if already complete</p>
495
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2280">server/src/app.service.ts:2280</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstorystate"><span>get<wbr/>Story<wbr/>State</span><a href="#getstorystate" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstorystate-1"><span class="tsd-kind-call-signature">getStoryState</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryState.html" class="tsd-signature-type tsd-kind-interface">StoryState</a><span class="tsd-signature-symbol">&gt;</span><a href="#getstorystate-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the current runtime state of a story.</p>
525
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2834">server/src/app.service.ts:2834</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getstorystate"><span>get<wbr/>Story<wbr/>State</span><a href="#getstorystate" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getstorystate-1"><span class="tsd-kind-call-signature">getStoryState</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryState.html" class="tsd-signature-type tsd-kind-interface">StoryState</a><span class="tsd-signature-symbol">&gt;</span><a href="#getstorystate-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the current runtime state of a story.</p>
496
526
  <p>Includes messages, pending message count, processing status, and story metadata.
497
527
  Useful for restoring UI state after reconnecting.</p>
498
528
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
499
529
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryState.html" class="tsd-signature-type tsd-kind-interface">StoryState</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Full story state object</p>
500
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2601">server/src/app.service.ts:2601</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="gettransactionbypaymentid"><span>get<wbr/>Transaction<wbr/>By<wbr/>Payment<wbr/>Id</span><a href="#gettransactionbypaymentid" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="gettransactionbypaymentid-1"><span class="tsd-kind-call-signature">getTransactionByPaymentId</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Transaction.html" class="tsd-signature-type tsd-kind-interface">Transaction</a><span class="tsd-signature-symbol">&gt;</span><a href="#gettransactionbypaymentid-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Retrieves a single transaction by its payment provider ID.</p>
530
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3155">server/src/app.service.ts:3155</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="gettransactionbypaymentid"><span>get<wbr/>Transaction<wbr/>By<wbr/>Payment<wbr/>Id</span><a href="#gettransactionbypaymentid" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="gettransactionbypaymentid-1"><span class="tsd-kind-call-signature">getTransactionByPaymentId</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Transaction.html" class="tsd-signature-type tsd-kind-interface">Transaction</a><span class="tsd-signature-symbol">&gt;</span><a href="#gettransactionbypaymentid-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Retrieves a single transaction by its payment provider ID.</p>
501
531
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">paymentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The payment provider ID used when the transaction was recorded</p>
502
532
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Transaction.html" class="tsd-signature-type tsd-kind-interface">Transaction</a><span class="tsd-signature-symbol">&gt;</span></h4><p>The matching <code>Transaction</code>, or <code>null</code> if not found</p>
503
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2933">server/src/app.service.ts:2933</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="gettransactions"><span>get<wbr/>Transactions</span><a href="#gettransactions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="gettransactions-1"><span class="tsd-kind-call-signature">getTransactions</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">limit</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">offset</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="TransactionHistoryResponse.html" class="tsd-signature-type tsd-kind-interface">TransactionHistoryResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#gettransactions-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns paginated transaction history for this user, sorted newest-first.</p>
533
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3487">server/src/app.service.ts:3487</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="gettransactions"><span>get<wbr/>Transactions</span><a href="#gettransactions" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="gettransactions-1"><span class="tsd-kind-call-signature">getTransactions</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">limit</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">offset</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="TransactionHistoryResponse.html" class="tsd-signature-type tsd-kind-interface">TransactionHistoryResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#gettransactions-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns paginated transaction history for this user, sorted newest-first.</p>
504
534
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">limit</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> = 50</span></span><div class="tsd-comment tsd-typography"><p>Maximum number of records to return (default: 50)</p>
505
535
  </div></li><li><span><span class="tsd-kind-parameter">offset</span>: <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> = 0</span></span><div class="tsd-comment tsd-typography"><p>Number of records to skip for pagination (default: 0)</p>
506
536
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="TransactionHistoryResponse.html" class="tsd-signature-type tsd-kind-interface">TransactionHistoryResponse</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with a <code>transactions</code> array and a <code>total</code> count</p>
507
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2944">server/src/app.service.ts:2944</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getuserartifact"><span>get<wbr/>User<wbr/>Artifact</span><a href="#getuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getuserartifact-1"><span class="tsd-kind-call-signature">getUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ArrayBufferLike</span><span class="tsd-signature-symbol">&gt;</span><a href="#getuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the content of a user artifact.</p>
537
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3498">server/src/app.service.ts:3498</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getuserartifact"><span>get<wbr/>User<wbr/>Artifact</span><a href="#getuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getuserartifact-1"><span class="tsd-kind-call-signature">getUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ArrayBufferLike</span><span class="tsd-signature-symbol">&gt;</span><a href="#getuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the content of a user artifact.</p>
508
538
  <p>Text artifacts are returned as <code>string</code>; binary artifacts (e.g. converted PDFs
509
539
  in intermediate state) may be returned as <code>Buffer</code>.</p>
510
540
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">artifactId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The artifact's ID (from <a href="#listuserartifacts" class="tsd-kind-method">listUserArtifacts</a>)</p>
511
541
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ArrayBufferLike</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The artifact content, or <code>null</code> if no artifact with that ID exists</p>
512
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2975">server/src/app.service.ts:2975</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getuserpreferences"><span>get<wbr/>User<wbr/>Preferences</span><a href="#getuserpreferences" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getuserpreferences-1"><span class="tsd-kind-call-signature">getUserPreferences</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><a href="#getuserpreferences-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the user's stored preferences object.</p>
542
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3529">server/src/app.service.ts:3529</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getuserpreferences"><span>get<wbr/>User<wbr/>Preferences</span><a href="#getuserpreferences" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getuserpreferences-1"><span class="tsd-kind-call-signature">getUserPreferences</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><a href="#getuserpreferences-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the user's stored preferences object.</p>
513
543
  <p>Preferences are application-defined - Briyah stores and returns them as-is.
514
544
  Returns <code>{}</code> if no preferences have been saved yet.</p>
515
545
  </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">any</span></h4><p>The preferences object previously written by <a href="#saveuserpreferences" class="tsd-kind-method">saveUserPreferences</a>,
516
546
  or an empty object if none exist</p>
517
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1360">server/src/app.service.ts:1360</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getuserpromptsdir"><span>get<wbr/>User<wbr/>Prompts<wbr/>Dir</span><a href="#getuserpromptsdir" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getuserpromptsdir-1"><span class="tsd-kind-call-signature">getUserPromptsDir</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><a href="#getuserpromptsdir-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the user prompts directory for this AppService's user.
547
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1803">server/src/app.service.ts:1803</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="getuserpromptsdir"><span>get<wbr/>User<wbr/>Prompts<wbr/>Dir</span><a href="#getuserpromptsdir" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="getuserpromptsdir-1"><span class="tsd-kind-call-signature">getUserPromptsDir</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><a href="#getuserpromptsdir-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the user prompts directory for this AppService's user.
518
548
  Used by the library copy flow to know where to write copied prompt folders.</p>
519
- </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1673">server/src/app.service.ts:1673</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="importstoryfromzip"><span>import<wbr/>Story<wbr/>From<wbr/>Zip</span><a href="#importstoryfromzip" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="importstoryfromzip-1"><span class="tsd-kind-call-signature">importStoryFromZip</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">zipBuffer</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><a href="#importstoryfromzip-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Reconstructs a story from a previously exported zip archive.</p>
549
+ </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2214">server/src/app.service.ts:2214</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="importstoryfromzip"><span>import<wbr/>Story<wbr/>From<wbr/>Zip</span><a href="#importstoryfromzip" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="importstoryfromzip-1"><span class="tsd-kind-call-signature">importStoryFromZip</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">zipBuffer</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Buffer</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span><a href="#importstoryfromzip-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Reconstructs a story from a previously exported zip archive.</p>
520
550
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">zipBuffer</span>: <span class="tsd-signature-type">Buffer</span></span><div class="tsd-comment tsd-typography"><p>Raw bytes of the zip file produced by <a href="#exportstorydata" class="tsd-kind-method">exportStoryData</a></p>
521
551
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Story metadata for the newly imported story</p>
522
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2238">server/src/app.service.ts:2238</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="interruptstory"><span>interrupt<wbr/>Story</span><a href="#interruptstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="interruptstory-1"><span class="tsd-kind-call-signature">interruptStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#interruptstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Cancels any pending AI turns and forces the human's turn.</p>
552
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2792">server/src/app.service.ts:2792</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="interruptstory"><span>interrupt<wbr/>Story</span><a href="#interruptstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="interruptstory-1"><span class="tsd-kind-call-signature">interruptStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#interruptstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Cancels any pending AI turns and forces the human's turn.</p>
523
553
  <p>Drops the room's pending message queue and pauses processing so the
524
554
  human-controlled agent becomes the current speaker. Any in-flight LLM
525
555
  calls (perceive or moderator) will discard their responses on return.</p>
526
556
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
527
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2640">server/src/app.service.ts:2640</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="introducecharactertostory"><span>introduce<wbr/>Character<wbr/>To<wbr/>Story</span><a href="#introducecharactertostory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="introducecharactertostory-1"><span class="tsd-kind-call-signature">introduceCharacterToStory</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">description</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">storyModel</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fromNarratorSuggestion</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#introducecharactertostory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Adds a new AI character to an existing story.</p>
557
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3194">server/src/app.service.ts:3194</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="introducecharactertostory"><span>introduce<wbr/>Character<wbr/>To<wbr/>Story</span><a href="#introducecharactertostory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="introducecharactertostory-1"><span class="tsd-kind-call-signature">introduceCharacterToStory</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">description</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">storyModel</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fromNarratorSuggestion</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#introducecharactertostory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Adds a new AI character to an existing story.</p>
528
558
  <p>Creates a character agent and integrates it into the story's room.
529
559
  The character profile is generated by the AI based on the provided description.</p>
530
560
  <p>When <a href="#getstorymessageemitter" class="tsd-kind-method">getStoryMessageEmitter</a> fires a <code>'suggestion'</code> update with
@@ -536,108 +566,119 @@ To reject it instead, call <a href="#declinecharacter" class="tsd-kind-method">d
536
566
  </div></li><li><span><span class="tsd-kind-parameter">description</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Brief description of the character's personality and role</p>
537
567
  </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">storyModel</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Optional model override from <code>story_models.json</code></p>
538
568
  </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">fromNarratorSuggestion</span>: <span class="tsd-signature-type">boolean</span></span><div class="tsd-comment tsd-typography"><p>Set <code>true</code> when accepting a narrator <code>'suggestion'</code> update. Default <code>false</code>.</p>
539
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2661">server/src/app.service.ts:2661</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listagentartifacts"><span>list<wbr/>Agent<wbr/>Artifacts</span><a href="#listagentartifacts" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listagentartifacts-1"><span class="tsd-kind-call-signature">listAgentArtifacts</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listagentartifacts-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns metadata for all artifacts currently attached to an agent.</p>
569
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3215">server/src/app.service.ts:3215</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listagentartifacts"><span>list<wbr/>Agent<wbr/>Artifacts</span><a href="#listagentartifacts" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listagentartifacts-1"><span class="tsd-kind-call-signature">listAgentArtifacts</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listagentartifacts-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns metadata for all artifacts currently attached to an agent.</p>
540
570
  <p>Attached artifacts are included in the agent's context on every prompt, allowing
541
571
  the agent to reference their content. Use <a href="#attachartifacttoagent" class="tsd-kind-method">attachArtifactToAgent</a> and
542
572
  <a href="#detachartifactfromagent" class="tsd-kind-method">detachArtifactFromAgent</a> to manage attachments.</p>
543
573
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
544
574
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of artifact metadata objects for the agent's attached artifacts</p>
545
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-22">Throws<a href="#throws-22" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
546
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L3314">server/src/app.service.ts:3314</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listagents"><span>list<wbr/>Agents</span><a href="#listagents" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listagents-1"><span class="tsd-kind-call-signature">listAgents</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listagents-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists all top-level agents belonging to this user.</p>
575
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-23">Throws<a href="#throws-23" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
576
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3868">server/src/app.service.ts:3868</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listagents"><span>list<wbr/>Agents</span><a href="#listagents" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listagents-1"><span class="tsd-kind-call-signature">listAgents</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">includeRoomAgents</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listagents-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists all top-level agents belonging to this user.</p>
547
577
  <p>Agents that are owned by a room or story are excluded - use
548
578
  <a href="#getroomdetails" class="tsd-kind-method">getRoomDetails</a> or story methods to access those agents.</p>
549
- </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of agent metadata objects</p>
550
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L585">server/src/app.service.ts:585</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listaimodels"><span>list<wbr/>Ai<wbr/>Models</span><a href="#listaimodels" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listaimodels-1"><span class="tsd-kind-call-signature">listAiModels</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">aiServiceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ModelInfo.html" class="tsd-signature-type tsd-kind-interface">ModelInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listaimodels-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Fetches available models from the specified AI service provider.</p>
579
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">includeRoomAgents</span>: <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = false</span></span><div class="tsd-comment tsd-typography"><p>Also return the agents owned by a room or story.
580
+ Only for offering an existing agent as something to copy; the agent list a
581
+ user manages is the default, unowned one.</p>
582
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of agent metadata objects</p>
583
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L649">server/src/app.service.ts:649</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listaimodels"><span>list<wbr/>Ai<wbr/>Models</span><a href="#listaimodels" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listaimodels-1"><span class="tsd-kind-call-signature">listAiModels</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">aiServiceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ModelInfo.html" class="tsd-signature-type tsd-kind-interface">ModelInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listaimodels-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Fetches available models from the specified AI service provider.</p>
551
584
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">aiServiceName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Provider name as returned by <a href="#getaiservicenames" class="tsd-kind-method">getAiServiceNames</a></p>
552
585
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ModelInfo.html" class="tsd-signature-type tsd-kind-interface">ModelInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of model descriptors including name, description, and service</p>
553
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L126">server/src/app.service.ts:126</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listattachedfiles"><span>list<wbr/>Attached<wbr/>Files</span><a href="#listattachedfiles" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listattachedfiles-1"><span class="tsd-kind-call-signature">listAttachedFiles</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="FileList.html" class="tsd-signature-type tsd-kind-interface">FileList</a><span class="tsd-signature-symbol">&gt;</span><a href="#listattachedfiles-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists the files currently attached to an agent.</p>
586
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L167">server/src/app.service.ts:167</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listattachedfiles"><span>list<wbr/>Attached<wbr/>Files</span><a href="#listattachedfiles" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listattachedfiles-1"><span class="tsd-kind-call-signature">listAttachedFiles</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="FileList.html" class="tsd-signature-type tsd-kind-interface">FileList</a><span class="tsd-signature-symbol">&gt;</span><a href="#listattachedfiles-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists the files currently attached to an agent.</p>
554
587
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
555
588
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="FileList.html" class="tsd-signature-type tsd-kind-interface">FileList</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with a <code>files</code> array of file names. Returns <code>{ files: [] }</code> if the agent is not found.</p>
556
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1887">server/src/app.service.ts:1887</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listchapters"><span>list<wbr/>Chapters</span><a href="#listchapters" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listchapters-1"><span class="tsd-kind-call-signature">listChapters</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">chapters</span><span class="tsd-signature-symbol">:</span> <a href="ChapterInfo.html" class="tsd-signature-type tsd-kind-interface">ChapterInfo</a><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">}</span><a href="#listchapters-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all chapter checkpoints for a story.</p>
589
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2441">server/src/app.service.ts:2441</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listchapters"><span>list<wbr/>Chapters</span><a href="#listchapters" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listchapters-1"><span class="tsd-kind-call-signature">listChapters</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">chapters</span><span class="tsd-signature-symbol">:</span> <a href="ChapterInfo.html" class="tsd-signature-type tsd-kind-interface">ChapterInfo</a><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">}</span><a href="#listchapters-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all chapter checkpoints for a story.</p>
557
590
  <p>Chapters are created by <a href="#progressstory" class="tsd-kind-method">progressStory</a> and can be read with <a href="#getchapter" class="tsd-kind-method">getChapter</a>.</p>
558
591
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
559
592
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">chapters</span><span class="tsd-signature-symbol">:</span> <a href="ChapterInfo.html" class="tsd-signature-type tsd-kind-interface">ChapterInfo</a><span class="tsd-signature-symbol">[]</span> <span class="tsd-signature-symbol">}</span></h4><p>Object with a <code>chapters</code> array of chapter info objects</p>
560
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2704">server/src/app.service.ts:2704</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listcharacters"><span>list<wbr/>Characters</span><a href="#listcharacters" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listcharacters-1"><span class="tsd-kind-call-signature">listCharacters</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Character.html" class="tsd-signature-type tsd-kind-interface">Character</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listcharacters-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all current characters in a story.</p>
593
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3258">server/src/app.service.ts:3258</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listcharacters"><span>list<wbr/>Characters</span><a href="#listcharacters" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listcharacters-1"><span class="tsd-kind-call-signature">listCharacters</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Character.html" class="tsd-signature-type tsd-kind-interface">Character</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listcharacters-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all current characters in a story.</p>
561
594
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
562
595
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Character.html" class="tsd-signature-type tsd-kind-interface">Character</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of character objects (derived from the story's room agents)</p>
563
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2755">server/src/app.service.ts:2755</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listimagemodels"><span>list<wbr/>Image<wbr/>Models</span><a href="#listimagemodels" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listimagemodels-1"><span class="tsd-kind-call-signature">listImageModels</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ImageModelOption</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listimagemodels-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns models available for image generation, as configured in
596
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3309">server/src/app.service.ts:3309</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listimagemodels"><span>list<wbr/>Image<wbr/>Models</span><a href="#listimagemodels" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listimagemodels-1"><span class="tsd-kind-call-signature">listImageModels</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ImageModelOption</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listimagemodels-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns models available for image generation, as configured in
564
597
  <code>common/config/image_models.json</code>.</p>
565
598
  </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">ImageModelOption</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of model descriptors. Returns an empty array if the config file is missing.</p>
566
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L137">server/src/app.service.ts:137</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listnativetoolsummaries"><span>list<wbr/>Native<wbr/>Tool<wbr/>Summaries</span><a href="#listnativetoolsummaries" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listnativetoolsummaries-1"><span class="tsd-kind-call-signature">listNativeToolSummaries</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="ToolSummary.html" class="tsd-signature-type tsd-kind-interface">ToolSummary</a><span class="tsd-signature-symbol">[]</span><a href="#listnativetoolsummaries-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists native (host-registered) tools as code-free summaries. These are
599
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L178">server/src/app.service.ts:178</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listnativetoolsummaries"><span>list<wbr/>Native<wbr/>Tool<wbr/>Summaries</span><a href="#listnativetoolsummaries" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listnativetoolsummaries-1"><span class="tsd-kind-call-signature">listNativeToolSummaries</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="ToolSummary.html" class="tsd-signature-type tsd-kind-interface">ToolSummary</a><span class="tsd-signature-symbol">[]</span><a href="#listnativetoolsummaries-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists native (host-registered) tools as code-free summaries. These are
567
600
  grantable to agents but not editable through the API.</p>
568
601
  </div><h4 class="tsd-returns-title">Returns <a href="ToolSummary.html" class="tsd-signature-type tsd-kind-interface">ToolSummary</a><span class="tsd-signature-symbol">[]</span></h4><p>Array of native tool summaries</p>
569
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1805">server/src/app.service.ts:1805</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listpromptfiles"><span>list<wbr/>Prompt<wbr/>Files</span><a href="#listpromptfiles" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listpromptfiles-1"><span class="tsd-kind-call-signature">listPromptFiles</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="FileList.html" class="tsd-signature-type tsd-kind-interface">FileList</a><a href="#listpromptfiles-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the names of all prompt files in a folder, merged from both the common
602
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2358">server/src/app.service.ts:2358</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listpromptfiles"><span>list<wbr/>Prompt<wbr/>Files</span><a href="#listpromptfiles" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listpromptfiles-1"><span class="tsd-kind-call-signature">listPromptFiles</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="FileList.html" class="tsd-signature-type tsd-kind-interface">FileList</a><a href="#listpromptfiles-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the names of all prompt files in a folder, merged from both the common
570
603
  and user prompt directories.</p>
571
604
  <p>Pass <code>'shared'</code> as <code>folderName</code> to list files in the root prompts directory.
572
605
  Files that exist in both directories appear once in the result.</p>
573
606
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">folderName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Folder to list, or <code>'shared'</code> for the root prompts directory</p>
574
607
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="FileList.html" class="tsd-signature-type tsd-kind-interface">FileList</a></h4><p>Object with a <code>files</code> array of base names (no extension), sorted alphabetically</p>
575
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1395">server/src/app.service.ts:1395</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listpromptfileswithscope"><span>list<wbr/>Prompt<wbr/>Files<wbr/>With<wbr/>Scope</span><a href="#listpromptfileswithscope" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listpromptfileswithscope-1"><span class="tsd-kind-call-signature">listPromptFilesWithScope</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFilesResponse.html" class="tsd-signature-type tsd-kind-interface">PromptFilesResponse</a><a href="#listpromptfileswithscope-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns prompt file names in a folder annotated with their origin scope.</p>
608
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1838">server/src/app.service.ts:1838</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listpromptfileswithscope"><span>list<wbr/>Prompt<wbr/>Files<wbr/>With<wbr/>Scope</span><a href="#listpromptfileswithscope" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listpromptfileswithscope-1"><span class="tsd-kind-call-signature">listPromptFilesWithScope</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFilesResponse.html" class="tsd-signature-type tsd-kind-interface">PromptFilesResponse</a><a href="#listpromptfileswithscope-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns prompt file names in a folder annotated with their origin scope.</p>
576
609
  <p>When the same file name exists in both the common and user directories,
577
610
  the user copy wins and the entry is reported as <code>scope: 'user'</code>.
578
611
  Pass <code>'shared'</code> as <code>folderName</code> to list files in the root prompts directory.</p>
579
612
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">folderName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Folder to list, or <code>'shared'</code> for the root prompts directory</p>
580
613
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="PromptFilesResponse.html" class="tsd-signature-type tsd-kind-interface">PromptFilesResponse</a></h4><p>Object with a <code>files</code> array of <code>{ name, scope }</code> entries, sorted alphabetically</p>
581
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1446">server/src/app.service.ts:1446</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listpromptfolders"><span>list<wbr/>Prompt<wbr/>Folders</span><a href="#listpromptfolders" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listpromptfolders-1"><span class="tsd-kind-call-signature">listPromptFolders</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><a href="#listpromptfolders-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the union of prompt folder names from both the common and user prompt directories.</p>
614
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1889">server/src/app.service.ts:1889</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listpromptfolders"><span>list<wbr/>Prompt<wbr/>Folders</span><a href="#listpromptfolders" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listpromptfolders-1"><span class="tsd-kind-call-signature">listPromptFolders</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><a href="#listpromptfolders-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the union of prompt folder names from both the common and user prompt directories.</p>
582
615
  <p>Use this to discover available prompt folders before calling <a href="#listpromptfiles" class="tsd-kind-method">listPromptFiles</a>.
583
616
  If a folder exists in both directories it appears once in the result.</p>
584
617
  </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span></h4><p>Sorted array of folder names</p>
585
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L441">server/src/app.service.ts:441</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listpromptfolderswithscope"><span>list<wbr/>Prompt<wbr/>Folders<wbr/>With<wbr/>Scope</span><a href="#listpromptfolderswithscope" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listpromptfolderswithscope-1"><span class="tsd-kind-call-signature">listPromptFoldersWithScope</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">scope</span><span class="tsd-signature-symbol">?:</span> <a href="../types/PromptScope.html" class="tsd-signature-type tsd-kind-type-alias">PromptScope</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFoldersResponse.html" class="tsd-signature-type tsd-kind-interface">PromptFoldersResponse</a><a href="#listpromptfolderswithscope-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns prompt folder names annotated with their origin scope (<code>'common'</code> or <code>'user'</code>).</p>
618
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L502">server/src/app.service.ts:502</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listpromptfolderswithscope"><span>list<wbr/>Prompt<wbr/>Folders<wbr/>With<wbr/>Scope</span><a href="#listpromptfolderswithscope" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listpromptfolderswithscope-1"><span class="tsd-kind-call-signature">listPromptFoldersWithScope</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">scope</span><span class="tsd-signature-symbol">?:</span> <a href="../types/PromptScope.html" class="tsd-signature-type tsd-kind-type-alias">PromptScope</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="PromptFoldersResponse.html" class="tsd-signature-type tsd-kind-interface">PromptFoldersResponse</a><a href="#listpromptfolderswithscope-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns prompt folder names annotated with their origin scope (<code>'common'</code> or <code>'user'</code>).</p>
586
619
  <p>When the same folder name exists in both directories, the user copy wins and the
587
620
  entry is reported as <code>scope: 'user'</code>.</p>
588
621
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">scope</span>: <a href="../types/PromptScope.html" class="tsd-signature-type tsd-kind-type-alias">PromptScope</a></span><div class="tsd-comment tsd-typography"><p>Optional filter: <code>'common'</code> returns only system-provided folders,
589
622
  <code>'user'</code> returns only user-created folders, omit to return all</p>
590
623
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="PromptFoldersResponse.html" class="tsd-signature-type tsd-kind-interface">PromptFoldersResponse</a></h4><p>Object with a <code>folders</code> array of <code>{ name, scope }</code> entries, sorted by name</p>
591
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L473">server/src/app.service.ts:473</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listprompts"><span>list<wbr/>Prompts</span><a href="#listprompts" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listprompts-1"><span class="tsd-kind-call-signature">listPrompts</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listprompts-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all prepared prompt template names available to a specific agent.</p>
624
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L534">server/src/app.service.ts:534</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listprompts"><span>list<wbr/>Prompts</span><a href="#listprompts" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listprompts-1"><span class="tsd-kind-call-signature">listPrompts</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listprompts-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all prepared prompt template names available to a specific agent.</p>
592
625
  <p>Merges prompts from the agent's own prompt folder and the root prompts directory,
593
626
  deduplicating across both. These names can be passed to <a href="#runpreparedprompt" class="tsd-kind-method">runPreparedPrompt</a>.</p>
594
627
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
595
628
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of prompt template names (without file extension)</p>
596
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-23">Throws<a href="#throws-23" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
597
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L517">server/src/app.service.ts:517</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listpublishedagents"><span>list<wbr/>Published<wbr/>Agents</span><a href="#listpublishedagents" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listpublishedagents-1"><span class="tsd-kind-call-signature">listPublishedAgents</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listpublishedagents-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists all published agent instances belonging to this user.</p>
629
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-24">Throws<a href="#throws-24" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
630
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L578">server/src/app.service.ts:578</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listpublishedagents"><span>list<wbr/>Published<wbr/>Agents</span><a href="#listpublishedagents" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listpublishedagents-1"><span class="tsd-kind-call-signature">listPublishedAgents</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listpublishedagents-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists all published agent instances belonging to this user.</p>
598
631
  <p>Published agents are clones of template agents that are accessible
599
632
  via the public API (e.g. for end-users to chat with). Agents owned
600
633
  by rooms are excluded from this list.</p>
601
634
  </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="AgentInfo.html" class="tsd-signature-type tsd-kind-interface">AgentInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of agent metadata objects for all published instances</p>
602
635
  <div class="tsd-comment tsd-typography"><div class="tsd-tag-see"><h4 class="tsd-anchor-link" id="see-3">See<a href="#see-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p><a href="#publishagentinstance" class="tsd-kind-method">publishAgentInstance</a></p>
603
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1167">server/src/app.service.ts:1167</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listrooms"><span>list<wbr/>Rooms</span><a href="#listrooms" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listrooms-1"><span class="tsd-kind-call-signature">listRooms</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listrooms-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists all rooms belonging to this user.</p>
636
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1589">server/src/app.service.ts:1589</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listpublishedrooms"><span>list<wbr/>Published<wbr/>Rooms</span><a href="#listpublishedrooms" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listpublishedrooms-1"><span class="tsd-kind-call-signature">listPublishedRooms</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listpublishedrooms-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists every published room instance this user owns.</p>
637
+ <p>The room counterpart to <a href="#listpublishedagents" class="tsd-kind-method">listPublishedAgents</a>, and the only view of
638
+ them that is not filtered by which template they came from — a published
639
+ room is a live public link, and the point of the list is seeing all of them
640
+ and what they have cost.</p>
641
+ </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of room summary objects, one per published instance</p>
642
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1743">server/src/app.service.ts:1743</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listrooms"><span>list<wbr/>Rooms</span><a href="#listrooms" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listrooms-1"><span class="tsd-kind-call-signature">listRooms</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listrooms-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists the rooms this user builds and owns.</p>
643
+ <p>Published instances are excluded — use <a href="#getpublishedroominstances" class="tsd-kind-method">getPublishedRoomInstances</a> for
644
+ those, which is also how the client reaches them.</p>
604
645
  </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="RoomInfo.html" class="tsd-signature-type tsd-kind-interface">RoomInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of room summary objects (id, name, goal, agent count)</p>
605
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L765">server/src/app.service.ts:765</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="liststories"><span>list<wbr/>Stories</span><a href="#liststories" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="liststories-1"><span class="tsd-kind-call-signature">listStories</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">[]</span><a href="#liststories-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists all stories belonging to this user.</p>
646
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1170">server/src/app.service.ts:1170</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="liststories"><span>list<wbr/>Stories</span><a href="#liststories" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="liststories-1"><span class="tsd-kind-call-signature">listStories</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">[]</span><a href="#liststories-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists all stories belonging to this user.</p>
606
647
  </div><h4 class="tsd-returns-title">Returns <a href="StoryInfo.html" class="tsd-signature-type tsd-kind-interface">StoryInfo</a><span class="tsd-signature-symbol">[]</span></h4><p>Array of story metadata objects</p>
607
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2490">server/src/app.service.ts:2490</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="liststoryartifacts"><span>list<wbr/>Story<wbr/>Artifacts</span><a href="#liststoryartifacts" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="liststoryartifacts-1"><span class="tsd-kind-call-signature">listStoryArtifacts</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><a href="#liststoryartifacts-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all artifacts associated with a story.</p>
648
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3044">server/src/app.service.ts:3044</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="liststoryartifacts"><span>list<wbr/>Story<wbr/>Artifacts</span><a href="#liststoryartifacts" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="liststoryartifacts-1"><span class="tsd-kind-call-signature">listStoryArtifacts</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><a href="#liststoryartifacts-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns all artifacts associated with a story.</p>
608
649
  <p>Story artifacts include the plot plan and any documents published by agents
609
650
  during the narrative.</p>
610
651
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
611
652
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span></h4><p>Array of artifact metadata objects</p>
612
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L3286">server/src/app.service.ts:3286</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="liststorygenres"><span>list<wbr/>Story<wbr/>Genres</span><a href="#liststorygenres" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="liststorygenres-1"><span class="tsd-kind-call-signature">listStoryGenres</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><a href="#liststorygenres-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the available story genre names.</p>
653
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3840">server/src/app.service.ts:3840</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="liststorygenres"><span>list<wbr/>Story<wbr/>Genres</span><a href="#liststorygenres" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="liststorygenres-1"><span class="tsd-kind-call-signature">listStoryGenres</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><a href="#liststorygenres-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns the available story genre names.</p>
613
654
  <p>Genres are read from <code>common/story_ideas/</code> - each <code>.json</code> file corresponds to a genre.
614
655
  Pass a genre name to <a href="#getrandomstoryideabygenre" class="tsd-kind-method">getRandomStoryIdeaByGenre</a> to get a story idea.</p>
615
656
  </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span></h4><p>Array of genre names (e.g. <code>['fantasy', 'sci-fi', 'mystery']</code>)</p>
616
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L187">server/src/app.service.ts:187</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="liststorymodels"><span>list<wbr/>Story<wbr/>Models</span><a href="#liststorymodels" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="liststorymodels-1"><span class="tsd-kind-call-signature">listStoryModels</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ModelInfo.html" class="tsd-signature-type tsd-kind-interface">ModelInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#liststorymodels-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns models available for story generation, as configured in
657
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L228">server/src/app.service.ts:228</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="liststorymodels"><span>list<wbr/>Story<wbr/>Models</span><a href="#liststorymodels" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="liststorymodels-1"><span class="tsd-kind-call-signature">listStoryModels</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ModelInfo.html" class="tsd-signature-type tsd-kind-interface">ModelInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#liststorymodels-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns models available for story generation, as configured in
617
658
  <code>common/config/story_models.json</code>.</p>
618
659
  </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ModelInfo.html" class="tsd-signature-type tsd-kind-interface">ModelInfo</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of model descriptors. Returns an empty array if the config file is missing.</p>
619
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L166">server/src/app.service.ts:166</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listtools"><span>list<wbr/>Tools</span><a href="#listtools" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listtools-1"><span class="tsd-kind-call-signature">listTools</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listtools-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists user-authored tools (with code). Empty when authoring is disabled.</p>
660
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L207">server/src/app.service.ts:207</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listtools"><span>list<wbr/>Tools</span><a href="#listtools" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listtools-1"><span class="tsd-kind-call-signature">listTools</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span><a href="#listtools-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Lists user-authored tools (with code). Empty when authoring is disabled.</p>
620
661
  </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Array of user-authored tool definitions</p>
621
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1794">server/src/app.service.ts:1794</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listuserartifacts"><span>list<wbr/>User<wbr/>Artifacts</span><a href="#listuserartifacts" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listuserartifacts-1"><span class="tsd-kind-call-signature">listUserArtifacts</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><a href="#listuserartifacts-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns metadata for all artifacts owned by this user.</p>
662
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2347">server/src/app.service.ts:2347</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="listuserartifacts"><span>list<wbr/>User<wbr/>Artifacts</span><a href="#listuserartifacts" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="listuserartifacts-1"><span class="tsd-kind-call-signature">listUserArtifacts</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span><a href="#listuserartifacts-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Returns metadata for all artifacts owned by this user.</p>
622
663
  <p>Artifacts are persistent named documents that can be attached to agents
623
664
  (see <a href="#attachartifacttoagent" class="tsd-kind-method">attachArtifactToAgent</a>) or shared with rooms via the <code>'publish'</code> action.
624
665
  Use <a href="#getuserartifact" class="tsd-kind-method">getUserArtifact</a> to retrieve the actual content.</p>
625
666
  </div><h4 class="tsd-returns-title">Returns <a href="ArtifactMetadata.html" class="tsd-signature-type tsd-kind-interface">ArtifactMetadata</a><span class="tsd-signature-symbol">[]</span></h4><p>Array of artifact metadata objects (ID, name, creation date, etc.)</p>
626
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2962">server/src/app.service.ts:2962</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="pauseroom"><span>pause<wbr/>Room</span><a href="#pauseroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="pauseroom-1"><span class="tsd-kind-call-signature">pauseRoom</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#pauseroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Pauses message processing in a room.</p>
667
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3516">server/src/app.service.ts:3516</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="pauseroom"><span>pause<wbr/>Room</span><a href="#pauseroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="pauseroom-1"><span class="tsd-kind-call-signature">pauseRoom</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#pauseroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Pauses message processing in a room.</p>
627
668
  <p>Pending messages remain in the queue. Call <a href="#resumeroom" class="tsd-kind-method">resumeRoom</a> to continue processing.</p>
628
669
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
629
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-24">Throws<a href="#throws-24" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
630
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1016">server/src/app.service.ts:1016</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="processtext"><span>process<wbr/>Text</span><a href="#processtext" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="processtext-1"><span class="tsd-kind-call-signature">processText</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">text</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ProcessTextResponse.html" class="tsd-signature-type tsd-kind-interface">ProcessTextResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#processtext-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Sends a text prompt to an agent and returns its response.</p>
670
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-25">Throws<a href="#throws-25" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
671
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1437">server/src/app.service.ts:1437</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="processtext"><span>process<wbr/>Text</span><a href="#processtext" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="processtext-1"><span class="tsd-kind-call-signature">processText</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">text</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ProcessTextResponse.html" class="tsd-signature-type tsd-kind-interface">ProcessTextResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#processtext-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Sends a text prompt to an agent and returns its response.</p>
631
672
  <p>The exchange is added to the agent's conversation history and persisted to disk.</p>
632
673
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID (from <a href="#createagent" class="tsd-kind-method">createAgent</a> or <a href="#listagents" class="tsd-kind-method">listAgents</a>)</p>
633
674
  </div></li><li><span><span class="tsd-kind-parameter">text</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The prompt text to send</p>
634
675
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ProcessTextResponse.html" class="tsd-signature-type tsd-kind-interface">ProcessTextResponse</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Object containing the agent's reply text (<code>result</code>), the latest formatted
635
676
  message, its index in the history, and cumulative token counts and cost</p>
636
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-25">Throws<a href="#throws-25" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
637
- </div><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-4">Example<a href="#example-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-6">const</span><span class="hl-1"> </span><span class="hl-7">result</span><span class="hl-1"> = </span><span class="hl-3">await</span><span class="hl-1"> </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">processText</span><span class="hl-1">(</span><span class="hl-4">agent</span><span class="hl-1">.</span><span class="hl-4">id</span><span class="hl-1">, </span><span class="hl-2">&#39;What is the capital of France?&#39;</span><span class="hl-1">);</span><br/><span class="hl-4">console</span><span class="hl-1">.</span><span class="hl-0">log</span><span class="hl-1">(</span><span class="hl-4">result</span><span class="hl-1">.</span><span class="hl-4">result</span><span class="hl-1">); </span><span class="hl-5">// &#39;Paris&#39;</span><br/><span class="hl-4">console</span><span class="hl-1">.</span><span class="hl-0">log</span><span class="hl-1">(</span><span class="hl-4">result</span><span class="hl-1">.</span><span class="hl-4">totalCost</span><span class="hl-1">); </span><span class="hl-5">// e.g. 0.000023</span>
677
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-26">Throws<a href="#throws-26" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
678
+ </div><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-3">Example<a href="#example-3" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-6">const</span><span class="hl-1"> </span><span class="hl-7">result</span><span class="hl-1"> = </span><span class="hl-3">await</span><span class="hl-1"> </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">processText</span><span class="hl-1">(</span><span class="hl-4">agent</span><span class="hl-1">.</span><span class="hl-4">id</span><span class="hl-1">, </span><span class="hl-2">&#39;What is the capital of France?&#39;</span><span class="hl-1">);</span><br/><span class="hl-4">console</span><span class="hl-1">.</span><span class="hl-0">log</span><span class="hl-1">(</span><span class="hl-4">result</span><span class="hl-1">.</span><span class="hl-4">result</span><span class="hl-1">); </span><span class="hl-5">// &#39;Paris&#39;</span><br/><span class="hl-4">console</span><span class="hl-1">.</span><span class="hl-0">log</span><span class="hl-1">(</span><span class="hl-4">result</span><span class="hl-1">.</span><span class="hl-4">totalCost</span><span class="hl-1">); </span><span class="hl-5">// e.g. 0.000023</span>
638
679
  </code><button type="button">Copy</button></pre>
639
680
 
640
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L365">server/src/app.service.ts:365</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="progressstory"><span>progress<wbr/>Story</span><a href="#progressstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="progressstory-1"><span class="tsd-kind-call-signature">progressStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#progressstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Advances the story to the next chapter.</p>
681
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L426">server/src/app.service.ts:426</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="progressstory"><span>progress<wbr/>Story</span><a href="#progressstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="progressstory-1"><span class="tsd-kind-call-signature">progressStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#progressstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Advances the story to the next chapter.</p>
641
682
  <p>Creates a checkpoint of the current chapter state and rebuilds the opening scene.
642
683
  The story is <strong>immediately playable when this Promise resolves</strong> - the <code>'ready'</code>
643
684
  progress event fires just before the function returns, so awaiting this call is
@@ -649,7 +690,7 @@ independently on demand when it individually reaches the compaction threshold
649
690
  (see <a href="#compactstory" class="tsd-kind-method">compactStory</a> for manual compaction).</p>
650
691
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
651
692
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with the new <code>chapterIndex</code></p>
652
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2588">server/src/app.service.ts:2588</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="publishagentinstance"><span>publish<wbr/>Agent<wbr/>Instance</span><a href="#publishagentinstance" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="publishagentinstance-1"><span class="tsd-kind-call-signature">publishAgentInstance</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">instanceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">publicUrl</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#publishagentinstance-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a publicly accessible clone of a template agent.</p>
693
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3142">server/src/app.service.ts:3142</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="publishagentinstance"><span>publish<wbr/>Agent<wbr/>Instance</span><a href="#publishagentinstance" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="publishagentinstance-1"><span class="tsd-kind-call-signature">publishAgentInstance</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">instanceName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">publicUrl</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span><a href="#publishagentinstance-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a publicly accessible clone of a template agent.</p>
653
694
  <p>The new instance is independent of the template's conversation history.
654
695
  Multiple instances can be created from a single template. Use
655
696
  <a href="#resetpublishedinstance" class="tsd-kind-method">resetPublishedInstance</a> to restore an instance to the template's
@@ -657,12 +698,12 @@ current state.</p>
657
698
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">templateId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>ID of the template agent to clone</p>
658
699
  </div></li><li><span><span class="tsd-kind-parameter">instanceName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Display name for the new instance</p>
659
700
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-symbol">{</span> <span class="tsd-kind-property">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span> <span class="tsd-kind-property">publicUrl</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span> <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with the new <code>instanceId</code> and the <code>publicUrl</code> path</p>
660
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-26">Throws<a href="#throws-26" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the template agent does not exist</p>
701
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-27">Throws<a href="#throws-27" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the template agent does not exist</p>
661
702
  </div><div class="tsd-tag-see"><h4 class="tsd-anchor-link" id="see-4">See<a href="#see-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><ul>
662
703
  <li><a href="#getpublishedinstances" class="tsd-kind-method">getPublishedInstances</a></li>
663
704
  <li><a href="#resetpublishedinstance" class="tsd-kind-method">resetPublishedInstance</a></li>
664
705
  </ul>
665
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1076">server/src/app.service.ts:1076</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="publishartifact"><span>publish<wbr/>Artifact</span><a href="#publishartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="publishartifact-1"><span class="tsd-kind-call-signature">publishArtifact</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">creator</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">body</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">viewers</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#publishartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Programmatically publishes an artifact to a room.</p>
706
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1497">server/src/app.service.ts:1497</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="publishartifact"><span>publish<wbr/>Artifact</span><a href="#publishartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="publishartifact-1"><span class="tsd-kind-call-signature">publishArtifact</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">creator</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">body</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">viewers</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#publishartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Programmatically publishes an artifact to a room.</p>
666
707
  <p>This is the imperative equivalent of an agent sending a <code>'publish'</code> action message.
667
708
  Agents in the room can read and reference the artifact in subsequent prompts.</p>
668
709
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
@@ -670,17 +711,17 @@ Agents in the room can read and reference the artifact in subsequent prompts.</p
670
711
  </div></li><li><span><span class="tsd-kind-parameter">creator</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Display name of the creator</p>
671
712
  </div></li><li><span><span class="tsd-kind-parameter">body</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The artifact's text content</p>
672
713
  </div></li><li><span><span class="tsd-kind-parameter">viewers</span>: <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> = []</span></span><div class="tsd-comment tsd-typography"><p>Agent names that can view this artifact (empty array = all agents)</p>
673
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-27">Throws<a href="#throws-27" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
674
- </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-28">Throws<a href="#throws-28" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If <code>name</code> is empty</p>
675
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1656">server/src/app.service.ts:1656</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="publishroom"><span>publish<wbr/>Room</span><a href="#publishroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="publishroom-1"><span class="tsd-kind-call-signature">publishRoom</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">publishedName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">userId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span><a href="#publishroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a publicly accessible clone of a template room.</p>
714
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-28">Throws<a href="#throws-28" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
715
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-29">Throws<a href="#throws-29" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If <code>name</code> is empty</p>
716
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2197">server/src/app.service.ts:2197</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="publishroom"><span>publish<wbr/>Room</span><a href="#publishroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="publishroom-1"><span class="tsd-kind-call-signature">publishRoom</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">templateId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">publishedName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">userId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span><a href="#publishroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Creates a publicly accessible clone of a template room.</p>
676
717
  <p>The instance is a full copy of the template including all agents.
677
718
  Use <a href="#resetpublishedroominstance" class="tsd-kind-method">resetPublishedRoomInstance</a> to restore it to the template's state.</p>
678
719
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">templateId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>ID of the template room to clone</p>
679
720
  </div></li><li><span><span class="tsd-kind-parameter">publishedName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Display name for the instance (defaults to the template's name)</p>
680
721
  </div></li><li><span><span class="tsd-kind-parameter">userId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The owning user's ID (used for public access mapping)</p>
681
722
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The new instance's room ID</p>
682
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-29">Throws<a href="#throws-29" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the template room does not exist</p>
683
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1256">server/src/app.service.ts:1256</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="recordtransaction"><span>record<wbr/>Transaction</span><a href="#recordtransaction" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="recordtransaction-1"><span class="tsd-kind-call-signature">recordTransaction</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">amount</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">status</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">&quot;pending&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;succeeded&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;failed&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;cancelled&quot;</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Transaction.html" class="tsd-signature-type tsd-kind-interface">Transaction</a><span class="tsd-signature-symbol">&gt;</span><a href="#recordtransaction-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Records a new payment transaction.</p>
723
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-30">Throws<a href="#throws-30" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the template room does not exist</p>
724
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1679">server/src/app.service.ts:1679</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="recordtransaction"><span>record<wbr/>Transaction</span><a href="#recordtransaction" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="recordtransaction-1"><span class="tsd-kind-call-signature">recordTransaction</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">amount</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">status</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">&quot;pending&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;succeeded&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;failed&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;cancelled&quot;</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Transaction.html" class="tsd-signature-type tsd-kind-interface">Transaction</a><span class="tsd-signature-symbol">&gt;</span><a href="#recordtransaction-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Records a new payment transaction.</p>
684
725
  <p>Call this when your payment provider confirms a payment has been initiated.
685
726
  The <code>paymentId</code> should be the unique identifier issued by your payment provider
686
727
  (e.g. a Stripe Payment Intent ID). Use <a href="#updatetransactionstatus" class="tsd-kind-method">updateTransactionStatus</a> to update
@@ -689,86 +730,93 @@ the status once the provider confirms success or failure.</p>
689
730
  </div></li><li><span><span class="tsd-kind-parameter">paymentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Unique payment identifier from your payment provider</p>
690
731
  </div></li><li><span><span class="tsd-kind-parameter">status</span>: <span class="tsd-signature-type">&quot;pending&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;succeeded&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;failed&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;cancelled&quot;</span><span class="tsd-signature-symbol"> = &#39;pending&#39;</span></span><div class="tsd-comment tsd-typography"><p>Initial status; defaults to <code>'pending'</code></p>
691
732
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="Transaction.html" class="tsd-signature-type tsd-kind-interface">Transaction</a><span class="tsd-signature-symbol">&gt;</span></h4><p>The created <code>Transaction</code> record</p>
692
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2904">server/src/app.service.ts:2904</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="reloadagent"><span>reload<wbr/>Agent</span><a href="#reloadagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="reloadagent-1"><span class="tsd-kind-call-signature">reloadAgent</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#reloadagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Clears an agent's conversation history while preserving its configuration
733
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3458">server/src/app.service.ts:3458</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="reloadagent"><span>reload<wbr/>Agent</span><a href="#reloadagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="reloadagent-1"><span class="tsd-kind-call-signature">reloadAgent</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#reloadagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Clears an agent's conversation history while preserving its configuration
693
734
  and re-attaching any previously uploaded files.</p>
694
735
  <p>Useful for starting a fresh conversation without recreating the agent.
695
736
  If the history begins with a summary block (from a prior compaction), only
696
737
  messages after the summary are cleared.</p>
697
738
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
698
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-30">Throws<a href="#throws-30" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
699
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1983">server/src/app.service.ts:1983</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="renameuserartifact"><span>rename<wbr/>User<wbr/>Artifact</span><a href="#renameuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="renameuserartifact-1"><span class="tsd-kind-call-signature">renameUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">newName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#renameuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Changes the display name of an artifact.</p>
739
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-31">Throws<a href="#throws-31" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
740
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2537">server/src/app.service.ts:2537</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="removeroomagent"><span>remove<wbr/>Room<wbr/>Agent</span><a href="#removeroomagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="removeroomagent-1"><span class="tsd-kind-call-signature">removeRoomAgent</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#removeroomagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Removes an agent from a room, and deletes it if the room owns it.</p>
741
+ </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
742
+ </div></li><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
743
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-32">Throws<a href="#throws-32" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist, or the agent is not in it</p>
744
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-33">Throws<a href="#throws-33" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room is a published instance</p>
745
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-34">Throws<a href="#throws-34" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If removing the moderator would leave an agent that
746
+ sends MODERATE messages with nothing to route them</p>
747
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1112">server/src/app.service.ts:1112</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="renameuserartifact"><span>rename<wbr/>User<wbr/>Artifact</span><a href="#renameuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="renameuserartifact-1"><span class="tsd-kind-call-signature">renameUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">newName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#renameuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Changes the display name of an artifact.</p>
700
748
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">artifactId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The artifact's ID (from <a href="#listuserartifacts" class="tsd-kind-method">listUserArtifacts</a>)</p>
701
749
  </div></li><li><span><span class="tsd-kind-parameter">newName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>New display name for the artifact</p>
702
750
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><p><code>true</code> on success, <code>false</code> if no artifact with that ID exists</p>
703
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L3252">server/src/app.service.ts:3252</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resetpublishedinstance"><span>reset<wbr/>Published<wbr/>Instance</span><a href="#resetpublishedinstance" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resetpublishedinstance-1"><span class="tsd-kind-call-signature">resetPublishedInstance</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#resetpublishedinstance-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Resets a published agent instance to its template's current state.</p>
751
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3806">server/src/app.service.ts:3806</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resetpublishedinstance"><span>reset<wbr/>Published<wbr/>Instance</span><a href="#resetpublishedinstance" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resetpublishedinstance-1"><span class="tsd-kind-call-signature">resetPublishedInstance</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#resetpublishedinstance-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Resets a published agent instance to its template's current state.</p>
704
752
  <p>Clears the instance's conversation history and regenerates it from
705
753
  the template agent. Does not affect the template itself.</p>
706
754
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">instanceId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>ID of the published instance to reset</p>
707
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-31">Throws<a href="#throws-31" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the instance does not exist</p>
708
- </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-32">Throws<a href="#throws-32" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the agent is not a published instance</p>
709
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1144">server/src/app.service.ts:1144</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resetpublishedroominstance"><span>reset<wbr/>Published<wbr/>Room<wbr/>Instance</span><a href="#resetpublishedroominstance" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resetpublishedroominstance-1"><span class="tsd-kind-call-signature">resetPublishedRoomInstance</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#resetpublishedroominstance-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Resets a published room instance to a clean state.</p>
755
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-35">Throws<a href="#throws-35" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the instance does not exist</p>
756
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-36">Throws<a href="#throws-36" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the agent is not a published instance</p>
757
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1566">server/src/app.service.ts:1566</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resetpublishedroominstance"><span>reset<wbr/>Published<wbr/>Room<wbr/>Instance</span><a href="#resetpublishedroominstance" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resetpublishedroominstance-1"><span class="tsd-kind-call-signature">resetPublishedRoomInstance</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">instanceId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#resetpublishedroominstance-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Resets a published room instance to a clean state.</p>
710
758
  <p>Clears the instance's messages and artifacts, and resets all of its
711
759
  cloned agents to their template state. Does not affect the template room.</p>
712
760
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">instanceId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>ID of the published room instance to reset</p>
713
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-33">Throws<a href="#throws-33" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the instance does not exist</p>
714
- </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-34">Throws<a href="#throws-34" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room is not a published instance</p>
715
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1305">server/src/app.service.ts:1305</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resetroom"><span>reset<wbr/>Room</span><a href="#resetroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resetroom-1"><span class="tsd-kind-call-signature">resetRoom</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#resetroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Clears a room's message history and artifacts, and resets all member agents.</p>
761
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-37">Throws<a href="#throws-37" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the instance does not exist</p>
762
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-38">Throws<a href="#throws-38" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room is not a published instance</p>
763
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1758">server/src/app.service.ts:1758</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resetroom"><span>reset<wbr/>Room</span><a href="#resetroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resetroom-1"><span class="tsd-kind-call-signature">resetRoom</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#resetroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Clears a room's message history and artifacts, and resets all member agents.</p>
716
764
  <p>Agent configurations (model, prompt, files) are preserved; only conversation
717
765
  history and artifacts are removed.</p>
718
766
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
719
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-35">Throws<a href="#throws-35" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
720
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2040">server/src/app.service.ts:2040</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resetstory"><span>reset<wbr/>Story</span><a href="#resetstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resetstory-1"><span class="tsd-kind-call-signature">resetStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#resetstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Resets a story to the beginning while preserving artifacts and the opening scene.</p>
767
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-39">Throws<a href="#throws-39" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
768
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2594">server/src/app.service.ts:2594</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resetstory"><span>reset<wbr/>Story</span><a href="#resetstory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resetstory-1"><span class="tsd-kind-call-signature">resetStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#resetstory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Resets a story to the beginning while preserving artifacts and the opening scene.</p>
721
769
  <p>If a chapter 1 backup exists, agents are restored from it; otherwise their
722
770
  conversation histories are cleared. The list of declined characters is also cleared.</p>
723
771
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
724
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-36">Throws<a href="#throws-36" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the story or its room does not exist</p>
725
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2082">server/src/app.service.ts:2082</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="respondtostory"><span>respond<wbr/>To<wbr/>Story</span><a href="#respondtostory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="respondtostory-1"><span class="tsd-kind-call-signature">respondToStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#respondtostory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Submits the human player's response to the story.</p>
772
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-40">Throws<a href="#throws-40" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the story or its room does not exist</p>
773
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2636">server/src/app.service.ts:2636</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="respondtostory"><span>respond<wbr/>To<wbr/>Story</span><a href="#respondtostory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="respondtostory-1"><span class="tsd-kind-call-signature">respondToStory</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#respondtostory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Submits the human player's response to the story.</p>
726
774
  <p>Adds the content as a player message and triggers the AI characters
727
775
  to continue the narrative.</p>
728
776
  <p>Pass the literal string <code>'PASS'</code> (case-insensitive) to skip the player's
729
777
  turn and let the AI characters continue without player input.</p>
730
778
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
731
779
  </div></li><li><span><span class="tsd-kind-parameter">content</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The player's message or action, or <code>'PASS'</code> to skip the turn</p>
732
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2627">server/src/app.service.ts:2627</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resumepausedstories"><span>resume<wbr/>Paused<wbr/>Stories</span><a href="#resumepausedstories" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resumepausedstories-1"><span class="tsd-kind-call-signature">resumePausedStories</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">&gt;</span><a href="#resumepausedstories-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Resumes any stories that were paused due to insufficient balance.</p>
780
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3181">server/src/app.service.ts:3181</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resumepausedstories"><span>resume<wbr/>Paused<wbr/>Stories</span><a href="#resumepausedstories" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resumepausedstories-1"><span class="tsd-kind-call-signature">resumePausedStories</span><span class="tsd-signature-symbol">()</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">&gt;</span><a href="#resumepausedstories-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Resumes any stories that were paused due to insufficient balance.</p>
733
781
  <p>Call this after adding balance via <a href="#addbalance" class="tsd-kind-method">addBalance</a> to allow stories that
734
782
  stalled mid-processing to continue from where they left off.</p>
735
783
  </div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">&gt;</span></h4><p>The number of stories that were resumed</p>
736
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2502">server/src/app.service.ts:2502</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resumeroom"><span>resume<wbr/>Room</span><a href="#resumeroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resumeroom-1"><span class="tsd-kind-call-signature">resumeRoom</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#resumeroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Resumes message processing in a room that was previously paused.</p>
784
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3056">server/src/app.service.ts:3056</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="resumeroom"><span>resume<wbr/>Room</span><a href="#resumeroom" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="resumeroom-1"><span class="tsd-kind-call-signature">resumeRoom</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#resumeroom-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Resumes message processing in a room that was previously paused.</p>
737
785
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
738
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-37">Throws<a href="#throws-37" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
739
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1030">server/src/app.service.ts:1030</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="revertstorychapter"><span>revert<wbr/>Story<wbr/>Chapter</span><a href="#revertstorychapter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="revertstorychapter-1"><span class="tsd-kind-call-signature">revertStoryChapter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#revertstorychapter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Reverts the most recent chapter progression for a story. Restores room
786
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-41">Throws<a href="#throws-41" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
787
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1451">server/src/app.service.ts:1451</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="revertstorychapter"><span>revert<wbr/>Story<wbr/>Chapter</span><a href="#revertstorychapter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="revertstorychapter-1"><span class="tsd-kind-call-signature">revertStoryChapter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#revertstorychapter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Reverts the most recent chapter progression for a story. Restores room
740
788
  messages, artifacts, and agent histories from the previous chapter
741
789
  backup, then deletes that backup. Only valid when the current chapter
742
790
  has not been played past the opening scene.</p>
743
791
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
744
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-38">Throws<a href="#throws-38" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the story or its room does not exist</p>
745
- </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-39">Throws<a href="#throws-39" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If revert is not currently valid</p>
746
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2167">server/src/app.service.ts:2167</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="runpreparedprompt"><span>run<wbr/>Prepared<wbr/>Prompt</span><a href="#runpreparedprompt" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="runpreparedprompt-1"><span class="tsd-kind-call-signature">runPreparedPrompt</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">promptName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">variables</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="PreparedPromptResponse.html" class="tsd-signature-type tsd-kind-interface">PreparedPromptResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#runpreparedprompt-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Executes a named Handlebars prompt template against an agent.</p>
792
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-42">Throws<a href="#throws-42" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the story or its room does not exist</p>
793
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-43">Throws<a href="#throws-43" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If revert is not currently valid</p>
794
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2721">server/src/app.service.ts:2721</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="runpreparedprompt"><span>run<wbr/>Prepared<wbr/>Prompt</span><a href="#runpreparedprompt" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="runpreparedprompt-1"><span class="tsd-kind-call-signature">runPreparedPrompt</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">promptName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">variables</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="PreparedPromptResponse.html" class="tsd-signature-type tsd-kind-interface">PreparedPromptResponse</a><span class="tsd-signature-symbol">&gt;</span><a href="#runpreparedprompt-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Executes a named Handlebars prompt template against an agent.</p>
747
795
  <p>The template is loaded from the agent's prompt folder (with the standard 4-level
748
796
  fallback). <code>variables</code> are substituted into the template before sending.</p>
749
797
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
750
798
  </div></li><li><span><span class="tsd-kind-parameter">promptName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Template name returned by <a href="#listprompts" class="tsd-kind-method">listPrompts</a> (without extension)</p>
751
799
  </div></li><li><span><span class="tsd-kind-parameter">variables</span>: <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol"> = {}</span></span><div class="tsd-comment tsd-typography"><p>Key-value pairs substituted into the template's <code>{{variable}}</code> placeholders</p>
752
800
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="PreparedPromptResponse.html" class="tsd-signature-type tsd-kind-interface">PreparedPromptResponse</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Object with a <code>result</code> string containing the agent's response</p>
753
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-40">Throws<a href="#throws-40" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
754
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L560">server/src/app.service.ts:560</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="savechapter"><span>save<wbr/>Chapter</span><a href="#savechapter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="savechapter-1"><span class="tsd-kind-call-signature">saveChapter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#savechapter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Overwrites the content of a chapter checkpoint.</p>
801
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-44">Throws<a href="#throws-44" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
802
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L621">server/src/app.service.ts:621</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="savechapter"><span>save<wbr/>Chapter</span><a href="#savechapter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="savechapter-1"><span class="tsd-kind-call-signature">saveChapter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">chapterIndex</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#savechapter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Overwrites the content of a chapter checkpoint.</p>
755
803
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
756
804
  </div></li><li><span><span class="tsd-kind-parameter">chapterIndex</span>: <span class="tsd-signature-type">number</span></span><div class="tsd-comment tsd-typography"><p>The chapter number to overwrite</p>
757
805
  </div></li><li><span><span class="tsd-kind-parameter">content</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The new chapter content</p>
758
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-41">Throws<a href="#throws-41" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the chapter cannot be saved</p>
759
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2728">server/src/app.service.ts:2728</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="savecharacter"><span>save<wbr/>Character</span><a href="#savecharacter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="savecharacter-1"><span class="tsd-kind-call-signature">saveCharacter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#savecharacter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Saves a character's profile markdown.</p>
806
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-45">Throws<a href="#throws-45" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the chapter cannot be saved</p>
807
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3282">server/src/app.service.ts:3282</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="savecharacter"><span>save<wbr/>Character</span><a href="#savecharacter" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="savecharacter-1"><span class="tsd-kind-call-signature">saveCharacter</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#savecharacter-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Saves a character's profile markdown.</p>
760
808
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
761
809
  </div></li><li><span><span class="tsd-kind-parameter">characterName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The character's name</p>
762
810
  </div></li><li><span><span class="tsd-kind-parameter">content</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Markdown content for the character profile</p>
763
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2778">server/src/app.service.ts:2778</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="savecharacterinventory"><span>save<wbr/>Character<wbr/>Inventory</span><a href="#savecharacterinventory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="savecharacterinventory-1"><span class="tsd-kind-call-signature">saveCharacterInventory</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#savecharacterinventory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Saves a character's inventory markdown.</p>
811
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3332">server/src/app.service.ts:3332</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="savecharacterinventory"><span>save<wbr/>Character<wbr/>Inventory</span><a href="#savecharacterinventory" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="savecharacterinventory-1"><span class="tsd-kind-call-signature">saveCharacterInventory</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">characterName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#savecharacterinventory-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Saves a character's inventory markdown.</p>
764
812
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
765
813
  </div></li><li><span><span class="tsd-kind-parameter">characterName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The character's name</p>
766
814
  </div></li><li><span><span class="tsd-kind-parameter">content</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Markdown content for the character inventory</p>
767
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2801">server/src/app.service.ts:2801</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="saveplotplan"><span>save<wbr/>Plot<wbr/>Plan</span><a href="#saveplotplan" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="saveplotplan-1"><span class="tsd-kind-call-signature">savePlotPlan</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#saveplotplan-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Saves the story's plot plan.</p>
815
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3355">server/src/app.service.ts:3355</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="saveplotplan"><span>save<wbr/>Plot<wbr/>Plan</span><a href="#saveplotplan" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="saveplotplan-1"><span class="tsd-kind-call-signature">savePlotPlan</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">storyId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#saveplotplan-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Saves the story's plot plan.</p>
768
816
  <p>Persists the content as a room artifact via the publish mechanism.</p>
769
817
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">storyId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The story's ID</p>
770
818
  </div></li><li><span><span class="tsd-kind-parameter">content</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The plot plan markdown to save</p>
771
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2863">server/src/app.service.ts:2863</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="savepromptfile"><span>save<wbr/>Prompt<wbr/>File</span><a href="#savepromptfile" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="savepromptfile-1"><span class="tsd-kind-call-signature">savePromptFile</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fileType</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#savepromptfile-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Writes content to a prompt file in the user prompt directory.</p>
819
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3417">server/src/app.service.ts:3417</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="savepromptfile"><span>save<wbr/>Prompt<wbr/>File</span><a href="#savepromptfile" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="savepromptfile-1"><span class="tsd-kind-call-signature">savePromptFile</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">folderName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fileName</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">fileType</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#savepromptfile-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Writes content to a prompt file in the user prompt directory.</p>
772
820
  <p>Always saves to the user directory - common prompt files are never overwritten.
773
821
  If the target folder does not exist it is created automatically.
774
822
  Passing <code>'shared'</code> as <code>folderName</code> writes to the root user prompts directory.</p>
@@ -778,21 +826,22 @@ rather than writing an empty document.</p>
778
826
  </div></li><li><span><span class="tsd-kind-parameter">fileName</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Base name of the file (without extension)</p>
779
827
  </div></li><li><span><span class="tsd-kind-parameter">content</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>File content to write</p>
780
828
  </div></li><li><span><span class="tsd-kind-parameter">fileType</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p><code>'prompt'</code> (writes a <code>.prompt</code> file) or <code>'json'</code> (writes a <code>.json</code> file)</p>
781
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1564">server/src/app.service.ts:1564</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="saveuserpreferences"><span>save<wbr/>User<wbr/>Preferences</span><a href="#saveuserpreferences" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="saveuserpreferences-1"><span class="tsd-kind-call-signature">saveUserPreferences</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">preferences</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#saveuserpreferences-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Persists the user's preferences object to disk.</p>
829
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2105">server/src/app.service.ts:2105</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="saveuserpreferences"><span>save<wbr/>User<wbr/>Preferences</span><a href="#saveuserpreferences" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="saveuserpreferences-1"><span class="tsd-kind-call-signature">saveUserPreferences</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">preferences</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">void</span><a href="#saveuserpreferences-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Persists the user's preferences object to disk.</p>
782
830
  <p>The shape of <code>preferences</code> is application-defined. Pass any serializable object;
783
831
  it will be stored as JSON and returned verbatim by <a href="#getuserpreferences" class="tsd-kind-method">getUserPreferences</a>.</p>
784
832
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">preferences</span>: <span class="tsd-signature-type">any</span></span><div class="tsd-comment tsd-typography"><p>Serializable preferences object to store</p>
785
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1380">server/src/app.service.ts:1380</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="sendroommessage"><span>send<wbr/>Room<wbr/>Message</span><a href="#sendroommessage" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="sendroommessage-1"><span class="tsd-kind-call-signature">sendRoomMessage</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">sender</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">action</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">targets</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">clearQueue</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">context</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">unknown</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="SendMessageResult.html" class="tsd-signature-type tsd-kind-interface">SendMessageResult</a><span class="tsd-signature-symbol">&gt;</span><a href="#sendroommessage-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Adds a message to a room's pending queue to be processed by the agents.</p>
833
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1823">server/src/app.service.ts:1823</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="sendroommessage"><span>send<wbr/>Room<wbr/>Message</span><a href="#sendroommessage" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="sendroommessage-1"><span class="tsd-kind-call-signature">sendRoomMessage</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">sender</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">action</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">targets</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">clearQueue</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">context</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">unknown</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="SendMessageResult.html" class="tsd-signature-type tsd-kind-interface">SendMessageResult</a><span class="tsd-signature-symbol">&gt;</span><a href="#sendroommessage-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Adds a message to a room's pending queue to be processed by the agents.</p>
786
834
  <p><strong>Action values:</strong></p>
787
835
  <ul>
788
- <li><code>'speak'</code> <em>(default)</em> - all agents hear the message; <code>targets</code> (if provided) restricts which agents may respond</li>
836
+ <li><code>'moderate'</code> <em>(default)</em> - routes the message through the room's moderator (story rooms only)</li>
837
+ <li><code>'speak'</code> - all agents hear the message; <code>targets</code> (if provided) restricts which agents may respond</li>
789
838
  <li><code>'whisper'</code> - only agents listed in <code>targets</code> hear the message</li>
790
839
  <li><code>'think'</code> - inaudible; stays only in the sender's history, not shown to other agents</li>
791
840
  <li><code>'shout'</code> - overrides all other conversations; all agents hear and respond</li>
792
- <li><code>'publish'</code> - publishes a new room artifact; <code>content</code> is the artifact body</li>
793
- <li><code>'adjourn'</code> - signals intent to halt the conversation</li>
794
- <li><code>'moderate'</code> - routes the message through the room's moderator (story rooms only)</li>
841
+ <li><code>'adjourn'</code> - signals intent to halt the conversation; the room adjourns once every agent agrees</li>
795
842
  </ul>
843
+ <p>Anything else is sent as <code>'speak'</code>. To create an artifact use <a href="#publishartifact" class="tsd-kind-method">publishArtifact</a>
844
+ rather than this method.</p>
796
845
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
797
846
  </div></li><li><span><span class="tsd-kind-parameter">content</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The message text (or artifact body when <code>action</code> is <code>'publish'</code>)</p>
798
847
  </div></li><li><span><span class="tsd-kind-parameter">sender</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Display name of the sender (e.g. <code>'User'</code>, <code>'System'</code>)</p>
@@ -801,26 +850,26 @@ it will be stored as JSON and returned verbatim by <a href="#getuserpreferences"
801
850
  </div></li><li><span><span class="tsd-kind-parameter">clearQueue</span>: <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol"> = false</span></span><div class="tsd-comment tsd-typography"><p>If <code>true</code>, clears any pending messages before adding this one. Default <code>false</code>.</p>
802
851
  </div></li><li><span><code class="tsd-tag">Optional</code><span class="tsd-kind-parameter">context</span>: <span class="tsd-signature-type">unknown</span></span></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="SendMessageResult.html" class="tsd-signature-type tsd-kind-interface">SendMessageResult</a><span class="tsd-signature-symbol">&gt;</span></h4><p>Whether the message was accepted. A human agent's message is rejected
803
852
  (<code>accepted: false</code> with a <code>reason</code>) when it is not the human's turn to speak.</p>
804
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-42">Throws<a href="#throws-42" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
805
- </div><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-5">Example<a href="#example-5" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-5">// Broadcast a message that all agents can respond to</span><br/><span class="hl-3">await</span><span class="hl-1"> </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">sendRoomMessage</span><span class="hl-1">(</span><span class="hl-4">roomId</span><span class="hl-1">, </span><span class="hl-2">&#39;Hello everyone!&#39;</span><span class="hl-1">, </span><span class="hl-2">&#39;User&#39;</span><span class="hl-1">, </span><span class="hl-2">&#39;speak&#39;</span><span class="hl-1">);</span><br/><br/><span class="hl-5">// Whisper to a specific agent</span><br/><span class="hl-6">const</span><span class="hl-1"> </span><span class="hl-7">result</span><span class="hl-1"> = </span><span class="hl-3">await</span><span class="hl-1"> </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">sendRoomMessage</span><span class="hl-1">(</span><span class="hl-4">roomId</span><span class="hl-1">, </span><span class="hl-2">&#39;Just between us...&#39;</span><span class="hl-1">, </span><span class="hl-2">&#39;User&#39;</span><span class="hl-1">, </span><span class="hl-2">&#39;whisper&#39;</span><span class="hl-1">, [</span><span class="hl-2">&#39;James&#39;</span><span class="hl-1">]);</span><br/><span class="hl-3">if</span><span class="hl-1"> (!</span><span class="hl-4">result</span><span class="hl-1">.</span><span class="hl-4">accepted</span><span class="hl-1">) {</span><br/><span class="hl-1"> </span><span class="hl-4">console</span><span class="hl-1">.</span><span class="hl-0">log</span><span class="hl-1">(</span><span class="hl-4">result</span><span class="hl-1">.</span><span class="hl-4">reason</span><span class="hl-1">); </span><span class="hl-5">// e.g. &quot;It is James&#39;s turn to speak&quot;</span><br/><span class="hl-1">}</span>
853
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-46">Throws<a href="#throws-46" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
854
+ </div><div class="tsd-tag-example"><h4 class="tsd-anchor-link" id="example-4">Example<a href="#example-4" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><pre><code class="typescript"><span class="hl-5">// Broadcast a message that all agents can respond to</span><br/><span class="hl-3">await</span><span class="hl-1"> </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">sendRoomMessage</span><span class="hl-1">(</span><span class="hl-4">roomId</span><span class="hl-1">, </span><span class="hl-2">&#39;Hello everyone!&#39;</span><span class="hl-1">, </span><span class="hl-2">&#39;User&#39;</span><span class="hl-1">, </span><span class="hl-2">&#39;speak&#39;</span><span class="hl-1">);</span><br/><br/><span class="hl-5">// Whisper to a specific agent</span><br/><span class="hl-6">const</span><span class="hl-1"> </span><span class="hl-7">result</span><span class="hl-1"> = </span><span class="hl-3">await</span><span class="hl-1"> </span><span class="hl-4">appService</span><span class="hl-1">.</span><span class="hl-0">sendRoomMessage</span><span class="hl-1">(</span><span class="hl-4">roomId</span><span class="hl-1">, </span><span class="hl-2">&#39;Just between us...&#39;</span><span class="hl-1">, </span><span class="hl-2">&#39;User&#39;</span><span class="hl-1">, </span><span class="hl-2">&#39;whisper&#39;</span><span class="hl-1">, [</span><span class="hl-2">&#39;James&#39;</span><span class="hl-1">]);</span><br/><span class="hl-3">if</span><span class="hl-1"> (!</span><span class="hl-4">result</span><span class="hl-1">.</span><span class="hl-4">accepted</span><span class="hl-1">) {</span><br/><span class="hl-1"> </span><span class="hl-4">console</span><span class="hl-1">.</span><span class="hl-0">log</span><span class="hl-1">(</span><span class="hl-4">result</span><span class="hl-1">.</span><span class="hl-4">reason</span><span class="hl-1">); </span><span class="hl-5">// e.g. &quot;It is James&#39;s turn to speak&quot;</span><br/><span class="hl-1">}</span>
806
855
  </code><button type="button">Copy</button></pre>
807
856
 
808
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L966">server/src/app.service.ts:966</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="setroomleader"><span>set<wbr/>Room<wbr/>Leader</span><a href="#setroomleader" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="setroomleader-1"><span class="tsd-kind-call-signature">setRoomLeader</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">agentNickname</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#setroomleader-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Sets which agent leads the room's conversation and persists the change.</p>
857
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1379">server/src/app.service.ts:1379</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="setroomleader"><span>set<wbr/>Room<wbr/>Leader</span><a href="#setroomleader" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="setroomleader-1"><span class="tsd-kind-call-signature">setRoomLeader</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">roomId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">agentNickname</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#setroomleader-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Sets which agent leads the room's conversation and persists the change.</p>
809
858
  <p>The room leader is given conversational authority in the default room
810
859
  prompts (other agents defer to it) and is consulted on adjournment.</p>
811
860
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">roomId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The room's ID</p>
812
861
  </div></li><li><span><span class="tsd-kind-parameter">agentNickname</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>Nickname of the member agent to make leader</p>
813
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-43">Throws<a href="#throws-43" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
814
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L827">server/src/app.service.ts:827</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="testtool"><span>test<wbr/>Tool</span><a href="#testtool" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="testtool-1"><span class="tsd-kind-call-signature">testTool</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">args</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Record</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../types/ToolRunResult.html" class="tsd-signature-type tsd-kind-type-alias">ToolRunResult</a><span class="tsd-signature-symbol">&gt;</span><a href="#testtool-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Runs a tool with the given arguments for testing from the Tools page.
862
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-47">Throws<a href="#throws-47" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the room does not exist</p>
863
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L1238">server/src/app.service.ts:1238</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="testtool"><span>test<wbr/>Tool</span><a href="#testtool" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="testtool-1"><span class="tsd-kind-call-signature">testTool</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">args</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Record</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../types/ToolRunResult.html" class="tsd-signature-type tsd-kind-type-alias">ToolRunResult</a><span class="tsd-signature-symbol">&gt;</span><a href="#testtool-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Runs a tool with the given arguments for testing from the Tools page.
815
864
  Failures are returned in-band as <code>{ ok: false, error }</code>.</p>
816
865
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">name</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The tool's name</p>
817
866
  </div></li><li><span><span class="tsd-kind-parameter">args</span>: <span class="tsd-signature-type">Record</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-signature-type">any</span><span class="tsd-signature-symbol">&gt;</span></span><div class="tsd-comment tsd-typography"><p>Named arguments for the tool</p>
818
867
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="../types/ToolRunResult.html" class="tsd-signature-type tsd-kind-type-alias">ToolRunResult</a><span class="tsd-signature-symbol">&gt;</span></h4><p>The tool run result</p>
819
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1877">server/src/app.service.ts:1877</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="updateagent"><span>update<wbr/>Agent</span><a href="#updateagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="updateagent-1"><span class="tsd-kind-call-signature">updateAgent</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">updates</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{</span><br/>        <span class="tsd-kind-property">agentNickname</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>        <span class="tsd-kind-property">allowSearch</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>        <span class="tsd-kind-property">beginInstruction</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>        <span class="tsd-kind-property">description</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>        <span class="tsd-kind-property">isControlledByHuman</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>        <span class="tsd-kind-property">maxOutputTokens</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">;</span><br/>        <span class="tsd-kind-property">modelName</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>        <span class="tsd-kind-property">reasoningEffort</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">&quot;low&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;medium&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;high&quot;</span><span class="tsd-signature-symbol">;</span><br/>        <span class="tsd-kind-property">toolNames</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/>    <span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#updateagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates one or more properties of an existing agent and persists the changes.</p>
868
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2431">server/src/app.service.ts:2431</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="updateagent"><span>update<wbr/>Agent</span><a href="#updateagent" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="updateagent-1"><span class="tsd-kind-call-signature">updateAgent</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">agentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">updates</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">UpdateAgentRequest</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#updateagent-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates one or more properties of an existing agent and persists the changes.</p>
820
869
  <p>Only fields that are present in the <code>updates</code> object are changed;
821
870
  omitted fields are left as-is.</p>
822
871
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">agentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The agent's ID</p>
823
- </div></li><li><span><span class="tsd-kind-parameter">updates</span>: <span class="tsd-signature-symbol">{</span><br/>    <span class="tsd-kind-property">agentNickname</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>    <span class="tsd-kind-property">allowSearch</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>    <span class="tsd-kind-property">beginInstruction</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>    <span class="tsd-kind-property">description</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>    <span class="tsd-kind-property">isControlledByHuman</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">;</span><br/>    <span class="tsd-kind-property">maxOutputTokens</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">;</span><br/>    <span class="tsd-kind-property">modelName</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">;</span><br/>    <span class="tsd-kind-property">reasoningEffort</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">&quot;low&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;medium&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;high&quot;</span><span class="tsd-signature-symbol">;</span><br/>    <span class="tsd-kind-property">toolNames</span><span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">;</span><br/><span class="tsd-signature-symbol">}</span></span><div class="tsd-comment tsd-typography"><p>Fields to update:</p>
872
+ </div></li><li><span><span class="tsd-kind-parameter">updates</span>: <span class="tsd-signature-type">UpdateAgentRequest</span></span><div class="tsd-comment tsd-typography"><p>Fields to update:</p>
824
873
  <ul>
825
874
  <li><code>agentNickname</code> - short display name</li>
826
875
  <li><code>description</code> - role or personality description</li>
@@ -831,19 +880,19 @@ omitted fields are left as-is.</p>
831
880
  <li><code>allowSearch</code> - enable web search capability (provider must support it)</li>
832
881
  <li><code>beginInstruction</code> - prompt sent when the host app triggers a &quot;Begin&quot; action</li>
833
882
  </ul>
834
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-44">Throws<a href="#throws-44" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
835
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1746">server/src/app.service.ts:1746</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="updatetool"><span>update<wbr/>Tool</span><a href="#updatetool" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="updatetool-1"><span class="tsd-kind-call-signature">updateTool</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">tool</span><span class="tsd-signature-symbol">:</span> <a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">&gt;</span><a href="#updatetool-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates an existing user-authored tool.</p>
883
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-48">Throws<a href="#throws-48" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If no agent with the given ID exists</p>
884
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2287">server/src/app.service.ts:2287</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="updatetool"><span>update<wbr/>Tool</span><a href="#updatetool" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="updatetool-1"><span class="tsd-kind-call-signature">updateTool</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">name</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">tool</span><span class="tsd-signature-symbol">:</span> <a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">&gt;</span><a href="#updatetool-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates an existing user-authored tool.</p>
836
885
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">name</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The tool's name</p>
837
886
  </div></li><li><span><span class="tsd-kind-parameter">tool</span>: <a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a></span><div class="tsd-comment tsd-typography"><p>The updated tool definition</p>
838
887
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><a href="ToolDefinition.html" class="tsd-signature-type tsd-kind-interface">ToolDefinition</a><span class="tsd-signature-symbol">&gt;</span></h4><p>The saved tool definition</p>
839
- <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-45">Throws<a href="#throws-45" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the tool does not exist</p>
840
- </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-46">Throws<a href="#throws-46" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If authoring is disabled</p>
841
- </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L1838">server/src/app.service.ts:1838</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="updatetransactionstatus"><span>update<wbr/>Transaction<wbr/>Status</span><a href="#updatetransactionstatus" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="updatetransactionstatus-1"><span class="tsd-kind-call-signature">updateTransactionStatus</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">status</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">&quot;pending&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;succeeded&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;failed&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;cancelled&quot;</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#updatetransactionstatus-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates the status of an existing transaction.</p>
888
+ <div class="tsd-comment tsd-typography"><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-49">Throws<a href="#throws-49" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If the tool does not exist</p>
889
+ </div><div class="tsd-tag-throws"><h4 class="tsd-anchor-link" id="throws-50">Throws<a href="#throws-50" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h4><p>If authoring is disabled</p>
890
+ </div></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L2392">server/src/app.service.ts:2392</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="updatetransactionstatus"><span>update<wbr/>Transaction<wbr/>Status</span><a href="#updatetransactionstatus" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="updatetransactionstatus-1"><span class="tsd-kind-call-signature">updateTransactionStatus</span><span class="tsd-signature-symbol">(</span><br/>    <span class="tsd-kind-parameter">paymentId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span><br/>    <span class="tsd-kind-parameter">status</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">&quot;pending&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;succeeded&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;failed&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;cancelled&quot;</span><span class="tsd-signature-symbol">,</span><br/><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span><a href="#updatetransactionstatus-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Updates the status of an existing transaction.</p>
842
891
  <p>Call this when your payment provider webhook confirms the final outcome of a payment.</p>
843
892
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">paymentId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The payment provider ID used when the transaction was recorded</p>
844
893
  </div></li><li><span><span class="tsd-kind-parameter">status</span>: <span class="tsd-signature-type">&quot;pending&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;succeeded&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;failed&quot;</span> <span class="tsd-signature-symbol">|</span> <span class="tsd-signature-type">&quot;cancelled&quot;</span></span><div class="tsd-comment tsd-typography"><p>New status (<code>'succeeded'</code>, <code>'failed'</code>, or <code>'cancelled'</code>)</p>
845
- </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L2920">server/src/app.service.ts:2920</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="updateuserartifact"><span>update<wbr/>User<wbr/>Artifact</span><a href="#updateuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="updateuserartifact-1"><span class="tsd-kind-call-signature">updateUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#updateuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Replaces the content of an existing artifact.</p>
894
+ </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">&gt;</span></h4><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3474">server/src/app.service.ts:3474</a></li></ul></aside></div></li></ul></section><section class="tsd-panel tsd-member"><h3 class="tsd-anchor-link" id="updateuserartifact"><span>update<wbr/>User<wbr/>Artifact</span><a href="#updateuserartifact" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></h3><ul class="tsd-signatures"><li class=""><div class="tsd-signature tsd-anchor-link" id="updateuserartifact-1"><span class="tsd-kind-call-signature">updateUserArtifact</span><span class="tsd-signature-symbol">(</span><span class="tsd-kind-parameter">artifactId</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-kind-parameter">content</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">boolean</span><a href="#updateuserartifact-1" aria-label="Permalink" class="tsd-anchor-icon"><svg viewBox="0 0 24 24" aria-hidden="true"><use href="../assets/icons.svg#icon-anchor"></use></svg></a></div><div class="tsd-description"><div class="tsd-comment tsd-typography"><p>Replaces the content of an existing artifact.</p>
846
895
  </div><div class="tsd-parameters"><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameter-list"><li><span><span class="tsd-kind-parameter">artifactId</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>The artifact's ID (from <a href="#listuserartifacts" class="tsd-kind-method">listUserArtifacts</a>)</p>
847
896
  </div></li><li><span><span class="tsd-kind-parameter">content</span>: <span class="tsd-signature-type">string</span></span><div class="tsd-comment tsd-typography"><p>New content to write</p>
848
897
  </div></li></ul></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4><p><code>true</code> on success, <code>false</code> if no artifact with that ID exists</p>
849
- <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/d1fac1dc6a8773bd0b24a6f5f0a2b72e91020670/server/src/app.service.ts#L3000">server/src/app.service.ts:3000</a></li></ul></aside></div></li></ul></section></section></details></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>On This Page</h3></summary><div class="tsd-accordion-details"><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Accessors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Accessors</summary><div><a href="#userauthoredtoolsenabled"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Accessor"><use href="../assets/icons.svg#icon-262144"></use></svg><span>user<wbr/>Authored<wbr/>Tools<wbr/>Enabled</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Methods</summary><div><a href="#addbalance"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Balance</span></a><a href="#attachartifacttoagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>attach<wbr/>Artifact<wbr/>To<wbr/>Agent</span></a><a href="#attachdocument"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>attach<wbr/>Document</span></a><a href="#compactagentconversation"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>compact<wbr/>Agent<wbr/>Conversation</span></a><a href="#compactstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>compact<wbr/>Story</span></a><a href="#convertuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>convert<wbr/>User<wbr/>Artifact</span></a><a href="#createagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Agent</span></a><a href="#createpromptfolder"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Prompt<wbr/>Folder</span></a><a href="#createroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Room</span></a><a href="#createstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Story</span></a><a href="#createtool"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Tool</span></a><a href="#createuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>User<wbr/>Artifact</span></a><a href="#declinecharacter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>decline<wbr/>Character</span></a><a href="#deleteagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Agent</span></a><a href="#deleteattachedfile"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Attached<wbr/>File</span></a><a href="#deleteattachedfilebyid"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Attached<wbr/>File<wbr/>By<wbr/>Id</span></a><a href="#deletechapter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Chapter</span></a><a href="#deletecharacterfromstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Character<wbr/>From<wbr/>Story</span></a><a href="#deletepromptfile"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Prompt<wbr/>File</span></a><a href="#deletepromptfolder"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Prompt<wbr/>Folder</span></a><a href="#deleteroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Room</span></a><a href="#deletestory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Story</span></a><a href="#deletetool"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Tool</span></a><a href="#deleteuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>User<wbr/>Artifact</span></a><a href="#detachartifactfromagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>detach<wbr/>Artifact<wbr/>From<wbr/>Agent</span></a><a href="#downloadstorymarkdown"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>download<wbr/>Story<wbr/>Markdown</span></a><a href="#editroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>edit<wbr/>Room</span></a><a href="#ensureagentstatecallback"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>ensure<wbr/>Agent<wbr/>State<wbr/>Callback</span></a><a href="#ensureroomstatecallback"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>ensure<wbr/>Room<wbr/>State<wbr/>Callback</span></a><a href="#exportstorydata"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>export<wbr/>Story<wbr/>Data</span></a><a href="#getagentdetails"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Agent<wbr/>Details</span></a><a href="#getagenthistory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Agent<wbr/>History</span></a><a href="#getagentmessageemitter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Agent<wbr/>Message<wbr/>Emitter</span></a><a href="#getagentmessages"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Agent<wbr/>Messages</span></a><a href="#getaiservicenames"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Ai<wbr/>Service<wbr/>Names</span></a><a href="#getbalance"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Balance</span></a><a href="#getbalancemessageemitter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Balance<wbr/>Message<wbr/>Emitter</span></a><a href="#getchapter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Chapter</span></a><a href="#getcharacter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Character</span></a><a href="#getcharacterinventory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Character<wbr/>Inventory</span></a><a href="#getplotplan"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Plot<wbr/>Plan</span></a><a href="#getpromptfile"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Prompt<wbr/>File</span></a><a href="#getpublishedinstances"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Published<wbr/>Instances</span></a><a href="#getpublishedroominstances"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Published<wbr/>Room<wbr/>Instances</span></a><a href="#getrandomstoryidea"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Random<wbr/>Story<wbr/>Idea</span></a><a href="#getrandomstoryideabygenre"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Random<wbr/>Story<wbr/>Idea<wbr/>By<wbr/>Genre</span></a><a href="#getroomartifacts"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Room<wbr/>Artifacts</span></a><a href="#getroombyid"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Room<wbr/>By<wbr/>Id</span></a><a href="#getroomdetails"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Room<wbr/>Details</span></a><a href="#getroommessageemitter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Room<wbr/>Message<wbr/>Emitter</span></a><a href="#getroommessages"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Room<wbr/>Messages</span></a><a href="#getstoryartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>Artifact</span></a><a href="#getstoryinfo"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>Info</span></a><a href="#getstorymessageemitter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>Message<wbr/>Emitter</span></a><a href="#getstorymessages"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>Messages</span></a><a href="#getstoryprogressemitter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>Progress<wbr/>Emitter</span></a><a href="#getstorystate"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>State</span></a><a href="#gettransactionbypaymentid"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Transaction<wbr/>By<wbr/>Payment<wbr/>Id</span></a><a href="#gettransactions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Transactions</span></a><a href="#getuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>User<wbr/>Artifact</span></a><a href="#getuserpreferences"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>User<wbr/>Preferences</span></a><a href="#getuserpromptsdir"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>User<wbr/>Prompts<wbr/>Dir</span></a><a href="#importstoryfromzip"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>import<wbr/>Story<wbr/>From<wbr/>Zip</span></a><a href="#interruptstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>interrupt<wbr/>Story</span></a><a href="#introducecharactertostory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>introduce<wbr/>Character<wbr/>To<wbr/>Story</span></a><a href="#listagentartifacts"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Agent<wbr/>Artifacts</span></a><a href="#listagents"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Agents</span></a><a href="#listaimodels"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Ai<wbr/>Models</span></a><a href="#listattachedfiles"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Attached<wbr/>Files</span></a><a href="#listchapters"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Chapters</span></a><a href="#listcharacters"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Characters</span></a><a href="#listimagemodels"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Image<wbr/>Models</span></a><a href="#listnativetoolsummaries"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Native<wbr/>Tool<wbr/>Summaries</span></a><a href="#listpromptfiles"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompt<wbr/>Files</span></a><a href="#listpromptfileswithscope"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompt<wbr/>Files<wbr/>With<wbr/>Scope</span></a><a href="#listpromptfolders"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompt<wbr/>Folders</span></a><a href="#listpromptfolderswithscope"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompt<wbr/>Folders<wbr/>With<wbr/>Scope</span></a><a href="#listprompts"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompts</span></a><a href="#listpublishedagents"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Published<wbr/>Agents</span></a><a href="#listrooms"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Rooms</span></a><a href="#liststories"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Stories</span></a><a href="#liststoryartifacts"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Story<wbr/>Artifacts</span></a><a href="#liststorygenres"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Story<wbr/>Genres</span></a><a href="#liststorymodels"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Story<wbr/>Models</span></a><a href="#listtools"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Tools</span></a><a href="#listuserartifacts"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>User<wbr/>Artifacts</span></a><a href="#pauseroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>pause<wbr/>Room</span></a><a href="#processtext"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>process<wbr/>Text</span></a><a href="#progressstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>progress<wbr/>Story</span></a><a href="#publishagentinstance"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>publish<wbr/>Agent<wbr/>Instance</span></a><a href="#publishartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>publish<wbr/>Artifact</span></a><a href="#publishroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>publish<wbr/>Room</span></a><a href="#recordtransaction"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>record<wbr/>Transaction</span></a><a href="#reloadagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reload<wbr/>Agent</span></a><a href="#renameuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>rename<wbr/>User<wbr/>Artifact</span></a><a href="#resetpublishedinstance"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reset<wbr/>Published<wbr/>Instance</span></a><a href="#resetpublishedroominstance"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reset<wbr/>Published<wbr/>Room<wbr/>Instance</span></a><a href="#resetroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reset<wbr/>Room</span></a><a href="#resetstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reset<wbr/>Story</span></a><a href="#respondtostory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>respond<wbr/>To<wbr/>Story</span></a><a href="#resumepausedstories"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>resume<wbr/>Paused<wbr/>Stories</span></a><a href="#resumeroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>resume<wbr/>Room</span></a><a href="#revertstorychapter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>revert<wbr/>Story<wbr/>Chapter</span></a><a href="#runpreparedprompt"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>run<wbr/>Prepared<wbr/>Prompt</span></a><a href="#savechapter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>Chapter</span></a><a href="#savecharacter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>Character</span></a><a href="#savecharacterinventory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>Character<wbr/>Inventory</span></a><a href="#saveplotplan"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>Plot<wbr/>Plan</span></a><a href="#savepromptfile"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>Prompt<wbr/>File</span></a><a href="#saveuserpreferences"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>User<wbr/>Preferences</span></a><a href="#sendroommessage"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>send<wbr/>Room<wbr/>Message</span></a><a href="#setroomleader"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>set<wbr/>Room<wbr/>Leader</span></a><a href="#testtool"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>test<wbr/>Tool</span></a><a href="#updateagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>Agent</span></a><a href="#updatetool"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>Tool</span></a><a href="#updatetransactionstatus"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>Transaction<wbr/>Status</span></a><a href="#updateuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>User<wbr/>Artifact</span></a></div></details></div></details></div><div class="site-menu"><nav id="tsd-sidebar-links" class="tsd-navigation"><a href="https://github.com/your-org/briyah" class="tsd-nav-link">GitHub</a><a href="https://www.npmjs.com/package/briyah" class="tsd-nav-link">npm</a></nav><nav class="tsd-navigation"><a href="../modules.html">Briyah SDK - v1.3.4</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer><p class="tsd-generator">Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></footer><div class="overlay"></div></body></html>
898
+ <aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/WilhiteSoftwareLLC/briyah/blob/42abde56c2aa5dcc25d18a2c58a7b7f2503d123a/server/src/app.service.ts#L3554">server/src/app.service.ts:3554</a></li></ul></aside></div></li></ul></section></section></details></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div><details open class="tsd-accordion tsd-page-navigation"><summary class="tsd-accordion-summary"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg><h3>On This Page</h3></summary><div class="tsd-accordion-details"><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Accessors"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Accessors</summary><div><a href="#userauthoredtoolsenabled"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Accessor"><use href="../assets/icons.svg#icon-262144"></use></svg><span>user<wbr/>Authored<wbr/>Tools<wbr/>Enabled</span></a></div></details><details open class="tsd-accordion tsd-page-navigation-section"><summary class="tsd-accordion-summary" data-key="section-Methods"><svg width="20" height="20" viewBox="0 0 24 24" fill="none" aria-hidden="true"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Methods</summary><div><a href="#addbalance"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>add<wbr/>Balance</span></a><a href="#attachartifacttoagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>attach<wbr/>Artifact<wbr/>To<wbr/>Agent</span></a><a href="#attachdocument"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>attach<wbr/>Document</span></a><a href="#compactagentconversation"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>compact<wbr/>Agent<wbr/>Conversation</span></a><a href="#compactstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>compact<wbr/>Story</span></a><a href="#convertuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>convert<wbr/>User<wbr/>Artifact</span></a><a href="#createagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Agent</span></a><a href="#createpromptfolder"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Prompt<wbr/>Folder</span></a><a href="#createroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Room</span></a><a href="#createroomagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Room<wbr/>Agent</span></a><a href="#createstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Story</span></a><a href="#createtool"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>Tool</span></a><a href="#createuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>create<wbr/>User<wbr/>Artifact</span></a><a href="#declinecharacter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>decline<wbr/>Character</span></a><a href="#deleteagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Agent</span></a><a href="#deleteattachedfile"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Attached<wbr/>File</span></a><a href="#deleteattachedfilebyid"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Attached<wbr/>File<wbr/>By<wbr/>Id</span></a><a href="#deletechapter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Chapter</span></a><a href="#deletecharacterfromstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Character<wbr/>From<wbr/>Story</span></a><a href="#deletepromptfile"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Prompt<wbr/>File</span></a><a href="#deletepromptfolder"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Prompt<wbr/>Folder</span></a><a href="#deleteroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Room</span></a><a href="#deletestory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Story</span></a><a href="#deletetool"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>Tool</span></a><a href="#deleteuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>delete<wbr/>User<wbr/>Artifact</span></a><a href="#detachartifactfromagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>detach<wbr/>Artifact<wbr/>From<wbr/>Agent</span></a><a href="#downloadstorymarkdown"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>download<wbr/>Story<wbr/>Markdown</span></a><a href="#editroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>edit<wbr/>Room</span></a><a href="#ensureagentstatecallback"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>ensure<wbr/>Agent<wbr/>State<wbr/>Callback</span></a><a href="#ensureroomstatecallback"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>ensure<wbr/>Room<wbr/>State<wbr/>Callback</span></a><a href="#exportstorydata"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>export<wbr/>Story<wbr/>Data</span></a><a href="#getagentdetails"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Agent<wbr/>Details</span></a><a href="#getagenthistory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Agent<wbr/>History</span></a><a href="#getagentmessageemitter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Agent<wbr/>Message<wbr/>Emitter</span></a><a href="#getagentmessages"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Agent<wbr/>Messages</span></a><a href="#getaiservicenames"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Ai<wbr/>Service<wbr/>Names</span></a><a href="#getbalance"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Balance</span></a><a href="#getbalancemessageemitter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Balance<wbr/>Message<wbr/>Emitter</span></a><a href="#getchapter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Chapter</span></a><a href="#getcharacter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Character</span></a><a href="#getcharacterinventory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Character<wbr/>Inventory</span></a><a href="#getplotplan"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Plot<wbr/>Plan</span></a><a href="#getpromptfile"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Prompt<wbr/>File</span></a><a href="#getpromptfolderdefaults"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Prompt<wbr/>Folder<wbr/>Defaults</span></a><a href="#getpublishedinstances"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Published<wbr/>Instances</span></a><a href="#getpublishedroominstances"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Published<wbr/>Room<wbr/>Instances</span></a><a href="#getrandomstoryidea"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Random<wbr/>Story<wbr/>Idea</span></a><a href="#getrandomstoryideabygenre"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Random<wbr/>Story<wbr/>Idea<wbr/>By<wbr/>Genre</span></a><a href="#getroomartifacts"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Room<wbr/>Artifacts</span></a><a href="#getroombyid"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Room<wbr/>By<wbr/>Id</span></a><a href="#getroomdetails"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Room<wbr/>Details</span></a><a href="#getroommessageemitter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Room<wbr/>Message<wbr/>Emitter</span></a><a href="#getroommessages"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Room<wbr/>Messages</span></a><a href="#getstoryartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>Artifact</span></a><a href="#getstoryinfo"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>Info</span></a><a href="#getstorymessageemitter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>Message<wbr/>Emitter</span></a><a href="#getstorymessages"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>Messages</span></a><a href="#getstoryprogressemitter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>Progress<wbr/>Emitter</span></a><a href="#getstorystate"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Story<wbr/>State</span></a><a href="#gettransactionbypaymentid"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Transaction<wbr/>By<wbr/>Payment<wbr/>Id</span></a><a href="#gettransactions"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>Transactions</span></a><a href="#getuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>User<wbr/>Artifact</span></a><a href="#getuserpreferences"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>User<wbr/>Preferences</span></a><a href="#getuserpromptsdir"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>get<wbr/>User<wbr/>Prompts<wbr/>Dir</span></a><a href="#importstoryfromzip"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>import<wbr/>Story<wbr/>From<wbr/>Zip</span></a><a href="#interruptstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>interrupt<wbr/>Story</span></a><a href="#introducecharactertostory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>introduce<wbr/>Character<wbr/>To<wbr/>Story</span></a><a href="#listagentartifacts"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Agent<wbr/>Artifacts</span></a><a href="#listagents"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Agents</span></a><a href="#listaimodels"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Ai<wbr/>Models</span></a><a href="#listattachedfiles"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Attached<wbr/>Files</span></a><a href="#listchapters"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Chapters</span></a><a href="#listcharacters"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Characters</span></a><a href="#listimagemodels"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Image<wbr/>Models</span></a><a href="#listnativetoolsummaries"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Native<wbr/>Tool<wbr/>Summaries</span></a><a href="#listpromptfiles"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompt<wbr/>Files</span></a><a href="#listpromptfileswithscope"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompt<wbr/>Files<wbr/>With<wbr/>Scope</span></a><a href="#listpromptfolders"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompt<wbr/>Folders</span></a><a href="#listpromptfolderswithscope"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompt<wbr/>Folders<wbr/>With<wbr/>Scope</span></a><a href="#listprompts"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Prompts</span></a><a href="#listpublishedagents"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Published<wbr/>Agents</span></a><a href="#listpublishedrooms"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Published<wbr/>Rooms</span></a><a href="#listrooms"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Rooms</span></a><a href="#liststories"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Stories</span></a><a href="#liststoryartifacts"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Story<wbr/>Artifacts</span></a><a href="#liststorygenres"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Story<wbr/>Genres</span></a><a href="#liststorymodels"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Story<wbr/>Models</span></a><a href="#listtools"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>Tools</span></a><a href="#listuserartifacts"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>list<wbr/>User<wbr/>Artifacts</span></a><a href="#pauseroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>pause<wbr/>Room</span></a><a href="#processtext"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>process<wbr/>Text</span></a><a href="#progressstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>progress<wbr/>Story</span></a><a href="#publishagentinstance"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>publish<wbr/>Agent<wbr/>Instance</span></a><a href="#publishartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>publish<wbr/>Artifact</span></a><a href="#publishroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>publish<wbr/>Room</span></a><a href="#recordtransaction"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>record<wbr/>Transaction</span></a><a href="#reloadagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reload<wbr/>Agent</span></a><a href="#removeroomagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>remove<wbr/>Room<wbr/>Agent</span></a><a href="#renameuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>rename<wbr/>User<wbr/>Artifact</span></a><a href="#resetpublishedinstance"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reset<wbr/>Published<wbr/>Instance</span></a><a href="#resetpublishedroominstance"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reset<wbr/>Published<wbr/>Room<wbr/>Instance</span></a><a href="#resetroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reset<wbr/>Room</span></a><a href="#resetstory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>reset<wbr/>Story</span></a><a href="#respondtostory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>respond<wbr/>To<wbr/>Story</span></a><a href="#resumepausedstories"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>resume<wbr/>Paused<wbr/>Stories</span></a><a href="#resumeroom"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>resume<wbr/>Room</span></a><a href="#revertstorychapter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>revert<wbr/>Story<wbr/>Chapter</span></a><a href="#runpreparedprompt"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>run<wbr/>Prepared<wbr/>Prompt</span></a><a href="#savechapter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>Chapter</span></a><a href="#savecharacter"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>Character</span></a><a href="#savecharacterinventory"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>Character<wbr/>Inventory</span></a><a href="#saveplotplan"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>Plot<wbr/>Plan</span></a><a href="#savepromptfile"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>Prompt<wbr/>File</span></a><a href="#saveuserpreferences"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>save<wbr/>User<wbr/>Preferences</span></a><a href="#sendroommessage"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>send<wbr/>Room<wbr/>Message</span></a><a href="#setroomleader"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>set<wbr/>Room<wbr/>Leader</span></a><a href="#testtool"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>test<wbr/>Tool</span></a><a href="#updateagent"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>Agent</span></a><a href="#updatetool"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>Tool</span></a><a href="#updatetransactionstatus"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>Transaction<wbr/>Status</span></a><a href="#updateuserartifact"><svg class="tsd-kind-icon" viewBox="0 0 24 24" aria-label="Method"><use href="../assets/icons.svg#icon-2048"></use></svg><span>update<wbr/>User<wbr/>Artifact</span></a></div></details></div></details></div><div class="site-menu"><nav id="tsd-sidebar-links" class="tsd-navigation"><a href="https://github.com/your-org/briyah" class="tsd-nav-link">GitHub</a><a href="https://www.npmjs.com/package/briyah" class="tsd-nav-link">npm</a></nav><nav class="tsd-navigation"><a href="../modules.html">Briyah SDK - v1.4.0</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer><p class="tsd-generator">Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></footer><div class="overlay"></div></body></html>