DEX wrapper that provides the ability to do efficient larger swaps

It’s a well-known fact that whenever you do a sizeable swap wrt liquidity it moves the price of the asset on the AMM, which opens up opportunities for arbitrageurs. Now, this opportunity created by the trader benefits mostly the arbitrageurs apart from really small fees taken by liquidity providers, while the original trader loses money to slippage.

Why give the benefits from the opportunity created from your swap to a random bot while you lose money on slippage!

Image for post
Image for post

Enter into the CandyShop, the only place where you can buy tasty Candies! Each candy has a wrapper which is your lottery ticket, so buying candies is buying lottery tickets! …


The all — seeing & all — hearing protector of Matic

Image for post
Image for post
Credits: Pepakura Helmet Heimdall by GimpeeIndustries

Matic Network has a three-layered security architecture in which there are the following entities involved:

1) Block Producers —aka BOR chain: These are involved in batching transactions in blocks to ensure faster confirmation times

2) Validator Layer — aka Heimdall: These are validator nodes that batch the blocks produced by the block producers and push them to the Ethereum

3) Network Watchers —They are actors on the Ethereum, and use fraud proofs to challenge any transaction that they deem fraudulent on the sidechains.


Summer of 2018 will always be remembered because of amazing time i had working on my project Python Hydra .

I learnt a great deal of stuff apart from raw coding . I understood why and how code-design processes are important , how documentation is a must even if you don’t like doing it at the moment.

Overview of the project !

My task was to build a open api parser to convert open api documentation to hydra documentation so that users can easily migrate from open api to hydra . …


GSoC-2018 with Python Hydra

Hey! I am writing this post as the summer comes to an end and so does the 3rd phase of GSoC, i really wish it wasn't limited to summer, clap if you agree!

I worked on creating a parser to convert OpenAPI Document to Hydra API Documentation which will greatly reduce the barrier to entry and people will be able to migrate to hydrus easily , in one command to be precise . The parser was created over several iterations and i think we have a pretty robust parser now .

My idea was to parse the doc for the information required by the `doc_maker` to create a Hydra document , hence i started by referring to the sample hydra doc generator given here. From there i managed to break the process into following…


We all wanted our own space ships at some point in our childhood , right ? We fulfilled your dream guys ! No kidding . We at hydrus are trying to showcase the abilities of parser and agent by using this demo .

One of the aims of this demo was to allow users and devs to understand the concept or what hydrus is trying to achieve quickly and in a fun way , this would encourage people to help us push hydrus to another level in terms of general adoption.

For now we were focussing on single server single client , but connecting to multiple servers at once should be a trivial task . We allow users to convert existing open api doc to hydra doc and starting a hydrus server using this doc in a single command , users can then head over to the web interface and just enter the URL of server and connect to it . The hydra-agent is amazing in its querying abilities and allows any user to query any server using natural language like commands. You might want to read the above line again to understand how amazing that is ! …


Phase 2 was great , i learnt a great deal on how to plan and execute correctly , how to apply design principles , how to make codebase flexible from my mentors . Last week we fixed some trivial issues and fixed them quickly and also thought about some changes we need to make to test suite of hydrus , specially test_crud.py .

There was this issue in hydrus where in the entrypoint “@id” field there were more than one _: , I fixed it quickly by putting a conditional statement which checked if the @id had more than one _: and removed the extra one . …


hydrus is an amazing tool for building REST API’s but every software deserves new features and upgrades , so we decided to add some new features to hydrus. We wanted some features like custom endpoints and arrays as input parameters in hydrus as we needed those so that we can parse open api document accurately and represent the api structure in a better way .

In hydrus the endpoint was same as the class name by default and there was no option to change this ,hence to allow users to define custom endpoints and to facilitate creation of endpoints like store/inventory/order we needed this feature . To implement we passed path during class creation and collection_path during addition of class to HYDRA api documentation. …


Our last implementation worked okay , but in terms of features or ability to parse various open api specifications we were still lacking as the parser wasnt generalised enough. This week saw various enhancements , optimisations to the parser along with correction of many mistakes .

We had a lot of global variables which were defined in the main method , if parser was to be used as an independent module these variables would have to be initialised by the user which is certainly not what we want , so we created a method which could be the starting point for the process of parsing the documentation . …


Our last implementation worked okay , but in terms of features or ability to parse various open api specifications we were still lacking as the parser wasnt generalised enough. This week saw various enhancements , optimisations to the parser along with correction of many mistakes .

We had a lot of global variables which were defined in the main method , if parser was to be used as an independent module these variables would have to be initialised by the user which is certainly not what we want , so we created a method which could be the starting point for the process of parsing the documentation . …


In the last implementation we had assumed a lot of things and were still figuring out how to map some specific open api objects to hydra object , in this new implementation things have *not* changed . Don`t be disappointed yet , this implementation was in the right direction and we moved to a new and efficient way of parsing the open api specification and generalised a lot of stuff , let me tell you how .

In the last implementation we parsed the definitions first , then parsed the paths and attached the classes when we get a reference of them in the parameters or response object . I decided to spice things up this time , i tried to parse the paths directly and when the parser came across a reference to class we went to the location where the class was defined and parsed the class as well .This way we could allow the user to define the class anywhere in the documentation , be it ‘definitions’ object or ‘components’ object or anywhere else . …

Vaibhav Chellani

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store