
# SeiAI SDK

🔥 An AI-powered SDK for the Sei blockchain with advanced features for DeFi and AI integration.

## Features

- Wallet Management
  - Import wallets using mnemonic phrases
  - Send tokens and perform P2P swaps
  
- DeFi & Blockchain Integration
  - Real-time token prices and market data
  - DEX Integration
    - Automated market maker (AMM) swaps
    - Limit orders and order management
    - Liquidity provision and staking
    - Order history tracking
  - Staking & Governance
    - Token staking and unstaking
    - Validator management
    - Governance proposal voting
    - Validator list retrieval
  
  - Advanced Trading
    - Limit order creation
    - Order cancellation
    - Historical order tracking
    - Custom trading pairs
  - Market Analysis
    - Real-time price tracking
    - Trading volume analysis
    - Liquidity monitoring
    - Market depth tracking
    - Advanced Order Management
      - Market orders
      - Order book analysis
      - Position tracking
    - Enhanced Staking Features
      - Reward compounding
      - Staking analytics
    - Advanced Market Analysis
      - Price history analysis
      - Market depth tracking
      - Liquidity pool analysis
      - Real-time market summaries
    - Position Management
      - Position tracking
      - Portfolio analysis
      - Risk metrics

- AI Integration
  - Multiple AI Models:
    - OpenAI: GPT-4 Turbo (gpt-4-turbo-preview)
    - Anthropic: Claude 3 Opus (claude-3-opus-20240229)
    - Google: Gemini Pro Vision (gemini-pro-vision)
    - Groq: Mixtral 8x7B-32K (mixtral-8x7b-32768)
  
  - Specialized AI Agents:
    - Market Analysis Agent: Uses selected model for real-time market data analysis
    - Trading Signals Agent: Dedicated to technical analysis and trading patterns
    - Chat Agent: General-purpose interaction and market updates

## Installation

```bash
npm install seiai
```

## Quick Start

```javascript
import SeiAISDK from 'seiai';

const sdk = new SeiAISDK({
  rpcNodes: ['YOUR_RPC_NODE'],  // Add your RPC node
  chainId: 'YOUR_CHAIN_ID',     // Add your chain ID
  ai: {
    model: 'openai',            // Choose: 'openai', 'anthropic', 'gemini', or 'groq'
    apiKey: 'YOUR_API_KEY',     // Your AI model API key
    maxTokens: 300,             // Optional
    temperature: 0.7            // Optional
  }
});

// Import wallet
await sdk.importWallet('your mnemonic phrase');

// Get token price
const price = await sdk.getTokenPrice('SEI');

// Chat with AI
const response = await sdk.chatWithAI('What is the current SEI price?');
```

## Documentation

For detailed documentation and examples, visit our [documentation](https://docs.sei.io).

## License

MIT License
