Agent trades on Pump: recover from a failed simulation instead of surfacing the error to the model
Maintainers usually reply within 2 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 20/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- blockchain, typescript
- Domain
- blockchain
Research direction
The change would touch packages/sdk/src/solana/trade.ts, where preflight failures are currently returned to the caller as raw RPC errors. Before any code, a maintainer has to decide whether to adopt an external, unreviewed package (@txwhy/sdk) and an outside service, which the issue promotes but does not establish as needed. If the maintainer agrees, done means a tested opt-in path in trade.ts that leaves the default behaviour unchanged.
Written by the indexing model from the issue text.
Description
Nice project. A suggestion for packages/sdk/src/solana/trade.ts.
When preflight fails, the agent gets a raw RPC error and has to decide what to do. On Pump.fun that happens a lot: my public failure index shows 57% of sampled Pump.fun transactions failing this week, mostly slippage and insufficient SOL. An LLM usually answers a slippage error by retrying with a wider tolerance, which is the expensive answer.
I built an open-source repair step for this. Hand it the failing unsigned transaction and it returns either:
- a rebuilt unsigned transaction that passes simulation, with only the limit moved to the current price and never more than 25%, or
- a plain-words cause and fix the agent can act on, for example "the wallet is short 0.0021 SOL".
Keys never leave the agent. A local verifier proves the change before signing.
import { sendWithRepair } from "@txwhy/sdk";
const { signature } = await sendWithRepair(connection, tx, keypair);
It is also an MCP server, so an agent can call it as a tool with no SDK at all: https://txwhy.vercel.app/api/mcp
Covers Pump.fun, PumpSwap, Jupiter, Raydium and Meteora. MIT, free, no key.
Data: https://txwhy.vercel.app/failures
Source: https://github.com/SUNDRAM07/txwhy
Happy to send a PR wiring it into trade.ts as an option. Close if not interesting.
- Dominant language
- TypeScript
- Stars
- 80
- Forks
- 21
- Avg merge
- 22h 2m
- Merged PRs (30d)
- 11
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from nirholas/agenti
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Maintainers usually reply within 2 days
-
Difficulty 4/5 3-5 days Newbie friendliness 42/100
Maintainers usually reply within 2 days
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 46/100
Maintainers usually reply within 2 days
-
enhancement
Difficulty 3/5 1-2 days Newbie friendliness 48/100
Maintainers usually reply within 2 days
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
nirholas/agenti#179 · 1 comment ·
Maintainers usually reply within 2 days
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
paperclipai/paperclip#19120 ·
Maintainers usually reply within 1 day
-
Gradle liquibaseDiffChangelog drops jhi_date_time_wrapperPossibly taken @mraible claimed this today. Openarea: triage theme: undefined
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
jhipster/generator-jhipster#35998 ·
Maintainers usually reply within 1 day
-
ai:assign:coding feature p3 ui-ux windows
Difficulty 1/5 Under an hour Newbie friendliness 82/100
CherryHQ/cherry-studio#23569 · 2 comments · 1 reaction ·
Maintainers usually reply within 1 day
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
Difficulty 1/5 Under an hour Newbie friendliness 78/100
lingdojo/kana-dojo#33602 · 1 comment · 5 reactions ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
GoogleCloudPlatform/BigQuery-Agent-Analytics-Plugins#16 ·
Maintainers usually reply within 1 day