piotrostr / listen
- ΠΏΡΡΠ½ΠΈΡΠ°, 24 ΡΠ½Π²Π°ΡΡ 2025β―Π³. Π² 00:00:01
Solana Swiss Army Knife
listen is a Solana Swiss-Knife toolkit for algorithmic trading
And more!
It works plug'n'play with $arc rig framework framework allowing AI Agents interact with the Solana blockchain, see example: src/agent.rs and the output image.
For complete rundown of features, check out the CLI output of cargo run or the
documentation.
To play around with listen-rs, you can use the UI
Fill in the .env.example and ./dashboard/.env.example, copy over to .env and ./dashboard/.env.example, then
docker compose up
You can then access the dashboard over http://localhost:4173
Warning
listen-rs is undergoing rapid iterations, some things might not work and there could be breaking changes
System Dependencies
protocbuild-essentialpkg-configlibssl-devConfiguration
.env.example to .envauth.json for JITO authentication (optional, gRPC HTTP/2.0 searcher client)fund.jsonBoth keypairs are in solana-keygen format, array of 64 bytes, 32 bytes
private key and 32 bytes public key.
# Install dependencies
sudo apt install protoc build-essential pkg-config libssl-dev
# Build
cargo build --release
# Run services
./run-systemd-services.shcargo run -- listen \
--worker-count [COUNT] \
--buffer-size [SIZE]cargo run -- swap \
--input-mint sol \
--output-mint EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v \
--amount 10000000Warning
Default configuration is set for mainnet with small transactions. Ensure proper configuration for testnet usage and carefully review code before execution.
Listen includes built-in metrics exposed at localhost:3030/metrics. To visualize:
prometheus --config=prometheus.ymllocalhost:3030/metricsGrafana should show something like this
The stackcollapse.pl can be installed through
gh repo clone brendangregg/FlameGraph && \
sudo cp FlameGraph/stackcollapse.pl /usr/local/bin && \
sudo cp FlameGraph/flamegraph.pl /usr/local/binProfile swap performance using DTrace to produce a flamegraph:
./hack/profile-swap.sh