bayesline.api.equity.PortfolioSettings#
- pydantic model bayesline.api.equity.PortfolioSettings#
Specifies different options of obtaining portfolios.
Show JSON schema
{ "title": "PortfolioSettings", "description": "Specifies different options of obtaining portfolios.", "type": "object", "properties": { "portfolio_schema": { "anyOf": [ { "type": "string" }, { "type": "integer" }, { "$ref": "#/$defs/PortfolioOrganizerSettings" } ], "description": "The portfolio organizer settings to use as an underlying schema of portfolios. The 'Default' schema is used by default.", "title": "Portfolio Schema" }, "ffill": { "default": "no-ffill", "enum": [ "no-ffill", "ffill-with-drift" ], "title": "Ffill", "type": "string" }, "unpack": { "default": "no-unpack", "enum": [ "no-unpack", "unpack" ], "title": "Unpack", "type": "string" } }, "$defs": { "PortfolioOrganizerSettings": { "additionalProperties": false, "description": "Specifies which portfolios to enable (from different sources).\n\nDifferent sources (e.g. uploaded portfolios) can provide the same portfolio\nidentifiers. These settings allow to specify which portfolios to enable from\nwhich sources.", "properties": { "dataset": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "The name of the underlying dataset to use for price data needed to forward fill portfolios, obtain corporate actions, etc.If none is given then the configured default dataset is used.", "examples": [ "Bayesline-US" ], "title": "Dataset" }, "enabled_portfolios": { "anyOf": [ { "type": "string" }, { "additionalProperties": { "type": "string" }, "type": "object" } ], "description": "The enabled portfolios from different sources. The key is the portfolio ID, and the value is the source (name of the underlying portfolio service). Pass a str to reference an entire portfolio source (e.g. all portfolios from an upload).", "title": "Enabled Portfolios" } }, "required": [ "enabled_portfolios" ], "title": "PortfolioOrganizerSettings", "type": "object" } }, "additionalProperties": false, "required": [ "portfolio_schema" ] }
- Config:
frozen: bool = True
extra: str = forbid
- Fields:
ffill (Literal['no-ffill', 'ffill-with-drift'])
portfolio_schema (str | int | bayesline.api._src.equity.portfolio_settings.PortfolioOrganizerSettings)
unpack (Literal['no-unpack', 'unpack'])
-
field portfolio_schema:
Annotated
[str
|int
|PortfolioOrganizerSettings
] [Required]# The portfolio organizer settings to use as an underlying schema of portfolios. The ‘Default’ schema is used by default.
- Constraints:
references = <class ‘bayesline.api._src.equity.portfolio_settings.PortfolioOrganizerSettings’>