@outputai/cli 0.1.13-next.0bb44fb.0 → 0.1.13-next.0fd573d.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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Generated by orval v8.6.2 🍺
2
+ * Generated by orval v8.8.0 🍺
3
3
  * Do not edit manually.
4
4
  * Output.ai API
5
5
  * API for managing and executing Output.ai workflows
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Generated by orval v8.6.2 🍺
2
+ * Generated by orval v8.8.0 🍺
3
3
  * Do not edit manually.
4
4
  * Output.ai API
5
5
  * API for managing and executing Output.ai workflows
@@ -81,7 +81,7 @@ services:
81
81
  condition: service_healthy
82
82
  worker:
83
83
  condition: service_healthy
84
- image: outputai/api:${OUTPUT_API_VERSION:-0.1.13-next.0bb44fb.0}
84
+ image: outputai/api:${OUTPUT_API_VERSION:-0.1.13-next.0fd573d.0}
85
85
  init: true
86
86
  networks:
87
87
  - main
@@ -0,0 +1,11 @@
1
+ import { Command } from '@oclif/core';
2
+ export default class Migrate extends Command {
3
+ static description: string;
4
+ static examples: string[];
5
+ static flags: {
6
+ from: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
7
+ to: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
8
+ notes: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
9
+ };
10
+ run(): Promise<void>;
11
+ }
@@ -0,0 +1,40 @@
1
+ import { Command, Flags } from '@oclif/core';
2
+ import { ensureOutputAISystem } from '#services/coding_agents.js';
3
+ import { invokeMigrate } from '#services/claude_client.js';
4
+ export default class Migrate extends Command {
5
+ static description = 'Upgrade a project between versions of the Output framework. ' +
6
+ 'Fetches the matching migration guide from docs.output.ai and applies it.';
7
+ static examples = [
8
+ '<%= config.bin %> <%= command.id %>',
9
+ '<%= config.bin %> <%= command.id %> --to 0.2.0',
10
+ '<%= config.bin %> <%= command.id %> --from 0.1.12 --to 0.2.0',
11
+ '<%= config.bin %> <%= command.id %> --to 0.2.0 --notes "skip the http changes, we don\'t use that package"'
12
+ ];
13
+ static flags = {
14
+ from: Flags.string({
15
+ description: 'Version to migrate from. Defaults to the framework version in your package.json.',
16
+ required: false
17
+ }),
18
+ to: Flags.string({
19
+ description: 'Version to migrate to. Defaults to the latest published version.',
20
+ required: false
21
+ }),
22
+ notes: Flags.string({
23
+ char: 'n',
24
+ description: 'Extra guidance passed through to the migration agent.',
25
+ required: false
26
+ })
27
+ };
28
+ async run() {
29
+ const { flags } = await this.parse(Migrate);
30
+ const projectRoot = process.cwd();
31
+ this.log('Checking .outputai directory structure...');
32
+ await ensureOutputAISystem(projectRoot);
33
+ this.log('\nInvoking the /output-migrate skill...');
34
+ this.log('This may take a moment...\n');
35
+ const summary = await invokeMigrate(flags.from ?? '', flags.to ?? '', flags.notes);
36
+ this.log('\n=========');
37
+ this.log(summary);
38
+ this.log('=========\n');
39
+ }
40
+ }
@@ -1,3 +1,3 @@
1
1
  {
2
- "framework": "0.1.13-next.0bb44fb.0"
2
+ "framework": "0.1.13-next.0fd573d.0"
3
3
  }
@@ -5,6 +5,7 @@ import { Options } from '@anthropic-ai/claude-agent-sdk';
5
5
  export declare const ADDITIONAL_INSTRUCTIONS: {
6
6
  readonly PLAN: "\n! IMPORTANT !\n1. Use TodoWrite to track your progress through plan creation.\n\n2. Please respond with only the final version of the plan content.\n\n3. Respond in a markdown format with these metadata headers:\n\n---\ntitle: <plan-title>\ndescription: <plan-description>\ndate: <plan-date>\n---\n\n<plan-content>\n\n4. After you mark all todos as complete, you must respond with the final version of the plan.\n\n5. DO NOT write the plan to disk — the CLI will handle saving the file to the plans directory.\n\n6. DO NOT suggest any next steps, follow-up commands, or instructions for the user — the CLI will inform the user of next steps after saving.\n";
7
7
  readonly BUILD: "\n! IMPORTANT !\n1. Use TodoWrite to track your progress through workflow implementation.\n\n2. Follow the implementation plan exactly as specified in the plan file.\n\n3. Implement all workflow files following Output.ai patterns and best practices.\n\n4. After you mark all todos as complete, provide a summary of what was implemented.\n";
8
+ readonly MIGRATE: "\n! IMPORTANT !\n1. Use TodoWrite to track your progress through the migration.\n\n2. Fetch the migration guide from https://docs.output.ai/migrations — do not invent migration steps from memory.\n\n3. If the specific guide URL 404s, fall back to the /migrations index and chain the guides that cover the version range.\n\n4. Confirm the planned changes with the user before editing files.\n\n5. After you mark all todos as complete, provide a summary of which files changed and whether the type check passed.\n";
8
9
  };
