google-deepmind / concordia

A library for generative social simulation
Apache License 2.0
497 stars 96 forks source link

feat: Amazon Bedrock Support ⛰️ #70

Closed JGalego closed 1 month ago

JGalego commented 1 month ago

Adds support for Amazon Bedrock models via Converse API.

Tested on the A Murder Mistery 🕵️ scenario with Mistral Small.

Changes:

PS: Thanks to @jzleibo for presenting this project at OxML24.

JGalego commented 1 month ago

CLA signed ✍🏻 PR blocked due to unrelated issues detected by GitHub Actions

duenez commented 1 month ago

Maybe this needs to be sync'd to head? I don't see that error in the main branch.

duenez commented 1 month ago

Nevermind, I see the problem. Fix is on its way.

JGalego commented 1 month ago

Maybe this needs to be sync'd to head? I don't see that error in the main branch.

Last commit to main is 2d old and I forked this today, so that's not an issue. The install-examples action is converting the notebooks to python files and the issues are there.

duenez commented 1 month ago

This should be fixed at head now.

JGalego commented 1 month ago

Missed your initial comment. Thanks for fixing this so fast - branch sync'd, all checks ✅

austinmw commented 1 month ago

@JGalego Hi, curious if it'd make sense to use function calling support (for available models) in the future in order to remove the need for parsing and retries (_MAX_MULTIPLE_CHOICE_ATTEMPTS)?

JGalego commented 1 month ago

@JGalego Hi, curious if it'd make sense to use function calling support (for available models) in the future in order to remove the need for parsing and retries (_MAX_MULTIPLE_CHOICE_ATTEMPTS)?

IMHO for the retry mechanism, it would be overkill. Also, the goal was to keep the implementation consistent (similar) to the one used for the other LM providers. Having said that, tool use is listed as an improvement in the original paper (hence why I went for the Converse API).

Screenshot 2024-07-13 at 08 21 15

JGalego commented 1 month ago

@duenez The feedback/copybara check is failing - anything I should do?

jzleibo commented 1 month ago

Earlier today I attempted to follow the instructions we have to fix the minor lint error which was blocking it from submitting. I believe my edit is now waiting on approval from Edgar or John. Then once they approve it the whole pull request will go in.

On Sun, Jul 14, 2024, 1:08 AM João Galego @.***> wrote:

@duenez https://github.com/duenez The feedback/copybara check is failing - anything I should do?

— Reply to this email directly, view it on GitHub https://github.com/google-deepmind/concordia/pull/70#issuecomment-2227143923, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAHFJWSBZYZ2VT5PDTZP4EDZMG6QXAVCNFSM6AAAAABKY6K6GOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMRXGE2DGOJSGM . You are receiving this because you were mentioned.Message ID: @.***>