Giter VIP home page Giter VIP logo

similar-ordinals's Introduction

Hi there ๐Ÿ‘‹

I am Jiri, a software developer from Prague.

I am interested in all things about Bitcoin, programming and data-science. My favourite language by far is python (even though Rust starts to come close).

Work projects

I am currently working for Trezor as a firmware developer on the trezor-firmware repository.

For the purposes of firmware repository, I also created two standalone python tools, that we used for decreasing the size of our binary. Both of these are public packages installable by pip:

  • binsize - analyzing the size of symbols from .elf files - repository
  • upysize - linter to find optimizations to micropython code to reduce its size - repository

Personal projects

When I have time, I like working on hobby personal projects. I have done countless smaller or bigger scripts/applications and each one taught me something new. Some of the most notable are:

  • OrdSimilarity - https://ordsimilarity.com/ - a search engine for similar ordinals pictures - repository
  • OrdMempool - https://ordmempool.space/ - observing BTC mempool for new ordinals - repository
  • BtcStatts - https://btcstatts.com/ - statistics about BTC ordinals - repository
  • MusilBlockchain - https://www.musil-blockchain.cz/ - my personal website about blockchain technology from 2018 - repository
  • GrdddjDashboard - https://grdddj.eu/ - showing some of the smaller website applications in one directory
  • ChessRobot - video - application playing lightning-speed chess on the screen against an opponent - repository
  • CalculatorChat - GUI acting both as a calculator and full-featured Messenger-like chat service - repository
  • ClipboardMonitor - analyzing clipboard content in real-time and doing arbitrary things with it - repository
  • ShortcutsToShortcuts - GUI for binding certain key presses with certain actions repository
  • CryptoMarketWatcher - app sending notifications about cryptocurrency prices reaching certain levels - repository
  • PiskvorkyInTerminal - my first bigger application, from 2018, when I was starting learning Java and programming in general - repository

similar-ordinals's People

Contributors

arsalaan-alam avatar grdddj avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

similar-ordinals's Issues

Create MVP frontend

Website with a basic functionality:

  • allow for user inputting a custom file or ordinal ID
  • call backend with this data
  • display results

Add details to duplicates

In case of duplicates, we should make it clear which ordinal is the original one (first minted) and which is the duplicate. In case of more duplicates, sort them and probably give them ids - "duplicate 1, "duplicate 2", etc.

Deploy the API and website

Because it is not so much fun on localhost.

After being public, we might send the website/API to some potentially interested parties, e.g.:

  • webpages with statistics
  • minting websites
  • ordinals marketplaces

Increase the speed of getting API results by creating Rust server

Currently, the python API loads the ordinals fingerprints into memory on startup to start comparing them immediately on each request.

This is good enough and approximately matches the Rust implementation, which loads the JSON file from scratch each time.

The logical conclusion is to create a server in Rust - probably only for the purpose of getting results on the backend - and replicating the approach we have now in python API - load the data from JSON into memory at server startup, so it does not need to waste time for each request.

Create support for shareable/saveable links

When some results are cool or important, there may be a need to save/share them.

Could be made possible with optional URL queries, e.g. ordsimilarity.com?ord_id=25 would automatically send a request for results with ord_id=25 and show them

Support svg images

They are currently throwing PIL error, because they are not "normal" image. Try to do it somehow, like taking the first frame and turning it into a picture

Decide on a strategy on showing the duplicates

When there is a lot of duplicates, what is the case e.f. for ord_id 0, we might want to show just the duplicated ones (maybe sorted by their ID), or also some other ones with similarity 256 to make it interesting

Implement real-time updating of the hash DB and similarity index

For MVP, it should be fine to work with a static dataset, where we can compare all the ordinals with ord_id less than 1_044_219. Also, the similarity index is built from this dataset, so it does not account for all the newest ordinals above this ord_id.

However, later we might want to do the update process regularly, preferably in real-time, so we always have the latest data and do not miss some similarities.

The update logic could look something like this:

  • get all the newly minted ordinals we do not have
  • calculate and save hashes for them
  • updating the similarity index (this is the tricky part)
    • calculate and save top_n similarities for all the new ones
    • for each ordinal from the old ones calculating similarity with all the new ones, and updating their top_n to possibly include similarities with some of the new ones

Use Hiro API

It might be beneficial to use Hiro API, and not only because that way we would qualify for their price on the hackathon.

Actually, their API seems to be really nice - https://docs.hiro.so/ordinals

Some endpoints we could use:

Consider application of BTC lightning payments on the website/API

It would be pretty cool if we could have the option to charge some small money amounts (if we decide to) in BTC for using the service.

The API could be behind a "paywall" and users would need to send proof that they paid some satoshis to a lightning wallet.

On the frontend, this could be easily done by a QR code, how to solve it on the backend would require more thought...

Add tests

We should add at least some basic test suite checking that the similarity algorithms (comparing the fingerprints) work as expected.

Some end-to-end tests of finding a similar picture in a directory of other pictures would be also nice.

Create MVP backend

API with basic functionality:

  • take either ord_id or a file upload and return the most similar ordinal documents

Document the code

Each file and function should preferably have at least a short description

Setup API monitoring

We want to immediately know that the API is down, so we could troubleshoot it.

We might also have some self-healing capabilities so that the API restarts itself when in problems.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.