llama-index tools azure_translate integration
Project description
Azure Translate Tool
This tool connects to a Azure account and allows an Agent to perform text translation into a variet of different languages
You will need to set up an api key and translate instance using Azure, learn more here: https://learn.microsoft.com/en-us/azure/ai-services/translator/translator-overview
For a full list of supported languages see here: https://learn.microsoft.com/en-us/azure/ai-services/translator/language-support
This tool has a more extensive example usage documented in a Jupyter notebook here
Usage
Here's an example usage of the AzureTranslateToolSpec.
from llama_index.agent.openai import OpenAIAgent
from llama_index.tools.azure_translate import AzureTranslateToolSpec
translate_tool = AzureTranslateToolSpec(api_key="your-key", region="eastus")
agent = OpenAIAgent.from_tools(
translate_tool.to_tool_list(),
verbose=True,
)
print(agent.chat('Say "hello world" in 5 different languages'))
translate
: Translate text to a target language
This loader is designed to be used as a way to load data as a Tool in a Agent.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for llama_index_tools_azure_translate-0.2.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | a3052abeb0ff9855adcc113b991641d3fc0a68698191b27f5670929f2edebca4 |
|
MD5 | 6ff0f549cae4f478b653eeaaab57588b |
|
BLAKE2b-256 | 8715ab58905c852a850674548f1563f6f0ba2a3534d32e972306849f7024b8e0 |
Hashes for llama_index_tools_azure_translate-0.2.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1a38093c5bc07737f9bfa6d9e0b295f7f6b8036369495bc4bcf107c63191a2f0 |
|
MD5 | 4aa9893a63bb3d614ee4556c5159fd09 |
|
BLAKE2b-256 | b60c00e2469a1cd30085aa8dbbef8882bb6b3f82c64f1876cc92a3cff46af5c9 |