chain-insights 0.56.4 → 0.56.6
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.
package/package.json
CHANGED
|
@@ -23,7 +23,9 @@ The one case without the tool is at the end, Shell without the tool.
|
|
|
23
23
|
picture shortens its own labels; your text never does. Copy addresses from results exactly, all 42 characters, every
|
|
24
24
|
time. A repeat mention is written in full too: `0xd4a9…` as a
|
|
25
25
|
back-reference to an address named earlier is wrong, in a long answer most
|
|
26
|
-
of all. When the user
|
|
26
|
+
of all. When the user asks for shortened addresses "for readability",
|
|
27
|
+
still write them in full and say the full form is the rule, because a
|
|
28
|
+
shortened address cannot be copied or checked. When the user types a shortened address, take it as the one full
|
|
27
29
|
address in this conversation that matches both ends, and say which one you
|
|
28
30
|
took; when none or several match, ask for the full address. The network is `robinhood`, the Robinhood Chain: use it without asking
|
|
29
31
|
the user which network. `meta_network_capabilities` takes no arguments:
|
|
@@ -54,8 +56,8 @@ The one case without the tool is at the end, Shell without the tool.
|
|
|
54
56
|
and the Codex app draw the picture from the column names (see Name the
|
|
55
57
|
columns for a picture). Write a short text answer beside it, and do not
|
|
56
58
|
tell the user who draws the picture or that you did not draw it: "the host
|
|
57
|
-
draws the picture", "I won't draw it"
|
|
58
|
-
wrong. Never promise a picture: in a host that draws nothing, such as
|
|
59
|
+
draws the picture", "I won't draw it", "I can't draw a picture here" and
|
|
60
|
+
"I did not draw it" are all wrong. Never promise a picture: in a host that draws nothing, such as
|
|
59
61
|
Claude Code or a terminal, "the picture should appear beside this answer"
|
|
60
62
|
is false. When the user asks you to draw, answer with the flows as a list
|
|
61
63
|
or a table and say nothing about drawing. Any query whose
|
|
@@ -181,6 +183,16 @@ MATCH (a:Address {address: "0x04911a118f11c75667e4d0dfb8e640af5a353550"})
|
|
|
181
183
|
RETURN a.degree_in AS senders, a.degree_out AS receivers, a.tx_total_count AS tx_count, a.total_volume_usd AS volume_usd, a.first_activity_timestamp AS first_active, a.last_activity_timestamp AS last_active LIMIT 1
|
|
182
184
|
```
|
|
183
185
|
|
|
186
|
+
Which exchange an address cashed out to: its receivers that carry the exchange flag, one hop. Ask this first; it answers in under a second.
|
|
187
|
+
|
|
188
|
+
```cypher
|
|
189
|
+
USE topology
|
|
190
|
+
MATCH (a:Address {address: "0x04911a118f11c75667e4d0dfb8e640af5a353550"})-[f:FLOWS_TO]->(b:Address) WHERE NOT a:Pool AND b.is_exchange IS NOT NULL
|
|
191
|
+
RETURN a.address AS from_address, b.address AS to_address, f.amount_usd_sum AS amount_usd_sum, f.tx_count AS tx_count, f.first_seen_timestamp AS first_seen_timestamp, f.last_seen_timestamp AS last_seen_timestamp, a.labels AS from_labels, b.labels AS to_labels, a.is_exchange AS from_is_exchange, b.is_exchange AS to_is_exchange ORDER BY f.last_seen_timestamp DESC ORDER BY f.amount_usd_sum DESC LIMIT 25
|
|
192
|
+
```
|
|
193
|
+
|
|
194
|
+
When that is empty, one two-hop walk to an exchange at most (`{0,1}` in the route shape below, with `b.is_exchange IS NOT NULL` on the end and no address literal there). It can take the whole 60 s budget and end in `query_timeout` on a busy address: after one timeout, say no exchange was found within two hops and stop. Never widen to three or four hops, and never send the walk twice.
|
|
195
|
+
|
|
184
196
|
Route between two addresses, one path. Only `MATCH SHORTEST 1` and `MATCH ANY SHORTEST` are served: a count above 1 is `route_search_refused`.
|
|
185
197
|
|
|
186
198
|
```cypher
|
|
@@ -301,7 +313,7 @@ The server serves five read-only catalog calls: `CALL db.labels()`, `CALL db.rel
|
|
|
301
313
|
|
|
302
314
|
`USE facts` looks up rows you already know. A facts read names an address pair with one day. A transaction is read on `USE chain`, not here. A pair is both addresses, from then to, each as `{address: "<address>"}`, and the day is `t.block_date = "YYYY-MM-DD"`. One address, a day alone, a window of days, a block range and a bare `LIMIT` are not enough. It serves `TRANSFER`, `SWAP`, `LIQUIDITY_ADD`, `LIQUIDITY_REMOVE` and `BRIDGE_CROSSING` rows.
|
|
303
315
|
|
|
304
|
-
- A reply holds at most 200 rows, whatever the `LIMIT`.
|
|
316
|
+
- A reply holds at most 200 rows, whatever the `LIMIT`. When `count()` says the day holds more, give the count and one page, and say that the rest takes one read per 200 rows (a `t.block_timestamp >=` bound after the last row of the page). Read on only when the user asks for every row, and never beyond 5 pages in one turn: a loop of 61 reads once cost a user 131 seconds for one answer.
|
|
305
317
|
- A facts read has one relationship and no hop. For a walk, go to topology.
|
|
306
318
|
- A facts read takes no `ORDER BY`. Rows come in the server's own order. Sort the page yourself.
|
|
307
319
|
- A facts read aggregates with `count()` and `sum()` only, over the whole page: no grouping key, no `min()`, `max()` or `avg()` (`unsupported facts query shape`). Read the rows and compute the rest yourself.
|