Skip to content
All library documents

Using Rental Metadata to Set Strategy Usage Limits

Article FMZ digest · Author: 发明者量化-小小梦

Summary

This document explains how a strategy provider can use metadata attached to a platform registration code to apply different operating limits to different renters. Metadata is a string set when creating a code, and the strategy reads it at runtime to select a permission tier. The example is a long-only spot strategy that maps tier labels to maximum base-currency holdings, with an additional default limit when no metadata is supplied.

The walkthrough describes creating a rental code with a selected tier, running the strategy under that code, and editing the metadata later. It reports that changing a code’s metadata and restarting the running instance activates a stricter holding cap. The same pattern could be adapted to other controls, such as restricting exchanges or accounts, and futures strategies would need to inspect position data rather than spot balances. This is a platform-specific implementation example, not a general security mechanism; the author emphasizes that limits must be designed around the strategy’s own trading logic and that essential non-entry actions such as closing positions should continue when a cap is reached.

Key ideas

  • Registration-code metadata can represent different strategy access or configuration tiers.
  • A running strategy can read the metadata and map it to limits such as a maximum spot holding.
  • The example demonstrates that changing the metadata and restarting an instance applies a different tier.
  • Controls for futures or other strategy types must use the relevant position and account data.
  • Limit handling should prevent additional entries while preserving necessary management actions such as exits.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.