Dynamic AI Model Manager

AI Agent SDK supports multiple AI model providers. Below are the currently available llm_config provider options:

  • OpenAI: Represents the OpenAI provider.

  • Anthropic: Represents the Anthropic provider.

  • Mistral: Represents the Mistral provider.

  • Fireworks: Represents the Fireworks provider.

  • GoogleGenAI: Represents the Google Generative AI provider

Example: Using Crypto.com AI Agent with Gemini

Here is an example to use the Crypto.com AI Agent with Google's Gemini model for Cronos chain interactions:

from crypto_com_agent_client import Agent, SQLitePlugin


# Initialize the agent
agent = Agent.init(
   llm_config={
       "provider": "GoogleGenAI",
       "model": "gemini-1.5",
       "provider-api-key": "your-api-key",
   },
   blockchain_config={
       "chainId": "chain-id",
       "explorer-api-key": "your-api-key",
       "private-key": "your-private-key",
       "sso-wallet-url": "your-sso-wallet-url",
   },
   plugins={
       "storage": SQLitePlugin(db_path="agent_state.db"),
       "instructions": "You are an assistant that always provides useful responses."
   },
)


# Interaction
response = agent.interact("Get latest block height")
print(response)

Last updated

Was this helpful?