Skip to content

Conversation

@MegaRedHand
Copy link
Contributor

@MegaRedHand MegaRedHand commented Jan 30, 2025

NOTE: this will be merged (with improvements) gradually into the v2 branch. When that's finished, this PR will be closed.

Fixes #

What Changed?

This PR introduces two new crates to the SDK: eigen-aggregator and eigen-operator, with a higher-level interface than the other crates.

Reviewer Checklist

  • New features are tested and documented
  • PR updates the changelog with a description of changes
  • PR has one of the changelog-X labels (if applies)
  • Code deprecates any old functionality before removing it

@MegaRedHand MegaRedHand changed the base branch from main to dev January 30, 2025 16:24
@MegaRedHand MegaRedHand marked this pull request as draft January 30, 2025 20:59
@MegaRedHand MegaRedHand marked this pull request as ready for review February 3, 2025 20:21
@MegaRedHand MegaRedHand marked this pull request as draft February 3, 2025 20:21
@MegaRedHand MegaRedHand marked this pull request as ready for review February 3, 2025 20:55
.process_new_signature(task_index, task_response_digest, signature, operator_id)
.await?;
info!("processed signature for index {:?}", task_index);
let quorum_reached = {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this assumed that 2 signatures are needed to process .
there's a better way in dev branch here
https://github.com/Layr-Labs/incredible-squaring-avs-rs/blob/b953a8127b604d91175d71e7c2b47ad4023f7e77/crates/aggregator/src/lib.rs#L320-L395

it handles all cases using total stake and quorum threshold percentage. Its hardcoded rn there with 4800 (40% of 12000(total stake))

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. However, I was thinking of just waiting for a signature aggregate to be returned by the BLS aggregation service.

Copy link
Contributor

@supernovahs supernovahs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

^

@MegaRedHand MegaRedHand added the changelog-added [changelog] PR adds a new feature label Feb 17, 2025
#[derive(Debug, Default, Serialize, Deserialize, PartialEq, Eq, Clone)]
pub struct OperatorRegistrationConfig {
pub register_operator: bool,
pub operator_to_avs_registration_sig_salt: String,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think we can name this AvsOperatorRegistrationConfig and add another struct for EigenlayerOperatorRegistrationConfig so people are not confused.

we can make the params optional that are only available in pre slashing or post slashing. like we did in writer structs.

Ex : allocation_delay, salt etc
can make a PR if you agree with this

Copy link
Contributor

@supernovahs supernovahs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

commented on operator config

use serde::{Deserialize, Serialize};

#[derive(Debug, Default, Serialize, Deserialize, PartialEq, Eq, Clone)]
pub struct ContractsConfig {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

naming ? AvsContractsConfig?

Copy link
Contributor

@supernovahs supernovahs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have a doubt, what if some one wants to add 3 operators config using our config crate, can they do it right now? No right? since we are assuming only 1 key store pairs in EcdsaConfig and BlsConfig?

@supernovahs
Copy link
Contributor

I have a doubt, what if some one wants to add 3 operators config using our config crate, can they do it right now? No right? since we are assuming only 1 key store pairs in EcdsaConfig and BlsConfig?

maybe one way can be
use sdk::EcdsaConfig ;
use sdk::EcdsaConfig as Ecdsa2Config ;
use sdk::EcdsaConfig as Ecdsa3Config;

@MegaRedHand MegaRedHand marked this pull request as draft April 7, 2025 18:04
@MegaRedHand
Copy link
Contributor Author

Continued in v2 branch. First version in #469

@pablodeymo pablodeymo deleted the sdk-ux-improvment branch April 30, 2025 18:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog-added [changelog] PR adds a new feature M-prevent-stale

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants