diff --git a/.github/workflows/run-continue-agent.yml b/.github/workflows/run-continue-agent.yml index c98cf963a00..6194838fe8b 100644 --- a/.github/workflows/run-continue-agent.yml +++ b/.github/workflows/run-continue-agent.yml @@ -4,14 +4,15 @@ on: workflow_call: inputs: prompt: - description: "The prompt to send to the Continue agent" - required: true - type: string - config: - description: "The config to use (e.g., continuedev/default-background-agent)" + description: "Additional prompting to send to the Continue agent" required: false type: string - default: "continuedev/default-background-agent" + default: "" + agent: + description: "The agent to use (e.g., continuedev/github-pr-agent)" + required: true + type: string + default: "continuedev/github-pr-agent" branch_name: description: "The base branch name to work from" required: false @@ -33,7 +34,7 @@ jobs: -H "Authorization: Bearer ${{ secrets.CONTINUE_API_KEY }}" \ -d '{ "prompt": "${{ inputs.prompt }}", - "config": "${{ inputs.config }}", + "agent": "${{ inputs.agent }}", "branchName": "${{ inputs.branch_name }}", "repoUrl": "https://github.com/${{ github.repository }}" }') diff --git a/.github/workflows/tidy-up-codebase.yml b/.github/workflows/tidy-up-codebase.yml index 729998a28ac..dc70faaaa1f 100644 --- a/.github/workflows/tidy-up-codebase.yml +++ b/.github/workflows/tidy-up-codebase.yml @@ -10,8 +10,7 @@ jobs: run-cn-task: uses: ./.github/workflows/run-continue-agent.yml with: - prompt: "Review every Markdown documentation file and verify that descriptions, examples, or behavior outlines accurately reflect the current code. Only update documentation; do not modify code. Check the corresponding code to confirm behavior before making changes. Correct any inaccuracies or outdated information in descriptions, examples, or behavior outlines. Preserve existing Markdown formatting, style, and structure. Do not add new sections, speculative explanations, or details not present in the code. Only update statements that are clearly incorrect or misleading; do not rewrite text for style or preference. Keep edits minimal and focused, ensuring that the Markdown matches what the code actually does. If verification against the code is ambiguous, leave the documentation unchanged. Use branch name bot/cleanup--" - config: continuedev/default-background-agent + agent: continuedev/tidy-up-markdown-agent branch_name: main secrets: CONTINUE_API_KEY: ${{ secrets.CONTINUE_API_KEY }} diff --git a/docs/guides/cli.mdx b/docs/guides/cli.mdx index d3584f8836a..87e29a51be3 100644 --- a/docs/guides/cli.mdx +++ b/docs/guides/cli.mdx @@ -54,7 +54,7 @@ echo "$(git diff) Generate a conventional commit name for the current git change `cn` uses [`config.yaml`](/reference), the exact same configuration file as Continue. This means that you can log in to [Continue Mission Control](/hub/introduction) or use your existing local configuration. -To switch between configurations, you can use the `/config` slash command in `cn`, or you can start it with the `--config` flag (e.g. `cn --config continuedev/default-agent` or `cn --config ~/.continue/config.yaml`). +To switch between configurations, you can use the `/config` slash command in `cn`, or you can start it with the `--config` flag (e.g. `cn --config continuedev/default-cli-config` or `cn --config ~/.continue/config.yaml`). ### How to Add Custom Models diff --git a/extensions/cli/spec/config-loading.md b/extensions/cli/spec/config-loading.md index 0f474b5a7b5..2bf0bde570c 100644 --- a/extensions/cli/spec/config-loading.md +++ b/extensions/cli/spec/config-loading.md @@ -37,7 +37,7 @@ This document specifies the behavior of the CLI's configuration loading system, 3. **Default Resolution** (if no flag and no saved URI) - **Authenticated**: First user assistant from `listAssistants()` - **config.yaml**: The saved config file at `~/.continue/config.yaml` - - **Unauthenticated**: Falls back to `continuedev/default-agent` + - **Unauthenticated**: Falls back to `continuedev/default-cli-config` ## Authentication State Interactions @@ -61,7 +61,7 @@ This document specifies the behavior of the CLI's configuration loading system, **Available Options:** - Local YAML files only -- Default assistant (`continuedev/default-agent`) +- Default assistant (`continuedev/default-cli-config`) **Behavior:** @@ -121,7 +121,7 @@ This document specifies the behavior of the CLI's configuration loading system, **No User Assistants:** - Authenticated user has no personal assistants -- **Result**: Falls back to `continuedev/default-agent` +- **Result**: Falls back to `continuedev/default-cli-config` **Default Agent Unavailable:** diff --git a/extensions/cli/src/configLoader.ts b/extensions/cli/src/configLoader.ts index 34ab3e35873..3106a1d6d15 100644 --- a/extensions/cli/src/configLoader.ts +++ b/extensions/cli/src/configLoader.ts @@ -36,8 +36,8 @@ export type ConfigSource = | { type: "cli-flag"; path: string } | { type: "saved-uri"; uri: string } | { type: "user-assistant"; slug: string } - | { type: "default-config-yaml" } - | { type: "default-agent" } + | { type: "local-config-yaml" } + | { type: "remote-default-config" } | { type: "no-config" }; /** @@ -124,16 +124,16 @@ function determineConfigSource( // Priority 3: Default resolution based on auth state if (authConfig === null) { - // Unauthenticated: check for default config.yaml, then fallback to default agent + // Unauthenticated: check for default config.yaml, then fallback to default config const defaultConfigPath = path.join(env.continueHome, "config.yaml"); if (fs.existsSync(defaultConfigPath)) { - return { type: "default-config-yaml" }; + return { type: "local-config-yaml" }; } - return { type: "default-agent" }; + return { type: "remote-default-config" }; } else { // In headless, user assistant fallback behavior isn't supported if (isHeadless) { - return { type: "default-agent" }; + return { type: "remote-default-config" }; } // Authenticated: try user assistants first return { type: "user-assistant", slug: "" }; // Empty slug means "first available" @@ -178,16 +178,16 @@ async function loadFromSource( injectBlocks, ); - case "default-config-yaml": - return await loadDefaultConfigYaml( + case "local-config-yaml": + return await loadLocalConfigYaml( accessToken, organizationId, apiClient, injectBlocks, ); - case "default-agent": - return await loadDefaultAgent( + case "remote-default-config": + return await loadDefaultConfig( organizationId, apiClient, accessToken, @@ -214,7 +214,7 @@ async function loadFromSource( "Failed to load user assistants, falling back to default agent", ), ); - return await loadDefaultAgent( + return await loadDefaultConfig( organizationId, apiClient, accessToken, @@ -334,7 +334,7 @@ async function loadUserAssistantWithFallback( } // No user assistants, fall back to default agent - return await loadDefaultAgent( + return await loadDefaultConfig( organizationId, apiClient, accessToken, @@ -345,7 +345,7 @@ async function loadUserAssistantWithFallback( /** * Loads default config.yaml from ~/.continue/config.yaml */ -async function loadDefaultConfigYaml( +async function loadLocalConfigYaml( accessToken: string | null, organizationId: string | null, apiClient: DefaultApiInterface, @@ -362,9 +362,9 @@ async function loadDefaultConfigYaml( } /** - * Loads the default continuedev/default-agent + * Loads the default continuedev/default-config */ -async function loadDefaultAgent( +async function loadDefaultConfig( organizationId: string | null, apiClient: DefaultApiInterface, accessToken: string | null, @@ -372,7 +372,7 @@ async function loadDefaultAgent( ): Promise { const resp = await apiClient.getAssistant({ ownerSlug: "continuedev", - packageSlug: "default-agent", + packageSlug: "default-cli-config", organizationId: organizationId ?? undefined, }); @@ -582,7 +582,7 @@ function getUriFromSource(source: ConfigSource): string | null { : `slug://${source.path}`; case "saved-uri": return source.uri; - case "default-config-yaml": + case "local-config-yaml": return `file://${path.join(env.continueHome, "config.yaml")}`; default: return null; diff --git a/extensions/cli/src/e2e/local-config-switching.test.tsx b/extensions/cli/src/e2e/local-config-switching.test.tsx index b82ee3e8872..5f323a29595 100644 --- a/extensions/cli/src/e2e/local-config-switching.test.tsx +++ b/extensions/cli/src/e2e/local-config-switching.test.tsx @@ -11,7 +11,7 @@ describe("Local Config Switching Investigation", () => { "/absolute/path/to/config.yaml", ], remoteAssistantSlugs: [ - "continuedev/default-agent", + "continuedev/default-cli-config", "myorg/custom-assistant", "user/my-assistant", ], @@ -43,14 +43,14 @@ describe("Local Config Switching Investigation", () => { const problemScenarios = [ { name: "Remote to Remote switching", - from: "continuedev/default-agent", + from: "continuedev/default-cli-config", to: "myorg/custom-assistant", works: true, reason: "Both are assistant slugs, normal flow works", }, { name: "Remote to Local switching", - from: "continuedev/default-agent", + from: "continuedev/default-cli-config", to: "~/.continue/config.yaml", works: false, // This is the reported issue reason: "UNKNOWN - this is what we need to debug", @@ -58,7 +58,7 @@ describe("Local Config Switching Investigation", () => { { name: "Local to Remote switching", from: "~/.continue/config.yaml", - to: "continuedev/default-agent", + to: "continuedev/default-cli-config", works: false, // Likely also broken reason: "UNKNOWN - probably same root cause", }, diff --git a/extensions/cli/src/services/ConfigService.test.ts b/extensions/cli/src/services/ConfigService.test.ts index fb7b250d88b..be1e03010c6 100644 --- a/extensions/cli/src/services/ConfigService.test.ts +++ b/extensions/cli/src/services/ConfigService.test.ts @@ -107,7 +107,7 @@ describe("ConfigService", () => { test("should initialize with undefined config path", async () => { vi.mocked(configLoader.loadConfiguration).mockResolvedValue({ config: mockConfig as any, - source: { type: "default-agent" } as any, + source: { type: "remote-default-config" } as any, }); const state = await service.doInitialize({ @@ -257,7 +257,7 @@ describe("ConfigService", () => { // Initialize without config path vi.mocked(configLoader.loadConfiguration).mockResolvedValue({ config: mockConfig as any, - source: { type: "default-agent" } as any, + source: { type: "remote-default-config" } as any, }); await service.doInitialize({ authConfig: { accessToken: "token" } as any, diff --git a/extensions/cli/src/services/MCPService.test.ts b/extensions/cli/src/services/MCPService.test.ts index f61be694612..3a9f195761a 100644 --- a/extensions/cli/src/services/MCPService.test.ts +++ b/extensions/cli/src/services/MCPService.test.ts @@ -36,7 +36,7 @@ describe("MCPService", () => { beforeEach(() => { mcpService = new MCPService(); mockAssistant = { - name: "test-assistant", + name: "Test Config", version: "1.0.0", mcpServers: [ { @@ -196,7 +196,7 @@ describe("MCPService", () => { it("should default to stdio transport when type is not specified", async () => { const defaultAssistant: AssistantConfig = { - name: "default-assistant", + name: "Default Config", version: "1.0.0", mcpServers: [ { diff --git a/extensions/cli/vitest.setup.ts b/extensions/cli/vitest.setup.ts index 2dcf0f8d0b5..ac91939574b 100644 --- a/extensions/cli/vitest.setup.ts +++ b/extensions/cli/vitest.setup.ts @@ -13,15 +13,15 @@ global.fetch = vi .mockImplementation(async (url: string | URL, ...args) => { const urlString = url.toString(); - // Mock the default-agent API call - if (urlString.includes("get-assistant/continuedev/default-agent")) { + // Mock the default config API call + if (urlString.includes("get-assistant/continuedev/default-cli-config")) { return { ok: true, status: 200, json: async () => ({ configResult: { config: { - name: "Default Agent", + name: "Default Config", version: "0.0.1", schema: "v1", models: [