@blockrun/franklin 3.20.0 → 3.20.1

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.
@@ -306,9 +306,8 @@ On-chain affiliate (20 bps in sell-token, force-set server-side) flows to BlockR
306
306
  - \`/v1/surf/social/*\` — KOL/CT mindshare, smart-follower history, tweets, user profiles. The canonical source for crypto-Twitter signal.
307
307
  - \`/v1/surf/fund/{detail,portfolio,ranking}\` — VC fund profiles, portfolios, ranking.
308
308
  - \`/v1/surf/project/{detail,defi/metrics,defi/ranking}\` — project profiles + DeFi protocol metrics.
309
- - \`/v1/surf/chat/completions\` — surf-1.5 chat model with first-class citations (\`citation: ["source","chart"]\`). \$0.02/call flat.
310
309
 
311
- For Surf workflows, prefer the bundled skills (\`/surf-market\`, \`/surf-chain\`, \`/surf-social\`, \`/surf-chat\`) — they document which endpoint to pick for which question and the cost trade-off. Skipped (use the dedicated tools instead): \`/v1/surf/prediction-market/*\` (use \`PredictionMarket\`), \`/v1/surf/search/*\` (use \`ExaSearch\`), \`/v1/surf/web/*\` (use \`BrowserX\`).
310
+ For Surf workflows, prefer the bundled skills (\`/surf-market\`, \`/surf-chain\`, \`/surf-social\`) — they document which endpoint to pick for which question and the cost trade-off. Skipped (use the dedicated tools instead): \`/v1/surf/prediction-market/*\` (use \`PredictionMarket\`), \`/v1/surf/search/*\` (use \`ExaSearch\`), \`/v1/surf/web/*\` (use \`BrowserX\`). \`/v1/surf/chat/completions\` (surf-1.5) is temporarily disabled in v3.20.1 — the BlockRun gateway's upstream path returns 404 from Surf; will be re-enabled in a follow-up release once the gateway side is fixed.
312
311
 
313
312
  **Generic gateway primitive**: \`BlockRun({ path, method, params, body })\` is a single capability that signs x402 and forwards to ANY path under \`/api\`. Use it for Surf endpoints (above) and any future BlockRun partner that doesn't have a dedicated capability yet. Always specify the exact path; the primitive will not guess.
314
313
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blockrun/franklin",
3
- "version": "3.20.0",
3
+ "version": "3.20.1",
4
4
  "description": "Franklin Agent — The AI agent with a wallet. Spends USDC autonomously to get real work done. Pay per action, no subscriptions.",
5
5
  "type": "module",
6
6
  "exports": {
@@ -1,76 +0,0 @@
1
- ---
2
- name: surf-chat
3
- description: Crypto-native chat with citations via the surf-1.5 model. Different from a generic LLM call — surf-1.5 is grounded in live crypto data and returns first-class citations (source links + charts). Use when the user wants research-shaped answers about projects, tokens, market events, or DeFi protocols, with sources attached.
4
- triggers:
5
- - "surf chat"
6
- - "crypto research"
7
- - "ask surf"
8
- - "with citations"
9
- - "grounded answer"
10
- argument-hint: <research question>
11
- cost-receipt: true
12
- ---
13
-
14
- You are running inside Franklin on **{{wallet_chain}}**. The `surf-1.5` model is crypto-native: it knows current market data, projects, on-chain flow, social signal, and returns structured citations. Reach for it when the user wants a sourced answer rather than a vibes-based one.
15
-
16
- **Chain note:** Surf currently settles x402 payments on **Base** only. If the user's active chain is `solana`, ask them to `/chain base` before calling — surf-1.5 is $0.02/call, so a failed payment retry isn't free.
17
-
18
- ## How to use
19
-
20
- Call:
21
-
22
- ```
23
- BlockRun({
24
- path: "/v1/surf/chat/completions",
25
- method: "POST",
26
- body: {
27
- model: "surf-1.5",
28
- messages: [
29
- { role: "user", content: "<the question>" }
30
- ],
31
- citation: ["source", "chart"]
32
- }
33
- })
34
- ```
35
-
36
- Cost: **flat $0.02 per call** (per-token billing is Phase 2 upstream).
37
-
38
- ### Response shape
39
-
40
- OpenAI-compatible, with two extras:
41
- - `choices[0].message.content` — the text answer
42
- - `choices[0].message.citations[]` — array of `{ type: "source" | "chart", url, title }`
43
-
44
- When you report back to the user, **always include the citations** as a footer:
45
-
46
- ```
47
- [Answer text]
48
-
49
- Sources:
50
- 1. <title> — <url>
51
- 2. <title> — <url>
52
- ```
53
-
54
- If `citations` is empty, mention that the answer is ungrounded.
55
-
56
- ### Multi-turn
57
-
58
- Pass previous `messages` back in for follow-up turns. Each turn is $0.02.
59
-
60
- ## When to use surf-chat vs the main agent loop
61
-
62
- - **Use surf-chat** when: the question is about market state, project research, narrative tracking, or "what happened to X in the last week" — anywhere fresh crypto context matters and you want citations to share with the user.
63
- - **Use the main agent loop** (no surf-chat) when: the question is general reasoning, coding, planning, summarization of content already in scope, or anything where adding citations doesn't add value.
64
-
65
- The wallet is funding the surf-chat call directly — be deliberate about reaching for it.
66
-
67
- ## When to use surf-chat vs the data endpoints
68
-
69
- - **surf-chat** is good when you don't know which endpoints to compose, or when the answer is qualitative ("what's the bull case for $X?").
70
- - The **`/surf-market` / `/surf-chain` / `/surf-social` skills** are better when the question is structured ("price of BTC", "RSI on ETH", "wallet net worth") — they're $0.001–$0.005 each and you keep full control of the data.
71
-
72
- If you can answer with one $0.001 call to a data endpoint, do that. Only escalate to surf-chat when the question needs synthesis across many endpoints or the user explicitly asks for cited research.
73
-
74
- ## The user asked
75
-
76
- $ARGUMENTS