Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide report of agent balance and task balance #5

Open
mikedotexe opened this issue Dec 7, 2022 · 1 comment
Open

Provide report of agent balance and task balance #5

mikedotexe opened this issue Dec 7, 2022 · 1 comment
Assignees

Comments

@mikedotexe
Copy link
Contributor

For now we can use this:
https://jsfiddle.net/beaver71/2j2gk8nb/

Where you can edit the data for the two charts. The data for the two charts has the similar x: …, y: … that we're outputting here.

Let's please create a chart that shows two lines:

  1. One representing a task (paying three people, for instance) and the total balance (this should be going down)
  2. One representing the agent's native and manager state balance

Create a task, give it 1 JUNO. Make sure the agent has enough JUNO so complete all the recurring payments (without having to stop and call withdraw)

Then at the end, when the task has completed, stop the agent and call withdraw.

At this point the indexer will have enough data to put into the JSFiddle link above.

And if you could please run that test on tasks that are Once and and Immediate.

I have been using this script that does payments every other block:

recurring payment simple script.zip

(Note, in the zip file above I do not have scripts for Once and Immediate, so if you can please write those it'd be great)


The most important thing we need to know: what percentage did the agent end up making in all the tests? How does this compare to our expectations?

If we could have a report of that, it'd be amazing, thank you

@nlipartiia-hacken
Copy link
Contributor

nlipartiia-hacken commented Jan 6, 2023

I tried analyzing agent balance for Bank message (two actions). Results look like this:
Once: https://jsfiddle.net/tLv25rc4/11/
Immediate: https://jsfiddle.net/tLv25rc4/8/

Agent seems profitable, but I think he receives about 13% instead of 5%:
spent on proxy_call: 31250
manager-state increase: 35280
agent profit: 4030
4030 / 31250 = 0.12986

The same calculations for the last proxy_call:
spent on proxy_call: 33646
manager-state increase: 35280
agent profit: 1634
1634 / 33646 = 0.04856
So in this case it's a little less than 5% profit.

It seems logical since each proxy_call agent receives reward as if it's the last (most expensive) proxy_call.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants