npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@murphy-labs/strateg-protocol-core

v0.2.86

Published

This repository contains a collection of contracts for managing strategies and related operations within a decentralized finance (DeFi) ecosystem. These contracts facilitate various functionalities such as strategy vault creation, asset buffering, operato

Downloads

10

Readme

Strateg Core Contracts

This repository contains a collection of contracts for managing strategies and related operations within a decentralized finance (DeFi) ecosystem. These contracts facilitate various functionalities such as strategy vault creation, asset buffering, operator proxy, block registry, and more. Below is an overview of each contract:

Contracts

StrategVaultFactory

The StrategVaultFactory contract is responsible for creating new strategy vaults. It allows users to deploy vault contracts with specified parameters such as name, symbol, underlying asset, strategy, fees, and more. The factory also provides functions for upgrading the vault and ERC3525 implementations, executing emergency operations, setting protocol fees, and retrieving information about owned vaults.

StrategVaultManagement

The StrategVaultManagement contract serves as a middleware between users and the actual strategy vaults. It handles access control and deposit limits based on the defined middleware strategy. The contract implements various strategies, including public access, whitelisted addresses, and holder requirements. It also supports timelock restrictions and deposit limits for both users and the vault.

StrategOperatorProxy

The StrategOperatorProxy contract acts as a proxy for executing operations on behalf of the operator. It enables the operator to perform actions such as vault harvesting, rebalancing, withdrawal rebalancing, and fee withdrawals. Only users with the OPERATOR_ROLE can access these functionalities.

StrategBlockRegistry

The StrategBlockRegistry contract allows the registration and removal of strategy blocks. Blocks represent different strategies used within the ecosystem. The contract maintains a mapping of block addresses to their corresponding metadata, including the deployer, name, and IPFS hash. The registry enforces access control based on ownership or deployer role.

StrategAssetBuffer

The StrategAssetBuffer contract provides a minimalistic mutualized buffer for strategy vaults. Users can deposit assets into the buffer, which temporarily holds the assets outside the vault strategies accounting. This allows for easier asset management and flexibility within the ecosystem.

Usage

To use these contracts, you can deploy them individually or as part of a larger DeFi system. Each contract has specific functions and access control roles to manage various operations and configurations. You can interact with the contracts using the appropriate Ethereum wallet or smart contract interaction tool.

Please refer to the individual contract source code and associated documentation for detailed information on the functions, events, and usage instructions.

Development

To contribute or make changes to these contracts, follow these steps:

  1. Clone the repository:

    git clone https://gitlab.com/murphy-labs/strateg-protocol/contracts/core.git
  2. Install the necessary dependencies:

    npm install --force

    The --force is mandatory because there is a package version conflict with hardhat-deploy but everything is working fine. There is no solution until we migrate on ethers v6

  3. Make the desired changes to the contract files.

  4. Compile the contracts:

    npx hardhat compile
  5. Run the tests to ensure everything is working as expected:

    npx hardhat test
  6. Submit a pull request with your changes for review.

License

This project is licensed under the BUSL-1.1 license. Please refer to the individual contract files for their specific license information.

Disclaimer

These contracts are provided as-is without any warranty or guarantee of any kind. Use them at your own risk. Always review and audit the code before deploying it in a production environment.