Search content
Sort by

Showing 8 of 8 results by alerdenisov
Post
Topic
Board Development & Technical Discussion
Re: Pure TypeScript library to operate with sats (zero-dependencies)
by
alerdenisov
on 31/08/2023, 10:07:41 UTC
2. Function fromString allow to pass any notation.

Oh, i didn't know fromString actually accept any notation.

I assume to deprecate original and introduce from or even parse, what do you think?

parse seems to be good idea. But i'd suggest you get additional opinion first since i'm not expert in either ordinal and programming.


Deprecation is the exact that way: it will notice developer method is going to be deleted (in the future) and lead to another.


Am I right in assuming the string that you are passing to fetch the rare sats information (Sat.fromName) is the wallet name? ord uses Bitcoin Core to create wallets which store said sats.

Speaking of which, this library can only explore rare sats inside wallets that are on the local computer, at a specific filesystem path I guess, and no other locations, right?

I see this library as a tool to convert and check rarity of sats. It isn't SDK to call API or interact with Ordinals, but I'm working on tools to interact as well (they're dependent on thridparty services and I decide to split library and sdk).

Accordingly to question. Sat.fromName parse the sat name (sush as alerdenisov or satoshi) to ordinal number. Let me refer official handbook (https://docs.ordinals.com/overview.html) to avoid copy paste of name notaion definition.
Post
Topic
Board Development & Technical Discussion
Re: Pure TypeScript library to operate with sats (zero-dependencies)
by
alerdenisov
on 30/08/2023, 14:53:07 UTC
I did quick test with few inscription and it seems to works properly. So here are few of my thought,
1. Is it right to assume your library only have function to look for sat properties of Ordinals inscription based on one of known value (e.g. decimal)?
2. It annoys me fromDecimal require me to enter string rather than decimal.

Code:
> Sat.fromDecimal(313225.1127208201)
<repl>.ts:29:17 - error TS2345: Argument of type 'number' is not assignable to parameter of type 'string'.

29 Sat.fromDecimal(313225.1127208201)
> Sat.fromDecimal("313225.1127208201")
Sat { n: 1308063627208201 }

3. Function fromString with parameter sat initially confuse me. Different name such as fromSat or fromSatNumber probably would be better.

Thank you for feedback. Sounds reasonable! About string as type of argument – let me check max precision of JS number and max possible decimal notation. If fix – i will add additional type.
Function fromString allow to pass any notation. I assume to deprecate original and introduce from or even parse, what do you think?

I don't want to ask any external API (such as explorer or bitcoin rpc) and let to use library inside quite limited environment with V8 interp. So any operations with inscription isn't available by design.

I will add rarity and exotic check function for Sat class and function to pass whole range for scan. I think that's all I can imagine without being tied to external data.
Post
Topic
Board Development & Technical Discussion
Merits 5 from 1 user
Topic OP
Pure TypeScript library to operate with sats (zero-dependencies)
by
alerdenisov
on 29/08/2023, 13:38:04 UTC
⭐ Merited by ETFbitcoin (5)
Hello, bitcoiners and builders.

Story behind in advance: I came back from EVM to check do I have exotic/rare sats on my wallet from 2017 (still HODL with 600% profit) and found (thanks for early builders) few polindromes. But during exploration I found lack of JS lib to operate with sats (convert from one to another notation, parse from strings and etc). I decided to fill the gap with 0-dependency implementation on pure TS and publish as open-source public npm module.
 
https://github.com/tookey-io/sats — source-code
https://www.npmjs.com/package/@tookey-io/sats — npm library

Here is simple example:
Code:
import { Sat } from "@tookey-io/sats";

const sat = Sat.fromName("alerdenisov");
console.log("alerdenisov sat #" + sat.n); // 1892488848343776
console.log("alerdenisov sat mine height: " + sat.decimal.height.n); // 717982
console.log("alerdenisov sat mine offset: " + sat.decimal.offset); // 98343776

I would like to see your feedback and stars on github!  Tongue

PS: API is simple and partially documented and very welcome to contribute typedoc if you free to
PSS: Rarity and exotic checks for sats are coming with v0.1.0
Post
Topic
Board Altcoin Discussion
Re: Website, white paper, road map development ICO launcher
by
alerdenisov
on 15/12/2017, 12:22:32 UTC
Any demo is available? Or it custom solutions for each case?
Post
Topic
Board Beginners & Help
Merits 2 from 2 users
Re: cryptocurrency
by
alerdenisov
on 14/12/2017, 14:47:16 UTC
⭐ Merited by AGD (1) ,ETFbitcoin (1)
First of all, I suppose you should differ cryptocurrencies based on protocol behind then.

Basically we could to separate protocols by next features:
1) Block validators motivation way based on consensus
2) Transaction and data storing rules

