wispy-ai 1.5.0 → 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (116) hide show
  1. package/CHANGELOG.md +49 -0
  2. package/README.md +156 -252
  3. package/dist/ai/tools.d.ts.map +1 -1
  4. package/dist/ai/tools.js +229 -0
  5. package/dist/ai/tools.js.map +1 -1
  6. package/dist/channels/discord/adapter.d.ts +17 -18
  7. package/dist/channels/discord/adapter.d.ts.map +1 -1
  8. package/dist/channels/discord/adapter.js +138 -115
  9. package/dist/channels/discord/adapter.js.map +1 -1
  10. package/dist/channels/matrix/adapter.d.ts +36 -0
  11. package/dist/channels/matrix/adapter.d.ts.map +1 -0
  12. package/dist/channels/matrix/adapter.js +271 -0
  13. package/dist/channels/matrix/adapter.js.map +1 -0
  14. package/dist/channels/signal/adapter.d.ts +28 -23
  15. package/dist/channels/signal/adapter.d.ts.map +1 -1
  16. package/dist/channels/signal/adapter.js +209 -130
  17. package/dist/channels/signal/adapter.js.map +1 -1
  18. package/dist/channels/slack/adapter.d.ts +28 -17
  19. package/dist/channels/slack/adapter.d.ts.map +1 -1
  20. package/dist/channels/slack/adapter.js +179 -88
  21. package/dist/channels/slack/adapter.js.map +1 -1
  22. package/dist/cli/setup/wizard.d.ts.map +1 -1
  23. package/dist/cli/setup/wizard.js +174 -0
  24. package/dist/cli/setup/wizard.js.map +1 -1
  25. package/dist/cli/ui/banner.d.ts +1 -1
  26. package/dist/cli/ui/banner.js +1 -1
  27. package/dist/core/process-manager.d.ts +73 -0
  28. package/dist/core/process-manager.d.ts.map +1 -0
  29. package/dist/core/process-manager.js +207 -0
  30. package/dist/core/process-manager.js.map +1 -0
  31. package/dist/core/sessions.d.ts +82 -0
  32. package/dist/core/sessions.d.ts.map +1 -0
  33. package/dist/core/sessions.js +227 -0
  34. package/dist/core/sessions.js.map +1 -0
  35. package/dist/integrations/base.d.ts +1 -1
  36. package/dist/integrations/base.d.ts.map +1 -1
  37. package/dist/integrations/base.js.map +1 -1
  38. package/dist/integrations/categories.d.ts.map +1 -1
  39. package/dist/integrations/categories.js +12 -0
  40. package/dist/integrations/categories.js.map +1 -1
  41. package/dist/integrations/chat/matrix.d.ts +21 -0
  42. package/dist/integrations/chat/matrix.d.ts.map +1 -0
  43. package/dist/integrations/chat/matrix.js +160 -0
  44. package/dist/integrations/chat/matrix.js.map +1 -0
  45. package/dist/integrations/chat/msteams.d.ts +20 -0
  46. package/dist/integrations/chat/msteams.d.ts.map +1 -0
  47. package/dist/integrations/chat/msteams.js +138 -0
  48. package/dist/integrations/chat/msteams.js.map +1 -0
  49. package/dist/integrations/chat/signal.d.ts +20 -0
  50. package/dist/integrations/chat/signal.d.ts.map +1 -0
  51. package/dist/integrations/chat/signal.js +133 -0
  52. package/dist/integrations/chat/signal.js.map +1 -0
  53. package/dist/integrations/commerce/stripe.d.ts +20 -0
  54. package/dist/integrations/commerce/stripe.d.ts.map +1 -0
  55. package/dist/integrations/commerce/stripe.js +175 -0
  56. package/dist/integrations/commerce/stripe.js.map +1 -0
  57. package/dist/integrations/loader.js +23 -2
  58. package/dist/integrations/loader.js.map +1 -1
  59. package/dist/integrations/media/camera.d.ts +16 -0
  60. package/dist/integrations/media/camera.d.ts.map +1 -0
  61. package/dist/integrations/media/camera.js +134 -0
  62. package/dist/integrations/media/camera.js.map +1 -0
  63. package/dist/integrations/media/image-gen.d.ts +19 -0
  64. package/dist/integrations/media/image-gen.d.ts.map +1 -0
  65. package/dist/integrations/media/image-gen.js +215 -0
  66. package/dist/integrations/media/image-gen.js.map +1 -0
  67. package/dist/integrations/productivity/asana.d.ts +20 -0
  68. package/dist/integrations/productivity/asana.d.ts.map +1 -0
  69. package/dist/integrations/productivity/asana.js +194 -0
  70. package/dist/integrations/productivity/asana.js.map +1 -0
  71. package/dist/integrations/productivity/calendly.d.ts +21 -0
  72. package/dist/integrations/productivity/calendly.d.ts.map +1 -0
  73. package/dist/integrations/productivity/calendly.js +193 -0
  74. package/dist/integrations/productivity/calendly.js.map +1 -0
  75. package/dist/integrations/productivity/trello.d.ts +22 -0
  76. package/dist/integrations/productivity/trello.d.ts.map +1 -0
  77. package/dist/integrations/productivity/trello.js +156 -0
  78. package/dist/integrations/productivity/trello.js.map +1 -0
  79. package/dist/integrations/security/onepassword.d.ts +22 -0
  80. package/dist/integrations/security/onepassword.d.ts.map +1 -0
  81. package/dist/integrations/security/onepassword.js +147 -0
  82. package/dist/integrations/security/onepassword.js.map +1 -0
  83. package/dist/integrations/smart-home/sonos.d.ts +22 -0
  84. package/dist/integrations/smart-home/sonos.d.ts.map +1 -0
  85. package/dist/integrations/smart-home/sonos.js +192 -0
  86. package/dist/integrations/smart-home/sonos.js.map +1 -0
  87. package/dist/integrations/social/instagram.d.ts +39 -0
  88. package/dist/integrations/social/instagram.d.ts.map +1 -0
  89. package/dist/integrations/social/instagram.js +247 -0
  90. package/dist/integrations/social/instagram.js.map +1 -0
  91. package/dist/integrations/social/linkedin.d.ts +29 -0
  92. package/dist/integrations/social/linkedin.d.ts.map +1 -0
  93. package/dist/integrations/social/linkedin.js +166 -0
  94. package/dist/integrations/social/linkedin.js.map +1 -0
  95. package/dist/integrations/social/reddit.d.ts +39 -0
  96. package/dist/integrations/social/reddit.d.ts.map +1 -0
  97. package/dist/integrations/social/reddit.js +317 -0
  98. package/dist/integrations/social/reddit.js.map +1 -0
  99. package/dist/integrations/social/signal.d.ts +21 -0
  100. package/dist/integrations/social/signal.d.ts.map +1 -0
  101. package/dist/integrations/social/signal.js +143 -0
  102. package/dist/integrations/social/signal.js.map +1 -0
  103. package/dist/integrations/tools/canvas.d.ts +21 -0
  104. package/dist/integrations/tools/canvas.d.ts.map +1 -0
  105. package/dist/integrations/tools/canvas.js +229 -0
  106. package/dist/integrations/tools/canvas.js.map +1 -0
  107. package/dist/skills/registry.d.ts +43 -0
  108. package/dist/skills/registry.d.ts.map +1 -0
  109. package/dist/skills/registry.js +172 -0
  110. package/dist/skills/registry.js.map +1 -0
  111. package/dist/wallet/payment-bridge.d.ts +115 -0
  112. package/dist/wallet/payment-bridge.d.ts.map +1 -0
  113. package/dist/wallet/payment-bridge.js +245 -0
  114. package/dist/wallet/payment-bridge.js.map +1 -0
  115. package/package.json +20 -13
  116. package/wispy/memory/2026-02-07.md +0 -8
