Skip to content

Added recipe discovery / execution to ACP server.#8925

Open
natelastname wants to merge 1 commit intoaaif-goose:mainfrom
natelastname:add/acp-recipe-execution
Open

Added recipe discovery / execution to ACP server.#8925
natelastname wants to merge 1 commit intoaaif-goose:mainfrom
natelastname:add/acp-recipe-execution

Conversation

@natelastname
Copy link
Copy Markdown

Summary

Adds ACP support for Goose slash command discovery and execution feedback.

This change introduces:

  • Slash command discovery in ACP
    • Builds AvailableCommand list from configured slash_commands (global config)
    • Uses recipe metadata:
      • recipe.description → command description
      • parameters[].description → input hint (instead of hardcoded string)
  • Execution feedback
    • When a slash command is invoked via ACP, emits a visible message:
      Running recipe: /<command>
      
    • This provides immediate user feedback, since recipe expansion is otherwise agent-visible only
  • Design alignment
    • Only exposes commands explicitly configured as slash_commands (not all discovered recipes)
    • Keeps ACP behavior consistent with CLI and HTTP execution paths

Testing

I haven't included any actual unit tests, but I am happy to add some if this approach is accepted by the maintainers.

  • Started Goose ACP server and connected via an ACP client (in this case, agent-shell in Emacs.)
  • Verified:
    • Configured slash commands appear in available_commands_update
    • Input hint reflects recipe parameter description
    • Invoking /speckit.constitution:
      • Emits “Running recipe: …” message
      • Executes recipe successfully
      • Continues normal agent response

Related Issues

Relates to ACP integration work (no specific issue yet)
Discussion: N/A

Screenshots/Demos (for UX changes)

This is not a UX change but here's a screenshot.

Screenshot from 2026-04-29 21-02-48

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 88955a934d

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines +2286 to +2288
.split_whitespace()
.next()
.filter(|cmd| cmd.starts_with('/'))
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Reuse command parser when emitting recipe-run feedback

This slash-command detection path uses split_whitespace() to extract the command token, but actual command execution in agents/execute_commands.rs splits only on a literal space (split_once(' ')). As a result, prompts like /recipe\targ or /recipe\narg will emit Running recipe: /recipe here even though the command dispatcher won’t resolve that recipe, so ACP clients get false execution feedback for commands that never run.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant