agentwallet-sdk 4.0.5 → 5.0.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.
Files changed (400) hide show
  1. package/README.md +154 -158
  2. package/dist/abi.d.ts +396 -46
  3. package/dist/abi.d.ts.map +1 -1
  4. package/dist/abi.js +0 -2
  5. package/dist/abi.js.map +1 -1
  6. package/dist/ap2/index.d.ts +185 -0
  7. package/dist/ap2/index.d.ts.map +1 -0
  8. package/dist/ap2/index.js +255 -0
  9. package/dist/ap2/index.js.map +1 -0
  10. package/dist/bridge/abis.d.ts.map +1 -1
  11. package/dist/bridge/abis.js +0 -2
  12. package/dist/bridge/abis.js.map +1 -1
  13. package/dist/bridge/client.d.ts +28 -43
  14. package/dist/bridge/client.d.ts.map +1 -1
  15. package/dist/bridge/client.js +0 -2
  16. package/dist/bridge/client.js.map +1 -1
  17. package/dist/bridge/index.d.ts +1 -0
  18. package/dist/bridge/index.d.ts.map +1 -1
  19. package/dist/bridge/index.js +0 -2
  20. package/dist/bridge/index.js.map +1 -1
  21. package/dist/bridge/types.d.ts +48 -32
  22. package/dist/bridge/types.d.ts.map +1 -1
  23. package/dist/bridge/types.js +0 -2
  24. package/dist/bridge/types.js.map +1 -1
  25. package/dist/bridge/unified.d.ts +101 -0
  26. package/dist/bridge/unified.d.ts.map +1 -0
  27. package/dist/bridge/unified.js +284 -0
  28. package/dist/bridge/unified.js.map +1 -0
  29. package/dist/chains.d.ts +62 -0
  30. package/dist/chains.d.ts.map +1 -0
  31. package/dist/chains.js +108 -0
  32. package/dist/chains.js.map +1 -0
  33. package/dist/escrow/MutualStakeEscrow.d.ts +75 -0
  34. package/dist/escrow/MutualStakeEscrow.d.ts.map +1 -0
  35. package/dist/escrow/MutualStakeEscrow.js +339 -0
  36. package/dist/escrow/MutualStakeEscrow.js.map +1 -0
  37. package/dist/escrow/types.d.ts +59 -0
  38. package/dist/escrow/types.d.ts.map +1 -0
  39. package/dist/escrow/types.js +11 -0
  40. package/dist/escrow/types.js.map +1 -0
  41. package/dist/escrow/verifiers.d.ts +26 -0
  42. package/dist/escrow/verifiers.d.ts.map +1 -0
  43. package/dist/escrow/verifiers.js +53 -0
  44. package/dist/escrow/verifiers.js.map +1 -0
  45. package/dist/fiat/index.d.ts +10 -0
  46. package/dist/fiat/index.d.ts.map +1 -0
  47. package/dist/fiat/index.js +9 -0
  48. package/dist/fiat/index.js.map +1 -0
  49. package/dist/fiat/onramp.d.ts +101 -0
  50. package/dist/fiat/onramp.d.ts.map +1 -0
  51. package/dist/fiat/onramp.js +155 -0
  52. package/dist/fiat/onramp.js.map +1 -0
  53. package/dist/fiat/providers/index.d.ts +16 -0
  54. package/dist/fiat/providers/index.d.ts.map +1 -0
  55. package/dist/fiat/providers/index.js +30 -0
  56. package/dist/fiat/providers/index.js.map +1 -0
  57. package/dist/fiat/providers/moonpay.d.ts +22 -0
  58. package/dist/fiat/providers/moonpay.d.ts.map +1 -0
  59. package/dist/fiat/providers/moonpay.js +107 -0
  60. package/dist/fiat/providers/moonpay.js.map +1 -0
  61. package/dist/fiat/providers/stripe.d.ts +26 -0
  62. package/dist/fiat/providers/stripe.d.ts.map +1 -0
  63. package/dist/fiat/providers/stripe.js +135 -0
  64. package/dist/fiat/providers/stripe.js.map +1 -0
  65. package/dist/fiat/providers/transak.d.ts +26 -0
  66. package/dist/fiat/providers/transak.d.ts.map +1 -0
  67. package/dist/fiat/providers/transak.js +119 -0
  68. package/dist/fiat/providers/transak.js.map +1 -0
  69. package/dist/fiat/types.d.ts +106 -0
  70. package/dist/fiat/types.d.ts.map +1 -0
  71. package/dist/fiat/types.js +13 -0
  72. package/dist/fiat/types.js.map +1 -0
  73. package/dist/flash/executor.d.ts +119 -0
  74. package/dist/flash/executor.d.ts.map +1 -0
  75. package/dist/flash/executor.js +195 -0
  76. package/dist/flash/executor.js.map +1 -0
  77. package/dist/flash/index.d.ts +28 -0
  78. package/dist/flash/index.d.ts.map +1 -0
  79. package/dist/flash/index.js +29 -0
  80. package/dist/flash/index.js.map +1 -0
  81. package/dist/flash/scanner.d.ts +133 -0
  82. package/dist/flash/scanner.d.ts.map +1 -0
  83. package/dist/flash/scanner.js +212 -0
  84. package/dist/flash/scanner.js.map +1 -0
  85. package/dist/flash/types.d.ts +136 -0
  86. package/dist/flash/types.d.ts.map +1 -0
  87. package/dist/flash/types.js +23 -0
  88. package/dist/flash/types.js.map +1 -0
  89. package/dist/gas/index.d.ts +4 -0
  90. package/dist/gas/index.d.ts.map +1 -0
  91. package/dist/gas/index.js +3 -0
  92. package/dist/gas/index.js.map +1 -0
  93. package/dist/gas/sponsor.d.ts +70 -0
  94. package/dist/gas/sponsor.d.ts.map +1 -0
  95. package/dist/gas/sponsor.js +193 -0
  96. package/dist/gas/sponsor.js.map +1 -0
  97. package/dist/gas/types.d.ts +76 -0
  98. package/dist/gas/types.d.ts.map +1 -0
  99. package/dist/gas/types.js +21 -0
  100. package/dist/gas/types.js.map +1 -0
  101. package/dist/identity/agent-identity.d.ts +276 -0
  102. package/dist/identity/agent-identity.d.ts.map +1 -0
  103. package/dist/identity/agent-identity.js +300 -0
  104. package/dist/identity/agent-identity.js.map +1 -0
  105. package/dist/identity/erc6551.d.ts +441 -0
  106. package/dist/identity/erc6551.d.ts.map +1 -0
  107. package/dist/identity/erc6551.js +517 -0
  108. package/dist/identity/erc6551.js.map +1 -0
  109. package/dist/identity/erc8004.d.ts +296 -141
  110. package/dist/identity/erc8004.d.ts.map +1 -1
  111. package/dist/identity/erc8004.js +43 -12
  112. package/dist/identity/erc8004.js.map +1 -1
  113. package/dist/identity/index.d.ts +6 -2
  114. package/dist/identity/index.d.ts.map +1 -1
  115. package/dist/identity/index.js +3 -2
  116. package/dist/identity/index.js.map +1 -1
  117. package/dist/identity/reputation.d.ts +318 -0
  118. package/dist/identity/reputation.d.ts.map +1 -0
  119. package/dist/identity/reputation.js +272 -0
  120. package/dist/identity/reputation.js.map +1 -0
  121. package/dist/identity/validation.d.ts +284 -0
  122. package/dist/identity/validation.d.ts.map +1 -0
  123. package/dist/identity/validation.js +226 -0
  124. package/dist/identity/validation.js.map +1 -0
  125. package/dist/index.d.ts +32624 -1011
  126. package/dist/index.d.ts.map +1 -1
  127. package/dist/index.js +16 -12
  128. package/dist/index.js.map +1 -1
  129. package/dist/mev/index.d.ts +4 -0
  130. package/dist/mev/index.d.ts.map +1 -0
  131. package/dist/mev/index.js +8 -0
  132. package/dist/mev/index.js.map +1 -0
  133. package/dist/mev/protection.d.ts +54 -0
  134. package/dist/mev/protection.d.ts.map +1 -0
  135. package/dist/mev/protection.js +185 -0
  136. package/dist/mev/protection.js.map +1 -0
  137. package/dist/mev/risk.d.ts +19 -0
  138. package/dist/mev/risk.d.ts.map +1 -0
  139. package/dist/mev/risk.js +95 -0
  140. package/dist/mev/risk.js.map +1 -0
  141. package/dist/mev/types.d.ts +49 -0
  142. package/dist/mev/types.d.ts.map +1 -0
  143. package/dist/mev/types.js +2 -0
  144. package/dist/mev/types.js.map +1 -0
  145. package/dist/plugins/elizaos.d.ts +26 -14
  146. package/dist/plugins/elizaos.d.ts.map +1 -1
  147. package/dist/plugins/elizaos.js +0 -2
  148. package/dist/plugins/elizaos.js.map +1 -1
  149. package/dist/policy/SpendingPolicy.d.ts +89 -15
  150. package/dist/policy/SpendingPolicy.d.ts.map +1 -1
  151. package/dist/policy/SpendingPolicy.js +0 -2
  152. package/dist/policy/SpendingPolicy.js.map +1 -1
  153. package/dist/policy/SpendingPolicy.test.d.ts +2 -0
  154. package/dist/policy/SpendingPolicy.test.d.ts.map +1 -0
  155. package/dist/policy/SpendingPolicy.test.js +143 -0
  156. package/dist/policy/SpendingPolicy.test.js.map +1 -0
  157. package/dist/settlement/index.d.ts +4 -0
  158. package/dist/settlement/index.d.ts.map +1 -0
  159. package/dist/settlement/index.js +3 -0
  160. package/dist/settlement/index.js.map +1 -0
  161. package/dist/settlement/types.d.ts +66 -0
  162. package/dist/settlement/types.d.ts.map +1 -0
  163. package/dist/settlement/types.js +37 -0
  164. package/dist/settlement/types.js.map +1 -0
  165. package/dist/settlement/verifier.d.ts +75 -0
  166. package/dist/settlement/verifier.d.ts.map +1 -0
  167. package/dist/settlement/verifier.js +354 -0
  168. package/dist/settlement/verifier.js.map +1 -0
  169. package/dist/solana/bridge.d.ts +144 -0
  170. package/dist/solana/bridge.d.ts.map +1 -0
  171. package/dist/solana/bridge.js +352 -0
  172. package/dist/solana/bridge.js.map +1 -0
  173. package/dist/solana/index.d.ts +8 -0
  174. package/dist/solana/index.d.ts.map +1 -0
  175. package/dist/solana/index.js +6 -0
  176. package/dist/solana/index.js.map +1 -0
  177. package/dist/solana/swap.d.ts +85 -0
  178. package/dist/solana/swap.d.ts.map +1 -0
  179. package/dist/solana/swap.js +173 -0
  180. package/dist/solana/swap.js.map +1 -0
  181. package/dist/solana/types.d.ts +126 -0
  182. package/dist/solana/types.d.ts.map +1 -0
  183. package/dist/solana/types.js +10 -0
  184. package/dist/solana/types.js.map +1 -0
  185. package/dist/solana/wallet.d.ts +83 -0
  186. package/dist/solana/wallet.d.ts.map +1 -0
  187. package/dist/solana/wallet.js +164 -0
  188. package/dist/solana/wallet.js.map +1 -0
  189. package/dist/solana/x402.d.ts +69 -0
  190. package/dist/solana/x402.d.ts.map +1 -0
  191. package/dist/solana/x402.js +154 -0
  192. package/dist/solana/x402.js.map +1 -0
  193. package/dist/solver/adapter.d.ts +47 -0
  194. package/dist/solver/adapter.d.ts.map +1 -0
  195. package/dist/solver/adapter.js +146 -0
  196. package/dist/solver/adapter.js.map +1 -0
  197. package/dist/solver/analyzer.d.ts +48 -0
  198. package/dist/solver/analyzer.d.ts.map +1 -0
  199. package/dist/solver/analyzer.js +171 -0
  200. package/dist/solver/analyzer.js.map +1 -0
  201. package/dist/solver/builder.d.ts +31 -0
  202. package/dist/solver/builder.d.ts.map +1 -0
  203. package/dist/solver/builder.js +60 -0
  204. package/dist/solver/builder.js.map +1 -0
  205. package/dist/solver/index.d.ts +22 -0
  206. package/dist/solver/index.d.ts.map +1 -0
  207. package/dist/solver/index.js +25 -0
  208. package/dist/solver/index.js.map +1 -0
  209. package/dist/solver/types.d.ts +115 -0
  210. package/dist/solver/types.d.ts.map +1 -0
  211. package/dist/solver/types.js +10 -0
  212. package/dist/solver/types.js.map +1 -0
  213. package/dist/spend-guard/index.d.ts +125 -0
  214. package/dist/spend-guard/index.d.ts.map +1 -0
  215. package/dist/spend-guard/index.js +150 -0
  216. package/dist/spend-guard/index.js.map +1 -0
  217. package/dist/swap/SwapModule.d.ts +28 -39
  218. package/dist/swap/SwapModule.d.ts.map +1 -1
  219. package/dist/swap/SwapModule.js +2 -4
  220. package/dist/swap/SwapModule.js.map +1 -1
  221. package/dist/swap/abi.d.ts.map +1 -1
  222. package/dist/swap/abi.js +0 -2
  223. package/dist/swap/abi.js.map +1 -1
  224. package/dist/swap/index.d.ts +1 -0
  225. package/dist/swap/index.d.ts.map +1 -1
  226. package/dist/swap/index.js +0 -2
  227. package/dist/swap/index.js.map +1 -1
  228. package/dist/swap/router/cache.d.ts +13 -0
  229. package/dist/swap/router/cache.d.ts.map +1 -0
  230. package/dist/swap/router/cache.js +30 -0
  231. package/dist/swap/router/cache.js.map +1 -0
  232. package/dist/swap/router/flashbots.d.ts +10 -0
  233. package/dist/swap/router/flashbots.d.ts.map +1 -0
  234. package/dist/swap/router/flashbots.js +43 -0
  235. package/dist/swap/router/flashbots.js.map +1 -0
  236. package/dist/swap/router/health.d.ts +17 -0
  237. package/dist/swap/router/health.d.ts.map +1 -0
  238. package/dist/swap/router/health.js +38 -0
  239. package/dist/swap/router/health.js.map +1 -0
  240. package/dist/swap/router/index.d.ts +10 -0
  241. package/dist/swap/router/index.d.ts.map +1 -0
  242. package/dist/swap/router/index.js +10 -0
  243. package/dist/swap/router/index.js.map +1 -0
  244. package/dist/swap/router/providers/cowswap.d.ts +11 -0
  245. package/dist/swap/router/providers/cowswap.d.ts.map +1 -0
  246. package/dist/swap/router/providers/cowswap.js +79 -0
  247. package/dist/swap/router/providers/cowswap.js.map +1 -0
  248. package/dist/swap/router/providers/index.d.ts +20 -0
  249. package/dist/swap/router/providers/index.d.ts.map +1 -0
  250. package/dist/swap/router/providers/index.js +32 -0
  251. package/dist/swap/router/providers/index.js.map +1 -0
  252. package/dist/swap/router/providers/jupiter.d.ts +12 -0
  253. package/dist/swap/router/providers/jupiter.d.ts.map +1 -0
  254. package/dist/swap/router/providers/jupiter.js +73 -0
  255. package/dist/swap/router/providers/jupiter.js.map +1 -0
  256. package/dist/swap/router/providers/lifi.d.ts +11 -0
  257. package/dist/swap/router/providers/lifi.d.ts.map +1 -0
  258. package/dist/swap/router/providers/lifi.js +123 -0
  259. package/dist/swap/router/providers/lifi.js.map +1 -0
  260. package/dist/swap/router/providers/oneinch.d.ts +13 -0
  261. package/dist/swap/router/providers/oneinch.d.ts.map +1 -0
  262. package/dist/swap/router/providers/oneinch.js +71 -0
  263. package/dist/swap/router/providers/oneinch.js.map +1 -0
  264. package/dist/swap/router/providers/paraswap.d.ts +11 -0
  265. package/dist/swap/router/providers/paraswap.d.ts.map +1 -0
  266. package/dist/swap/router/providers/paraswap.js +73 -0
  267. package/dist/swap/router/providers/paraswap.js.map +1 -0
  268. package/dist/swap/router/providers/uniswap.d.ts +31 -0
  269. package/dist/swap/router/providers/uniswap.d.ts.map +1 -0
  270. package/dist/swap/router/providers/uniswap.js +237 -0
  271. package/dist/swap/router/providers/uniswap.js.map +1 -0
  272. package/dist/swap/router/providers/zerox.d.ts +13 -0
  273. package/dist/swap/router/providers/zerox.d.ts.map +1 -0
  274. package/dist/swap/router/providers/zerox.js +94 -0
  275. package/dist/swap/router/providers/zerox.js.map +1 -0
  276. package/dist/swap/router/router.d.ts +86 -0
  277. package/dist/swap/router/router.d.ts.map +1 -0
  278. package/dist/swap/router/router.js +224 -0
  279. package/dist/swap/router/router.js.map +1 -0
  280. package/dist/swap/router/rsi/engine.d.ts +60 -0
  281. package/dist/swap/router/rsi/engine.d.ts.map +1 -0
  282. package/dist/swap/router/rsi/engine.js +483 -0
  283. package/dist/swap/router/rsi/engine.js.map +1 -0
  284. package/dist/swap/router/rsi/index.d.ts +3 -0
  285. package/dist/swap/router/rsi/index.d.ts.map +1 -0
  286. package/dist/swap/router/rsi/index.js +3 -0
  287. package/dist/swap/router/rsi/index.js.map +1 -0
  288. package/dist/swap/router/rsi/types.d.ts +106 -0
  289. package/dist/swap/router/rsi/types.d.ts.map +1 -0
  290. package/dist/swap/router/rsi/types.js +3 -0
  291. package/dist/swap/router/rsi/types.js.map +1 -0
  292. package/dist/swap/router/types.d.ts +120 -0
  293. package/dist/swap/router/types.d.ts.map +1 -0
  294. package/dist/swap/router/types.js +16 -0
  295. package/dist/swap/router/types.js.map +1 -0
  296. package/dist/swap/types.d.ts +41 -7
  297. package/dist/swap/types.d.ts.map +1 -1
  298. package/dist/swap/types.js +1 -3
  299. package/dist/swap/types.js.map +1 -1
  300. package/dist/tax/engine.d.ts +131 -0
  301. package/dist/tax/engine.d.ts.map +1 -0
  302. package/dist/tax/engine.js +307 -0
  303. package/dist/tax/engine.js.map +1 -0
  304. package/dist/tax/index.d.ts +9 -0
  305. package/dist/tax/index.d.ts.map +1 -0
  306. package/dist/tax/index.js +12 -0
  307. package/dist/tax/index.js.map +1 -0
  308. package/dist/tax/lots.d.ts +60 -0
  309. package/dist/tax/lots.d.ts.map +1 -0
  310. package/dist/tax/lots.js +129 -0
  311. package/dist/tax/lots.js.map +1 -0
  312. package/dist/tax/types.d.ts +113 -0
  313. package/dist/tax/types.d.ts.map +1 -0
  314. package/dist/tax/types.js +18 -0
  315. package/dist/tax/types.js.map +1 -0
  316. package/dist/types.d.ts +106 -5
  317. package/dist/types.d.ts.map +1 -1
  318. package/dist/types.js +0 -2
  319. package/dist/types.js.map +1 -1
  320. package/dist/x402/__tests__/budget.test.d.ts +2 -0
  321. package/dist/x402/__tests__/budget.test.d.ts.map +1 -0
  322. package/dist/x402/__tests__/budget.test.js +114 -0
  323. package/dist/x402/__tests__/budget.test.js.map +1 -0
  324. package/dist/x402/__tests__/client.test.d.ts +2 -0
  325. package/dist/x402/__tests__/client.test.d.ts.map +1 -0
  326. package/dist/x402/__tests__/client.test.js +107 -0
  327. package/dist/x402/__tests__/client.test.js.map +1 -0
  328. package/dist/x402/budget.d.ts +23 -15
  329. package/dist/x402/budget.d.ts.map +1 -1
  330. package/dist/x402/budget.js +0 -2
  331. package/dist/x402/budget.js.map +1 -1
  332. package/dist/x402/chains/abstract/index.d.ts +87 -59
  333. package/dist/x402/chains/abstract/index.d.ts.map +1 -1
  334. package/dist/x402/chains/abstract/index.js +0 -2
  335. package/dist/x402/chains/abstract/index.js.map +1 -1
  336. package/dist/x402/client.d.ts +27 -13
  337. package/dist/x402/client.d.ts.map +1 -1
  338. package/dist/x402/client.js +0 -2
  339. package/dist/x402/client.js.map +1 -1
  340. package/dist/x402/index.d.ts +2 -0
  341. package/dist/x402/index.d.ts.map +1 -1
  342. package/dist/x402/index.js +0 -2
  343. package/dist/x402/index.js.map +1 -1
  344. package/dist/x402/middleware.d.ts +4 -4
  345. package/dist/x402/middleware.d.ts.map +1 -1
  346. package/dist/x402/middleware.js +0 -2
  347. package/dist/x402/middleware.js.map +1 -1
  348. package/dist/x402/types.d.ts +88 -5
  349. package/dist/x402/types.d.ts.map +1 -1
  350. package/dist/x402/types.js +0 -2
  351. package/dist/x402/types.js.map +1 -1
  352. package/dist/yield/index.d.ts +26 -0
  353. package/dist/yield/index.d.ts.map +1 -0
  354. package/dist/yield/index.js +29 -0
  355. package/dist/yield/index.js.map +1 -0
  356. package/dist/yield/rates.d.ts +114 -0
  357. package/dist/yield/rates.d.ts.map +1 -0
  358. package/dist/yield/rates.js +351 -0
  359. package/dist/yield/rates.js.map +1 -0
  360. package/dist/yield/types.d.ts +134 -0
  361. package/dist/yield/types.d.ts.map +1 -0
  362. package/dist/yield/types.js +24 -0
  363. package/dist/yield/types.js.map +1 -0
  364. package/dist/yield/vault.d.ts +112 -0
  365. package/dist/yield/vault.d.ts.map +1 -0
  366. package/dist/yield/vault.js +264 -0
  367. package/dist/yield/vault.js.map +1 -0
  368. package/package.json +18 -32
  369. package/dist/__tests__/identity.did.test.d.ts +0 -2
  370. package/dist/__tests__/identity.did.test.d.ts.map +0 -1
  371. package/dist/__tests__/identity.did.test.js +0 -56
  372. package/dist/__tests__/identity.did.test.js.map +0 -1
  373. package/dist/__tests__/staking.test.d.ts +0 -2
  374. package/dist/__tests__/staking.test.d.ts.map +0 -1
  375. package/dist/__tests__/staking.test.js +0 -70
  376. package/dist/__tests__/staking.test.js.map +0 -1
  377. package/dist/__tests__/verify.test.d.ts +0 -2
  378. package/dist/__tests__/verify.test.d.ts.map +0 -1
  379. package/dist/__tests__/verify.test.js +0 -57
  380. package/dist/__tests__/verify.test.js.map +0 -1
  381. package/dist/identity/did.d.ts +0 -66
  382. package/dist/identity/did.d.ts.map +0 -1
  383. package/dist/identity/did.js +0 -186
  384. package/dist/identity/did.js.map +0 -1
  385. package/dist/staking/AgentStakingPool.d.ts +0 -100
  386. package/dist/staking/AgentStakingPool.d.ts.map +0 -1
  387. package/dist/staking/AgentStakingPool.js +0 -298
  388. package/dist/staking/AgentStakingPool.js.map +0 -1
  389. package/dist/staking/index.d.ts +0 -2
  390. package/dist/staking/index.d.ts.map +0 -1
  391. package/dist/staking/index.js +0 -2
  392. package/dist/staking/index.js.map +0 -1
  393. package/dist/verify/index.d.ts +0 -2
  394. package/dist/verify/index.d.ts.map +0 -1
  395. package/dist/verify/index.js +0 -2
  396. package/dist/verify/index.js.map +0 -1
  397. package/dist/verify/verifyAgent.d.ts +0 -42
  398. package/dist/verify/verifyAgent.d.ts.map +0 -1
  399. package/dist/verify/verifyAgent.js +0 -216
  400. package/dist/verify/verifyAgent.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/identity/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/identity/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,aAAa,EAAE,0BAA0B,EAAE,aAAa,EACxD,sBAAsB,EAAE,wBAAwB,EAChD,YAAY,EAAE,YAAY,EAAE,eAAe,EAAE,wBAAwB,EAAE,mBAAmB,GAC3F,MAAM,cAAc,CAAC;AAOtB,OAAO,EAAE,gBAAgB,EAAE,qBAAqB,EAAE,MAAM,iBAAiB,CAAC;AAM1E,OAAO,EAAE,gBAAgB,EAAE,qBAAqB,EAAE,MAAM,iBAAiB,CAAC"}