package/CHANGELOG.md ADDED
@@ -0,0 +1,49 @@
1
+ # Changelog
2
+
3
+ ## [1.6.0] - 2026-02-20
4
+
5
+ ### Added
6
+ - **Named Sessions** with isolated context, daily auto-reset, and instant switching
7
+ - **Process Manager** to spawn, monitor, kill, and auto-restart background processes
8
+ - **Skills.sh Registry** client with search, install, and uninstall for 67,000+ community skills
9
+ - **Cross-Model Delegation** to Claude, GPT-4o, Llama, Groq, Kimi, and 200+ models via OpenRouter
10
+ - **Cross-Model Payment Bridge** so any delegated model can trigger x402 payments
11
+ - **Model Comparison** tool to send the same prompt to multiple models side-by-side
12
+ - **Slack** channel adapter (Socket Mode with mentions, threads)
13
+ - **Matrix** channel adapter (Client-Server API v3, long-poll sync)
14
+ - **Signal** channel adapter (signal-cli REST API)
15
+ - 14 new integrations: LinkedIn, Instagram, Reddit, MS Teams, Matrix, Signal, Trello, Asana, Calendly, Image Generation, Camera/Screenshot, Stripe, 1Password, Sonos
16
+ - Canvas integration for SVG and Mermaid diagram generation
17
+ - Budget controls with daily limits, per-transaction caps, auto-approve thresholds
18
+ - Proactive goal tools (agent_goal_set, agent_goals_list)
19
+ - Multi-provider setup wizard (configure Gemini + Anthropic + OpenAI + Ollama + OpenRouter in one flow)
20
+
21
+ ### Changed
22
+ - Tool count expanded from 90+ to 120+
23
+ - Integration count expanded from 27 to 42+
24
+ - Channel count expanded from 7 to 10
25
+ - Updated README to comprehensive product documentation
26
+ - Updated docs site (docs.wispy.cc) with all v1.6 features
27
+
28
+ ## [1.5.1] - 2026-02-08
29
+
30
+ ### Added
31
+ - Marathon Mode with autonomous multi-step execution, checkpointing, and auto-recovery
32
+ - Thinking Levels (low/medium/high/ultra) with up to 24K thinking tokens
33
+ - x402 agentic commerce with USDC payments on SKALE
34
+ - AP2 mandate chains and BITE v2 encryption
35
+ - DeFi swap engine with Algebra DEX integration
36
+ - Telegram and WhatsApp channel adapters with Marathon support
37
+ - Discord channel adapter with threads and file uploads
38
+ - REST API and WebSocket channels
39
+ - Agent-to-Agent (A2A) protocol support
40
+ - 90+ built-in tools across file system, web, browser, code execution, memory, media, blockchain
41
+ - 27 integrations across Google, productivity, social, smart home, and AI models
42
+ - Browser automation with 39 tools + 55 built-in skills via Playwright
43
+ - Interactive setup wizard (onboard command)
44
+ - Health check (doctor command)
45
+ - Day/night theme support
46
+
47
+ ## [1.0.0] - 2026-01-15
48
+
49
+ - Initial release
package/README.md CHANGED
@@ -2,315 +2,222 @@
2
2
  <img src="assets/banner.png" alt="Wispy Banner" width="100%" />