One of them give us way to exchange value in a private way (ZCash, Monero, Dash), another provide VM for smart-contracts. Some of them allow anyone to mine cryptocurrency, another require stakes to "forge" coins.

I think great way to understand most of them: select some which is most interested for you from list below and we will discuss more about them:
Top 100 Cryptocurrencies in few words
Code:
Name            | Sym.  | Description                             
----------------|-------|------------------------------------------
Bitcoin         | BTC   | Digital gold                             
Ethereum        | ETH   | Programmable contracts and money         
Bitcoin Cash    | BCH   | Bitcoin clone                           
Ripple          | XRP   | Enterprise payment settlement network   
Litecoin        | LTC   | Faster Bitcoin                           
Dash            | DASH  | Privacy-focused Bitcoin clone           
NEO             | NEO   | Chinese-market Ethereum                 
NEM             | XEM   | Batteries-included digital assets       
Monero          | XMR   | Private digital cash                     
Ethereum Classic| ETC   | Ethereum clone                           
IOTA            | MIOTA | Internet-of-things payments             
Qtum            | QTUM  | Ethereum contracts on Bitcoin           
OmiseGO         | OMG   | Banking, remittance, and exchange       
Zcash           | ZEC   | Private digital cash                     
BitConnect      | BCC   | Madoff-like investment fund             
Lisk            | LSK   | Decentralized applications in JavaScript
Cardano         | ADA   | Layered currency and contracts           
Tether          | USDT  | Price = 1 USD                           
Stellar Lumens  | XLM   | Digital IOUs                             
EOS             | EOS   | Decentralized applications on WebAssembly
Hshare          | HSR   | Blockchain switchboard                   
Waves           | WAVES | Decentralized exchange and crowdfunding 
Stratis         | STRAT | Decentralized applications in C#         
Komodo          | KMD   | Decentralized ICOs                       
Ark             | ARK   | Blockchain switchboard                   
Electroneum     | ETN   | Monero clone                             
Bytecoin        | BCN   | Privacy-focused cryptocurrency           
Steem           | STEEM | Reddit with money voting                 
Ardor           | ARDR  | Blockchain for spawning blockchains     
Binance Coin    | BNB   | Pay Binance exchange fees               
Augur           | REP   | Decentralized prediction market         
Populous        | PPT   | Invoice trading futures                 
Decred          | DCR   | Bitcoin with alternative governance     
TenX            | PAY   | Cryptocurrency credit card               
MaidSafeCoin    | MAID  | Rent disk space                         
BitcoinDark     | BTCD  | Zcoin close                             
BitShares       | BTS   | Decentralized exchange                   
Golem           | GNT   | Rent other people's computers           
PIVX            | PIVX  | Inflationary Dash clone                 
Gas             | GAS   | Pay fees on Neo                         
TRON            | TRX   | In-app-purchases                         
Vertcoin        | VTC   | Bitcoin clone                           
MonaCoin        | MONA  | Japanese Dogecoin                       
Factom          | FCT   | Decentralized record keeping             
Basic Attention | BAT   | Decentralized ad network                 
SALT            | SALT  | Cryptocurrency-backed loans             
Kyber Network   | KNC   | Decentralized exchange                   
Dogecoin        | DOGE  | Serious meme bitcoin clone               
DigixDAO        | DGD   | Organisation manages tokenized gold     
Veritaseum      | VERI  | Vaporware                               
Walton          | WTC   | IoT Blockchain                           
SingularDTV     | SNGLS | Decentralized Netflix                   
Bytom           | BTM   | Physical assets as tokens               
Byteball Bytes  | GBYTE | Decentralized database and currency     
GameCredits     | GAME  | Video game currency                     
Metaverse ETP   | ETP   | Chinese Ethereum plus identity           
GXShares        | GXS   | Decentralized Chinese Equifax           
Syscoin         | SYS   | Decentralized marketplace               
Siacoin         | SC    | Rent disk space                         
Status          | SNT   | Decentralized application browser       
0x              | ZRX   | Decentralized exchange                   
Verge           | XVG   | Privacy Dogecoin                         
Lykke           | LKK   | Digital asset exchange                   
Civic           | CVC   | Identity and Authentication App         
Blocknet        | BLOCK | Decentralized exchange                   
Metal           | MTL   | Payments with rewards program           
Iconomi         | ICN   | Digital asset investment funds           
Aeternity       | AE    | Decentralized apps (prototype)           
DigiByte        | DGB   | Faster Bitcoin                           
Bancor          | BNT   | Token Index Funds                       
Ripio Credit    | RCN   | Co-signed Cryptocurrency Loans           
ATMChain        | ATM   | Advertising network                     
Gnosis          | GNO   | Decentralized prediction market         
VeChain         | VEN   | Supply chain item IDs                   
Pura            | PURA  | Cryptocurrency                           
Particl         | PART  | Privacy marketplace and chat             
KuCoin Shares   | KCS   | Profit-sharing exchange fees             
Bitquence       | BQX   | Mint for cryptocurrency investments     
FunFair         | FUN   | Decentralized casino                     
ChainLink       | LINK  | External data for contracts             
Power Ledger    | POWR  | Airbnb for electricity                   
Nxt             | NXT   | Cryptocurrency and marketplace           
Monaco          | MCO   | Cryptocurrency credit card               
Cryptonex       | CNX   | Zerocoin clone                           
MCAP            | MCAP  | Mining investment fund                   
Storj           | STORJ | Rent disk space                         
ZenCash         | ZEN   | Privacy-focused Bitcoin clone           
Nexus           | NXS   | Bitcoin clone                           
Neblio          | NEBL  | Decentralized application platform       
Zeusshield      | ZSC   | Decentralized insurance                 
Streamr DATAcoin| DATA  | Real-time data marketplace               
ZCoin           | XZC   | Private digital cash                     
NAV Coin        | NAV   | Bitcoin with private transactions       
AdEx            | ADX   | Advertising exchange                     
Open Trading    | OTN   | Decentralized exchange                   
SmartCash       | SMART | Zcoin clone with rewards                 
Bitdeal         | BDL   | Bitcoin clone                           
Loopring        | LRC   | Decentralized exchange                   
Edgeless        | EDG   | Decentralized casino                     
FairCoin        | FAIR  | Bitcoin that rewards savers
Post
Topic
Board Project Development
Re: New DiceBot in progress
by
alerdenisov
on 31/08/2017, 18:24:46 UTC
What a reason to do it? I mean winning in dice is impossible (because of math). If you're interesting I could to post my bot code (because it is useless)
Post
Topic
Board Project Development
Re: How to create trading bot?
by
alerdenisov
on 31/08/2017, 10:24:46 UTC
First of all I should to decide which strategy was in basement of bot.

