Skip to content

HyperbolicLabs/Hyperbolic-AgentKit

Repository files navigation

Hyperbolic Agentkit x X (Twitter) Chatbot x CDP Agentkit

This repository is inspired by and modified from Coinbase's CDP Agentkit. We extend our gratitude to the Coinbase Developer Platform team for their original work.

A template for running an AI agent with both blockchain and compute capabilities, plus X posting using:

This template demonstrates a chatbot that can:

Compute Operations (via Hyperbolic):

  • Rent GPU compute resources
  • Check GPU availability
  • Monitor GPU status
  • Access to GPU machines
  • Run command lines on remote GPU machines

Blockchain Operations (via CDP):

  • Deploy tokens (ERC-20 & NFTs)
  • Manage wallets
  • Execute transactions
  • Interact with smart contracts
  • Post on X

Prerequisites

  1. Python Version

    • This project requires Python 3.12
    • If using Poetry, you can ensure the correct version with:
    poetry env use python3.12
    poetry install
  2. API Keys

  3. Browser Automation

    • Install Playwright browsers after installing dependencies:
    poetry run playwright install

Quick Start

  1. Set Up Environment Variables

    # Copy the example environment file
    cp .env.example .env

    Then edit .env file and add your API keys

  2. Install Dependencies

    poetry install
  3. Run the Bot You can run the bot in two ways:

    a. Terminal Interface

    poetry run python chatbot.py
    • Choose between chat mode or autonomous mode
    • Start interacting with blockchain and compute resources!

    b. Web Interface (Gradio)

    poetry run python gradio_ui.py
    • Access the user-friendly web interface
    • Chat with the agent through your browser
    • View responses in a modern chat interface

Features

  • Interactive chat mode for guided interactions
  • Autonomous mode for self-directed operations
  • Full CDP Agentkit integration for blockchain operations
  • Hyperbolic integration for compute operations
  • Persistent wallet management
  • X (Twitter) integration
  • Modern web interface powered by Gradio