diff --git a/packages/ai-bot/tests/prompt-construction-test.ts b/packages/ai-bot/tests/prompt-construction-test.ts index 146bafdbfc2..d5a6d91a4fb 100644 --- a/packages/ai-bot/tests/prompt-construction-test.ts +++ b/packages/ai-bot/tests/prompt-construction-test.ts @@ -3224,7 +3224,7 @@ Attached Files (files with newer versions don't show their content): id: 'http://localhost:4201/admin/custom-embedded/Skill/72d005b5-1a6b-4c6d-995f-2411c5948e74', attributes: { instructions: - 'Use the tool SwitchSubmodeCommand with "code" to go to codemode and "interact" to go to interact mode.', + 'Use the tool SwitchSubmodeTool with "code" to go to codemode and "interact" to go to interact mode.', commands: [ { codeRef: { @@ -3323,7 +3323,7 @@ Attached Files (files with newer versions don't show their content): ); assert.ok( switchSubmodeTool, - 'Should have SwitchSubmodeCommand function available', + 'Should have SwitchSubmodeTool function available', ); }); diff --git a/packages/base/ai-app-generator.gts b/packages/base/ai-app-generator.gts index fc234da0070..42725144f6c 100644 --- a/packages/base/ai-app-generator.gts +++ b/packages/base/ai-app-generator.gts @@ -12,7 +12,7 @@ import { fn } from '@ember/helper'; import { on } from '@ember/modifier'; import { restartableTask } from 'ember-concurrency'; -import AskAiCommand from '@cardstack/boxel-host/commands/ask-ai'; +import AskAiTool from '@cardstack/boxel-host/commands/ask-ai'; import { AskAiInput } from './command'; import { tracked } from '@glimmer/tracking'; @@ -54,7 +54,7 @@ export class AiAppGenerator extends CardDef { throw new Error('No command context found'); } - let command = new AskAiCommand(commandContext); + let command = new AskAiTool(commandContext); await command.execute( new AskAiInput({ prompt: this.args.model.promptValue, diff --git a/packages/base/card-api.gts b/packages/base/card-api.gts index 831c259ad1e..92bfd6b1cf3 100644 --- a/packages/base/card-api.gts +++ b/packages/base/card-api.gts @@ -138,8 +138,8 @@ import FilePencilIcon from '@cardstack/boxel-icons/file-pencil'; import WandIcon from '@cardstack/boxel-icons/wand'; import HashIcon from '@cardstack/boxel-icons/hash'; // normalizeEnumOptions used by enum moved to packages/base/enum.gts -import PatchThemeCommand from '@cardstack/boxel-host/commands/patch-theme'; -import CopyAndEditCommand from '@cardstack/boxel-host/commands/copy-and-edit'; +import PatchThemeTool from '@cardstack/boxel-host/commands/patch-theme'; +import CopyAndEditTool from '@cardstack/boxel-host/commands/copy-and-edit'; import { md5 } from 'super-fast-md5'; import { @@ -3289,7 +3289,7 @@ export class Theme extends CardDef { if (!params.commandContext || !this.id) { return; } - let cmd = new CopyAndEditCommand(params.commandContext); + let cmd = new CopyAndEditTool(params.commandContext); await cmd.execute({ card: this, }); @@ -3300,7 +3300,7 @@ export class Theme extends CardDef { { label: 'Modify Theme via AI', action: async () => { - let cmd = new PatchThemeCommand(params.commandContext); + let cmd = new PatchThemeTool(params.commandContext); await cmd.execute({ cardId: this.id as unknown as string, }); diff --git a/packages/base/command.gts b/packages/base/command.gts index ab754538859..da0fcc8505c 100644 --- a/packages/base/command.gts +++ b/packages/base/command.gts @@ -27,7 +27,9 @@ import { } from './commands/search-card-result'; import { eq, gt } from '@cardstack/boxel-ui/helpers'; -export type CommandStatus = 'applied' | 'ready' | 'applying'; +export type ToolCallStatus = 'applied' | 'ready' | 'applying'; +// Pre-rename spelling; new code imports `ToolCallStatus`. +export type CommandStatus = ToolCallStatus; export class ApplyMarkdownEditInput extends CardDef { @field cardId = contains(StringField); diff --git a/packages/base/commands/search-card-result.gts b/packages/base/commands/search-card-result.gts index c1192732166..c62267eb117 100644 --- a/packages/base/commands/search-card-result.gts +++ b/packages/base/commands/search-card-result.gts @@ -251,7 +251,7 @@ class SearchCardsResultEmbeddedView extends Component< class SearchCardsResultIsolatedView extends SearchCardsResultEmbeddedView {