autogenhub / autogen

A programming framework for agentic AI. Discord: https://discord.gg/pAbnFJrkgZ
https://autogenhub.github.io/autogen/
Apache License 2.0
119 stars 23 forks source link

Correct TextMessageCompressor's cache parameter initialising on import #68

Closed marklysze closed 1 month ago

marklysze commented 1 month ago

Why are these changes needed?

The TextMessageCompressor's cache parameter for __init__() has a default value of Cache.disk(). This is causing it to run on import rather than just on instantiation.

This PR changes the default to None and the Cache.disk() is executed within __init__.

Related issue number

Raised by @omarhurani, #63

Checks

codecov-commenter commented 1 month ago

Welcome to Codecov :tada:

Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests.

:information_source: You can also turn on project coverage checks and project coverage reporting on Pull Request comment

Thanks for integrating Codecov - We've got you covered :open_umbrella:

omarhurani commented 1 month ago

Tested it, no .cache dir is created when doing import autogen. Thanks!