Skip to main content

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

File details

Details for the file llama_index_tools_azure_translate-0.3.0.tar.gz.

File metadata

File hashes

Hashes for llama_index_tools_azure_translate-0.3.0.tar.gz
Algorithm Hash digest
SHA256 dce3c4cd12ba4baf37f31489c6c209dfd0434b47d11b31a167bd211c9dc67812
MD5 41ff04cfce1cb08e215e2f98df1343fc
BLAKE2b-256 799c5472ea8b709273bce00ec193a8ec0aec9c8d4ae14d1b28f344ee0e8e3ccb

See more details on using hashes here.

File details

Details for the file llama_index_tools_azure_translate-0.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for llama_index_tools_azure_translate-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 756c05d71de09d938964e2aa4e1c244b12c3c6fde510c8c8b1b5c467fdf55455
MD5 49b0e35250b74bd0caa8f9d4c5dc4890
BLAKE2b-256 d3f1f85d95a8771da8bdebb1ba7a52e8e1f7888bbf82eecd931dbc114e6b4e7b

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page