@make-u-free/migi 0.5.21 → 0.5.22

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 (2) hide show
  1. package/package.json +1 -1
  2. package/src/agent.js +10 -8
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@make-u-free/migi",
3
- "version": "0.5.21",
3
+ "version": "0.5.22",
4
4
  "description": "Your AI right-hand agent. Works anywhere, with any LLM API.",
5
5
  "type": "module",
6
6
  "bin": {
package/src/agent.js CHANGED
@@ -220,14 +220,16 @@ JSON形式のみで返答(他のテキスト不要):
220
220
  while (true) {
221
221
  spinner.start('考え中…')
222
222
 
223
- const stream = await this.client.chat.completions.create({
224
- model: this.model,
225
- messages,
226
- tools: this.tools,
227
- tool_choice: 'auto',
228
- stream: true,
229
- ...(signal ? { signal } : {})
230
- })
223
+ const stream = await this.client.chat.completions.create(
224
+ {
225
+ model: this.model,
226
+ messages,
227
+ tools: this.tools,
228
+ tool_choice: 'auto',
229
+ stream: true
230
+ },
231
+ signal ? { signal } : {}
232
+ )
231
233
 
232
234
  let content = ''
233
235
  const tcMap = {} // tool_calls をインデックスで蓄積