IntentVM (Patent-Pending)
The Problem: Traditional blockchains require users to specify exact execution steps. A simple "swap then stake" requires 2 transactions, 2 signatures, and 2 consensus rounds.
The Solution: IntentVM accepts a single intent -- expressed as structured JSON or natural language -- and decomposes it into the optimal sequence of native operations, executed atomically in one block slot.
User: "swap 100 VXS for USDC and stake the rest"
IntentVM decomposes:
1. Swap (VXS -> USDC via VexiDEX)
2. Stake (remaining VXS to validator)
Result: 1 intent, 1 signature, 2 operations, 1 block slot
Key Advantage -- 1 Intent, 1 Signature, N Operations
On Solana or Ethereum, "swap then stake" = 2 transactions, 2 signatures, 2 consensus rounds. On Vexidus, it is 1 bundle, 1 signature, 1 round. This gives Vexidus 3-5x effective throughput per user action compared to per-transaction chains.
Provenance
IntentVM was first built and tested as a Solana on-chain program (Program ID: AcfdgJoduQxLLPwFDVTi3FWrqEERPhmQ9UAwNkrkYfnJ). Real transaction proofs exist from Solana localnet (slot 331,223, 12,099 compute units). It was then rebuilt as a core protocol feature on Vexidus -- not a theoretical design, but a port of working code.
Supported Goals
- Swap -- Token exchange via VexiDEX pools
- Stake -- Delegate VXS to validators
- Provide Liquidity -- Add to AMM pools
- Bridge -- Cross-chain with tier-aware proof verification
- Composite -- Atomic multi-step (bridge + swap + stake in one intent)
- Custom -- VNS registration, future LLM-parsed intents
Goal Types
pub enum Goal {
Swap { from_token, to_token, amount }, // Token swap (requires VexiDEX)
Stake { token, amount, validator }, // Stake VXS (works now)
ProvideLiquidity { token_a, token_b, ... }, // LP provision (requires VexiDEX)
Bridge { source_chain, token_symbol, amount, proof }, // Cross-chain bridge
Composite(Vec<Goal>), // Atomic multi-step (1 intent, 1 sig, N ops)
Custom(String), // NL-parsed (VNS, future LLM)
}
Current Execution Status
| Goal | Status | Notes |
|---|---|---|
| Stake | Works end-to-end | Maps to native Operation::Stake |
| Swap | Routing stub | VexiDEX AMM is live (disc 38-41), but IntentVM select_best_dex() not yet wired to pool queries. Direct vex_swap works. |
| ProvideLiquidity | Routing stub | VexiDEX pools exist. IntentVM routing to pools pending. Direct vex_addLiquidity works. |
| Bridge | Works end-to-end | Tier-aware proof verification, bridgeability guards, composable with Swap/Stake |
| Composite | Works | Recursively processes sub-goals. "bridge + swap" = atomic |
| Custom | Partial | VNS registration works (register_vns:name). General LLM integration future. |
Constraints
pub struct Constraints {
pub max_slippage: Option<u8>, // 0-100%
pub deadline: Option<Timestamp>, // Execution deadline
pub min_output: Option<Amount>, // Minimum output amount
pub preferred_route: RoutePreference, // Automatic, PreferDex, Custom
pub sponsored_gas: bool, // Gas sponsorship
}
RPC Endpoints
| Method | Input | Output |
|---|---|---|
vex_submitIntent | intent (JSON or NL string), sender address | Bundle hash |
vex_getExecutionPlan | intent (JSON or NL string) | Execution steps, estimated gas, savings |
vex_getIntentStatus | bundle hash | Status (pending/completed/failed), gas used |
Natural Language Patterns
| Pattern | Example | Goal Type |
|---|---|---|
| Swap | "swap 100 VXS for USDC" | Goal::Swap |
| Swap with slippage | "swap 50 ETH for VXS with 3% slippage" | Goal::Swap + constraints |
| Stake | "stake 1000 VXS" | Goal::Stake |
| Stake with validator | "stake 500 VXS with validator Vx1abc..." | Goal::Stake |
| Bridge | "bridge 10 SOL from solana" | Goal::Bridge |
| Bridge + Swap | "bridge 10 SOL from solana and swap to VXS" | Goal::Composite |
| Register Name | "register chris.vex" | Goal::Custom("register_vns:chris") |
| Unknown | "do something complex" | Goal::Custom (future LLM) |
Known Token Symbols
| Symbol | Token | Mint Address |
|---|---|---|
| VXS | Native Vexidus | Address::ZERO |
| USDC | Bridged USDC | Blake3("ethereum_USDC") |
| USDT | Bridged USDT | Blake3("ethereum_USDT") |
| SOL | Bridged SOL | Blake3("solana_SOL") |
| ETH/WETH | Bridged ETH | Blake3("ethereum_ETH") |
| BTC/WBTC | Bridged BTC | Blake3("ethereum_WBTC") |
Architecture
User Input (NL or JSON)
|
v
NL Parser
| pattern matching, maps to Goal enum
v
IntentBuilder
| fluent API, builds Goal + Constraints
v
RPC: vex_submitIntent
| builds intent bundle, submits to mempool
v
Execution Engine
| decomposes Goal -> native Operations
| Stake -> stake operation
| Swap -> DEX routing
| Composite -> recursive processing
v
Block Execution
Future: LLM Integration
The NL parser currently uses regex patterns. For more complex intents, integrate an LLM:
User: "Buy VXS with half my USDC and stake it with the highest-APY validator"
-> LLM extracts: Composite([
Swap { from: USDC, to: VXS, amount: 50% of balance },
Stake { token: VXS, amount: all, validator: highest_apy }
])
The Goal::Custom(String) variant is reserved for LLM-processed intents. Integration path:
- Client sends NL to LLM API (Grok, Claude, etc.)
- LLM returns structured Goal JSON
- Client submits structured JSON via
vex_submitIntent
Developer Guide
For code examples and SDK usage, see the IntentVM Developer Guide.