[Steem Curator] - Oracle-D Posts Curation

in #utopian-io6 years ago (edited)

Repository:

https://github.com/mightypanda-x/steem-curator

Production URL:

https://steemcurator.com/

Previous Posts

https://busy.org/@mightypanda/steem-curator-mvp-comments-curation
https://busy.org/@mightypanda/steem-curator-easies-curation-and-tech-debt
https://busy.org/@mightypanda/steem-curator-sorting-feature-and-utopian-posts
https://busy.org/@mightypanda/steem-curator---user-preference-settings
https://busy.org/@mightypanda/steem-curator---utopian-moderator-comment-curation

New Feature and associated pull request

Oracle D is a new project that brings investments to the steem platform and has a list of approved writers who write about these projects. These writers are rewarded with an upvote from oracle-d account. Rewards are usually in the range of $25 to $35. Since this is a lesser known whale, it provides for a great opportunity to make big curation rewards.

Pull Request: https://github.com/mightypanda-x/steem-curator/commit/8b9b3804ba63c50fb60343c9724b5b3586f44017

Under the hood

src/app/oracle-d-posts/oracle-d-posts.component.ts

Maintaining a list of oracle-d reviewers and bloggers. This is a hard coded list as there is no way to find out approved oracle-d bloggers. This list is compiled from the oracle-d account voting behavior.
image.png

Dispatching actions to retrieve last 5 posts for the users. Posts for each author is retrieved individually so the whole page is not held up as we are working though the author list. This also provides for a good failsafe incase 1 or more steem apis fail to get a response.

We are also retrieving site preferences so we can show which posts user has already voted on and we can take them to their desired site.
image.png

src/app/post/reducers/post.reducers.ts

Retrieve action retrieves the posts for the author and updates the state with the newly retrieved list.
Clear action clears the state object.
image.png

This selector checks the retrieved posts for various conditions like:

  • They have beneficiary set as oracle-d.pay
  • They have not been voted by oracle-d already.
  • The post hasn't paid out
  • It has been at least 15 min since the post creation.
    image.png

src/app/post/services/post.service.ts

This code makes a call to steem api to get last 5 posts from the user. Once response is received, it promisifies the response.
image.png

This code allows us to retrieve posts for multiple authors at the same time. This combines multiple promise calls using Promise.all method. Essentially this code is future proof when we would like to use similar functionality for other parts of the application.
image.png

Once all the data is received, we feed this data to a datastore which is used to populate angular material table. This table allows for sorting of some essential columns for easier curation.

Feedback?

If you have any feedback or would like to add some new features, please let me know in the comments below.

Github: https://github.com/mightypanda-x

Sort:  

Thank you for your contribution. Does oracle-d has a frontend from where you can create the post? The code looks great and its explained very well in the contribution. However, writing hard-coded usernames is not good but you have explained the problem.

What you can do is before initialization analyzes the last week's voting behavior of oracle-d and then use those usernames only.


Your contribution has been evaluated according to Utopian policies and guidelines, as well as a predefined set of questions pertaining to the category.

To view those questions and the relevant answers related to your post, click here.


Need help? Write a ticket on https://support.utopian.io/.
Chat with us on Discord.
[utopian-moderator]

What you can do is before initialization analyzes the last week's voting behavior of oracle-d and then use those usernames only.

I was thinking the same. Maybe just keep a database with usernames that they voted on in the last two to three weeks and use that.

Thanks for the review and suggestion. I was thinking about looking that previous weeks votes to get author list, but they upvote lot of random posts too, so my list will be unnecessarily huge. They do have a front end to create posts.
CC: @amosbastian

What you can do is to get 2-3 weeks of upvote data and then remove those username which are very less. I guess you need to do some analysis, I can help you with the analysis if you need.

I will try finding some common thread. I will discuss my findings with you to see if thr is some good way to find. I keep trying to reduce calls to steem api so site is fast.

Cool, good luck with your findings :)

Thank you for your review, @codingdefined! Keep up the good work!

I want to work for oracle d

Hi @mightypanda!

Your post was upvoted by @steem-ua, new Steem dApp, using UserAuthority for algorithmic post curation!
Your post is eligible for our upvote, thanks to our collaboration with @utopian-io!
Feel free to join our @steem-ua Discord server

Hey, @mightypanda!

Thanks for contributing on Utopian.
We’re already looking forward to your next contribution!

Get higher incentives and support Utopian.io!
Simply set @utopian.pay as a 5% (or higher) payout beneficiary on your contribution post (via SteemPlus or Steeditor).

Want to chat? Join us on Discord https://discord.gg/h52nFrV.

Vote for Utopian Witness!

You got a 3.22% upvote from @oceanwhale courtesy of @mightypanda! Earn 100% earning payout by delegating SP to @oceanwhale. Visit www.OceanWhaleBot.com for details!

Coin Marketplace

STEEM 0.17
TRX 0.15
JST 0.028
BTC 58130.32
ETH 2361.48
USDT 1.00
SBD 2.38