@lingjingai/scriptctl 0.7.4 → 0.8.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.md +1 -1
- package/dist/common.d.ts +1 -5
- package/dist/common.js +1 -88
- package/dist/common.js.map +1 -1
- package/dist/help-text.js +1 -1
- package/dist/infra/providers.d.ts +7 -35
- package/dist/infra/providers.js +324 -314
- package/dist/infra/providers.js.map +1 -1
- package/dist/usecases/direct.js +14 -29
- package/dist/usecases/direct.js.map +1 -1
- package/package.json +6 -3
package/README.md
CHANGED
|
@@ -41,7 +41,7 @@ scriptctl script patch --patch <patch.json>
|
|
|
41
41
|
|---|---|
|
|
42
42
|
| `PROJECT_LITELLM_GATEWAY_API_KEY` | Anthropic key(仅 `--provider anthropic` 时需要) |
|
|
43
43
|
| `PROJECT_LITELLM_GATEWAY_BASE_URL` | 自定义 Anthropic gateway |
|
|
44
|
-
| `SCRIPTCTL_ANTHROPIC_MODEL` | 覆盖默认 model(默认 `claude-opus-4-7-
|
|
44
|
+
| `SCRIPTCTL_ANTHROPIC_MODEL` | 覆盖默认 model(默认 `claude-opus-4-7-packy`) |
|
|
45
45
|
| `AWB_BASE_URL` | script-output gateway URL |
|
|
46
46
|
| `LINGJING_AWB_ACCESS_KEY` | gateway 访问凭证 |
|
|
47
47
|
| `SANDBOX_PROJECT_GROUP_NO` | 项目组号(也可用 `--project-group-no`) |
|
package/dist/common.d.ts
CHANGED
|
@@ -16,7 +16,7 @@ export declare const EXIT_NEEDS_AGENT = 78;
|
|
|
16
16
|
export declare function isDebug(): boolean;
|
|
17
17
|
export declare const DEFAULT_PROVIDER = "anthropic";
|
|
18
18
|
export declare const DEFAULT_CONCURRENCY = 30;
|
|
19
|
-
export declare const DEFAULT_MODEL = "claude-opus-4-7-
|
|
19
|
+
export declare const DEFAULT_MODEL = "claude-opus-4-7-packy";
|
|
20
20
|
export declare const DEFAULT_MAX_TOKENS = 32000;
|
|
21
21
|
export declare const DEFAULT_BATCH_MAX_TOKENS = 16000;
|
|
22
22
|
export declare const DEFAULT_PROVIDER_ATTEMPTS = 3;
|
|
@@ -42,10 +42,6 @@ export declare const EFFECTIVE_FROM_VALUES: Set<string>;
|
|
|
42
42
|
export declare const ACTOR_REUSE_SCENE_LIMIT = 1;
|
|
43
43
|
export declare const PROP_REUSE_SCENE_LIMIT = 1;
|
|
44
44
|
export declare const MARKDOWN_BATCH_PROMPT_SPEC: string;
|
|
45
|
-
export type JsonSchema = Record<string, unknown>;
|
|
46
|
-
export declare const METADATA_EXTRACTION_SCHEMA: JsonSchema;
|
|
47
|
-
export declare const ASSET_CURATION_SCHEMA: JsonSchema;
|
|
48
|
-
export declare const EPISODE_TITLE_EXTRACTION_SCHEMA: JsonSchema;
|
|
49
45
|
export interface Report {
|
|
50
46
|
title?: string;
|
|
51
47
|
message?: string;
|
package/dist/common.js
CHANGED
|
@@ -21,7 +21,7 @@ export function isDebug() {
|
|
|
21
21
|
}
|
|
22
22
|
export const DEFAULT_PROVIDER = "anthropic";
|
|
23
23
|
export const DEFAULT_CONCURRENCY = 30;
|
|
24
|
-
export const DEFAULT_MODEL = "claude-opus-4-7-
|
|
24
|
+
export const DEFAULT_MODEL = "claude-opus-4-7-packy";
|
|
25
25
|
export const DEFAULT_MAX_TOKENS = 32000;
|
|
26
26
|
export const DEFAULT_BATCH_MAX_TOKENS = 16000;
|
|
27
27
|
export const DEFAULT_PROVIDER_ATTEMPTS = 3;
|
|
@@ -178,93 +178,6 @@ export const MARKDOWN_BATCH_PROMPT_SPEC = "Output format: a single markdown docu
|
|
|
178
178
|
" An item without `:` carries no description.\n" +
|
|
179
179
|
"- Lines marked [meta] in Batch Source are read-only metadata; do not promote\n" +
|
|
180
180
|
" them to actions.\n";
|
|
181
|
-
export const METADATA_EXTRACTION_SCHEMA = {
|
|
182
|
-
type: "object",
|
|
183
|
-
required: ["confidence", "worldview", "worldview_raw", "actors", "locations", "props"],
|
|
184
|
-
additionalProperties: false,
|
|
185
|
-
properties: {
|
|
186
|
-
confidence: { type: "string", enum: ["high", "medium", "low"] },
|
|
187
|
-
worldview: { type: "string", enum: WORLDVIEW_VALUES },
|
|
188
|
-
worldview_raw: { type: "string" },
|
|
189
|
-
actors: {
|
|
190
|
-
type: "array",
|
|
191
|
-
items: {
|
|
192
|
-
type: "object",
|
|
193
|
-
required: ["actor_id", "role_type", "description"],
|
|
194
|
-
additionalProperties: false,
|
|
195
|
-
properties: {
|
|
196
|
-
actor_id: { type: "string" },
|
|
197
|
-
role_type: { type: "string", enum: ROLE_TYPE_VALUES },
|
|
198
|
-
description: { type: "string" },
|
|
199
|
-
},
|
|
200
|
-
},
|
|
201
|
-
},
|
|
202
|
-
locations: {
|
|
203
|
-
type: "array",
|
|
204
|
-
items: {
|
|
205
|
-
type: "object",
|
|
206
|
-
required: ["location_id", "description"],
|
|
207
|
-
additionalProperties: false,
|
|
208
|
-
properties: {
|
|
209
|
-
location_id: { type: "string" },
|
|
210
|
-
description: { type: "string" },
|
|
211
|
-
},
|
|
212
|
-
},
|
|
213
|
-
},
|
|
214
|
-
props: {
|
|
215
|
-
type: "array",
|
|
216
|
-
items: {
|
|
217
|
-
type: "object",
|
|
218
|
-
required: ["prop_id", "description"],
|
|
219
|
-
additionalProperties: false,
|
|
220
|
-
properties: {
|
|
221
|
-
prop_id: { type: "string" },
|
|
222
|
-
description: { type: "string" },
|
|
223
|
-
},
|
|
224
|
-
},
|
|
225
|
-
},
|
|
226
|
-
},
|
|
227
|
-
};
|
|
228
|
-
export const ASSET_CURATION_SCHEMA = {
|
|
229
|
-
type: "object",
|
|
230
|
-
required: ["locations"],
|
|
231
|
-
additionalProperties: false,
|
|
232
|
-
properties: {
|
|
233
|
-
locations: {
|
|
234
|
-
type: "array",
|
|
235
|
-
items: {
|
|
236
|
-
type: "object",
|
|
237
|
-
required: ["location_id", "decision", "target_location_id", "reason"],
|
|
238
|
-
additionalProperties: false,
|
|
239
|
-
properties: {
|
|
240
|
-
location_id: { type: "string" },
|
|
241
|
-
decision: { type: "string", enum: ["keep", "merge"] },
|
|
242
|
-
target_location_id: { type: ["string", "null"] },
|
|
243
|
-
reason: { type: "string" },
|
|
244
|
-
},
|
|
245
|
-
},
|
|
246
|
-
},
|
|
247
|
-
},
|
|
248
|
-
};
|
|
249
|
-
export const EPISODE_TITLE_EXTRACTION_SCHEMA = {
|
|
250
|
-
type: "object",
|
|
251
|
-
required: ["episode_titles"],
|
|
252
|
-
additionalProperties: false,
|
|
253
|
-
properties: {
|
|
254
|
-
episode_titles: {
|
|
255
|
-
type: "array",
|
|
256
|
-
items: {
|
|
257
|
-
type: "object",
|
|
258
|
-
required: ["episode", "title"],
|
|
259
|
-
additionalProperties: false,
|
|
260
|
-
properties: {
|
|
261
|
-
episode: { type: "integer" },
|
|
262
|
-
title: { type: "string" },
|
|
263
|
-
},
|
|
264
|
-
},
|
|
265
|
-
},
|
|
266
|
-
},
|
|
267
|
-
};
|
|
268
181
|
export class CliError extends Error {
|
|
269
182
|
title;
|
|
270
183
|
exitCode;
|
package/dist/common.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"common.js","sourceRoot":"","sources":["../src/common.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,aAAa,CAAC;AACtC,OAAO,KAAK,EAAE,MAAM,SAAS,CAAC;AAC9B,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAElC,OAAO,EACL,aAAa,EACb,eAAe,GAEhB,MAAM,oBAAoB,CAAC;AAE5B,MAAM,CAAC,MAAM,OAAO,GAAG,CAAC,CAAC;AACzB,MAAM,CAAC,MAAM,UAAU,GAAG,EAAE,CAAC;AAC7B,MAAM,CAAC,MAAM,UAAU,GAAG,EAAE,CAAC;AAC7B,MAAM,CAAC,MAAM,YAAY,GAAG,EAAE,CAAC;AAC/B,MAAM,CAAC,MAAM,gBAAgB,GAAG,EAAE,CAAC;AAEnC;;;;;;;;GAQG;AACH,MAAM,UAAU,O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C,CAAC,CAAC;QACpC,CAAC;IACH,CAAC;YAAS,CAAC;QACT,EAAE,CAAC,SAAS,CAAC,EAAE,CAAC,CAAC;IACnB,CAAC;IACD,OAAO,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AAC9B,CAAC"}
|
package/dist/help-text.js
CHANGED
|
@@ -139,7 +139,7 @@ Required
|
|
|
139
139
|
Options
|
|
140
140
|
- --workspace-path Workspace directory. Default: workspace
|
|
141
141
|
- --provider LLM provider: anthropic, mock(test only). Default: anthropic
|
|
142
|
-
- --model Provider model. Default: claude-opus-4-7-
|
|
142
|
+
- --model Provider model. Default: claude-opus-4-7-packy
|
|
143
143
|
- --concurrency Parallel episode extraction workers. Default: 30
|
|
144
144
|
- --batch-mode Batch planning mode: episode. Default: episode
|
|
145
145
|
- --batch-target-lines Target non-metadata content lines per batch. Default: 36
|
|
@@ -13,53 +13,25 @@ export declare class MockProvider implements ProviderLike {
|
|
|
13
13
|
extractAssetCuration(_sourceText: string, _script: Dict): Dict;
|
|
14
14
|
extractEpisodeTitles(sourceText: string, episodePlan: Dict): Dict;
|
|
15
15
|
}
|
|
16
|
-
export declare class
|
|
16
|
+
export declare class LiteLLMProvider implements ProviderLike {
|
|
17
17
|
readonly name = "anthropic";
|
|
18
|
-
private readonly client;
|
|
19
18
|
private readonly model;
|
|
20
|
-
|
|
21
|
-
private
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
* Run a request that forces a specific tool call via `tool_choice`, then return that
|
|
25
|
-
* tool's `input` dict (already parsed by the SDK — no JSON.parse needed). Returns
|
|
26
|
-
* `null` when the provider didn't emit the expected tool_use block (e.g. refusal,
|
|
27
|
-
* truncated before tool call, gateway dropped tools field), letting the caller
|
|
28
|
-
* raise a method-specific CliError.
|
|
29
|
-
*/
|
|
30
|
-
private collectToolUseInput;
|
|
31
|
-
/**
|
|
32
|
-
* Generic completion entry point. Used by episode subcommand's gemini-writer to draft
|
|
33
|
-
* one episode's spec markdown from the assembled prompt. Throws CliError when the
|
|
34
|
-
* provider truncates output (so the caller can surface a deterministic error rather
|
|
35
|
-
* than committing a half-baked episode).
|
|
36
|
-
*/
|
|
19
|
+
private readonly modelId;
|
|
20
|
+
private readonly configuredMaxTokens;
|
|
21
|
+
constructor(modelId: string);
|
|
22
|
+
private capTokens;
|
|
37
23
|
complete(prompt: string, maxTokens?: number): Promise<string>;
|
|
38
24
|
extractEpisode(sourceText: string, episodePlan: Dict): Promise<Dict>;
|
|
39
25
|
extractBatch(sourceText: string, batchPlan: Dict): Promise<Dict>;
|
|
40
26
|
extractEpisodeTitles(sourceText: string, episodePlan: Dict): Promise<Dict>;
|
|
41
27
|
extractAssetCuration(_sourceText: string, script: Dict): Promise<Dict>;
|
|
42
28
|
extractMetadata(_sourceText: string, script: Dict): Promise<Dict>;
|
|
29
|
+
private extractStructured;
|
|
43
30
|
}
|
|
44
|
-
/**
|
|
45
|
-
* Google Gemini provider via REST API. No SDK dependency (uses fetch).
|
|
46
|
-
*
|
|
47
|
-
* Used as the default writer for `scriptctl episode draft`. The Anthropic provider
|
|
48
|
-
* stays available for other internal extraction tasks (metadata / title generation /
|
|
49
|
-
* direct-init batch extraction) where Claude tends to outperform Gemini on JSON
|
|
50
|
-
* schema adherence.
|
|
51
|
-
*
|
|
52
|
-
* Env:
|
|
53
|
-
* - `SCRIPTCTL_GEMINI_API_KEY` (or fallback `GEMINI_API_KEY`) required
|
|
54
|
-
* - `SCRIPTCTL_GEMINI_BASE_URL` optional override
|
|
55
|
-
* - `SCRIPTCTL_GEMINI_MODEL` optional default-model override
|
|
56
|
-
*/
|
|
57
31
|
export declare class GeminiProvider implements ProviderLike {
|
|
58
32
|
readonly name = "gemini";
|
|
59
|
-
private readonly apiKey;
|
|
60
|
-
private readonly baseUrl;
|
|
61
33
|
private readonly model;
|
|
62
|
-
constructor(
|
|
34
|
+
constructor(modelId?: string);
|
|
63
35
|
/**
|
|
64
36
|
* Plain-text completion. Used by `episode draft` to write a spec-md episode body.
|
|
65
37
|
*/
|