@cartanova/qgrid-ai-sdk 2.8.0 → 2.9.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.
- package/README.ko.md +18 -13
- package/README.md +18 -13
- package/dist/index.d.ts +1 -1
- package/package.json +1 -1
package/README.ko.md
CHANGED
|
@@ -12,8 +12,8 @@ AI SDK v6 custom `LanguageModelV3` provider for [qgrid](https://github.com/carta
|
|
|
12
12
|
+import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
13
13
|
|
|
14
14
|
const { text } = await generateText({
|
|
15
|
-
- model: openai("gpt-5.
|
|
16
|
-
+ model: qgrid("openai/gpt-5.
|
|
15
|
+
- model: openai("gpt-5.6-luna"),
|
|
16
|
+
+ model: qgrid("openai/gpt-5.6-luna"),
|
|
17
17
|
prompt: "서울 날씨 알려줘",
|
|
18
18
|
});
|
|
19
19
|
```
|
|
@@ -43,7 +43,7 @@ import { generateText } from "ai";
|
|
|
43
43
|
import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
44
44
|
|
|
45
45
|
const { text } = await generateText({
|
|
46
|
-
model: qgrid("openai/gpt-5.
|
|
46
|
+
model: qgrid("openai/gpt-5.6-luna"),
|
|
47
47
|
prompt: "서울 날씨 알려줘",
|
|
48
48
|
});
|
|
49
49
|
```
|
|
@@ -62,7 +62,7 @@ import { generateText } from "ai";
|
|
|
62
62
|
import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
63
63
|
|
|
64
64
|
const { text } = await generateText({
|
|
65
|
-
model: qgrid("openai/gpt-5.
|
|
65
|
+
model: qgrid("openai/gpt-5.6-luna"),
|
|
66
66
|
system: "당신은 학술 논문 요약가입니다.",
|
|
67
67
|
prompt: paperText,
|
|
68
68
|
});
|
|
@@ -77,7 +77,7 @@ import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
|
77
77
|
import { z } from "zod";
|
|
78
78
|
|
|
79
79
|
const { output } = await generateText({
|
|
80
|
-
model: qgrid("openai/gpt-5.
|
|
80
|
+
model: qgrid("openai/gpt-5.6-terra"),
|
|
81
81
|
system: "논문 메타데이터를 추출해주세요.",
|
|
82
82
|
prompt: paperText,
|
|
83
83
|
output: Output.object({
|
|
@@ -104,7 +104,7 @@ import { streamText } from "ai";
|
|
|
104
104
|
import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
105
105
|
|
|
106
106
|
const { textStream } = streamText({
|
|
107
|
-
model: qgrid("openai/gpt-5.
|
|
107
|
+
model: qgrid("openai/gpt-5.6-luna"),
|
|
108
108
|
prompt: "TypeScript의 장점을 설명해줘",
|
|
109
109
|
});
|
|
110
110
|
|
|
@@ -121,7 +121,7 @@ import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
|
121
121
|
import { z } from "zod";
|
|
122
122
|
|
|
123
123
|
const { text } = await generateText({
|
|
124
|
-
model: qgrid("openai/gpt-5.
|
|
124
|
+
model: qgrid("openai/gpt-5.6-luna"),
|
|
125
125
|
prompt: "서울 날씨 알려줘",
|
|
126
126
|
tools: {
|
|
127
127
|
getWeather: tool({
|
|
@@ -149,7 +149,7 @@ import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
|
149
149
|
import { z } from "zod";
|
|
150
150
|
|
|
151
151
|
const { output } = await generateText({
|
|
152
|
-
model: qgrid("openai/gpt-5.
|
|
152
|
+
model: qgrid("openai/gpt-5.6-terra"),
|
|
153
153
|
prompt: "서울 날씨를 조회해서 예보를 반환해줘.",
|
|
154
154
|
tools: {
|
|
155
155
|
getWeather: tool({
|
|
@@ -187,7 +187,7 @@ import { generateText } from "ai";
|
|
|
187
187
|
import { qgrid, type QgridProviderOptions } from "@cartanova/qgrid-ai-sdk";
|
|
188
188
|
|
|
189
189
|
const { text } = await generateText({
|
|
190
|
-
model: qgrid("openai/gpt-5.
|
|
190
|
+
model: qgrid("openai/gpt-5.6-terra"),
|
|
191
191
|
prompt: "복잡한 문제를 분석해줘",
|
|
192
192
|
providerOptions: {
|
|
193
193
|
qgrid: {
|
|
@@ -240,7 +240,7 @@ Anthropic `generateText` 요청에는 전역 설정을 바꾸지 않는 요청
|
|
|
240
240
|
|
|
241
241
|
```typescript
|
|
242
242
|
const { text } = await generateText({
|
|
243
|
-
model: qgrid("openai/gpt-5.
|
|
243
|
+
model: qgrid("openai/gpt-5.6-luna"),
|
|
244
244
|
prompt: nextTurnPrompt,
|
|
245
245
|
providerOptions: { qgrid: { sessionKey: "game-session-123" } },
|
|
246
246
|
});
|
|
@@ -255,7 +255,7 @@ OpenAI/codex 경로 전용, `generateText` 전용입니다. 해당 요청에만
|
|
|
255
255
|
|
|
256
256
|
```typescript
|
|
257
257
|
const result = await generateText({
|
|
258
|
-
model: qgrid("openai/gpt-5.
|
|
258
|
+
model: qgrid("openai/gpt-5.6-terra"),
|
|
259
259
|
prompt: "우주를 나는 고래 일러스트",
|
|
260
260
|
providerOptions: {
|
|
261
261
|
qgrid: {
|
|
@@ -272,7 +272,7 @@ const image = result.files[0]; // mediaType: "image/png", base64
|
|
|
272
272
|
|
|
273
273
|
```typescript
|
|
274
274
|
const result = await generateText({
|
|
275
|
-
model: qgrid("openai/gpt-5.
|
|
275
|
+
model: qgrid("openai/gpt-5.6-terra"),
|
|
276
276
|
messages: [
|
|
277
277
|
{
|
|
278
278
|
role: "user",
|
|
@@ -370,6 +370,7 @@ type QgridSupportedModel =
|
|
|
370
370
|
| "openai/gpt-5.3-codex"
|
|
371
371
|
| "openai/gpt-5.3-codex-spark"
|
|
372
372
|
// Anthropic
|
|
373
|
+
| "anthropic/claude-fable-5-1"
|
|
373
374
|
| "anthropic/claude-fable-5"
|
|
374
375
|
| "anthropic/claude-haiku-4-5"
|
|
375
376
|
| "anthropic/claude-sonnet-4"
|
|
@@ -386,6 +387,8 @@ type QgridSupportedModel =
|
|
|
386
387
|
| "anthropic/claude-opus-5"
|
|
387
388
|
```
|
|
388
389
|
|
|
390
|
+
`openai/gpt-5.4`, `openai/gpt-5.4-mini`, `openai/gpt-5.2`, `openai/gpt-5.3-codex`는 하위 호환을 위해 타입에 남아 있지만, qgrid가 사용하는 ChatGPT 구독 Codex 경로에서는 더 이상 제공되지 않습니다. `gpt-5.4`와 `gpt-5.4-mini`는 2026-08-31에 retire되었고(대체: `openai/gpt-5.6-terra`, `openai/gpt-5.6-luna`), `gpt-5.2`와 `gpt-5.3-codex`는 그보다 먼저 해당 경로에서 제거되었습니다. 이 id로 요청하면 백엔드에서 실패합니다.
|
|
391
|
+
|
|
389
392
|
### GPT-5.6 사양
|
|
390
393
|
|
|
391
394
|
| 모델 | Context (qgrid OpenAI 경로) | 최대 출력 | 1M tokens당 input / cached input / output |
|
|
@@ -398,9 +401,11 @@ type QgridSupportedModel =
|
|
|
398
401
|
|
|
399
402
|
`anthropic/claude-fable-5`는 1M context와 128K 최대 출력을 지원합니다. 1M tokens당 표준 단가는 input $10, cache read $1, 5분 cache write $12.50, 1시간 cache write $20, output $50입니다. qgrid는 Claude 응답의 5분/1시간 cache creation breakdown을 보존해 TTL별 단가를 각각 적용하며, breakdown이 없는 구버전 응답에서만 Claude Code가 subscription OAuth 경로에 자동 적용하는 1시간 TTL 단가로 fallback합니다. Fable은 adaptive thinking이 항상 켜져 있어야 하므로 qgrid는 이 모델의 adaptive thinking을 보존합니다.
|
|
400
403
|
|
|
404
|
+
`anthropic/claude-fable-5-1`(2026-09-01 출시)은 Fable 5와 같은 1M context, 128K 최대 출력, 항상 켜진 adaptive thinking, input $10 / output $50 단가를 공유합니다. cache read만 Fable 5의 $1 대신 1M tokens당 $0.25(input의 0.025x)로 과금되며, cache write는 $12.50(5분)/$20(1시간)으로 같습니다. Fable 5.1의 API 수준 파괴적 변경(forced `tool_choice` 거부, 모델에 귀속된 thinking 블록)은 qgrid에 영향을 주지 않습니다. qgrid는 도구를 끈 Claude Code를 fresh 프로세스로 실행하고 히스토리를 텍스트로 평탄화해 전달하기 때문입니다.
|
|
405
|
+
|
|
401
406
|
`anthropic/claude-opus-5`는 기본 1M context와 128K 최대 출력을 지원합니다. 1M tokens당 단가는 input $5, cache read $0.50, 5분 cache write $6.25, 1시간 cache write $10, output $25입니다. qgrid는 Opus 5의 기본 adaptive thinking 동작을 유지하고 `effort`로 추론 깊이를 조절합니다. 따라서 `xhigh` 또는 `max` effort에서 허용되지 않는 `thinking: disabled` 조합도 만들지 않습니다.
|
|
402
407
|
|
|
403
|
-
Claude Code는 Fable의 safety refusal을 Opus
|
|
408
|
+
Claude Code는 Fable의 safety refusal을 다른 Opus 모델로 자동 재시도할 수 있습니다. 현재 CLI는 refusal 카테고리에 따라 Opus 5 또는 Opus 4.8을 고릅니다. 이 경우 AI SDK 응답의 `response.modelId`와 `providerMetadata.qgrid.model`은 실제 serving 모델인 Opus를 가리킵니다. `providerMetadata.qgrid.requestedModel`은 Fable로 유지되고, `providerMetadata.qgrid.modelFallbacks`에 refusal fallback 이력이 담깁니다. 같은 metadata에서 `costSource`와 5분/1시간 cache-write 토큰 분해도 확인할 수 있습니다.
|
|
404
409
|
|
|
405
410
|
`openai/gpt-5.3-codex-spark`는 아직 token 단가가 확정·공개되지 않은 research preview입니다. 따라서 qgrid는 generic fallback 추정치를 보고하며, 이를 공식 단가로 취급하지 않습니다.
|
|
406
411
|
|
package/README.md
CHANGED
|
@@ -12,8 +12,8 @@ AI SDK v6 custom `LanguageModelV3` provider for [qgrid](https://github.com/carta
|
|
|
12
12
|
+import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
13
13
|
|
|
14
14
|
const { text } = await generateText({
|
|
15
|
-
- model: openai("gpt-5.
|
|
16
|
-
+ model: qgrid("openai/gpt-5.
|
|
15
|
+
- model: openai("gpt-5.6-luna"),
|
|
16
|
+
+ model: qgrid("openai/gpt-5.6-luna"),
|
|
17
17
|
prompt: "What's the weather in Seoul?",
|
|
18
18
|
});
|
|
19
19
|
```
|
|
@@ -43,7 +43,7 @@ import { generateText } from "ai";
|
|
|
43
43
|
import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
44
44
|
|
|
45
45
|
const { text } = await generateText({
|
|
46
|
-
model: qgrid("openai/gpt-5.
|
|
46
|
+
model: qgrid("openai/gpt-5.6-luna"),
|
|
47
47
|
prompt: "What's the weather in Seoul?",
|
|
48
48
|
});
|
|
49
49
|
```
|
|
@@ -62,7 +62,7 @@ import { generateText } from "ai";
|
|
|
62
62
|
import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
63
63
|
|
|
64
64
|
const { text } = await generateText({
|
|
65
|
-
model: qgrid("openai/gpt-5.
|
|
65
|
+
model: qgrid("openai/gpt-5.6-luna"),
|
|
66
66
|
system: "You are an academic paper summarizer.",
|
|
67
67
|
prompt: paperText,
|
|
68
68
|
});
|
|
@@ -77,7 +77,7 @@ import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
|
77
77
|
import { z } from "zod";
|
|
78
78
|
|
|
79
79
|
const { output } = await generateText({
|
|
80
|
-
model: qgrid("openai/gpt-5.
|
|
80
|
+
model: qgrid("openai/gpt-5.6-terra"),
|
|
81
81
|
system: "Extract the paper metadata.",
|
|
82
82
|
prompt: paperText,
|
|
83
83
|
output: Output.object({
|
|
@@ -112,7 +112,7 @@ import { streamText } from "ai";
|
|
|
112
112
|
import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
113
113
|
|
|
114
114
|
const { textStream } = streamText({
|
|
115
|
-
model: qgrid("openai/gpt-5.
|
|
115
|
+
model: qgrid("openai/gpt-5.6-luna"),
|
|
116
116
|
prompt: "Explain the benefits of TypeScript",
|
|
117
117
|
});
|
|
118
118
|
|
|
@@ -129,7 +129,7 @@ import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
|
129
129
|
import { z } from "zod";
|
|
130
130
|
|
|
131
131
|
const { text } = await generateText({
|
|
132
|
-
model: qgrid("openai/gpt-5.
|
|
132
|
+
model: qgrid("openai/gpt-5.6-luna"),
|
|
133
133
|
prompt: "What's the weather in Seoul?",
|
|
134
134
|
tools: {
|
|
135
135
|
getWeather: tool({
|
|
@@ -157,7 +157,7 @@ import { qgrid } from "@cartanova/qgrid-ai-sdk";
|
|
|
157
157
|
import { z } from "zod";
|
|
158
158
|
|
|
159
159
|
const { output } = await generateText({
|
|
160
|
-
model: qgrid("openai/gpt-5.
|
|
160
|
+
model: qgrid("openai/gpt-5.6-terra"),
|
|
161
161
|
prompt: "Look up Seoul's weather and return a forecast.",
|
|
162
162
|
tools: {
|
|
163
163
|
getWeather: tool({
|
|
@@ -196,7 +196,7 @@ import { generateText } from "ai";
|
|
|
196
196
|
import { qgrid, type QgridProviderOptions } from "@cartanova/qgrid-ai-sdk";
|
|
197
197
|
|
|
198
198
|
const { text } = await generateText({
|
|
199
|
-
model: qgrid("openai/gpt-5.
|
|
199
|
+
model: qgrid("openai/gpt-5.6-terra"),
|
|
200
200
|
prompt: "Analyze this complex problem",
|
|
201
201
|
providerOptions: {
|
|
202
202
|
qgrid: {
|
|
@@ -249,7 +249,7 @@ For multi-turn conversations, pass a caller-side domain ID (game session ID, cha
|
|
|
249
249
|
|
|
250
250
|
```typescript
|
|
251
251
|
const { text } = await generateText({
|
|
252
|
-
model: qgrid("openai/gpt-5.
|
|
252
|
+
model: qgrid("openai/gpt-5.6-luna"),
|
|
253
253
|
prompt: nextTurnPrompt,
|
|
254
254
|
providerOptions: { qgrid: { sessionKey: "game-session-123" } },
|
|
255
255
|
});
|
|
@@ -264,7 +264,7 @@ OpenAI/codex route only, `generateText` only. Enables codex's built-in `image_ge
|
|
|
264
264
|
|
|
265
265
|
```typescript
|
|
266
266
|
const result = await generateText({
|
|
267
|
-
model: qgrid("openai/gpt-5.
|
|
267
|
+
model: qgrid("openai/gpt-5.6-terra"),
|
|
268
268
|
prompt: "An illustration of a whale flying through space",
|
|
269
269
|
providerOptions: {
|
|
270
270
|
qgrid: {
|
|
@@ -281,7 +281,7 @@ Reference images can be passed through normal AI SDK multimodal message parts:
|
|
|
281
281
|
|
|
282
282
|
```typescript
|
|
283
283
|
const result = await generateText({
|
|
284
|
-
model: qgrid("openai/gpt-5.
|
|
284
|
+
model: qgrid("openai/gpt-5.6-terra"),
|
|
285
285
|
messages: [
|
|
286
286
|
{
|
|
287
287
|
role: "user",
|
|
@@ -380,6 +380,7 @@ type QgridSupportedModel =
|
|
|
380
380
|
| "openai/gpt-5.3-codex"
|
|
381
381
|
| "openai/gpt-5.3-codex-spark"
|
|
382
382
|
// Anthropic
|
|
383
|
+
| "anthropic/claude-fable-5-1"
|
|
383
384
|
| "anthropic/claude-fable-5"
|
|
384
385
|
| "anthropic/claude-haiku-4-5"
|
|
385
386
|
| "anthropic/claude-sonnet-4"
|
|
@@ -396,6 +397,8 @@ type QgridSupportedModel =
|
|
|
396
397
|
| "anthropic/claude-opus-5"
|
|
397
398
|
```
|
|
398
399
|
|
|
400
|
+
`openai/gpt-5.4`, `openai/gpt-5.4-mini`, `openai/gpt-5.2`, and `openai/gpt-5.3-codex` remain in the type for backward compatibility, but the ChatGPT-subscription Codex route that qgrid uses no longer serves them. `gpt-5.4` and `gpt-5.4-mini` retired on 2026-08-31 (replacements: `openai/gpt-5.6-terra` and `openai/gpt-5.6-luna`); `gpt-5.2` and `gpt-5.3-codex` were removed from that route earlier. Requests for these ids fail at the backend.
|
|
401
|
+
|
|
399
402
|
### GPT-5.6 specifications
|
|
400
403
|
|
|
401
404
|
| Model | Context (qgrid OpenAI route) | Max output | Input / cached input / output per 1M tokens |
|
|
@@ -408,9 +411,11 @@ All GPT-5.6 models support reasoning through `max`. Qgrid retains the observed s
|
|
|
408
411
|
|
|
409
412
|
`anthropic/claude-fable-5` has a 1M context window and 128K max output. Its standard prices per 1M tokens are $10 input, $1 cache read, $12.50 five-minute cache write, $20 one-hour cache write, and $50 output. qgrid preserves Claude's 5m/1h cache-creation breakdown and prices each TTL separately; only legacy responses without that breakdown fall back to the one-hour TTL automatically selected by Claude Code on subscription OAuth. Fable requires always-on adaptive thinking, so qgrid preserves adaptive thinking for this model.
|
|
410
413
|
|
|
414
|
+
`anthropic/claude-fable-5-1` (released 2026-09-01) shares Fable 5's 1M context window, 128K max output, always-on adaptive thinking, and $10 input / $50 output pricing. Its cache reads cost $0.25 per 1M tokens (0.025x the input price) instead of Fable 5's $1; cache writes stay at $12.50 (5m) and $20 (1h). Fable 5.1's API-level breaking changes (forced `tool_choice` rejection, model-bound thinking blocks) do not affect qgrid, which runs Claude Code with tools disabled and replays history as flattened text in a fresh process.
|
|
415
|
+
|
|
411
416
|
`anthropic/claude-opus-5` has a default 1M context window and 128K max output. Its prices per 1M tokens are $5 input, $0.50 cache read, $6.25 five-minute cache write, $10 one-hour cache write, and $25 output. qgrid keeps Opus 5's default adaptive thinking behavior and uses `effort` to control reasoning depth. This also avoids the invalid `thinking: disabled` combination at `xhigh` or `max` effort.
|
|
412
417
|
|
|
413
|
-
Claude Code may automatically retry a Fable safety refusal on Opus 4.8. In that case, the AI SDK response's `response.modelId` and `providerMetadata.qgrid.model` identify Opus as the actual serving model. `providerMetadata.qgrid.requestedModel` remains Fable, and `providerMetadata.qgrid.modelFallbacks` contains the refusal fallback history. The metadata also exposes `costSource` and the 5m/1h cache-write token split.
|
|
418
|
+
Claude Code may automatically retry a Fable safety refusal on another Opus model; the current CLI picks Opus 5 or Opus 4.8 by refusal category. In that case, the AI SDK response's `response.modelId` and `providerMetadata.qgrid.model` identify Opus as the actual serving model. `providerMetadata.qgrid.requestedModel` remains Fable, and `providerMetadata.qgrid.modelFallbacks` contains the refusal fallback history. The metadata also exposes `costSource` and the 5m/1h cache-write token split.
|
|
414
419
|
|
|
415
420
|
`openai/gpt-5.3-codex-spark` remains a research preview without final published per-token rates. qgrid therefore reports its generic fallback estimate rather than presenting that estimate as official pricing.
|
|
416
421
|
|
package/dist/index.d.ts
CHANGED
|
@@ -62,7 +62,7 @@ type QgridProviderOptions = {
|
|
|
62
62
|
size?: "1024x1024" | "1024x1536" | "1536x1024";
|
|
63
63
|
};
|
|
64
64
|
};
|
|
65
|
-
type QgridSupportedModel = "openai/gpt-5.6-sol" | "openai/gpt-5.6-terra" | "openai/gpt-5.6-luna" | "openai/gpt-5.5" | "openai/gpt-5.4" | "openai/gpt-5.2" | "openai/gpt-5.4-mini" | "openai/gpt-5.3-codex" | "openai/gpt-5.3-codex-spark" | "anthropic/claude-fable-5" | "anthropic/claude-haiku-4-5" | "anthropic/claude-sonnet-4" | "anthropic/claude-sonnet-4-5" | "anthropic/claude-sonnet-4-6" | "anthropic/claude-sonnet-4-7" | "anthropic/claude-sonnet-5" | "anthropic/claude-opus-4" | "anthropic/claude-opus-4-1" | "anthropic/claude-opus-4-5" | "anthropic/claude-opus-4-6" | "anthropic/claude-opus-4-7" | "anthropic/claude-opus-4-8" | "anthropic/claude-opus-5";
|
|
65
|
+
type QgridSupportedModel = "openai/gpt-5.6-sol" | "openai/gpt-5.6-terra" | "openai/gpt-5.6-luna" | "openai/gpt-5.5" | "openai/gpt-5.4" | "openai/gpt-5.2" | "openai/gpt-5.4-mini" | "openai/gpt-5.3-codex" | "openai/gpt-5.3-codex-spark" | "anthropic/claude-fable-5-1" | "anthropic/claude-fable-5" | "anthropic/claude-haiku-4-5" | "anthropic/claude-sonnet-4" | "anthropic/claude-sonnet-4-5" | "anthropic/claude-sonnet-4-6" | "anthropic/claude-sonnet-4-7" | "anthropic/claude-sonnet-5" | "anthropic/claude-opus-4" | "anthropic/claude-opus-4-1" | "anthropic/claude-opus-4-5" | "anthropic/claude-opus-4-6" | "anthropic/claude-opus-4-7" | "anthropic/claude-opus-4-8" | "anthropic/claude-opus-5";
|
|
66
66
|
type QgridLoggerConfig = {
|
|
67
67
|
/** qgrid 서버 주소. default: process.env.QGRID_URL, 없으면 기본값은 "http://localhost:44900" */
|
|
68
68
|
serverUrl?: string;
|