9
10
  export declare const PLAN_COMMAND_OPTIONS: Options;
10
11
  interface ReplyToClaudeOptions {
@@ -12,6 +13,7 @@ interface ReplyToClaudeOptions {
12
13
  applyAdditionalInstructions?: string;
13
14
  }
14
15
  export declare const BUILD_COMMAND_OPTIONS: Options;
16
+ export declare const MIGRATE_COMMAND_OPTIONS: Options;
15
17
  export declare class ClaudeInvocationError extends Error {
16
18
  cause?: Error | undefined;
17
19
  constructor(message: string, cause?: Error | undefined);
@@ -36,4 +38,14 @@ export declare function invokePlanWorkflow(description: string): Promise<string>
36
38
  * @returns Implementation output from claude-code
37
39
  */
38
40
  export declare function invokeBuildWorkflow(planFilePath: string, workflowDir: string, workflowName: string, additionalInstructions?: string): Promise<string>;
41
+ /**
42
+ * Invoke claude-code with /output-migrate slash command (registered via the output-migrate skill).
43
+ * The slash command fetches migration instructions from docs.output.ai —
44
+ * this CLI wrapper just passes through the version arguments.
45
+ * @param fromVersion - Current framework version (empty string = auto-detect)
46
+ * @param toVersion - Target version (empty string = use npm "latest")
47
+ * @param additionalInstructions - Optional user-supplied guidance
48
+ * @returns Migration summary from claude-code
49
+ */
50
+ export declare function invokeMigrate(fromVersion: string, toVersion: string, additionalInstructions?: string): Promise<string>;
39
51
  export {};
@@ -38,10 +38,26 @@ date: <plan-date>
38
38
  3. Implement all workflow files following Output.ai patterns and best practices.
39
39
 
40
40
  4. After you mark all todos as complete, provide a summary of what was implemented.
41
+ `,
42
+ MIGRATE: `
43
+ ! IMPORTANT !
44
+ 1. Use TodoWrite to track your progress through the migration.
45
+
46
+ 2. Fetch the migration guide from https://docs.output.ai/migrations — do not invent migration steps from memory.
47
+
48
+ 3. If the specific guide URL 404s, fall back to the /migrations index and chain the guides that cover the version range.
49
+
50
+ 4. Confirm the planned changes with the user before editing files.
51
+
52
+ 5. After you mark all todos as complete, provide a summary of which files changed and whether the type check passed.
41
53
  `
42
54
  };
55
+ // Slash-command naming convention used by the outputai plugin:
56
+ // - `outputai:<name>` — plugin commands under coding_assistants/.../commands/
57
+ // - `output-<kebab-name>` — skills under coding_assistants/.../skills/, which surface as top-level slash commands without the plugin prefix.
43
58
  const PLAN_COMMAND = 'outputai:plan_workflow';
44
59
  const BUILD_COMMAND = 'outputai:build_workflow';
60
+ const MIGRATE_COMMAND = 'output-migrate';
45
61
  const GLOBAL_CLAUDE_OPTIONS = {
46
62
  settingSources: ['user', 'project', 'local']
47
63
  };
@@ -51,6 +67,9 @@ export const PLAN_COMMAND_OPTIONS = {
51
67
  export const BUILD_COMMAND_OPTIONS = {
52
68
  permissionMode: 'bypassPermissions'
53
69
  };
70
+ export const MIGRATE_COMMAND_OPTIONS = {
71
+ permissionMode: 'bypassPermissions'
72
+ };
54
73
  export class ClaudeInvocationError extends Error {
55
74
  cause;
56
75
  constructor(message, cause) {
@@ -77,7 +96,7 @@ function validateEnvironment() {
77
96
  }
78
97
  }
79
98
  function validateSystem(systemMessage) {
80
- const requiredCommands = [PLAN_COMMAND, BUILD_COMMAND];
99
+ const requiredCommands = [PLAN_COMMAND, BUILD_COMMAND, MIGRATE_COMMAND];
81
100
  const availableCommands = systemMessage.slash_commands;
82
101
  const missingCommands = requiredCommands.filter(command => !availableCommands.includes(command));
83
102
  return {
@@ -219,3 +238,18 @@ export async function invokeBuildWorkflow(planFilePath, workflowDir, workflowNam
219
238
  `/${BUILD_COMMAND} ${commandArgs}`;
220
239
  return singleQuery(applyInstructions(fullCommand, ADDITIONAL_INSTRUCTIONS.BUILD), BUILD_COMMAND_OPTIONS);
221
240
  }
241
+ /**
242
+ * Invoke claude-code with /output-migrate slash command (registered via the output-migrate skill).
243
+ * The slash command fetches migration instructions from docs.output.ai —
244
+ * this CLI wrapper just passes through the version arguments.
245
+ * @param fromVersion - Current framework version (empty string = auto-detect)
246
+ * @param toVersion - Target version (empty string = use npm "latest")
247
+ * @param additionalInstructions - Optional user-supplied guidance
248
+ * @returns Migration summary from claude-code
249
+ */
250
+ export async function invokeMigrate(fromVersion, toVersion, additionalInstructions) {
251
+ const from = fromVersion || 'auto';
252
+ const to = toVersion || 'latest';
253
+ const commandArgs = [from, to, additionalInstructions].filter(Boolean).join(' ');
254
+ return singleQuery(applyInstructions(`/${MIGRATE_COMMAND} ${commandArgs}`, ADDITIONAL_INSTRUCTIONS.MIGRATE), MIGRATE_COMMAND_OPTIONS);
255
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@outputai/cli",
3
- "version": "0.1.13-next.0bb44fb.0",
3
+ "version": "0.1.13-next.0fd573d.0",
4
4
  "description": "CLI for Output.ai workflow generation",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -15,29 +15,29 @@
15
15
  },
16
16
  "dependencies": {
17
17
  "@anthropic-ai/claude-agent-sdk": "0.2.92",
18
- "@aws-sdk/client-s3": "3.1024.0",
18
+ "@aws-sdk/client-s3": "3.1031.0",
19
19
  "@hackylabs/deep-redact": "3.0.5",
20
- "@inquirer/prompts": "8.3.2",
20
+ "@inquirer/prompts": "8.4.1",
21
21
  "@oclif/core": "4.10.5",
22
- "@oclif/plugin-help": "6.2.42",
22
+ "@oclif/plugin-help": "6.2.44",
23
23
  "change-case": "5.4.4",
24
24
  "cli-progress": "3.12.0",
25
25
  "cli-table3": "0.6.5",
26
26
  "date-fns": "4.1.0",
27
27
  "debug": "4.4.3",
28
- "dotenv": "17.4.0",
28
+ "dotenv": "17.4.2",
29
29
  "handlebars": "4.7.9",
30
30
  "ink": "6.8.0",
31
31
  "ink-spinner": "5.0.0",
32
32
  "js-yaml": "4.1.1",
33
- "json-schema-library": "11.1.0",
33
+ "json-schema-library": "11.4.0",
34
34
  "ky": "1.14.3",
35
- "react": "19.2.4",
35
+ "react": "19.2.5",
36
36
  "semver": "7.7.4",
37
37
  "yaml": "^2.8.3",
38
- "@outputai/credentials": "0.1.13-next.0bb44fb.0",
39
- "@outputai/llm": "0.1.13-next.0bb44fb.0",
40
- "@outputai/evals": "0.1.13-next.0bb44fb.0"
38
+ "@outputai/credentials": "0.1.13-next.0fd573d.0",
39
+ "@outputai/evals": "0.1.13-next.0fd573d.0",
40
+ "@outputai/llm": "0.1.13-next.0fd573d.0"
41
41
  },
42
42
  "devDependencies": {
43
43
  "@types/cli-progress": "3.11.6",
@@ -45,7 +45,7 @@
45
45
  "@types/js-yaml": "4.0.9",
46
46
  "@types/react": "19.2.14",
47
47
  "@types/semver": "7.7.1",
48
- "orval": "8.6.2"
48
+ "orval": "8.8.0"
49
49
  },
50
50
  "license": "Apache-2.0",
51
51
  "publishConfig": {