aaif-goose / aaif-goose/goose

[FR] Allow custom arguments for GOOSE_SHELL

Open
#11,338 1 comment 1 reaction 1 assignee Claimed by @lifeizhou-ap View on GitHub
Dominant language
Rust
Stars
54.2k
Forks
6.2k
Avg merge
3d 2h
Merged PRs (30d)
262

Description

Add the ability to pass custom arguments to the shell or override default ones when using GOOSE_SHELL. 

**What problem would this solve?**

Hard-coded shell arguments block customization. Specifically, when setting GOOSE_SHELL to pwsh, the system forces the `-NoProfile` flag. This prevents Windows users from loading a profile to strip out default aliases that conflict with Linux-style tools.

I imagine there are Linux users who would benefit from this as well, since there are many changes that could be made to the environment that might be hindering (or beneficial).

**What would a good outcome look like?**

Users would be able to use `pwsh` as shell for Goose while ensuring Linux-style tools work without alias conflicts. 

**Possible approaches** 

- Allow a custom profile script path to run after the shell boots
- Allow users to pass custom arguments via a new environment variable like `GOOSE_SHELL_ARGS`
- Add a configuration setting to toggle the `-NoProfile` flag on or off
- This one isn't ideal because my profile does some things I wouldn't want, but I could change it temporarily; it's better than nothing.

**Additional context** 

Even when extensions are supplying function tools, LLMs will sometimes want to use one of these Linux-style tools instead, and when it attempts to use one and it's told the arguments are invalid (because `pwsh`'s aliases don't honor the same arguments) it confuses the AI quite a bit and it will start going in circles.

Furthermore, it's easy to actually supply these Linux-style tools now thanks to projects like uutils's [coreutils](https://github.com/uutils/coreutils) which compiles a full set of native Windows binaries that match up with the GNU toolset so often used in Linux shells.

Making these tools available to the LLMs could go a long way in reducing the amount of confusion they experience when working in a Windows environment.

I could potentially even have it load a custom Goose-only profile that sets aliases for tools I don't keep on my `PATH` due to name conflicts with tools that Windows supplies (e.g. `find`, `rmdir`, `sort`, …), which would break many `BAT`/`CMD` files.

* * *

- [x] I have verified this does not duplicate an existing feature request

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.