Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(agents): granite agent fixes, update granite docs and examples #243

Merged
merged 15 commits into from
Dec 13, 2024

Conversation

michael-desmond
Copy link
Contributor

Which issue(s) does this pull-request address?

  1. Granite example agents now have their own folder (examples/granite)
  2. Moved the granite docs from the /docs to to a README.md inside of examples/granite so we can link directly to the README and the code examples (cookbook)
  3. Added another example granite agent using retrieval with the wikipedia tool and updated documentation
  4. Fixed an issue where default runner was not picking up templates from the templates method, and thus could not be over ridden in the granite runner subclass
  5. Updates to granite system prompt (simplification), added time + date into the system prompt
  6. Custom granite user template (remove createdAt) and custom granite tool prompts
  7. Fixed an issue where the granite available tools were being double json encoded
  8. Added an embedding example
  9. Added a cosine similarity helper function

Checklist

  • I have read the contributor guide
  • Linting passes: yarn lint or yarn lint:fix
  • Formatting is applied: yarn format or yarn format:fix
  • Unit tests pass: yarn test:unit
  • E2E tests pass: yarn test:e2e
  • Tests are included
  • Documentation is changed or added
  • Commit messages and PR title follow conventional commits

Copy link
Contributor

@grahamwhiteuk grahamwhiteuk left a comment

Choose a reason for hiding this comment

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

Just a few minor bits to clean up and think about in the README. I also wonder whether we need some explanation around why the tooling is configured the way it is.

examples/agents/granite/README.md Outdated Show resolved Hide resolved
examples/agents/granite/README.md Outdated Show resolved Hide resolved
examples/agents/granite/README.md Outdated Show resolved Hide resolved
examples/agents/granite/README.md Outdated Show resolved Hide resolved
examples/agents/granite/README.md Outdated Show resolved Hide resolved
examples/agents/granite/README.md Outdated Show resolved Hide resolved
examples/agents/granite/granite_wiki_bee.ts Outdated Show resolved Hide resolved
examples/agents/granite/granite_wiki_bee.ts Outdated Show resolved Hide resolved
examples/agents/granite/granite_wiki_bee.ts Outdated Show resolved Hide resolved
src/internals/helpers/math.ts Outdated Show resolved Hide resolved
src/internals/helpers/math.ts Outdated Show resolved Hide resolved
src/agents/bee/runners/granite/prompts.ts Outdated Show resolved Hide resolved
src/agents/bee/runners/granite/prompts.ts Outdated Show resolved Hide resolved
src/agents/bee/runners/granite/prompts.ts Outdated Show resolved Hide resolved
src/agents/bee/runners/granite/prompts.ts Outdated Show resolved Hide resolved
src/agents/bee/runners/granite/prompts.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@grahamwhiteuk grahamwhiteuk left a comment

Choose a reason for hiding this comment

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

It looks to me like all the original review points have been addressed. We need to get this one merged ASAP so that we can use the resulting repo in the creation of some demo materials. @Tomas2D would you be able to go ahead and do the merge as it stands now?

src/agents/bee/runners/granite/prompts.ts Outdated Show resolved Hide resolved
src/internals/helpers/math.ts Outdated Show resolved Hide resolved
examples/agents/granite/granite_wiki_bee.ts Show resolved Hide resolved
Signed-off-by: Graham White <[email protected]>
Copy link
Contributor

@Tomas2D Tomas2D left a comment

Choose a reason for hiding this comment

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

Great work guys! 🚀

@Tomas2D Tomas2D merged commit 6d0c7c5 into main Dec 13, 2024
4 checks passed
@Tomas2D Tomas2D deleted the granite_updates branch December 13, 2024 07:55
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.

3 participants