3
3
  </p>
4
4
 
5
- <h1 align="center">Wispy — Agentic Commerce on SKALE</h1>
5
+ <h1 align="center">Wispy</h1>
6
6
 
7
7
  <p align="center">
8
- <strong>An AI Agent That Can Spend Money on the Internet by Itself</strong>
8
+ <strong>Autonomous AI Agent Platform</strong><br />
9
+ <em>120+ tools, 42+ integrations, multi-model, sessions, skills.sh, x402 commerce</em>
9
10
  </p>
10
11
 
11
12
  <p align="center">
12
- <a href="https://dorahacks.io/hackathon/x402"><img src="https://img.shields.io/badge/Hackathon-SF%20Agentic%20Commerce%20x402-purple?style=flat-square" alt="x402 Hackathon" /></a>
13
13
  <a href="https://www.npmjs.com/package/wispy-ai"><img src="https://img.shields.io/npm/v/wispy-ai?style=flat-square&color=31ccff" alt="npm version" /></a>
14
14
  <a href="https://opensource.org/licenses/MIT"><img src="https://img.shields.io/badge/license-MIT-blue?style=flat-square" alt="License" /></a>
15
15
  <a href="https://nodejs.org"><img src="https://img.shields.io/badge/node-%3E%3D20-brightgreen?style=flat-square" alt="Node.js" /></a>
16
16
  <a href="https://www.typescriptlang.org"><img src="https://img.shields.io/badge/TypeScript-5.7-blue?style=flat-square&logo=typescript&logoColor=white" alt="TypeScript" /></a>
17
- <a href="https://github.com/hausorlabs/wispy"><img src="https://img.shields.io/badge/Submission-Hausor%20Labs-31ccff?style=flat-square" alt="Hausor Labs" /></a>
18
17
  </p>
19
18
 
20
19
  <p align="center">
21
- <a href="#what-we-built">What We Built</a> &middot;
22
- <a href="#track-coverage">Tracks</a> &middot;
23
- <a href="#hackathon-implementation">Implementation</a> &middot;
24
- <a href="#run-the-demo">Run Demo</a> &middot;
25
- <a href="#architecture">Architecture</a> &middot;
26
- <a href="https://wispy.cc">Website</a>
20
+ <a href="https://docs.wispy.cc">Docs</a> &middot;
21
+ <a href="https://wispy.cc">Website</a> &middot;
22
+ <a href="https://app.wispy.cc">Platform</a> &middot;
23
+ <a href="https://github.com/hausorlabs/wispy">GitHub</a>
27
24
  </p>
28
25
 
29
26
  ---
30
27
 
