-
Notifications
You must be signed in to change notification settings - Fork 133
feat(integrations): add Agno integration docs #1529
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
Merged
Merged
Changes from 11 commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
e62e777
feat(integrations): add Agno integration docs
ohlava 1f768ee
Apply lint:md fix
ohlava a6f7e50
Merge branch 'master' into feat/agno-integration
jirispilka f624111
Update sources/platform/integrations/ai/agno.md
ohlava 36148d8
Apply comment suggestions
ohlava 97bbbb8
Merge branch 'master' into feat/agno-integration
ohlava cfd4b9d
Apply style changes for :::notes etc.
ohlava abc37be
Update sidebar position
ohlava e6a9577
Merge branch 'master' into feat/agno-integration
ohlava c169871
Merge branch 'apify:master' into feat/agno-integration
ohlava 3870730
Remove apify-langchain dependence.md
ohlava 9d8c38d
Apply suggestions from code review
ohlava b1bc08a
Configuration better readability and Alternative LLM providers
ohlava 29adfe0
Merge branch 'master' into feat/agno-integration
jirispilka 4b47fb9
Add link to agno docs
ohlava a55da5a
Merge branch 'master' into feat/agno-integration
jirispilka 8c86895
Remove baldness of Config options
ohlava 3c7ce70
Merge branch 'master' into feat/agno-integration
jirispilka File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -121,3 +121,4 @@ upvote | |
| walkthroughs? | ||
|
|
||
| ul | ||
| [Aa]gno | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,137 @@ | ||
| --- | ||
| title: Agno Integration | ||
| sidebar_label: Agno | ||
| description: Integrate Apify with Agno to power AI agents with web scraping, automation, and data insights. | ||
| sidebar_position: 14 | ||
| slug: /integrations/agno | ||
| --- | ||
|
|
||
| **Integrate Apify with Agno to power AI agents with web scraping, automation, and data insights.** | ||
|
|
||
| --- | ||
|
|
||
| ## What is Agno? | ||
|
|
||
| [Agno](https://docs.agno.com/) is an open-source framework for building intelligent AI agents. It provides a flexible architecture to create agents with custom tools, enabling seamless integration with external services like Apify for tasks such as web scraping, data extraction and automation. | ||
|
|
||
| :::note Agno documentation | ||
|
|
||
| Check out the [Agno documentation](https://docs.agno.com/introduction) for more details on building AI agents. | ||
|
|
||
| ::: | ||
|
|
||
| ## How to Use Apify with Agno | ||
|
|
||
| This guide shows how to integrate Apify Actors with Agno to empower your AI agents with real-time web data. We'll use the [RAG Web Browser](https://apify.com/apify/rag-web-browser) Actor to fetch web content and the [Google Places Crawler](https://apify.com/compass/crawler-google-places) Actor to extract location-based data. It is very easy to use with any other Actor by just passing the name of the Actor. See and choose from thousands of Actors in the [Apify Store](https://apify.com/store). | ||
|
|
||
| ### Prerequisites | ||
|
|
||
| - *Apify API token*: Obtain your token from the [Apify console](https://console.apify.com/account/integrations). | ||
jirispilka marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| - *Python environment*: Ensure Python is installed (version 3.8+ recommended). | ||
| - *Required packages*: Install the following dependencies in your terminal: | ||
ohlava marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| ```bash | ||
| pip install agno apify-client | ||
| ``` | ||
|
|
||
| ## Basic Integration Example | ||
|
|
||
| Start by setting up an Agno agent with Apify tools. This example uses the RAG Web Browser Actor to extract content from a specific URL. | ||
|
|
||
| ```python | ||
| from agno.agent import Agent | ||
| from agno.tools.apify import ApifyTools | ||
|
|
||
| # Initialize the agent with Apify tools | ||
| agent = Agent( | ||
| tools=[ | ||
| ApifyTools( | ||
| actors=["apify/rag-web-browser"], | ||
| apify_api_token="YOUR_APIFY_API_TOKEN" # Replace YOUR_APIFY_API_TOKEN with your token | ||
| ) | ||
| ], | ||
| show_tool_calls=True, | ||
| markdown=True | ||
| ) | ||
|
|
||
| # Fetch and display web content | ||
| agent.print_response("Extract key details from https://docs.agno.com/introduction", markdown=True) | ||
ohlava marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| ``` | ||
|
|
||
| Running this code will scrape the specified URL and return formatted content your agent can use. | ||
|
|
||
| :::tip Environment variable token | ||
|
|
||
| You can also set the APIFY_API_TOKEN environment variable instead of passing it directly in the code. | ||
|
|
||
| ::: | ||
|
|
||
ohlava marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ### Advanced Scenario: Travel Planning Agent | ||
ohlava marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| Combine multiple Apify Actors to create a powerful travel planning agent. This example uses the RAG Web Browser and Google Places Crawler to gather travel insights and local business data. | ||
|
|
||
| ```python | ||
| from agno.agent import Agent | ||
| from agno.tools.apify import ApifyTools | ||
ohlava marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
|
||
| # Create a travel planning agent | ||
| agent = Agent( | ||
| name="Travel Planner", | ||
| instructions=[ | ||
| "You are a travel planning assistant. Use web data and location insights to provide detailed travel recommendations." | ||
| ], | ||
| tools=[ | ||
| ApifyTools( | ||
| actors=[ | ||
| "apify/rag-web-browser", # For general web research | ||
| "compass/crawler-google-places" # For location-based data | ||
| ], | ||
| apify_api_token="YOUR_APIFY_API_TOKEN" | ||
ohlava marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ) | ||
| ], | ||
| show_tool_calls=True, | ||
| markdown=True | ||
| ) | ||
|
|
||
| # Plan a trip to Tokyo | ||
| agent.print_response( | ||
| """ | ||
| I'm traveling to Tokyo next month. | ||
| 1. Research the best time to visit and top attractions. | ||
| 2. Find a highly rated sushi restaurant near Shinjuku. | ||
| Compile a travel guide with this information. | ||
| """, | ||
| markdown=True | ||
| ) | ||
| ``` | ||
|
|
||
| This agent will fetch travel-related data and restaurant recommendations, providing a comprehensive travel guide: | ||
|
|
||
| 1. Use the RAG Web Browser to research Tokyo travel details. | ||
| 2. Use the Google Places Crawler to find a top sushi restaurant. | ||
| 3. Combine the results into a comprehensive guide. | ||
|
|
||
| :::tip Apify Store | ||
|
|
||
| Browse the [Apify Store](https://apify.com/store) to find additional Actors for tasks like social media scraping, e-commerce data extraction, or news aggregation. | ||
|
|
||
| ::: | ||
|
|
||
| ### Available Apify Tools | ||
ohlava marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| Agno supports any Apify Actor via the ApifyTools class. You can specify a single Actor ID or a list of Actor IDs to register multiple tools for your agent at once. | ||
|
|
||
| ## Configuration Options | ||
|
|
||
| | Parameter | Type | Default | Description | | ||
| | ---------------------------- | ------------------- | ------- | ------------------------------------------------------------------ | | ||
| | `apify_api_token` | `str` | `None` | Apify API token (or set via APIFY_API_TOKEN environment variable) | | ||
| | `actors` | `str` or `List[str]`| `None` | Single Actor ID or list of Actor IDs to register | | ||
ohlava marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
jirispilka marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| ## Resources | ||
|
|
||
| - [How to build an AI Agent](https://blog.apify.com/how-to-build-an-ai-agent/) | ||
jirispilka marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| - [Agno Framework Documentation](https://docs.agno.com) | ||
| - [Apify Platform Documentation](https://docs.apify.com) | ||
| - [Apify Actor Documentation](https://docs.apify.com/actors) | ||
| - [Apify Store - Browse available Actors](https://apify.com/store) | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.