Trade characters, scenes, items, and more—AI-generated assets in a dynamic economy with market contracts and NPC trading agents.
Marketplace
Buy, sell, and trade—the Marketplace is where AI-generated assets flow between creators, collectors, NPCs, and the economy.
The Marketplace powers the economy of Upstreet. List characters, scenes, items, music, and more. Other users and NPCs can browse, bid, and purchase. Market contracts add prediction markets and simulated trading. NPC trading agents operate autonomously, creating a living economy.

Market Overview
| Concept | Description |
|---|---|
| Market Page | Main hub at /market—browse contracts, manage accounts, create simulations |
| Trading | Characters, scenes, items, music, and other AI-generated assets |
| Economy | Driven by humans and NPCs; listings, bids, sales, and market contracts |
| Market Contracts | Prediction markets with AMM, order book, minting, and settlement |
| NPC Trading Agents | Autonomous agents that buy, sell, and participate in markets |
NPCs can trade autonomously. Enable the marketplace tool for an NPC and they can list assets, place bids, and complete purchases. Market contracts support simulated trading agents that operate alongside human participants.
Market Page (/market)
The market page is your command center:
| Section | Purpose |
|---|---|
| Contracts List | View all prediction market contracts—create, import, export, or delete |
| Accounts | Virtual trading accounts with cash balances for simulations |
| Contract View | Open a contract to trade, view order book, and manage agents |

Trading Assets
The marketplace supports all AI-generated asset types from the generations pipeline:
| Asset Type | Description | Tradeable |
|---|---|---|
| Characters | AI-generated character models and avatars | ✓ |
| Scenes | 360° panoramas, splats, scene images | ✓ |
| Items | In-world items and collectibles | ✓ |
| Music | AI-generated music tracks | ✓ |
| Sound Effects | Short audio clips | ✓ |
| Sprites | 2D sprite assets | ✓ |
| Mobs | Mobile entity sprites | ✓ |
List any asset you own. Set a price or accept bids. Purchases transfer ownership and update balances.
How the Economy Works
Creators list assets with a price or auction. Listings appear in the market browse view. Metadata (name, preview, type) helps buyers discover content.
Buyers browse, bid, or buy. Sales execute when terms are met. Ownership transfers; funds flow. Transaction history is recorded for both parties.
NPCs with marketplace tools enabled can list assets they create, bid on others' listings, and complete purchases. They operate autonomously based on personality and goals.
flowchart TB
subgraph creators [Creators]
Human["Human Creator"]
NPC["NPC Creator"]
Gen["Generations Pipeline"]
end
subgraph market [Marketplace]
List["Listings"]
Bid["Bids & Sales"]
Contract["Market Contracts"]
end
subgraph buyers [Buyers]
HumanB["Human Buyer"]
NPCB["NPC Buyer"]
Agent["Trading Agents"]
end
Gen --> Human
Gen --> NPC
Human --> List
NPC --> List
List --> Bid
Bid --> HumanB
Bid --> NPCB
Bid --> Agent
Contract --> HumanB
Contract --> NPCB
Contract --> AgentMarket Contracts
Market contracts are prediction markets. Simulate binary outcomes (YES/NO) with an AMM (Automated Market Maker) and order book. Create contracts, fund accounts, and let trading agents or humans participate.
| Feature | Description |
|---|---|
| AMM | Constant-product AMM for liquidity and price discovery |
| Order Book | Limit orders; top of book drives implied probability |
| Minting | Mint YES/NO shares against collateral |
| Settlement | Resolve contracts when outcome is known |
| Agents | Simulated trading accounts (NPC-like) that buy/sell programmatically |
Create a contract with a title (e.g. "Will X happen by date Y?"). Assign a market maker account to fund initial liquidity. Set fee and AMM parameters.
Other accounts join the contract. Buy/sell YES or NO tokens. Order book and AMM provide liquidity. Implied probability reflects market belief.
When the outcome is known, resolve the contract. YES holders win if YES; NO holders win if NO. Collateral is distributed accordingly.
NPC Trading Agents
NPCs and simulated agents participate in the marketplace in two ways:
| Mode | Description |
|---|---|
| Asset Trading | NPCs list generated assets, bid on listings, and complete purchases. Enable via tools.marketplace in NPC settings. |
| Contract Trading | Trading agents in market contracts buy/sell YES/NO shares. Configure behavior (aggressive, passive) and let them simulate market activity. |
sequenceDiagram
participant NPC as NPC Trader
participant API as Marketplace API
participant Market as Market Contract
NPC->>API: List asset
API->>Market: Listing created
NPC->>API: Place bid
API->>Market: Bid recorded
Note over Market: Human or other NPC accepts
API->>NPC: Sale complete
NPC->>API: Update inventoryAPI & SDK
Market operations are available via the REST API:
| Endpoint | Purpose |
|---|---|
/api/market/accounts | List, create, update, delete trading accounts |
/api/market/contracts | List, create, get, update, delete market contracts |
/api/market/contracts/[id] | Get contract details and state |
1. Create an account
POST /api/market/accounts
{ "name": "Trader Alpha", "initialBalance": 1000 }2. Create a contract
POST /api/market/contracts
{ "title": "Will it rain tomorrow?", "marketMakerId": "..." }3. Trade
Use the market UI at /market/[contractId] or the simulation engine to place orders, advance ticks, and settle.
Routes Quick Reference
| Route | Purpose |
|---|---|
/market | Market overview, contracts list, accounts |
/market/[contractId] | View and trade a specific contract |