@things-factory/ai-client-base 10.1.212 → 10.1.213

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@things-factory/ai-client-base",
3
- "version": "10.1.212",
3
+ "version": "10.1.213",
4
4
  "main": "dist-server/index.js",
5
5
  "things-factory": true,
6
6
  "author": "heartyoh",
@@ -24,11 +24,11 @@
24
24
  "dependencies": {
25
25
  "@anthropic-ai/sdk": "^0.40.0",
26
26
  "@google/generative-ai": "^0.24.0",
27
- "@things-factory/auth-base": "^10.1.212",
27
+ "@things-factory/auth-base": "^10.1.213",
28
28
  "@things-factory/env": "^10.1.149",
29
- "@things-factory/setting-base": "^10.1.212",
29
+ "@things-factory/setting-base": "^10.1.213",
30
30
  "@things-factory/shell": "^10.1.208",
31
31
  "openai": "^4.0.0"
32
32
  },
33
- "gitHead": "1e1cdb79fca2915580429af451b6cf1dae653a93"
33
+ "gitHead": "81f23aa18cb584c7d8185e81cca0d688f509cf8c"
34
34
  }
@@ -101,7 +101,8 @@ export interface RegistryAssistantInput {
101
101
  */
102
102
  onToolCall?: (record: ToolCallRecord) => void
103
103
  /** Set for an unattended run; tools and recorders see it as `context.run`. */
104
- run?: UnattendedRunRef
104
+ run?: UnattendedRunRef /** The stored conversation of this turn; tools see it as `context.conversation`. The caller's value, never the client's. */
105
+ conversation?: { id: string }
105
106
  }
106
107
 
107
108
  export interface RegistryAssistantResult extends AssistantChatResult<unknown> {
@@ -165,7 +166,8 @@ export async function registryAssistantChat(input: RegistryAssistantInput): Prom
165
166
  /* 번역기와 첨부는 서버의 값이다 — `host` 에서 받지 않는다(ADR-0061 2026-10-16 판정 1·2). */
166
167
  t: input.t ?? defaultValueTranslate,
167
168
  attachments: input.attachments ?? [],
168
- ...(input.run ? { run: input.run } : {})
169
+ ...(input.run ? { run: input.run } : {}),
170
+ ...(input.conversation?.id ? { conversation: { id: input.conversation.id } } : {})
169
171
  }
170
172
 
171
173
  const recorded = async (run: ToolCallRun, context: ToolCallContext) => {
@@ -75,6 +75,12 @@ export interface ToolCallContext {
75
75
  * it; a turn has none. The server's value - never from `host`.
76
76
  */
77
77
  run?: UnattendedRunRef
78
+ /**
79
+ * The stored conversation this turn belongs to - the server's value, never from `host`. A tool that acts on the room
80
+ * itself (inviting someone into it) reads it and asks the room's own rules; absent on a surface with no stored
81
+ * conversation and in an unattended run.
82
+ */
83
+ conversation?: { id: string }
78
84
  }
79
85
 
80
86
  export interface ToolCallMode {