pull down to refresh
0 sats \ 0 replies \ @noknees 1h \ parent \ on: 💰💰 NBA arbitrage oppurtunity 💰💰 Stacker_Sports
That's will make the market more accessible to both sellers and buyers!
People like @Undisciplined would love to get their hands on a clean executable of this code. If you throw in a minimal GUI - I'm sure people would happily give you some 💰fat bounty for it.
On it cap!
@mega_dreamer is Predyx a LMSR-based AMM model?
seeing the current percentages for this market do you think this would be a cheat script?
import numpy as np
import matplotlib.pyplot as plt
# LMSR Cost function: C(q) = b * ln(sum(exp(q_i / b)))
# Here, we track two outcomes: Pacers and Thunder
def lmsr_cost(q1, q2, b):
return b * np.log(np.exp(q1 / b) + np.exp(q2 / b))
# Marginal price of outcome 1 (Pacers)
def lmsr_price(q1, q2, b):
return np.exp(q1 / b) / (np.exp(q1 / b) + np.exp(q2 / b))
# Simulate cost of buying shares
def simulate_lmsr_buy(initial_q1, initial_q2, b, buy_shares, outcome='q1'):
# Determine which quantity we are increasing
q1, q2 = initial_q1, initial_q2
new_q1 = q1 + buy_shares if outcome == 'q1' else q1
new_q2 = q2 + buy_shares if outcome == 'q2' else q2
# Initial and final cost
initial_cost = lmsr_cost(q1, q2, b)
final_cost = lmsr_cost(new_q1, new_q2, b)
# Total cost to buy `buy_shares` of the selected outcome
cost = final_cost - initial_cost
# Final probability (price)
final_price = lmsr_price(new_q1, new_q2, b)
return cost, final_price
# Parameters
b = 10000 # liquidity parameter (higher b = more stable market)
initial_q1 = 0
initial_q2 = 0
buy_shares = 50000
# Simulate buying 50K shares for Pacers (q1)
cost_pacers, final_price_pacers = simulate_lmsr_buy(initial_q1, initial_q2, b, buy_shares, 'q1')
# Now simulate how many shares of Thunder (q2) are needed to bring the price back to 0.50
# We'll iterate to find that point
def find_thunder_shares_to_balance(q1, initial_q2, b, target_price=0.5):
for shares in range(1000, 100000, 100):
q2 = initial_q2 + shares
price = lmsr_price(q1, q2, b)
if abs(price - target_price) < 0.001:
cost = lmsr_cost(q1, q2, b) - lmsr_cost(q1, initial_q2, b)
return shares, cost, price
return None, None, None
thunder_shares, cost_thunder, final_price_thunder = find_thunder_shares_to_balance(buy_shares, 0, b)
(cost_pacers, final_price_pacers), (thunder_shares, cost_thunder, final_price_thunder)
Result
((43135.68167929173, 0.9933071490757152), (50000, 6864.318320708269, 0.5))
I just mean to ask if it works, I won't be using it real time, I was thinking of incorporating something of this sort in one of my projects
(reported by someone that changes their name here a lot)
add lnurl-auth explainer to lnurl-auth on settings page by the name changer
My eyesight improved? This one is weird. Like, I legit stopped wearing glasses for a couple months. Didn't need them. Not sure what that was about.
do you remember any radioactive spider biting you?
GOOD OBSERVATION!
Vitalik Buterin did build Tag (prolly first implementation of OP_RETURN).
Also, in 2013, Vitalik proposed more complex scripting for Bitcoin.
He submitted a proposal to the Bitcoin core community.
It was rejected—Bitcoin devs prioritized security and conservatism.
So Vitalik said: Fine, I’ll build my own chain—with blackjack and DAOs.
Ethereum was born in 2015 (it wasn’t until 2017+ that USDT moved to Ethereum, Tron, Solana, etc.)
:)
TL;DR
Bitcoin had smart contracts from Day 1 — just not the ones people hype-trade on.
Bitcoin Script enables core contract logic with far less risk.
If you’ve ever used a multisig, Lightning, or a timelock, you’ve already used Bitcoin smart contracts.
Ethereum made them flashy. Bitcoin made them functional.
Ethereum is an experiment in complexity. Bitcoin is an experiment in trust minimization.
34 sats \ 0 replies \ @noknees 19h \ parent \ on: Where are the new wonders of the world? mostly_harmless
that will be a worthy job us k00b juniors on SN :)
The plinth should read: The k00b who gave wings to Satoshi Nakamoto
and then k00b would be a word in the dictionary which would mean 1. an alternative metaphor to bitcoin, 2. the founder of world's most democratic form of currency
and maybe you'd get a Presidential Medal of Freedom after your work :)
@south_korea_ln you ever thought of this 😎
btw what update of your thesis? Is it published?