Magma is a low-opinion framework allowing developers to focus on the logic and behavior of their agents, rather than dealing with useless abstractions

Search code, repositories, users, issues, pull requests...

submited by
Style Pass
2024-09-19 23:00:04

Magma is a low-opinion framework allowing developers to focus on the logic and behavior of their agents, rather than dealing with useless abstractions. It gives you greater visibility and control over an agent's process as it occurs.

Magma providers all conform to Magma types, meaning you can now use different LLM providers in the same code without having to do type conversion

Use @tool and @toolparam decorators to tell your agent which methods are tools it has available. These tools can be called by the agent naturally, or force-called using the agent.trigger(...) method

With @middleware you can define different middleware functions to perform data validation, logging, and other vital operations during the agent's process. Now you have complete control over the flow of data, whereas other frameworks leave you in the dark as to what's happening under the hood.

Try looking through the examples in the demos/ folder. You can also clone the repo and run through each demo to get an idea of how to use Magma and how it works.

Leave a Comment