Skip to content

Commit

Permalink
chore: update docs again (#77)
Browse files Browse the repository at this point in the history
  • Loading branch information
lily-de committed Oct 7, 2024
1 parent 65f100c commit bb5a426
Show file tree
Hide file tree
Showing 76 changed files with 439 additions and 312 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/deploy_docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Deploy MkDocs

on:
push:
branches:
- main # Trigger deployment on pushes to main
paths:
- 'docs/**'
- 'mkdocs.yml'

jobs:
deploy:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.x'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install mkdocs mkdocs-material
- name: Build the documentation
run: mkdocs build

- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./site
5 changes: 2 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

<p>
<a href="#prerequisites">Prerequisites</a> •
<a href="#evaluations">Evaluations</a> •
<a href="#developing-and-testing">Developing and testing</a> •
<a href="#building-from-source">Building from source</a> •
<a href="#developing-goose-plugins">Developing goose-plugins</a> •
Expand Down Expand Up @@ -37,7 +36,7 @@ Plugins added directly to Goose are subject to rigorous review. This is because

Plugins in `goose-plugins` undergo less detailed reviews and are more modular or experimental. They can prove their value through usage or iteration over time and may be eventually moved over to Goose.

To see how to add a toolkit, see the [toolkits documentation][toolkits].
To see how to add a toolkit, see the [toolkits documentation][adding-toolkit].

### Running tests
```sh
Expand Down Expand Up @@ -123,4 +122,4 @@ This project follows the [Conventional Commits](https://www.conventionalcommits.
[uv]: https://docs.astral.sh/uv/
[ruff]: https://docs.astral.sh/ruff/
[just]: https://github.com/casey/just
[toolkits]: docs/docs/toolkits.md
[adding-toolkit]: https://square.github.io/goose/configuration.html#adding-a-toolkit
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -144,15 +144,17 @@ file is meant to provide additional context about your project. The context can
user-specific or at the project level in which case, you
can commit it to git. `.goosehints` file is Jinja templated so you could have something
like this:

```
Here is an overview of how to contribute:
{% include 'CONTRIBUTING.md' %}
&#123;% include 'CONTRIBUTING.md' %&#125;
The following justfile shows our common commands:
```just
{% include 'justfile' %}
&#123;% include 'justfile' %&#125;
```



### Examples
#### provider as `anthropic`

Expand Down
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes
85 changes: 43 additions & 42 deletions docs/docs/configuration.md → docs/configuration.md
Original file line number Diff line number Diff line change
@@ -1,47 +1,5 @@
# Configuring Goose

## Adding a toolkit
To make a toolkit available to Goose, add it to your project's pyproject.toml. For example in the Goose pyproject.toml file:
```
[project.entry-points."goose.toolkit"]
developer = "goose.toolkit.developer:Developer"
github = "goose.toolkit.github:Github"
# Add a line like this - the key becomes the name used in profiles
my-new-toolkit = "goose.toolkit.my_toolkits:MyNewToolkit" # this is the path to the class that implements the toolkit
```

Then to set up a profile that uses it, add something to `~/.config/goose/profiles.yaml`:
```yaml
my-profile:
provider: openai
processor: gpt-4o
accelerator: gpt-4o-mini
moderator: passive
toolkits: # new toolkit gets added here
- developer
- my-new-toolkit
```
And now you can run Goose with this new profile to use the new toolkit!
```sh
goose session start --profile my-profile
```

Or, if you're developing a new toolkit and want to test it:
```sh
uv run goose session start --profile my-profile
```

## Tuning it to your repo

Goose ships with the ability to read in the contents of a file named `.goosehints` from your repo. If you find yourself repeating the same information across sessions to Goose, this file is the right place to add this information.

This file will be read into the Goose system prompt if it is present in the current working directory.

> [!NOTE]
> `.goosehints` follows [jinja templating rules][jinja-guide] in case you want to leverage templating to insert file contents or variables.
## Profiles

If you need to customize goose, one way is via editing: `~/.config/goose/profiles.yaml`.
Expand Down Expand Up @@ -146,3 +104,46 @@ unit-test-gen:
```

[jinja-guide]: https://jinja.palletsprojects.com/en/3.1.x/


## Adding a toolkit
To make a toolkit available to Goose, add it to your project's pyproject.toml. For example in the Goose pyproject.toml file:
```
[project.entry-points."goose.toolkit"]
developer = "goose.toolkit.developer:Developer"
github = "goose.toolkit.github:Github"
# Add a line like this - the key becomes the name used in profiles
my-new-toolkit = "goose.toolkit.my_toolkits:MyNewToolkit" # this is the path to the class that implements the toolkit
```

Then to set up a profile that uses it, add something to `~/.config/goose/profiles.yaml`:
```yaml
my-profile:
provider: openai
processor: gpt-4o
accelerator: gpt-4o-mini
moderator: passive
toolkits: # new toolkit gets added here
- developer
- my-new-toolkit
```

And now you can run Goose with this new profile to use the new toolkit!

```sh
goose session start --profile my-profile
```

Or, if you're developing a new toolkit and want to test it:
```sh
uv run goose session start --profile my-profile
```

## Tuning Goose to your repo

Goose ships with the ability to read in the contents of a file named `.goosehints` from your repo. If you find yourself repeating the same information across sessions to Goose, this file is the right place to add this information.

This file will be read into the Goose system prompt if it is present in the current working directory.

> [!NOTE]
> `.goosehints` follows [jinja templating rules][jinja-guide] in case you want to leverage templating to insert file contents or variables.
1 change: 1 addition & 0 deletions docs/contributing.md
File renamed without changes.
1 change: 0 additions & 1 deletion docs/docs/contributing.md

This file was deleted.

18 changes: 0 additions & 18 deletions docs/docs/index.md

This file was deleted.

3 changes: 0 additions & 3 deletions docs/docs/providers.md

This file was deleted.

20 changes: 0 additions & 20 deletions docs/docs/tips.md

This file was deleted.

Loading

0 comments on commit bb5a426

Please sign in to comment.