@playdrop/playdrop-cli 0.17.2 → 0.17.5

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 (34) hide show
  1. package/config/client-meta.json +4 -4
  2. package/dist/apps/build.js +24 -4
  3. package/dist/apps/upload.js +31 -14
  4. package/dist/assetSpecs.js +2 -0
  5. package/dist/commands/upload-content.js +2 -0
  6. package/dist/commands/upload.js +3 -3
  7. package/dist/commands/worker/classification.d.ts +1 -0
  8. package/dist/commands/worker/classification.js +57 -0
  9. package/dist/commands/worker/game-source-commands.d.ts +18 -0
  10. package/dist/commands/worker/game-source-commands.js +182 -0
  11. package/dist/commands/worker/game-source-git.d.ts +1 -0
  12. package/dist/commands/worker/game-source-git.js +44 -16
  13. package/dist/commands/worker/generation.d.ts +3 -0
  14. package/dist/commands/worker/generation.js +71 -21
  15. package/dist/commands/worker.js +352 -249
  16. package/node_modules/@playdrop/api-client/dist/domains/chat.d.ts.map +1 -1
  17. package/node_modules/@playdrop/api-client/dist/domains/chat.js +7 -2
  18. package/node_modules/@playdrop/config/client-meta.json +4 -4
  19. package/node_modules/@playdrop/config/dist/tsconfig.tsbuildinfo +1 -1
  20. package/node_modules/@playdrop/types/dist/agent-task-classification.d.ts +68 -0
  21. package/node_modules/@playdrop/types/dist/agent-task-classification.d.ts.map +1 -0
  22. package/node_modules/@playdrop/types/dist/agent-task-classification.js +96 -0
  23. package/node_modules/@playdrop/types/dist/api.d.ts +2 -0
  24. package/node_modules/@playdrop/types/dist/api.d.ts.map +1 -1
  25. package/node_modules/@playdrop/types/dist/index.d.ts +1 -0
  26. package/node_modules/@playdrop/types/dist/index.d.ts.map +1 -1
  27. package/node_modules/@playdrop/types/dist/index.js +2 -0
  28. package/package.json +2 -2
  29. package/node_modules/@playwright/mcp/node_modules/fsevents/LICENSE +0 -22
  30. package/node_modules/@playwright/mcp/node_modules/fsevents/README.md +0 -83
  31. package/node_modules/@playwright/mcp/node_modules/fsevents/fsevents.d.ts +0 -46
  32. package/node_modules/@playwright/mcp/node_modules/fsevents/fsevents.js +0 -82
  33. package/node_modules/@playwright/mcp/node_modules/fsevents/fsevents.node +0 -0
  34. package/node_modules/@playwright/mcp/node_modules/fsevents/package.json +0 -62