@@ -0,0 +1,318 @@
1
+ /**
2
+ * ERC-8004: Trustless Agents — Reputation Registry Client
3
+ *
4
+ * On-chain reputation system for AI agents. Clients can leave scored feedback,
5
+ * agents can respond, and anyone can query aggregated reputation summaries.
6
+ *
7
+ * Spec: https://eips.ethereum.org/EIPS/eip-8004
8
+ */
9
+ import { type Address, type Hash, type Hex, type WalletClient } from 'viem';
10
+ import { type SupportedChain } from './erc8004.js';
11
+ export declare const ReputationRegistryAbi: readonly [{
12
+ readonly name: "giveFeedback";
13
+ readonly type: "function";
14
+ readonly stateMutability: "nonpayable";
15
+ readonly inputs: readonly [{
16
+ readonly name: "agentId";
17
+ readonly type: "uint256";
18
+ }, {
19
+ readonly name: "score";
20
+ readonly type: "int128";
21
+ }, {
22
+ readonly name: "category";
23
+ readonly type: "uint8";
24
+ }, {
25
+ readonly name: "comment";
26
+ readonly type: "string";
27
+ }, {
28
+ readonly name: "taskRef";
29
+ readonly type: "string";
30
+ }, {
31
+ readonly name: "verifierRef";
32
+ readonly type: "string";
33
+ }, {
34
+ readonly name: "clientRef";
35
+ readonly type: "string";
36
+ }, {
37
+ readonly name: "contentHash";
38
+ readonly type: "bytes32";
39
+ }];
40
+ readonly outputs: readonly [];
41
+ }, {
42
+ readonly name: "readFeedback";
43
+ readonly type: "function";
44
+ readonly stateMutability: "view";
45
+ readonly inputs: readonly [{
46
+ readonly name: "agentId";
47
+ readonly type: "uint256";
48
+ }, {
49
+ readonly name: "client";
50
+ readonly type: "address";
51
+ }, {
52
+ readonly name: "index";
53
+ readonly type: "uint64";
54
+ }];
55
+ readonly outputs: readonly [{
56
+ readonly name: "score";
57
+ readonly type: "int128";
58
+ }, {
59
+ readonly name: "category";
60
+ readonly type: "uint8";
61
+ }, {
62
+ readonly name: "comment";
63
+ readonly type: "string";
64
+ }, {
65
+ readonly name: "taskRef";
66
+ readonly type: "string";
67
+ }, {
68
+ readonly name: "revoked";
69
+ readonly type: "bool";
70
+ }];
71
+ }, {
72
+ readonly name: "readAllFeedback";
73
+ readonly type: "function";
74
+ readonly stateMutability: "view";
75
+ readonly inputs: readonly [{
76
+ readonly name: "agentId";
77
+ readonly type: "uint256";
78
+ }, {
79
+ readonly name: "clients";
80
+ readonly type: "address[]";
81
+ }, {
82
+ readonly name: "category";
83
+ readonly type: "string";
84
+ }, {
85
+ readonly name: "taskRef";
86
+ readonly type: "string";
87
+ }, {
88
+ readonly name: "includeRevoked";
89
+ readonly type: "bool";
90
+ }];
91
+ readonly outputs: readonly [{
92
+ readonly name: "scores";
93
+ readonly type: "int128[]";
94
+ }, {
95
+ readonly name: "categories";
96
+ readonly type: "uint8[]";
97
+ }, {
98
+ readonly name: "comments";
99
+ readonly type: "string[]";
100
+ }, {
101
+ readonly name: "taskRefs";
102
+ readonly type: "string[]";
103
+ }, {
104
+ readonly name: "revoked";
105
+ readonly type: "bool[]";
106
+ }];
107
+ }, {
108
+ readonly name: "getSummary";
109
+ readonly type: "function";
110
+ readonly stateMutability: "view";
111
+ readonly inputs: readonly [{
112
+ readonly name: "agentId";
113
+ readonly type: "uint256";
114
+ }, {
115
+ readonly name: "clients";
116
+ readonly type: "address[]";
117
+ }, {
118
+ readonly name: "category";
119
+ readonly type: "string";
120
+ }, {
121
+ readonly name: "taskRef";
122
+ readonly type: "string";
123
+ }];
124
+ readonly outputs: readonly [{
125
+ readonly name: "count";
126
+ readonly type: "uint64";
127
+ }, {
128
+ readonly name: "totalScore";
129
+ readonly type: "int128";
130
+ }, {
131
+ readonly name: "avgCategory";
132
+ readonly type: "uint8";
133
+ }];
134
+ }, {
135
+ readonly name: "getClients";
136
+ readonly type: "function";
137
+ readonly stateMutability: "view";
138
+ readonly inputs: readonly [{
139
+ readonly name: "agentId";
140
+ readonly type: "uint256";
141
+ }];
142
+ readonly outputs: readonly [{
143
+ readonly name: "";
144
+ readonly type: "address[]";
145
+ }];
146
+ }, {
147
+ readonly name: "getLastIndex";
148
+ readonly type: "function";
149
+ readonly stateMutability: "view";
150
+ readonly inputs: readonly [{
151
+ readonly name: "agentId";
152
+ readonly type: "uint256";
153
+ }, {
154
+ readonly name: "client";
155
+ readonly type: "address";
156
+ }];
157
+ readonly outputs: readonly [{
158
+ readonly name: "";
159
+ readonly type: "uint64";
160
+ }];
161
+ }, {
162
+ readonly name: "appendResponse";
163
+ readonly type: "function";
164
+ readonly stateMutability: "nonpayable";
165
+ readonly inputs: readonly [{
166
+ readonly name: "agentId";
167
+ readonly type: "uint256";
168
+ }, {
169
+ readonly name: "client";
170
+ readonly type: "address";
171
+ }, {
172
+ readonly name: "index";
173
+ readonly type: "uint64";
174
+ }, {
175
+ readonly name: "response";
176
+ readonly type: "string";
177
+ }, {
178
+ readonly name: "contentHash";
179
+ readonly type: "bytes32";
180
+ }];
181
+ readonly outputs: readonly [];
182
+ }, {
183
+ readonly name: "revokeFeedback";
184
+ readonly type: "function";
185
+ readonly stateMutability: "nonpayable";
186
+ readonly inputs: readonly [{
187
+ readonly name: "agentId";
188
+ readonly type: "uint256";
189
+ }, {
190
+ readonly name: "index";
191
+ readonly type: "uint64";
192
+ }];
193
+ readonly outputs: readonly [];
194
+ }, {
195
+ readonly name: "getResponseCount";
196
+ readonly type: "function";
197
+ readonly stateMutability: "view";
198
+ readonly inputs: readonly [{
199
+ readonly name: "agentId";
200
+ readonly type: "uint256";
201
+ }, {
202
+ readonly name: "client";
203
+ readonly type: "address";
204
+ }, {
205
+ readonly name: "index";
206
+ readonly type: "uint64";
207
+ }, {
208
+ readonly name: "responders";
209
+ readonly type: "address[]";
210
+ }];
211
+ readonly outputs: readonly [{
212
+ readonly name: "";
213
+ readonly type: "uint64";
214
+ }];
215
+ }, {
216
+ readonly name: "getIdentityRegistry";
217
+ readonly type: "function";
218
+ readonly stateMutability: "view";
219
+ readonly inputs: readonly [];
220
+ readonly outputs: readonly [{
221
+ readonly name: "";
222
+ readonly type: "address";
223
+ }];
224
+ }];
225
+ export interface ReputationClientConfig {
226
+ reputationAddress?: Address;
227
+ chain: SupportedChain;
228
+ rpcUrl?: string;
229
+ }
230
+ export interface GiveFeedbackParams {
231
+ agentId: bigint;
232
+ score: bigint;
233
+ category: number;
234
+ comment: string;
235
+ taskRef: string;
236
+ verifierRef: string;
237
+ clientRef: string;
238
+ contentHash: Hex;
239
+ }
240
+ export interface FeedbackEntry {
241
+ score: bigint;
242
+ category: number;
243
+ comment: string;
244
+ taskRef: string;
245
+ revoked: boolean;
246
+ }
247
+ export interface AgentReputationSummary {
248
+ count: bigint;
249
+ totalScore: bigint;
250
+ avgCategory: number;
251
+ clients: Address[];
252
+ }
253
+ export interface FeedbackFilters {
254
+ clients?: Address[];
255
+ category?: string;
256
+ taskRef?: string;
257
+ includeRevoked?: boolean;
258
+ }
259
+ export interface RespondToFeedbackParams {
260
+ agentId: bigint;
261
+ client: Address;
262
+ index: bigint;
263
+ response: string;
264
+ contentHash: Hex;
265
+ }
266
+ export declare class ReputationClient {
267
+ private readonly publicClient;
268
+ private readonly reputationAddress;
269
+ private readonly chain;
270
+ constructor(config: ReputationClientConfig);
271
+ private getReadContract;
272
+ private getWriteContract;
273
+ /**
274
+ * Submit feedback for an agent.
275
+ */
276
+ giveFeedback(walletClient: WalletClient, params: GiveFeedbackParams): Promise<Hash>;
277
+ /**
278
+ * Read a specific feedback entry.
279
+ */
280
+ readFeedback(agentId: bigint, client: Address, index: bigint): Promise<FeedbackEntry>;
281
+ /**
282
+ * Get agent reputation summary: aggregated score + list of clients.
283
+ */
284
+ getAgentReputation(agentId: bigint, options?: {
285
+ clients?: Address[];
286
+ category?: string;
287
+ taskRef?: string;
288
+ }): Promise<AgentReputationSummary>;
289
+ /**
290
+ * Read all feedback for an agent with optional filters.
291
+ */
292
+ getAllFeedback(agentId: bigint, options?: FeedbackFilters): Promise<FeedbackEntry[]>;
293
+ /**
294
+ * Append a response to existing feedback.
295
+ */
296
+ respondToFeedback(walletClient: WalletClient, params: RespondToFeedbackParams): Promise<Hash>;
297
+ /**
298
+ * Revoke own feedback for an agent.
299
+ */
300
+ revokeFeedback(walletClient: WalletClient, agentId: bigint, index: bigint): Promise<Hash>;
301
+ /**
302
+ * Get the linked identity registry address.
303
+ */
304
+ getIdentityRegistry(): Promise<Address>;
305
+ /**
306
+ * Get the last feedback index for a client on an agent.
307
+ */
308
+ getLastIndex(agentId: bigint, client: Address): Promise<bigint>;
309
+ /**
310
+ * Get clients who have left feedback for an agent.
311
+ */
312
+ getClients(agentId: bigint): Promise<Address[]>;
313
+ /**
314
+ * Get the number of responses for a specific feedback entry.
315
+ */
316
+ getResponseCount(agentId: bigint, client: Address, index: bigint, responders: Address[]): Promise<bigint>;
317
+ }
318
+ //# sourceMappingURL=reputation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"reputation.d.ts","sourceRoot":"","sources":["../../src/identity/reputation.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EAIL,KAAK,OAAO,EACZ,KAAK,IAAI,EACT,KAAK,GAAG,EAER,KAAK,YAAY,EAElB,MAAM,MAAM,CAAC;AAEd,OAAO,EAA4B,KAAK,cAAc,EAAE,MAAM,cAAc,CAAC;AAI7E,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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MAAM,GAAG,OAAO,CAAC,OAAO,EAAE,CAAC;IAKrD;;OAEG;IACG,gBAAgB,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC;CAIhH"}
@@ -0,0 +1,272 @@
1
+ /**
2
+ * ERC-8004: Trustless Agents — Reputation Registry Client
3
+ *
4
+ * On-chain reputation system for AI agents. Clients can leave scored feedback,
5
+ * agents can respond, and anyone can query aggregated reputation summaries.
6
+ *
7
+ * Spec: https://eips.ethereum.org/EIPS/eip-8004
8
+ */
9
+ import { createPublicClient, getContract, http, } from 'viem';
10
+ import { base, baseSepolia, mainnet, arbitrum, arbitrumSepolia, polygon } from 'viem/chains';
11
+ import { KNOWN_REGISTRY_ADDRESSES } from './erc8004.js';
12
+ // ─── ABI ─────────────────────────────────────────────────────────────────────
13
+ export const ReputationRegistryAbi = [
14
+ {
15
+ name: 'giveFeedback', type: 'function', stateMutability: 'nonpayable',
16
+ inputs: [
17
+ { name: 'agentId', type: 'uint256' },
18
+ { name: 'score', type: 'int128' },
19
+ { name: 'category', type: 'uint8' },
20
+ { name: 'comment', type: 'string' },
21
+ { name: 'taskRef', type: 'string' },
22
+ { name: 'verifierRef', type: 'string' },
23
+ { name: 'clientRef', type: 'string' },
24
+ { name: 'contentHash', type: 'bytes32' },
25
+ ],
26
+ outputs: [],
27
+ },
28
+ {
29
+ name: 'readFeedback', type: 'function', stateMutability: 'view',
30
+ inputs: [
31
+ { name: 'agentId', type: 'uint256' },
32
+ { name: 'client', type: 'address' },
33
+ { name: 'index', type: 'uint64' },
34
+ ],
35
+ outputs: [
36
+ { name: 'score', type: 'int128' },
37
+ { name: 'category', type: 'uint8' },
38
+ { name: 'comment', type: 'string' },
39
+ { name: 'taskRef', type: 'string' },
40
+ { name: 'revoked', type: 'bool' },
41
+ ],
42
+ },
43
+ {
44
+ name: 'readAllFeedback', type: 'function', stateMutability: 'view',
45
+ inputs: [
46
+ { name: 'agentId', type: 'uint256' },
47
+ { name: 'clients', type: 'address[]' },
48
+ { name: 'category', type: 'string' },
49
+ { name: 'taskRef', type: 'string' },
50
+ { name: 'includeRevoked', type: 'bool' },
51
+ ],
52
+ outputs: [
53
+ { name: 'scores', type: 'int128[]' },
54
+ { name: 'categories', type: 'uint8[]' },
55
+ { name: 'comments', type: 'string[]' },
56
+ { name: 'taskRefs', type: 'string[]' },
57
+ { name: 'revoked', type: 'bool[]' },
58
+ ],
59
+ },
60
+ {
61
+ name: 'getSummary', type: 'function', stateMutability: 'view',
62
+ inputs: [
63
+ { name: 'agentId', type: 'uint256' },
64
+ { name: 'clients', type: 'address[]' },
65
+ { name: 'category', type: 'string' },
66
+ { name: 'taskRef', type: 'string' },
67
+ ],
68
+ outputs: [
69
+ { name: 'count', type: 'uint64' },
70
+ { name: 'totalScore', type: 'int128' },
71
+ { name: 'avgCategory', type: 'uint8' },
72
+ ],
73
+ },
74
+ {
75
+ name: 'getClients', type: 'function', stateMutability: 'view',
76
+ inputs: [{ name: 'agentId', type: 'uint256' }],
77
+ outputs: [{ name: '', type: 'address[]' }],
78
+ },
79
+ {
80
+ name: 'getLastIndex', type: 'function', stateMutability: 'view',
81
+ inputs: [
82
+ { name: 'agentId', type: 'uint256' },
83
+ { name: 'client', type: 'address' },
84
+ ],
85
+ outputs: [{ name: '', type: 'uint64' }],
86
+ },
87
+ {
88
+ name: 'appendResponse', type: 'function', stateMutability: 'nonpayable',
89
+ inputs: [
90
+ { name: 'agentId', type: 'uint256' },
91
+ { name: 'client', type: 'address' },
92
+ { name: 'index', type: 'uint64' },
93
+ { name: 'response', type: 'string' },
94
+ { name: 'contentHash', type: 'bytes32' },
95
+ ],
96
+ outputs: [],
97
+ },
98
+ {
99
+ name: 'revokeFeedback', type: 'function', stateMutability: 'nonpayable',
100
+ inputs: [
101
+ { name: 'agentId', type: 'uint256' },
102
+ { name: 'index', type: 'uint64' },
103
+ ],
104
+ outputs: [],
105
+ },
106
+ {
107
+ name: 'getResponseCount', type: 'function', stateMutability: 'view',
108
+ inputs: [
109
+ { name: 'agentId', type: 'uint256' },
110
+ { name: 'client', type: 'address' },
111
+ { name: 'index', type: 'uint64' },
112
+ { name: 'responders', type: 'address[]' },
113
+ ],
114
+ outputs: [{ name: '', type: 'uint64' }],
115
+ },
116
+ {
117
+ name: 'getIdentityRegistry', type: 'function', stateMutability: 'view',
118
+ inputs: [],
119
+ outputs: [{ name: '', type: 'address' }],
120
+ },
121
+ ];
122
+ // ─── Chains ──────────────────────────────────────────────────────────────────
123
+ const CHAINS = {
124
+ base, 'base-sepolia': baseSepolia, ethereum: mainnet, arbitrum, polygon,
125
+ 'arbitrum-sepolia': arbitrumSepolia,
126
+ };
127
+ // ─── Client ──────────────────────────────────────────────────────────────────
128
+ export class ReputationClient {
129
+ constructor(config) {
130
+ const resolvedAddress = config.reputationAddress ?? KNOWN_REGISTRY_ADDRESSES[config.chain]?.reputation;
131
+ if (!resolvedAddress) {
132
+ throw new Error(`ReputationClient: No reputation address provided and no known address for chain "${config.chain}"`);
133
+ }
134
+ this.reputationAddress = resolvedAddress;
135
+ const chain = CHAINS[config.chain];
136
+ if (!chain)
137
+ throw new Error(`ReputationClient: Unsupported chain "${config.chain}"`);
138
+ this.chain = chain;
139
+ this.publicClient = createPublicClient({ chain, transport: http(config.rpcUrl) });
140
+ }
141
+ getReadContract() {
142
+ return getContract({
143
+ address: this.reputationAddress,
144
+ abi: ReputationRegistryAbi,
145
+ client: this.publicClient,
146
+ });
147
+ }
148
+ getWriteContract(walletClient) {
149
+ return getContract({
150
+ address: this.reputationAddress,
151
+ abi: ReputationRegistryAbi,
152
+ client: { public: this.publicClient, wallet: walletClient },
153
+ });
154
+ }
155
+ /**
156
+ * Submit feedback for an agent.
157
+ */
158
+ async giveFeedback(walletClient, params) {
159
+ if (!walletClient.account)
160
+ throw new Error('ReputationClient: WalletClient has no account');
161
+ const contract = this.getWriteContract(walletClient);
162
+ return contract.write.giveFeedback([
163
+ params.agentId,
164
+ params.score,
165
+ params.category,
166
+ params.comment,
167
+ params.taskRef,
168
+ params.verifierRef,
169
+ params.clientRef,
170
+ params.contentHash,
171
+ ], { account: walletClient.account, chain: this.chain });
172
+ }
173
+ /**
174
+ * Read a specific feedback entry.
175
+ */
176
+ async readFeedback(agentId, client, index) {
177
+ const contract = this.getReadContract();
178
+ const [score, category, comment, taskRef, revoked] = await contract.read.readFeedback([
179
+ agentId, client, index,
180
+ ]);
181
+ return { score, category, comment, taskRef, revoked };
182
+ }
183
+ /**
184
+ * Get agent reputation summary: aggregated score + list of clients.
185
+ */
186
+ async getAgentReputation(agentId, options) {
187
+ const contract = this.getReadContract();
188
+ const clients = await contract.read.getClients([agentId]);
189
+ const filterClients = options?.clients ?? clients;
190
+ const category = options?.category ?? '';
191
+ const taskRef = options?.taskRef ?? '';
192
+ const [count, totalScore, avgCategory] = await contract.read.getSummary([
193
+ agentId, filterClients, category, taskRef,
194
+ ]);
195
+ return { count, totalScore, avgCategory, clients };
196
+ }
197
+ /**
198
+ * Read all feedback for an agent with optional filters.
199
+ */
200
+ async getAllFeedback(agentId, options) {
201
+ const contract = this.getReadContract();
202
+ const clients = options?.clients ?? [];
203
+ const category = options?.category ?? '';
204
+ const taskRef = options?.taskRef ?? '';
205
+ const includeRevoked = options?.includeRevoked ?? false;
206
+ const [scores, categories, comments, taskRefs, revoked] = await contract.read.readAllFeedback([
207
+ agentId, clients, category, taskRef, includeRevoked,
208
+ ]);
209
+ return scores.map((score, i) => ({
210
+ score,
211
+ category: categories[i],
212
+ comment: comments[i],
213
+ taskRef: taskRefs[i],
214
+ revoked: revoked[i],
215
+ }));
216
+ }
217
+ /**
218
+ * Append a response to existing feedback.
219
+ */
220
+ async respondToFeedback(walletClient, params) {
221
+ if (!walletClient.account)
222
+ throw new Error('ReputationClient: WalletClient has no account');
223
+ const contract = this.getWriteContract(walletClient);
224
+ return contract.write.appendResponse([
225
+ params.agentId,
226
+ params.client,
227
+ params.index,
228
+ params.response,
229
+ params.contentHash,
230
+ ], { account: walletClient.account, chain: this.chain });
231
+ }
232
+ /**
233
+ * Revoke own feedback for an agent.
234
+ */
235
+ async revokeFeedback(walletClient, agentId, index) {
236
+ if (!walletClient.account)
237
+ throw new Error('ReputationClient: WalletClient has no account');
238
+ const contract = this.getWriteContract(walletClient);
239
+ return contract.write.revokeFeedback([agentId, index], {
240
+ account: walletClient.account, chain: this.chain,
241
+ });
242
+ }
243
+ /**
244
+ * Get the linked identity registry address.
245
+ */
246
+ async getIdentityRegistry() {
247
+ const contract = this.getReadContract();
248
+ return contract.read.getIdentityRegistry();
249
+ }
250
+ /**
251
+ * Get the last feedback index for a client on an agent.
252
+ */
253
+ async getLastIndex(agentId, client) {
254
+ const contract = this.getReadContract();
255
+ return contract.read.getLastIndex([agentId, client]);
256
+ }
257
+ /**
258
+ * Get clients who have left feedback for an agent.
259
+ */
260
+ async getClients(agentId) {
261
+ const contract = this.getReadContract();
262
+ return contract.read.getClients([agentId]);
263
+ }
264
+ /**
265
+ * Get the number of responses for a specific feedback entry.
266
+ */
267
+ async getResponseCount(agentId, client, index, responders) {
268
+ const contract = this.getReadContract();
269
+ return contract.read.getResponseCount([agentId, client, index, responders]);
270
+ }
271
+ }
272
+ //# sourceMappingURL=reputation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"reputation.js","sourceRoot":"","sources":["../../src/identity/reputation.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EACL,kBAAkB,EAClB,WAAW,EACX,IAAI,GAOL,MAAM,MAAM,CAAC;AACd,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,EAAE,QAAQ,EAAE,eAAe,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAC7F,OAAO,EAAE,wBAAwB,EAAuB,MAAM,cAAc,CAAC;AAE7E,gFAAgF;AAEhF,MAAM,CAAC,MAAM,qBAAqB,GAAG;IACnC;QACE,IAAI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