New classes
loc_authorities.api.TemporalEntityrepresents a temporal subject that is not currently registered or indexed by Library of Congressloc_authorities.api.DummyComplexEntityrepresents a complex topic that has valid sub-components but is not currently registered or indexed by Library of Congress.
Since both of these classes work with topics that don't exist in the Library of Congress API, the classes do not have true URIs and have only minimal RDF.
loc_authorities.api.TemporalEntity is designed to be used as a sub-component of loc_authorities.api.SubjectEntity or loc_authorities.api.DummyComplexEntity. When you pass a string value that cannot be parsed as a LoC identifier to either method, it will assume the object is loc_authorities.api.TemporalEntity and implement minimal RDF.
loc_authorities.api.DummyComplexEntity should be initialized from a list of identifiers. This can include plain labels for unindexed temporal entities (e.g. "1733") but should not for entities that have an identifier (e.g. use "sh2002012474", not "18th century"). To initialize a representation for "Almanacs--Pennsylvania--1733", you would call:
subject = loc_authorities.DummyComplexEntity(['sh85003744', 'n79022911-781', '1773'])
Initializing loc_authorities.api.DummyComplexEntity will retrieve the subcomponents from the Library of Congress API and provides minimal RDF. It also provides some convenience methods for accessing RDF properties (especially authoritative labels and instances).
Although the complex entities represented by loc_authorities.api.DummyComplexEntity do not have URIs, for queries to work, the entity must be assigned a persistent identifier. This implementation assigns a rdflib.BNode as the URI. This is cached in the session to allow for querying the RDF, but it will not (and is not intended to) persist between sessions.