Security Classification
Security Classification organizes each security into a hierarchical tree of classes and subclasses with up to 4 levels. It is what defines, for example, that a stock is in "Variable Income > Stocks" and that an inflation-indexed government bond is in "Fixed Income > Inflation Indexed > Government Bond". This structure is the basis for the allocation analyses of a portfolio by asset class and for investment profiles.
Level hierarchy
Each classification belongs to a level, from CLASSIFICATION_L0 (the broadest, such as Fixed Income, Variable Income or Multimarket) to CLASSIFICATION_L3 (the most detailed). Every classification below L0 points to its parent classification through parentId; at L0, parentId is null. A security is always placed in a structure with at least 2 and at most 4 levels, which means that to reclassify a security you need to provide (at least) its new CLASSIFICATION_L0 and CLASSIFICATION_L1.
In a portfolio's views, the hierarchy is cumulative: a security classified under "Fixed Income > Inflation Indexed" also counts toward the "Fixed Income" total.
Official classification and reclassification
By default, Gorila classifies securities using a proprietary methodology that seeks to adhere to market conventions and standards and that also uses official sources, such as B3 and Anbima. This proprietary classification does not always reflect the logic each institution uses to evaluate its portfolios. A fund classified by Anbima as Multimarket, but tied to the CDI, may be treated as Fixed Income by an asset manager, and this changes how the portfolio's target allocation compliance with the investor's profile is read.
For these cases, your organization can create custom classifications and reclassify securities:
- Custom classes can be created at any level, including as subclasses of Gorila's official classes. To build an entirely custom chain, create the classes in order, from L0 to L3, using the identifier of the newly created parent class at each step.
- Reclassifying a security means pointing it to one of your organization's classifications. Each security has a single classification at a time, and the securities you do not reclassify keep following the official classification.
- Reverting to the default: when you remove a security's custom classification, it returns to Gorila's official classification.
Reclassification applies to all portfolios in your organization. In connected portfolios (shared with your organization), you see the securities under your organization's classification, while the portfolio owner keeps seeing them under Gorila's official classification, in their personal account.
Editing and deletion
Only custom classifications can be renamed or deleted; Gorila's official classifications are fixed. When you delete a custom classification, all subclasses below it are also deleted, and the securities that were in them automatically return to Gorila's official classification.
Use in queries
Classifications can also be used to filter and group the metrics of portfolios and economic groups. Most metrics endpoints accept the securityClassification filter, and the per-position breakdowns accept grouping the result by classification level (groupBy equal to CLASSIFICATION_L0, CLASSIFICATION_L1, CLASSIFICATION_L2 or CLASSIFICATION_L3), as in List Position Market Values.
Where to access
In GorilaCORE, you can list the classifications available to your organization (with filters by level, parent classification and name), read a specific classification, and create, rename and delete custom classifications. To reclassify a security, or return it to the official classification, use the update security endpoint, providing the desired classificationId (or null).