Skip to content

Add storage implementation and update README + version #22

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 10 commits into from
Apr 2, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ _AI Agents with Onchain Intelligence_

## 📖 Overview

thirdweb AI is thirdweb's comprehensive toolkit for blockchain data analysis, wallet management, and AI agent interaction with blockchains. It simplifies complex blockchain operations into three core components: Insight for data analysis, Engine for wallet and contract operations, and Nebula for natural language-powered blockchain interactions.
thirdweb AI is thirdweb's comprehensive toolkit for blockchain data analysis, wallet management, and AI agent interaction with blockchains. It simplifies complex blockchain operations into four core components: Insight for data analysis, Engine for wallet and contract operations, Storage for decentralized file management, and Nebula for natural language-powered blockchain interactions.

## 🌐 Features

Expand All @@ -23,6 +23,11 @@ Core blockchain interaction capabilities:
- **Read**: Read operations for smart contracts and blockchain data
- **Write**: Transaction creation and contract interaction

### Storage
Decentralized storage capabilities:
- **Upload**: Upload files, directories, and JSON data to IPFS
- **Fetch**: Retrieve content from IPFS using thirdweb gateway

### Nebula
AI agent blockchain interaction:
- **Natural Language Agent Action**: Completing blockchain tasks through natural language instructions
Expand Down Expand Up @@ -68,18 +73,20 @@ See the list of [supported framework and installation guides](python/thirdweb-ai
#### Basic Usage

```python
from thirdweb_ai import Engine, Insight, Nebula, Tool
from thirdweb_ai import Engine, Insight, Nebula, Storage, Tool

# Initialize services
insight = Insight(secret_key=...)
nebula = Nebula(secret_key=...)
engine = Engine(...)
storage = Storage(secret_key=...)

# Example: Create tools for AI agents
tools = [
*insight.get_tools(),
*nebula.get_tools(),
*engine.get_tools(),
*storage.get_tools(),
# Or pick an individual tool from the services
]

Expand Down
5 changes: 4 additions & 1 deletion python/thirdweb-ai/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ With thirdweb-ai, your AI agents can:
- Deploy and interact with smart contracts
- Manage wallets and transactions
- Retrieve on-chain data
- Store and retrieve data on decentralized storage (IPFS)
- Access thirdweb's suite of web3 services

## Installation
Expand Down Expand Up @@ -48,12 +49,13 @@ pip install "thirdweb-ai[pydantic-ai]" # For Pydantic AI
thirdweb-ai provides a set of tools that can be integrated with various AI agent frameworks. Here's a basic example:

```python
from thirdweb_ai import Engine, Insight, Nebula, Tool
from thirdweb_ai import Engine, Insight, Nebula, Storage, Tool

# Initialize thirdweb services
insight = Insight(secret_key=...)
nebula = Nebula(secret_key=...)
engine = Engine(secret_key=...)
storage = Storage(secret_key=...)

# Get available tools
tools = [
Expand All @@ -62,6 +64,7 @@ tools = [
*insight.get_tools(),
*nebula.get_tools(),
*engine.get_tools(),
*storage.get_tools(),
# Or pick an individual tool from the services
]
```
Expand Down
2 changes: 1 addition & 1 deletion python/thirdweb-ai/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "thirdweb-ai"
version = "0.1.7"
version = "0.1.8"
description = "thirdweb AI"
authors = [{ name = "thirdweb", email = "[email protected]" }]
requires-python = ">=3.10,<4.0"
Expand Down
10 changes: 9 additions & 1 deletion python/thirdweb-mcp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ thirdweb MCP provides a unified interface to access thirdweb's suite of blockcha
- **Nebula**: Autonomous onchain execution - real-time on-chain analysis, code generation and contract interactions
- **Insight**: Blockchain data analysis capabilities for real-time on-chain data
- **Engine**: Integration with thirdweb's backend infrastructure for contract deployments and interactions
- **Storage**: Decentralized storage capabilities for uploading and retrieving data via IPFS

## Installation

Expand Down Expand Up @@ -44,7 +45,7 @@ uv sync

The thirdweb MCP server requires configuration based on which services you want to enable:

1. **thirdweb Secret Key**: Required for Nebula and Insight services. Obtain from the [thirdweb dashboard](https://thirdweb.com/dashboard).
1. **thirdweb Secret Key**: Required for Nebula, Insight, and Storage services. Obtain from the [thirdweb dashboard](https://thirdweb.com/dashboard).
2. **Chain IDs**: Blockchain network IDs to connect to (e.g., 1 for Ethereum mainnet, 137 for Polygon).
3. **Engine Configuration**: If using the Engine service, you'll need the Engine URL and authentication JWT.

Expand Down Expand Up @@ -141,6 +142,13 @@ Integrates with thirdweb's backend infrastructure:
- Interact with deployed contracts
- Manage wallet connections and transactions

### Storage

Provides decentralized storage functionality:
- Upload files, directories, and JSON data to IPFS
- Retrieve content from IPFS using thirdweb gateway
- Preserve directory structures when uploading

## License

[Apache-2.0 License](LICENSE)
Expand Down
2 changes: 1 addition & 1 deletion python/thirdweb-mcp/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "thirdweb-mcp"
version = "0.1.10"
version = "0.1.11"
description = "thirdweb MCP"
authors = [{ name = "thirdweb", email = "[email protected]" }]
requires-python = "~=3.10"
Expand Down