31
- ## SF Agentic Commerce x402 Hackathon — SKALE Labs
32
-
33
- > **Hackathon**: [SF Agentic Commerce x402](https://dorahacks.io/hackathon/x402) | **Dates**: Feb 11–14, 2026 | **Prize Pool**: $50,000
34
- >
35
- > **Team**: [Hausor Labs](https://hausorlabs.tech) — Brian Mwai, Joy C. Langat
36
-
37
- ---
38
-
39
- ## What We Built
40
-
41
- Wispy is an **autonomous AI agent** powered by Google Gemini 2.5 Pro that can **discover, evaluate, pay for, and consume** paid services on the internet — entirely on its own.
28
+ ## What is Wispy?
42
29
 
43
- During the hackathon, we built a complete **agentic commerce integration** on SKALE's BITE V2 Sandbox that covers all 5 tracks:
30
+ Wispy is an autonomous AI agent that lives in your terminal, messaging apps, and APIs. Powered by Google Gemini 2.5 Pro with multi-model delegation to Claude, GPT-4o, Llama, and 200+ models via OpenRouter.
44
31
 
45
- 1. **The agent finds a paid API** — discovers services behind HTTP 402 paywalls
46
- 2. **It decides if it's worth paying** — evaluates cost vs. budget with spending controls
47
- 3. **It pays with crypto** — signs EIP-3009 USDC authorizations, routed through Kobaru facilitator
48
- 4. **It encrypts sensitive transactions** — uses BITE v2 BLS threshold encryption so validators can't see the `to` or `data` fields until consensus
49
- 5. **It produces a full audit trail** — every payment logged, every decision tracked, every receipt stored
50
-
51
- No human intervention. No manual approvals for micro-payments. The agent manages its own wallet, respects its spending policy, and chains multiple paid calls to complete complex tasks.
32
+ ```bash
33
+ npm install -g wispy-ai
34
+ wispy onboard
35
+ wispy chat
36
+ ```
52
37
 
53
38
  ---
54
39
 
55
- ## Track Coverage
56
-
57
- | Track | Prize | What Wispy Demonstrates | Key Files |
58
- |-------|-------|------------------------|-----------|
59
- | **1. Overall Best Agent** | $9,500 | End-to-end: discover paid API decide ROI pay with USDC → deliver result → audit trail | [`demo/scenarios/track1-overall.ts`](src/integrations/agentic-commerce/demo/scenarios/track1-overall.ts) |
60
- | **2. x402 Tool Usage** | $7,000 | Chained x402 calls with EIP-3009 signed authorizations, budget-aware spending, per-call tracking | [`x402/buyer.ts`](src/integrations/agentic-commerce/x402/buyer.ts), [`x402/tracker.ts`](src/integrations/agentic-commerce/x402/tracker.ts) |
61
- | **3. AP2 Integration** | $7,000 | Intent → Cart → Payment → Receipt mandate chain with failure handling and rollback | [`ap2/flow.ts`](src/integrations/agentic-commerce/ap2/flow.ts) |
62
- | **4. DeFi Agent** | $3,000 | Multi-source research via Algebra DEX subgraphs, risk engine with guardrails, on-chain swaps | [`defi/swap.ts`](src/integrations/agentic-commerce/defi/swap.ts), [`defi/risk-engine.ts`](src/integrations/agentic-commerce/defi/risk-engine.ts) |
63
- | **5. Encrypted Agents (BITE v2)** | $4,500 | BLS threshold encryption of transactions, conditional execution, on-chain verification | [`bite/encrypted-tx.ts`](src/integrations/agentic-commerce/bite/encrypted-tx.ts) |
40
+ ## Features
41
+
42
+ ### Core
43
+
44
+ - **120+ Built-in Tools** across file system, web, browser automation, code execution, memory, media, blockchain, and identity
45
+ - **Marathon Mode** for multi-step, long-running autonomous tasks with checkpointing and auto-recovery
46
+ - **Thinking Levels** (low/medium/high/ultra) with up to 24K thinking tokens
47
+ - **Named Sessions** with isolated context, daily auto-reset, and instant switching
48
+ - **Process Manager** to spawn, monitor, and manage background processes
49
+ - **Skills.sh Registry** with 67,000+ community skills you can install with a single command
50
+
51
+ ### Multi-Model
52
+
53
+ - **Gemini 2.5 Pro** (core reasoning engine)
54
+ - **Cross-model delegation** to Claude Opus/Sonnet, GPT-4o, Groq, Kimi, Llama via Ollama, and 200+ models via OpenRouter
55
+ - **Model comparison** to send the same prompt to multiple models and compare responses
56
+ - **Setup wizard** configures all providers in one flow
57
+
58
+ ### Channels (10)
59
+
60
+ | Channel | Status |
61
+ |---------|--------|
62
+ | CLI (REPL) | Built-in |
63
+ | Telegram | Full adapter with Marathon support, file access, voice |
64
+ | WhatsApp | Baileys adapter with Marathon support |
65
+ | Discord | Full adapter with threads, file uploads |
66
+ | Slack | Socket Mode adapter with mentions, threads |
67
+ | Matrix | Client-Server API v3 with long-poll sync |
68
+ | Signal | signal-cli REST API adapter |
69
+ | REST API | Express with API key auth |
70
+ | WebSocket | Real-time streaming |
71
+ | Agent-to-Agent (A2A) | Google A2A protocol |
72
+
73
+ ### Integrations (42+)
74
+
75
+ | Category | Integrations |
76
+ |----------|-------------|
77
+ | AI Models | OpenAI, Anthropic, Ollama, OpenRouter, Groq, Kimi |
78
+ | Google | Calendar, Docs, Drive, Gmail, Maps, Meet, Search, Sheets, YouTube |
79
+ | Chat | Discord, Slack, Matrix, Signal, MS Teams |
80
+ | Productivity | Notion, GitHub, Linear, Obsidian, Trello, Asana, Calendly |
81
+ | Social | Twitter/X, LinkedIn, Instagram, Reddit |
82
+ | Smart Home | Home Assistant, Hue, Sonos |
83
+ | Music | Spotify |
84
+ | Commerce | Stripe |
85
+ | Security | 1Password |
86
+ | Media | Image Generation (DALL-E/Stability/Replicate), Camera/Screenshot |
87
+ | Tools | Weather, Webhooks, Canvas (SVG/Mermaid) |
88
+ | Browser | 39 automation tools + 55 built-in skills via Playwright |
89
+
90
+ ### Agentic Commerce (x402)
91
+
92
+ - **x402 protocol** for autonomous USDC payments on SKALE (gasless)
93
+ - **AP2 mandate chains** (intent, cart, payment, receipt)
94
+ - **BITE v2 encryption** for private transactions (BLS threshold)
95
+ - **DeFi swap engine** with Algebra DEX integration and risk controls
96
+ - **Cross-model payment bridge** so any AI model can trigger payments
97
+ - **Budget controls** with daily limits, per-transaction caps, auto-approve thresholds
64
98
 
65
99
  ---
66
100
 
67
- ## Hackathon Implementation
68
-
69
- > **All hackathon code lives in: [`src/integrations/agentic-commerce/`](src/integrations/agentic-commerce/)**
70
- >
71
- > **25 TypeScript files | 4,470 lines of code | 46 tests passing | 0 TypeScript errors**
72
-
73
- ### Directory Breakdown
101
+ ## Quick Start
74
102
 
75
- ```
76
- src/integrations/agentic-commerce/
77
-
78
- ├── config.ts # SKALE BITE V2 chain config, Algebra DEX contracts + ABIs
79
-
80
- ├── x402/ # Track 2: x402 Protocol
81
- │ ├── buyer.ts # HTTP 402 detection → EIP-3009 USDC authorization → retry with proof
82
- │ ├── seller.ts # Mock x402 seller endpoints for demo services
83
- │ └── tracker.ts # Per-call spend tracking, daily audit ledger, budget enforcement
84
-
85
- ├── ap2/ # Track 3: AP2 Protocol
86
- │ ├── mandates.ts # Intent / Cart / Payment mandate objects
87
- │ ├── receipts.ts # Payment receipts + transaction records
88
- │ └── flow.ts # AP2 orchestration engine (mandate chain with rollback)
89
-
90
- ├── defi/ # Track 4: DeFi Agent
91
- │ ├── swap.ts # Algebra DEX integration (SwapRouter + QuoterV2), direct USDC fallback
92
- │ └── risk-engine.ts # Position limits, volatility checks, slippage controls
93
-
94
- ├── bite/ # Track 5: Encrypted Agents
95
- │ ├── encrypted-tx.ts # BITE v2 BLS threshold encryption, on-chain submit + verify
96
- │ └── conditional.ts # Conditional execution: time-lock, delivery-proof, oracle gates
97
-
98
- ├── demo/ # Live Demo Infrastructure
99
- │ ├── server.ts # Launches mock x402 services (weather, sentiment, report, price)
100
- │ ├── runner.ts # Runs all 5 track demos end-to-end
101
- │ ├── verify.ts # On-chain verification utilities
102
- │ └── scenarios/
103
- │ ├── track1-overall.ts # Full agent commerce lifecycle
104
- │ ├── track2-x402.ts # Chained x402 paid API calls
105
- │ ├── track3-ap2.ts # AP2 mandate flow demo
106
- │ ├── track4-defi.ts # DeFi research + swap demo
107
- │ └── track5-bite.ts # BITE encrypted transaction demo
108
-
109
- ├── tests/ # 46 Tests (vitest)
110
- │ ├── ap2-flow.test.ts
111
- │ ├── bite-encrypt.test.ts
112
- │ ├── integration.test.ts
113
- │ ├── risk-engine.test.ts
114
- │ └── tracker.test.ts
115
-
116
- ├── index.ts # Integration entry: 11 agent tools registered into Wispy
117
- └── README.md # Detailed integration documentation
118
- ```
103
+ ```bash
104
+ # Install
105
+ npm install -g wispy-ai
119
106
 
120
- ### How Each Protocol Works
107
+ # Interactive setup (Gemini key + optional providers + Telegram + wallet)
108
+ wispy onboard
121
109
 
122
- **x402 Payment Flow (Track 2):**
123
- ```
124
- Agent makes HTTP request → Server returns 402 Payment Required
125
- → Agent reads price from x402 headers → Checks budget policy
126
- → Signs EIP-3009 USDC authorization → Sends to Kobaru facilitator
127
- → Facilitator settles on SKALE → Agent retries request with payment proof
128
- → Server validates receipt → Returns paid content → Agent logs spend
129
- ```
110
+ # Chat in the terminal
111
+ wispy chat
130
112
 
131
- **AP2 Mandate Chain (Track 3):**
132
- ```
133
- Agent creates INTENT mandate ("I need weather data")
134
- → Service responds with CART mandate (items + pricing)
135
- → Agent creates PAYMENT mandate (signed USDC authorization)
136
- → Service creates RECEIPT mandate (delivery confirmation)
137
- → Any step can fail → automatic rollback and retry with budget adjustment
138
- ```
113
+ # Start a Marathon (autonomous multi-step task)
114
+ wispy marathon "Build a full-stack SaaS dashboard with auth and payments"
139
115
 
140
- **BITE v2 Encryption Flow (Track 5):**
141
- ```
142
- Agent encrypts transaction fields (to + calldata) with BLS threshold keys
143
- → Submits encrypted tx to SKALE BITE magic address
144
- → Transaction is opaque in mempool — no MEV, no front-running
145
- → Validators cooperatively decrypt during consensus (2t+1 threshold)
146
- → Agent verifies decryption via bite_getDecryptedTransactionData RPC
147
- ```
116
+ # Run the gateway (all channels simultaneously)
117
+ wispy gateway
148
118
 
149
- **DeFi Agent Flow (Track 4):**
119
+ # Run as a background daemon
120
+ wispy gateway --daemon
150
121
  ```
151
- Agent queries Algebra DEX subgraph for pool data
152
- → Checks on-chain liquidity via Factory.poolByPair()
153
- → Runs risk engine (position limits, slippage, volatility)
154
- → Executes swap via SwapRouter.exactInputSingle() or falls back to direct USDC transfer
155
- → Logs trade decision with reason codes and risk score
156
- ```
157
-
158
- ### Agent Tools (11 Registered)
159
-
160
- The integration registers 11 tools into Wispy's tool system, making them available to the AI agent during conversations and autonomous tasks:
161
-
162
- | Tool | Track | Description |
163
- |------|-------|-------------|
164
- | `x402_pay_and_fetch` | 1, 2 | Access paid APIs via x402 with automatic payment |
165
- | `x402_check_budget` | 1, 2 | Check daily budget, spending limits, remaining allowance |
166
- | `x402_audit_trail` | 1, 2 | Full payment audit trail with per-call breakdown |
167
- | `ap2_purchase` | 3 | AP2 mandate flow: intent → cart → payment → receipt |
168
- | `ap2_get_receipts` | 3 | Retrieve AP2 transaction records |
169
- | `defi_research` | 4 | Multi-source market research via Algebra subgraphs |
170
- | `defi_swap` | 4 | Risk-controlled token swap on Algebra DEX |
171
- | `defi_trade_log` | 4 | Trade decisions with reason codes and risk scores |
172
- | `bite_encrypt_payment` | 5 | BITE v2 BLS threshold encryption of transactions |
173
- | `bite_check_and_execute` | 5 | Conditional execution of encrypted transactions |
174
- | `bite_lifecycle_report` | 5 | Encrypted payment lifecycle report |
175
122
 
176
123
  ---
177
124
 
178
- ## Run the Demo
125
+ ## CLI Commands
179
126
 
180
127
  ```bash
181
- # Clone the repo
182
- git clone https://github.com/hausorlabs/wispy.git
183
- cd wispy
128
+ wispy chat # Interactive REPL
129
+ wispy agent "prompt" # Single-shot prompt
130
+ wispy marathon "goal" # Autonomous multi-step task
131
+ wispy gateway # Start all channels
132
+ wispy onboard # Setup wizard
133
+ wispy doctor # Health check
134
+ wispy skills list # List browser skills
135
+ wispy integrations list # List all integrations
136
+ wispy wallet balance # Check wallet balance
137
+ wispy wallet details # Wallet address + chain info
138
+ ```
184
139
 
185
- # Install dependencies
186
- npm install
140
+ ---
187
141
 
188
- # Start mock x402 services (weather, sentiment, report, price data)
189
- npx tsx src/integrations/agentic-commerce/demo/server.ts
142
+ ## Configuration
190
143
 
191
- # Run all 5 track demos (in another terminal)
192
- npx tsx src/integrations/agentic-commerce/demo/runner.ts
144
+ Wispy uses `~/.wispy/config.yaml` for configuration and `.env` for secrets:
193
145
 
194
- # Run with real on-chain BITE transactions (requires funded wallet)
195
- AGENT_PRIVATE_KEY=0x... npx tsx src/integrations/agentic-commerce/demo/runner.ts
146
+ ```yaml
147
+ # config.yaml
148
+ gemini:
149
+ models:
150
+ pro: gemini-2.5-pro-preview-05-06
151
+ flash: gemini-2.5-flash-preview-05-20
196
152
 
197
- # Run individual tracks
198
- npx tsx src/integrations/agentic-commerce/demo/scenarios/track5-bite.ts
153
+ channels:
154
+ telegram: { enabled: true }
155
+ discord: { enabled: false }
156
+ slack: { enabled: false }
199
157
 
200
- # Run tests (46/46 passing)
201
- npx vitest run src/integrations/agentic-commerce/tests/
202
- ```
158
+ providers:
159
+ anthropic: { apiKey: "..." }
160
+ openai: { apiKey: "..." }
203
161
 
204
- ### Environment Variables
162
+ security:
163
+ autonomousMode: true
164
+ fullFilesystemAccess: true
205
165
 
206
- | Variable | Required | Description |
207
- |----------|----------|-------------|
208
- | `AGENT_PRIVATE_KEY` | For on-chain | Hex private key for the agent wallet (EIP-3009 signing) |
209
- | `SELLER_PRIVATE_KEY` | No | Hex private key for mock seller (auto-generated if not set) |
210
- | `GEMINI_API_KEY` | For AI | Google Gemini API key for the agent's reasoning engine |
166
+ wallet:
167
+ enabled: true
168
+ chain: skale-bite-sandbox
211
169
 
212
- ---
213
-
214
- ## Network & Contracts
170
+ theme: day
171
+ ```
215
172
 
216
- | Component | Value |
217
- |-----------|-------|
218
- | **Chain** | SKALE BITE V2 Sandbox (Chain ID: `103698795`) |
219
- | **RPC** | `https://base-sepolia-testnet.skalenodes.com/v1/bite-v2-sandbox` |
220
- | **USDC** | `0xc4083B1E81ceb461Ccef3FDa8A9F24F0d764B6D8` |
221
- | **Facilitator** | `https://gateway.kobaru.io` |
222
- | **Gas** | Free (SKALE is gasless) |
223
- | **Algebra SwapRouter** | `0x3012E9049d05B4B5369D690114D5A5861EbB85cb` |
224
- | **Algebra QuoterV2** | `0x03f8B4b140249Dc7B2503C928E7258CCe1d91F1A` |
225
- | **Algebra Factory** | `0x10253594A832f967994b44f33411940533302ACb` |
226
- | **BITE Magic Address** | `0x42495445204D452049274d20454e435259505444` |
173
+ ```bash
174
+ # .env
175
+ GEMINI_API_KEY=AIza...
176
+ TELEGRAM_BOT_TOKEN=123456:ABC...
177
+ AGENT_PRIVATE_KEY=0x...
178
+ ANTHROPIC_API_KEY=sk-ant-...
179
+ OPENAI_API_KEY=sk-...
180
+ ```
227
181
 
228
182
  ---
229
183
 
230
184
  ## Architecture
231
185
 
232
- ### Agentic Commerce Layer
233
-
234
186
  ```
235
- ┌─────────────────────────────────────────────────────────────────────┐
236
- WISPY AGENTIC COMMERCE
237
- ├─────────────────────────────────────────────────────────────────────┤
238
- │ │
239
- AI Agent (Gemini 2.5 Pro) │
240
- │ ┌──────────────────────────────────────────────────────────┐ │
241
- "Find weather data, pay for it, encrypt the payment"
242
- │ └──────────────┬───────────────────────────────────────────┘
243
-
244
- │ ┌──────────────▼───────────────────────────────────────────┐
245
- 11 Agent Tools
246
- │ │ x402_pay_and_fetch │ ap2_purchase │ defi_swap │ bite_* │ │
247
- └──────┬──────────┬──────────┬──────────┬─────────────────┘
248
- │ │ │ │ │ │
249
- ┌──────▼────┐ ┌───▼────┐ ┌──▼─────┐ ┌─▼──────────┐
250
- │ │ x402 AP2 │ │ DeFi │ │ BITE v2
251
- Buyer │ Mandate│ │ Swap │ │ Encrypted
252
- │ │ + Track │ │ Chain │ │ Engine │ │ Commerce │ │
253
- │ └──────┬────┘ └───┬────┘ └──┬─────┘ └─┬──────────┘ │
254
- │ │ │ │ │ │
255
- │ ┌──────▼──────────▼──────────▼──────────▼─────────────────┐ │
256
- │ │ SKALE BITE V2 Sandbox (Gasless) │ │
257
- │ │ USDC │ Algebra DEX │ BITE BLS Encryption │ Kobaru │ │
258
- │ └─────────────────────────────────────────────────────────┘ │
259
- │ │
260
- └─────────────────────────────────────────────────────────────────────┘
187
+ ┌─────────────────────────┐
188
+ Gemini 2.5 Pro (Core)
189
+ │ + Cross-Model Bridge │
190
+ └─────────┬───────────────┘
191
+
192
+ ┌───────────────────┼───────────────────┐
193
+
194
+ ┌────────▼──────┐ ┌───────▼───────┐ ┌─────────▼────────┐
195
+ 120+ Tools 42+ Integs │ │ x402 Commerce │
196
+ Sessions │ │ Skills.sh │ │ Payment Bridge │
197
+ Processes │ Browser (39) Budget Policy │
198
+ └────────┬──────┘ └───────┬───────┘ └─────────┬────────┘
199
+
200
+ ┌────────▼──────────────────▼──────────────────────▼──────┐
201
+ Channel Dock
202
+ CLI | Telegram | WhatsApp | Discord | Slack | Matrix
203
+ Signal | REST | WebSocket | A2A
204
+ └─────────────────────────────────────────────────────────┘
261
205
  ```
262
206
 
263
- ### Wispy Platform (Pre-existing)
264
-
265
- Wispy is a full autonomous AI agent platform with:
266
-
267
- - **Marathon Mode** — Multi-day autonomous task execution with checkpointing
268
- - **27+ Built-in Tools** — File ops, web scraping, browser automation, image generation
269
- - **Multi-Channel** — CLI, Telegram, WhatsApp, REST API, WebSocket
270
- - **ERC-8004 Identity** — On-chain agent registration on Base Sepolia
271
- - **A2A Protocol** — Agent-to-agent communication (Google)
272
- - **Memory System** — SQLite + vector embeddings for persistent context
273
-
274
- The agentic commerce integration plugs into this platform as a first-class integration, registering its 11 tools alongside Wispy's existing 27+ tools.
275
-
276
207
  ---
277
208
 
278
- ## Tech Stack
279
-
280
- | Component | Technology |
281
- |-----------|-----------|
282
- | **AI Agent** | Wispy (TypeScript, Google Gemini 2.5 Pro) |
283
- | **Blockchain** | SKALE BITE V2 Sandbox |
284
- | **Payments** | x402 protocol (EIP-3009 signed USDC) |
285
- | **Wallet** | viem + @x402/evm |
286
- | **DEX** | Algebra Integral v1.2.2 (concentrated liquidity) |
287
- | **Encryption** | BITE v2 BLS threshold encryption (@skalenetwork/bite) |
288
- | **Authorization** | AP2 mandate protocol |
289
- | **Runtime** | Node.js 20+, TypeScript 5.7, ESM |
290
- | **Testing** | vitest (46 tests) |
291
- | **Mock Services** | Express.js + @x402/express |
292
-
293
- ---
209
+ ## Documentation
294
210
 
295
- ## Hackathon Build Log
296
-
297
- | Day | Date | What We Built |
298
- |-----|------|---------------|
299
- | **Day 1** | Feb 11 | SKALE chain config, x402 buyer/seller/tracker, wallet setup, dependency integration |
300
- | **Day 2** | Feb 12 | AP2 mandate chain, BITE v2 encrypted transactions, DeFi swap engine with Algebra DEX |
301
- | **Day 3** | Feb 13 | Integration loader (11 tools), 5-track demo scenarios, 46 tests, demo infrastructure |
302
- | **Day 4** | Feb 14 | Documentation, CHANGELOG, README, submission polish |
211
+ Full documentation at **[docs.wispy.cc](https://docs.wispy.cc)**
303
212
 
304
213
  ---
305
214
 
306
- ## Deployed Contracts
215
+ ## Team
216
+
217
+ Built by [Hausor Labs](https://hausorlabs.tech)
307
218
 
308
- | Contract | Address | Network |
309
- |----------|---------|---------|
310
- | Agent Registry | [`0x158B236CC840FD3039a3Cf5D72AEfBF2550045C7`](https://sepolia.basescan.org/address/0x158B236CC840FD3039a3Cf5D72AEfBF2550045C7) | Base Sepolia |
311
- | USDC (Sandbox) | `0xc4083B1E81ceb461Ccef3FDa8A9F24F0d764B6D8` | SKALE BITE V2 Sandbox |
312
- | Algebra SwapRouter | `0x3012E9049d05B4B5369D690114D5A5861EbB85cb` | SKALE BITE V2 Sandbox |
313
- | Algebra Factory | `0x10253594A832f967994b44f33411940533302ACb` | SKALE BITE V2 Sandbox |
219
+ - **Brian Mwai** - Engineering
220
+ - **Joy C. Langat** - Product
314
221
 
315
222
  ---
316
223
 
@@ -320,13 +227,10 @@ The agentic commerce integration plugs into this platform as a first-class integ
320
227
 
321
228
  ---
322
229
 
323
- <p align="center">
324
- <strong>Wispy</strong> is built by <a href="https://hausorlabs.tech">Hausor Labs</a>
325
- </p>
326
-
327
230
  <p align="center">
328
231
  <a href="https://wispy.cc">wispy.cc</a> &middot;
329
232
  <a href="https://docs.wispy.cc">docs</a> &middot;
233
+ <a href="https://app.wispy.cc">platform</a> &middot;
330
234
  <a href="https://www.npmjs.com/package/wispy-ai">npm</a> &middot;
331
235
  <a href="https://github.com/hausorlabs/wispy">GitHub</a>
332
236
  </p>
@@ -1 +1 @@
1
- {"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../../src/ai/tools.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE;QACV,IAAI,EAAE,QAAQ,CAAC;QACf,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE;YAAE,IAAI,EAAE,MAAM,CAAC;YAAC,WAAW,EAAE,MAAM,CAAA;SAAE,CAAC,CAAC;QAClE,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;KACrB,CAAC;CACH;AAED,eAAO,MAAM,cAAc,EAAE,eAAe,EAksC3C,CAAC;AAEF,wBAAgB,mBAAmB,CACjC,OAAO,GAAE,OAAc,EACvB,UAAU,GAAE,eAAe,EAAO,EAClC,QAAQ,GAAE,eAAe,EAAO,EAChC,gBAAgB,GAAE,eAAe,EAAO,GACvC,OAAO,EAAE,CA2BX"}
1
+ {"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../../src/ai/tools.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE;QACV,IAAI,EAAE,QAAQ,CAAC;QACf,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE;YAAE,IAAI,EAAE,MAAM,CAAC;YAAC,WAAW,EAAE,MAAM,CAAA;SAAE,CAAC,CAAC;QAClE,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;KACrB,CAAC;CACH;AAED,eAAO,MAAM,cAAc,EAAE,eAAe,EAu6C3C,CAAC;AAEF,wBAAgB,mBAAmB,CACjC,OAAO,GAAE,OAAc,EACvB,UAAU,GAAE,eAAe,EAAO,EAClC,QAAQ,GAAE,eAAe,EAAO,EAChC,gBAAgB,GAAE,eAAe,EAAO,GACvC,OAAO,EAAE,CA2BX"}