Skip to content

feat: add global optional user goosehints file#73

Merged
michaelneale merged 5 commits intomainfrom
global_hints
Sep 27, 2024
Merged

feat: add global optional user goosehints file#73
michaelneale merged 5 commits intomainfrom
global_hints

Conversation

@michaelneale
Copy link
Collaborator

@michaelneale michaelneale commented Sep 18, 2024

addresses: #72

image

from ~/.config/goose/.goosehints:

I want you to say "good morning sunshine" when starting a new session always% 

Copy link
Contributor

@lukealvoeiro lukealvoeiro left a comment

Choose a reason for hiding this comment

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

No concerns with the implementation, just some thoughts below:

Developers typically work within a technical domain, and I'm guessing they would use this concept of global goosehints to describe information relevant to that domain that is applicable across projects.

However, sometimes you use Goose to explore other domains (e.g. working in a frontend project despite being an ML engineer), where some of this context would end up disrupting Goose's performance.

A couple ideas:

  1. Perhaps it would be worthwhile prompting users on goose session start to see if they want to use their global goosehints for that particular session?

  2. Another option could be having goosehints be added sequentially from parent directories from the CWD. That could mean you would have some root level goosehints, as well as project level goosehints, etc. An example below:

~/Development/.goosehints
~/Development/java/.goosehints
~/Development/java/buyer-subs/.goosehints

@michaelneale
Copy link
Collaborator Author

@lukealvoeiro yeah I did think of that - when you say sequentially added - you mean when goose starts a session or when code moves around dirs as part of the session?

@danielcorin
Copy link
Contributor

could we put this in ~/.config/goose instead?

@michaelneale
Copy link
Collaborator Author

yep could be in goose config - but I don't know if we want to commit to making it more complicated/smart just yet? ease into it?

@michaelneale michaelneale added the enhancement New feature or request label Sep 20, 2024
@michaelneale
Copy link
Collaborator Author

is in goose config dir now

"""Retrieve system configuration details for developer"""
hints_path = Path(".goosehints")
system_prompt = Message.load("prompts/developer.jinja").text
home_hints_path = Path.home() / ".config/goose/.goosehints"
Copy link

Choose a reason for hiding this comment

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

It doesn't seem necessary to use a hidden file when it's already in a hidden folder. It might be good to log an error if the dotfile exists though, just to avoid confusion.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@vfiano yeah can change it, wouldn't be too confusing as it is called .goosehints elsewhere?

Copy link
Collaborator

@codefromthecrypt codefromthecrypt left a comment

Choose a reason for hiding this comment

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

is the TL;DR; that most specific wins? or do hints accumulate? (personally prefer most specific wins)

Copy link
Collaborator

@baxen baxen left a comment

Choose a reason for hiding this comment

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

LGTM!

@michaelneale michaelneale merged commit d0d9734 into main Sep 27, 2024
@michaelneale michaelneale deleted the global_hints branch September 27, 2024 08:25
lukealvoeiro added a commit that referenced this pull request Oct 9, 2024
* main: (41 commits)
  chore: Add goose providers list command (#116)
  docs: working ollama for desktop (#125)
  docs: format and clean up warnings/errors (#120)
  docs: update deploy workflow (#124)
  feat: Implement a goose run command (#121)
  feat: saved api_key to keychain for user (#104)
  docs: add callout plugin (#119)
  chore: add a page to docs for Goose application examples (#117)
  fix: exit the goose and show the error message when provider environment variable is not set (#103)
  fix: Update OpenAI pricing per https://openai.com/api/pricing/ (#110)
  fix: update developer tool prompts to use plan task status to match allowable statuses update_plan tool call (#107)
  fix: removed the panel in the output so that the user won't have unnecessary pane borders in the copied content (#109)
  docs: update links to exchange to the new location (#108)
  chore: setup workspace for exchange (#105)
  fix: resolve uvx when using a git client or IDE (#98)
  ci: add include-markdown for mkdocs (#100)
  chore: fix broken badge on readme (#102)
  feat: add global optional user goosehints file (#73)
  docs: update docs (#99)
  chore(release): release 0.9.3 (#97)
  ...
cbruyndoncx pushed a commit to cbruyndoncx/goose that referenced this pull request Jul 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants

Comments