@@ -0,0 +1,68 @@
1
+ /** Descriptive screening metadata. Never use this to route, bill or version a task. */
2
+ export declare const AGENT_TASK_CLASSIFICATION_CATEGORIES: {
3
+ readonly question: readonly ["game_explanation", "capabilities"];
4
+ readonly game_work: readonly ["validation", "technical_fix", "visual_fix", "visual_polish", "gameplay_polish", "new_game", "feature", "refactor", "listing_marketing"];
5
+ readonly reject: readonly ["private_information", "content_policy", "exact_copy", "asset_theft", "unrelated", "unclear"];
6
+ };
7
+ export declare const AGENT_TASK_CLASSIFICATION_EFFORTS: readonly ["simple", "standard", "complex", "extra_ambitious"];
8
+ export declare const AGENT_TASK_CLASSIFICATION_MIN_CLI = "0.17.5";
9
+ export declare const AGENT_TASK_CLASSIFICATION_PROMPT_VERSION = 1;
10
+ export interface AgentTaskClassification {
11
+ type: keyof typeof AGENT_TASK_CLASSIFICATION_CATEGORIES;
12
+ category: (typeof AGENT_TASK_CLASSIFICATION_CATEGORIES)[keyof typeof AGENT_TASK_CLASSIFICATION_CATEGORIES][number];
13
+ effort: (typeof AGENT_TASK_CLASSIFICATION_EFFORTS)[number] | null;
14
+ flags: string[];
15
+ reason: string;
16
+ promptLanguage: string;
17
+ promptEnglishTranslation: string;
18
+ }
19
+ export declare const AGENT_TASK_CLASSIFICATION_SCHEMA: {
20
+ anyOf: {
21
+ type: string;
22
+ additionalProperties: boolean;
23
+ required: string[];
24
+ properties: {
25
+ type: {
26
+ type: string;
27
+ enum: string[];
28
+ };
29
+ category: {
30
+ type: string;
31
+ enum: ("game_explanation" | "capabilities" | "validation" | "technical_fix" | "visual_fix" | "visual_polish" | "gameplay_polish" | "new_game" | "feature" | "refactor" | "listing_marketing" | "private_information" | "content_policy" | "exact_copy" | "asset_theft" | "unrelated" | "unclear")[];
32
+ };
33
+ effort: {
34
+ type: string;
35
+ enum?: never;
36
+ } | {
37
+ type: string;
38
+ enum: ("simple" | "standard" | "complex" | "extra_ambitious")[];
39
+ };
40
+ flags: {
41
+ type: string;
42
+ maxItems: number;
43
+ items: {
44
+ type: string;
45
+ maxLength: number;
46
+ pattern: string;
47
+ };
48
+ };
49
+ reason: {
50
+ type: string;
51
+ minLength: number;
52
+ maxLength: number;
53
+ };
54
+ promptLanguage: {
55
+ type: string;
56
+ minLength: number;
57
+ maxLength: number;
58
+ };
59
+ promptEnglishTranslation: {
60
+ type: string;
61
+ minLength: number;
62
+ maxLength: number;
63
+ };
64
+ };
65
+ }[];
66
+ };
67
+ export declare function normalizeAgentTaskClassification(value: unknown): AgentTaskClassification | null;
68
+ //# sourceMappingURL=agent-task-classification.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"agent-task-classification.d.ts","sourceRoot":"","sources":["../src/agent-task-classification.ts"],"names":[],"mappings":"AAAA,uFAAuF;AACvF,eAAO,MAAM,oCAAoC;;;;CAIvC,CAAC;AACX,eAAO,MAAM,iCAAiC,+DAAgE,CAAC;AAC/G,eAAO,MAAM,iCAAiC,WAAW,CAAC;AAC1D,eAAO,MAAM,wCAAwC,IAAI,CAAC;AAE1D,MAAM,WAAW,uBAAuB;IACtC,IAAI,EAAE,MAAM,OAAO,oCAAoC,CAAC;IACxD,QAAQ,EAAE,CAAC,OAAO,oCAAoC,CAAC,CAAC,MAAM,OAAO,oCAAoC,CAAC,CAAC,MAAM,CAAC,CAAC;IACnH,MAAM,EAAE,CAAC,OAAO,iCAAiC,CAAC,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC;IAClE,KAAK,EAAE,MAAM,EAAE,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;IACf,cAAc,EAAE,MAAM,CAAC;IACvB,wBAAwB,EAAE,MAAM,CAAC;CAClC;AAED,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAe5C,CAAC;AAEF,wBAAgB,gCAAgC,CAAC,KAAK,EAAE,OAAO,GAAG,uBAAuB,GAAG,IAAI,CAwB/F"}
@@ -0,0 +1,96 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __export = (target, all) => {
6
+ for (var name in all)
7
+ __defProp(target, name, { get: all[name], enumerable: true });
8
+ };
9
+ var __copyProps = (to, from, except, desc) => {
10
+ if (from && typeof from === "object" || typeof from === "function") {
11
+ for (let key of __getOwnPropNames(from))
12
+ if (!__hasOwnProp.call(to, key) && key !== except)
13
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
14
+ }
15
+ return to;
16
+ };
17
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
18
+ var agent_task_classification_exports = {};
19
+ __export(agent_task_classification_exports, {
20
+ AGENT_TASK_CLASSIFICATION_CATEGORIES: () => AGENT_TASK_CLASSIFICATION_CATEGORIES,
21
+ AGENT_TASK_CLASSIFICATION_EFFORTS: () => AGENT_TASK_CLASSIFICATION_EFFORTS,
22
+ AGENT_TASK_CLASSIFICATION_MIN_CLI: () => AGENT_TASK_CLASSIFICATION_MIN_CLI,
23
+ AGENT_TASK_CLASSIFICATION_PROMPT_VERSION: () => AGENT_TASK_CLASSIFICATION_PROMPT_VERSION,
24
+ AGENT_TASK_CLASSIFICATION_SCHEMA: () => AGENT_TASK_CLASSIFICATION_SCHEMA,
25
+ normalizeAgentTaskClassification: () => normalizeAgentTaskClassification
26
+ });
27
+ module.exports = __toCommonJS(agent_task_classification_exports);
28
+ const AGENT_TASK_CLASSIFICATION_CATEGORIES = {
29
+ question: ["game_explanation", "capabilities"],
30
+ game_work: ["validation", "technical_fix", "visual_fix", "visual_polish", "gameplay_polish", "new_game", "feature", "refactor", "listing_marketing"],
31
+ reject: ["private_information", "content_policy", "exact_copy", "asset_theft", "unrelated", "unclear"]
32
+ };
33
+ const AGENT_TASK_CLASSIFICATION_EFFORTS = ["simple", "standard", "complex", "extra_ambitious"];
34
+ const AGENT_TASK_CLASSIFICATION_MIN_CLI = "0.17.5";
35
+ const AGENT_TASK_CLASSIFICATION_PROMPT_VERSION = 1;
36
+ const AGENT_TASK_CLASSIFICATION_SCHEMA = {
37
+ anyOf: Object.entries(AGENT_TASK_CLASSIFICATION_CATEGORIES).map(([type, categories]) => ({
38
+ type: "object",
39
+ additionalProperties: false,
40
+ required: ["type", "category", "effort", "flags", "reason", "promptLanguage", "promptEnglishTranslation"],
41
+ properties: {
42
+ type: { type: "string", enum: [type] },
43
+ category: { type: "string", enum: [...categories] },
44
+ effort: type === "reject" ? { type: "null" } : { type: "string", enum: [...AGENT_TASK_CLASSIFICATION_EFFORTS] },
45
+ flags: { type: "array", maxItems: 12, items: { type: "string", maxLength: 80, pattern: "^[A-Z][A-Z0-9_]*$" } },
46
+ reason: { type: "string", minLength: 1, maxLength: 600 },
47
+ promptLanguage: { type: "string", minLength: 2, maxLength: 35 },
48
+ promptEnglishTranslation: { type: "string", minLength: 1, maxLength: 1e5 }
49
+ }
50
+ }))
51
+ };
52
+ function normalizeAgentTaskClassification(value) {
53
+ if (!value || typeof value !== "object" || Array.isArray(value))
54
+ return null;
55
+ const { type, category, effort, flags, reason, promptLanguage, promptEnglishTranslation } = value;
56
+ if (type !== "question" && type !== "game_work" && type !== "reject")
57
+ return null;
58
+ const categories = AGENT_TASK_CLASSIFICATION_CATEGORIES[type];
59
+ if (typeof category !== "string" || !categories.includes(category))
60
+ return null;
61
+ const efforts = AGENT_TASK_CLASSIFICATION_EFFORTS;
62
+ if (type === "reject" ? effort !== null : !efforts.includes(effort))
63
+ return null;
64
+ if (!Array.isArray(flags) || flags.length > 12 || flags.some((flag) => typeof flag !== "string" || flag.length > 80 || !/^[A-Z][A-Z0-9_]*$/.test(flag)))
65
+ return null;
66
+ if (typeof reason !== "string" || !reason.trim() || reason.length > 600)
67
+ return null;
68
+ if (typeof promptEnglishTranslation !== "string" || !promptEnglishTranslation.trim() || promptEnglishTranslation.length > 1e5)
69
+ return null;
70
+ if (typeof promptLanguage !== "string" || promptLanguage.length > 35)
71
+ return null;
72
+ try {
73
+ if (Intl.getCanonicalLocales(promptLanguage).length !== 1)
74
+ return null;
75
+ } catch {
76
+ return null;
77
+ }
78
+ return {
79
+ type,
80
+ category,
81
+ effort,
82
+ flags: [...flags],
83
+ reason,
84
+ promptLanguage,
85
+ promptEnglishTranslation
86
+ };
87
+ }
88
+ // Annotate the CommonJS export names for ESM import in node:
89
+ 0 && (module.exports = {
90
+ AGENT_TASK_CLASSIFICATION_CATEGORIES,
91
+ AGENT_TASK_CLASSIFICATION_EFFORTS,
92
+ AGENT_TASK_CLASSIFICATION_MIN_CLI,
93
+ AGENT_TASK_CLASSIFICATION_PROMPT_VERSION,
94
+ AGENT_TASK_CLASSIFICATION_SCHEMA,
95
+ normalizeAgentTaskClassification
96
+ });
@@ -639,6 +639,8 @@ export interface AgentTaskResponseBase {
639
639
  usesFreeCloudGeneration: boolean;
640
640
  refund: AgentTaskRefundResponse | null;
641
641
  payload?: {
642
+ classification?: import("./agent-task-classification.js").AgentTaskClassification;
643
+ classificationPromptVersion?: number;
642
644
  safety?: Record<string, unknown>;
643
645
  model?: string;
644
646
  [key: string]: unknown;