Skip to content

Commit

Permalink
initial (#82)
Browse files Browse the repository at this point in the history
  • Loading branch information
kush-alloralabs authored Jan 7, 2025
2 parents 5ee67f5 + 5526688 commit 2b7e39d
Show file tree
Hide file tree
Showing 7 changed files with 186 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pages/_meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,9 @@
"community": {
"title": "Community",
"type": "page"
},
"marketplace": {
"title": "Marketplace",
"type": "page"
}
}
}
4 changes: 4 additions & 0 deletions pages/marketplace/_meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"explore": "Explore Allora's Marketplace",
"integrations": "Integrations"
}
16 changes: 16 additions & 0 deletions pages/marketplace/explore.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import { Cards, Card, Callout } from 'nextra/components'

# Explore Allora's Marketplace

Allora's marketplace is a platform for developers to build and publish integrations for the Allora network.

## Integrations

<Cards>
<Card title="Eliza OS" href="/marketplace/integrations/eliza-os" />
<Card title="GOAT SDK" href="/marketplace/integrations/goat-sdk" />
</Cards>

## Prerequisites

- Grab an [Allora API Key](https://developer.upshot.xyz) before you start. This is required to use the plugin.
4 changes: 4 additions & 0 deletions pages/marketplace/integrations/_meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"eliza-os": "Eliza OS",
"goat-sdk": "GOAT SDK"
}
97 changes: 97 additions & 0 deletions pages/marketplace/integrations/eliza-os.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
# Eliza Allora Plugin ✨

The Allora Network plugin for Eliza enables seamless integration with Allora's powerful AI inference platform. This integration allows Eliza agents to access real-time predictions and insights powered by Allora's sophisticated machine learning models.

## Features

- Leverage **Allora's self-improving AI inferences** within Eliza agents.
- Fetch real-time predictions for various topics like ETH price predictions, market trends, and more.
- **Simple integration** with no complex infrastructure required.

---

## Installation

First, install the plugin via npm:

```bash
npm install @eliza-sdk/plugin-allora
```

---

## Environment Variables

To use the plugin, you need an Allora API key. Add the following variable to your `.env` file:

- `ALLORA_API_KEY`: Your Allora API key. To generate an API key, visit the [Upshot Developer Portal](https://allora.network).

---

## Setup

Import and configure the Allora plugin in your Eliza agent project:

```typescript
import { allora } from '@eliza-sdk/plugin-allora'

const plugin = allora({
apiKey: process.env.ALLORA_API_KEY,
})
```

---

## Available Actions

### Fetch Price Prediction

Get a price prediction for a specified asset and timeframe.

```typescript
const prediction = await plugin.fetchPricePrediction({
asset: 'ETH',
timeframe: '5min',
})
console.log(prediction)
// Example Output:
// { topic: 'ETH 5min Prediction', id: 13, value: 3393.364326646801085508 }
```

---

## Example Agent Interaction

```plaintext
User: "What is the predicted ETH price in 5 minutes?"
Agent: "I'll get the inference now..."
Agent: "Inference provided by Allora Network on topic ETH 5min Prediction (ID: 13): 3393.364326646801085508"
```

---

## Testing the Plugin

### Prerequisites

- Ensure the `ALLORA_API_KEY` environment variable is correctly set in your `.env` file.
- Install all dependencies and ensure Eliza is properly configured.

### Steps

1. Set up your environment:
```bash
export ALLORA_API_KEY=your_api_key_here
```

2. Initialize the plugin in your Eliza agent.

3. Run a test interaction:
- Ask your agent for a prediction (e.g., "What is the predicted ETH price in 5 minutes?").
- Validate the response contains data from Allora.

---

## Resources

- [Eliza SDK](https://github.com/eliza-sdk) - Explore Eliza's capabilities.
60 changes: 60 additions & 0 deletions pages/marketplace/integrations/goat-sdk.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# Goat Allora Plugin 🐐 (TypeScript)

The Allora Network plugin for Goat SDK empowers your blockchain agents with advanced AI-driven predictive capabilities. This integration bridges Goat's powerful on-chain interaction capabilities with Allora's sophisticated prediction models.

## Features

- **Smart Market Predictions**: Access real-time price forecasts and market trend analysis
- **Cross-chain Intelligence**: Leverage data from multiple blockchain networks and off-chain sources
- **Automated Decision Support**: Make data-driven decisions using self-improving prediction models
- **Scalable Infrastructure**: Handle high-frequency predictions without managing complex backend systems

As a Goat developer, this plugin enables you to:
1. Integrate AI predictions directly into your on-chain automation
2. Access market forecasts for informed trading strategies
3. Build smarter DeFi agents with predictive capabilities
4. Combine blockchain interactions with AI-powered insights

## Installation

```
npm install @goat-sdk/plugin-allora
```

## Environment Variables

- `ALLORA_API_KEY`: Your Allora API key. This is required to use the plugin.
- [Get your API key](https://developer.upshot.xyz)

## Setup

```typescript
import { allora } from '@goat-sdk/plugin-allora'

const plugin = allora({
apiKey: process.env.ALLORA_API_KEY,
})
```

## Available Actions

### Fetch Price Prediction

Fetches a price prediction for the given asset and timeframe.

```typescript
const prediction = await plugin.fetchPricePrediction({
asset: 'ETH',
timeframe: '1h'
})
```

## Goat

Go out and eat some grass.

[Docs](https://ohmygoat.dev) | [Examples](https://github.com/goat-sdk/goat/tree/main/typescript/examples) | [Discord](https://discord.gg/goat-sdk)

## Goat 🐐

Goat 🐐 (Great On-chain Agent Toolkit) is an open-source library enabling AI agents to interact with blockchain protocols and smart contracts via their own wallets.
Binary file modified public/.DS_Store
Binary file not shown.

0 comments on commit 2b7e39d

Please sign in to comment.