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

feat: add agno docs #1261

Merged
merged 1 commit into from
Feb 6, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions docs/framework/phidata.mdx → docs/framework/agno.mdx
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
---
title: "Using Composio With Phidata"
sidebarTitle: "Phidata"
description: "Integrate Composio with Phidata agents to let them seamlessly interact with external apps"
title: "Using Composio With Agno"
sidebarTitle: "Agno"
description: "Integrate Composio with Agno agents to let them seamlessly interact with external apps"
---

## Star A Repository on Github
In this example, we will use Phidata Agent to star a repository on Github using Composio Tools
## Star A Repository on GitHub
In this example, we will use Agno Agent to star a repository on GitHub using Composio Tools

<Steps>
<Step title="Install Packages">
```bash Python
pip install composio-phidata
pip install composio-agno openai
Copy link
Collaborator

Choose a reason for hiding this comment

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

Consider specifying the minimum required versions for both composio-agno and openai packages to ensure compatibility. For example: pip install composio-agno>=0.7.1 openai>=1.0.0

```
</Step>
<Step title="Import Libraries & Initialize ComposioToolSet & LLM">
```python Python
from phi.assistant import Assistant
from composio_phidata import Action, App, ComposioToolSet
from agno.agent.agent import Agent
from composio_agno import Action, App, ComposioToolSet
Copy link
Collaborator

Choose a reason for hiding this comment

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

Consider adding a brief comment explaining what each imported component (Action, App, ComposioToolSet) is used for, to help new users understand their purpose.


toolset = ComposioToolSet()
```
Expand All @@ -39,20 +39,20 @@ Don't forget to set your `COMPOSIO_API_KEY` and `OPENAI_API_KEY` in your environ
</Tip>
</Step>

<Step title="Get All Github Tools">
<Step title="Get All GitHub Tools">
You can get all the tools for a given app as shown below, but you can get **specific actions** and filter actions using **usecase** & **tags**. Learn more [here](../../patterns/tools/use-tools/use-specific-actions)
```python Python
composio_tools = toolset.get_tools(apps=[App.GITHUB])
tools = toolset.get_tools(apps=[App.GITHUB])
```
</Step>
<Step title="Define the Assistant">
```python Python
assistant = Assistant(tools=composio_tools, show_tool_calls=True)
agent = Agent(tools=tools, show_tool_calls=True)
```
</Step>
<Step title="Execute the Agent">
```python Python
assistant.print_response("Can you star composiohq/composio repo?")
agent.print_response("Can you star ComposioHQ/composio repo?")
```
</Step>
</Steps>
Loading