Right now I could to choice few ways: algorithmic and neural network. In google you will find a lot of information, but I suggest to look at next open source projects (especially on their Issues, because a lot of discussions)

https://github.com/askmike/gekko
https://github.com/owocki/pytrader
https://github.com/michaelgrosner/tribeca
https://github.com/carlos8f/zenbot
Post
Topic
Board Development & Technical Discussion
Re: 1 Confirmation versus 6
by
alerdenisov
on 31/08/2017, 10:15:09 UTC
Additional to previous answers. It's needed not only to protect from rogue, also it's required because of protocol design. Let me explain:

Nobody could be sure that somewhere else there is no other bitcoin-branch, larger, when it is available in that part of the network.

The Bitcoin protocol says that the largest branch is always true. If someone shows a chain of blocks larger than mine (which means currently in my node), I believe it and use it. Imagine a situation where someone from Canada made a block and announced it on the network. At the same time, someone in China also made a block and announced. Due to network delays, the Chinese part of the network learns about the existence of chinese block before canadian block, and opposite situation in Canada. Since the branches are equal in length, it is impossible to tell which branch will be truth and here the race begins: who will make the next block faster.

And there possibility to mine without announcement for a while..

In simple way: much more confirmations, much more proof-of-work over transaction

(Here is link with latest orphaned-blocks: https://blockchain.info/orphaned-blocks)