menu
Data

Map Symbology

Asset Service provides the information needed to map from one identifier to another. Clients can retrieve this data via the GS Quant SDK.

Compatibility

Before running examples in this guide, ensure that source is set to Asset Service.

from gs_quant.markets.securities import SecurityMaster, SecurityMasterSource

SecurityMaster.set_source(SecurityMasterSource.ASSET_SERVICE)

Method availability varies by source:

MethodAsset ServiceSecurity Master
get_assetXX
get_identifiersX
get_all_identifiersX

Querying

You can look up a security using any of the identifier types in Asset Service (e.g. ric, bbid, cusip, sedol). Identifiers that refer to the same security will be returned, subject to licensing.

Milestoning

Identifiers are milestoned, such that the history of each identifier for a given security can be viewed. By default, data that is currently valid will be retrieved. However, users can specify an "as of" date to see identifier values that were in effect on a past date. (Other fields such as asset type and class are not milestoned.)

info

Note

Examples require an initialized GsSession. Please refer to Sessions for details.

Get By Identifier

import datetime
from gs_quant.markets.securities import AssetIdentifier, SecurityMaster

asset = SecurityMaster.get_asset('GS UN', AssetIdentifier.BLOOMBERG_ID, as_of=datetime.date(2021, 1, 5))
asset.get_identifiers()

Output:

{
  'GSID': '901026',
  'CUSIP': '38141G104',
  'ISIN': 'US38141G1040',
  'BBID': 'GS UN',
  'RIC': 'GS.N',
  'SEDOL': '2407966',
  'TICKER': 'GS',
  'BCID': 'GS US'
}

To spot check a few properties:

print(asset.name)
print(asset.exchange)

Output:

The Goldman Sachs Group, Inc.
NYSE