diff --git a/justfile b/justfile index 2d9123b..d4ea633 100644 --- a/justfile +++ b/justfile @@ -10,7 +10,7 @@ download-ftm-schema VERSION: mkdir -p schemas/{{VERSION}}/ wget https://github.com/opensanctions/followthemoney/archive/refs/tags/v{{VERSION}}.zip unzip v{{VERSION}}.zip >/dev/null - mv followthemoney-{{VERSION}}/followthemoney/schema/*.yaml followthemoney-{{VERSION}}/followthemoney/schema/*.yml schemas/{{VERSION}}/ 2>/dev/null; true + mv followthemoney-{{VERSION}}/followthemoney/schema/*.yaml schemas/{{VERSION}}/ rm -rf followthemoney-{{VERSION}}/ v{{VERSION}}.zip test: diff --git a/schemas/4.5.0/Address.yaml b/schemas/4.6.0/Address.yaml similarity index 85% rename from schemas/4.5.0/Address.yaml rename to schemas/4.6.0/Address.yaml index ef824bb..76adcfc 100644 --- a/schemas/4.5.0/Address.yaml +++ b/schemas/4.6.0/Address.yaml @@ -40,7 +40,7 @@ Address: type: address remarks: label: "Remarks" - description: "Handling instructions, like 'care of'." + description: "Handling instructions, like 'care of'" postOfficeBox: label: "PO Box" description: "A mailbox identifier at the post office" @@ -53,23 +53,20 @@ Address: description: "City, town, village or other locality" postalCode: label: "Postal code" - description: "Zip code or postcode." + description: "Zip code or postcode" maxLength: 16 region: label: "Region" - description: "Also province or area." + description: "Also province or area" state: label: "State" - description: "State or federal unit." + description: "State or federal unit" latitude: label: "Latitude" type: "number" longitude: label: "Longitude" type: "number" - country: - label: "Country" - type: "country" osmId: label: "OpenStreetmap Place ID" type: "identifier" diff --git a/schemas/4.5.0/Airplane.yaml b/schemas/4.6.0/Airplane.yaml similarity index 100% rename from schemas/4.5.0/Airplane.yaml rename to schemas/4.6.0/Airplane.yaml diff --git a/schemas/4.5.0/Analyzable.yaml b/schemas/4.6.0/Analyzable.yaml similarity index 100% rename from schemas/4.5.0/Analyzable.yaml rename to schemas/4.6.0/Analyzable.yaml diff --git a/schemas/4.5.0/Article.yaml b/schemas/4.6.0/Article.yaml similarity index 100% rename from schemas/4.5.0/Article.yaml rename to schemas/4.6.0/Article.yaml diff --git a/schemas/4.5.0/Asset.yaml b/schemas/4.6.0/Asset.yaml similarity index 100% rename from schemas/4.5.0/Asset.yaml rename to schemas/4.6.0/Asset.yaml diff --git a/schemas/4.5.0/Associate.yaml b/schemas/4.6.0/Associate.yaml similarity index 81% rename from schemas/4.5.0/Associate.yaml rename to schemas/4.6.0/Associate.yaml index f3206f1..b322772 100644 --- a/schemas/4.5.0/Associate.yaml +++ b/schemas/4.6.0/Associate.yaml @@ -1,7 +1,7 @@ Associate: label: "Associate" plural: "Associates" - description: "Non-family association between two people" + description: "Non-family association between two people." extends: - Interval matchable: false @@ -22,7 +22,7 @@ Associate: properties: person: label: "Person" - description: "The subject of the association." + description: "The subject of the association" type: entity range: Person reverse: @@ -30,7 +30,7 @@ Associate: label: "Associates" associate: label: "Associate" - description: "An associate of the subject person." + description: "An associate of the subject person" type: entity range: Person reverse: diff --git a/schemas/4.5.0/Audio.yaml b/schemas/4.6.0/Audio.yaml similarity index 100% rename from schemas/4.5.0/Audio.yaml rename to schemas/4.6.0/Audio.yaml diff --git a/schemas/4.5.0/BankAccount.yaml b/schemas/4.6.0/BankAccount.yaml similarity index 100% rename from schemas/4.5.0/BankAccount.yaml rename to schemas/4.6.0/BankAccount.yaml diff --git a/schemas/4.5.0/Call.yaml b/schemas/4.6.0/Call.yaml similarity index 100% rename from schemas/4.5.0/Call.yaml rename to schemas/4.6.0/Call.yaml diff --git a/schemas/4.5.0/CallForTenders.yaml b/schemas/4.6.0/CallForTenders.yaml similarity index 97% rename from schemas/4.5.0/CallForTenders.yaml rename to schemas/4.6.0/CallForTenders.yaml index 5127e36..0afe436 100644 --- a/schemas/4.5.0/CallForTenders.yaml +++ b/schemas/4.6.0/CallForTenders.yaml @@ -3,7 +3,7 @@ CallForTenders: plural: "Calls for tenders" description: > A public appeal issued by an authority, possibly on behalf of another, - for buying a specific work, supply or service + for buying a specific work, supply or service. extends: - Thing - Interval @@ -96,7 +96,7 @@ CallForTenders: type: url fallsUnderGPPScope: label: "Does this call fall under the scope of GPP?" - description: "European Green Public Procurement (GPP) or green purchasing." + description: "European Green Public Procurement (GPP) or green purchasing" certificationCheck: label: "Certification check" awardingDate: diff --git a/schemas/4.5.0/Company.yaml b/schemas/4.6.0/Company.yaml similarity index 73% rename from schemas/4.5.0/Company.yaml rename to schemas/4.6.0/Company.yaml index 8ac22d2..03d198b 100644 --- a/schemas/4.5.0/Company.yaml +++ b/schemas/4.6.0/Company.yaml @@ -24,14 +24,9 @@ Company: - previousName - registrationNumber properties: - jurisdiction: - label: Jurisdiction - type: country - registrationNumber: - label: Registration number - type: identifier capital: label: "Capital" + type: number voenCode: label: "VOEN" description: "Azerbaijan taxpayer ID" @@ -40,7 +35,7 @@ Company: coatoCode: label: "COATO / SOATO / OKATO" type: identifier - description: "Soviet classifier for territories, regions, districts, villages. Aka. SOATO and same as OKATO" + description: "Soviet classifier for territories, regions, districts, villages. Aka. SOATO and same as OKATO." matchable: false irsCode: label: "IRS Number" @@ -52,7 +47,7 @@ Company: matchable: false cikCode: label: "SEC Central Index Key" - description: "US SEC Central Index Key" + description: "US SEC Central Index Key for listed companies" type: identifier jibCode: label: "JIB" @@ -67,16 +62,16 @@ Company: matchable: false kppCode: label: "KPP" - description: "Russian code issued by the tax authority, identifies the reason for registration at the Federal Tax Service (Russian: КПП). A company may have multiple KPP codes (e.g. for different branches), and the codes are not unique across companies." + description: "(RU, КПП) Russian code issued by the tax authority, identifies the reason for registration at the Federal Tax Service. A company may have multiple KPP codes (e.g. for different branches), and the codes are not unique across companies." type: identifier matchable: false okvedCode: label: "OKVED(2) Classifier" - description: "Russian classifier that that categorizes businesses by their (primary and secondary) economic activities (Russian: ОКВЭД)" + description: "(RU, ОКВЭД) Russian classifier that categorizes businesses by their (primary and secondary) economic activities" matchable: false okopfCode: label: "OKOPF" - description: "Russian classifier that that categorizes different types of legal entities in Russia based on their organizational and legal structure (Russian: ОКОПФ)" + description: "(RU, ОКОПФ) Russian classifier that categorizes different types of legal entities in Russia based on their organizational and legal structure" matchable: false fnsCode: label: "Federal tax service code" @@ -92,16 +87,17 @@ Company: type: identifier pfrNumber: label: "PFR Number" - description: "(RU, ПФР) Pension Fund Registration number. AAA-BBB-CCCCCC, where AAA is organisation region, BBB is district, CCCCCC number at a specific branch" + description: "(RU, ПФР) Pension Fund Registration number. AAA-BBB-CCCCCC, where AAA is organisation region, BBB is district, and CCCCCC is the number at a specific branch." type: identifier oksmCode: label: OKSM - description: "Russian (ОКСМ) countries classifier" + description: "(RU, ОКСМ) Russian countries classifier" matchable: false isinCode: label: ISIN description: International Securities Identification Number type: identifier + deprecated: true ticker: label: Stock ticker symbol type: identifier diff --git a/schemas/4.5.0/Contract.yaml b/schemas/4.6.0/Contract.yaml similarity index 80% rename from schemas/4.5.0/Contract.yaml rename to schemas/4.6.0/Contract.yaml index 28be928..7386456 100644 --- a/schemas/4.5.0/Contract.yaml +++ b/schemas/4.6.0/Contract.yaml @@ -2,8 +2,8 @@ Contract: label: "Contract" plural: "Contracts" description: > - An contract or contract lot issued by an authority. Multiple lots - may be awarded to different suppliers (see ContractAward). + A contract or contract lot issued by an authority. Multiple lots + may be awarded to different suppliers (see `ContractAward`). extends: - Asset matchable: false @@ -42,8 +42,11 @@ Contract: range: Project type: label: "Type" - description: > - Type of contract. Potentially W (Works), U (Supplies), S (Services). + description: "Type of contract" + examples: + - W (Works) + - U (Supplies) + - S (Services) contractDate: label: "Contract date" type: date @@ -57,6 +60,9 @@ Contract: label: "Number of awards" status: label: "Status" + examples: + - In force + - Annulled method: label: "Procurement method" criteria: diff --git a/schemas/4.5.0/ContractAward.yaml b/schemas/4.6.0/ContractAward.yaml similarity index 100% rename from schemas/4.5.0/ContractAward.yaml rename to schemas/4.6.0/ContractAward.yaml diff --git a/schemas/4.5.0/CourtCase.yaml b/schemas/4.6.0/CourtCase.yaml similarity index 100% rename from schemas/4.5.0/CourtCase.yaml rename to schemas/4.6.0/CourtCase.yaml diff --git a/schemas/4.5.0/CourtCaseParty.yaml b/schemas/4.6.0/CourtCaseParty.yaml similarity index 100% rename from schemas/4.5.0/CourtCaseParty.yaml rename to schemas/4.6.0/CourtCaseParty.yaml diff --git a/schemas/4.5.0/CryptoWallet.yaml b/schemas/4.6.0/CryptoWallet.yaml similarity index 93% rename from schemas/4.5.0/CryptoWallet.yaml rename to schemas/4.6.0/CryptoWallet.yaml index fa73d6e..f36ccf3 100644 --- a/schemas/4.5.0/CryptoWallet.yaml +++ b/schemas/4.6.0/CryptoWallet.yaml @@ -20,6 +20,7 @@ CryptoWallet: - creationDate properties: publicKey: + # FIXME: this is a very unusual name for this. what do the bros call it??? label: Address description: Public key used to identify the wallet type: identifier diff --git a/schemas/4.5.0/Debt.yaml b/schemas/4.6.0/Debt.yaml similarity index 100% rename from schemas/4.5.0/Debt.yaml rename to schemas/4.6.0/Debt.yaml diff --git a/schemas/4.5.0/Directorship.yaml b/schemas/4.6.0/Directorship.yaml similarity index 92% rename from schemas/4.5.0/Directorship.yaml rename to schemas/4.6.0/Directorship.yaml index 2ac2c60..dc9d91d 100644 --- a/schemas/4.5.0/Directorship.yaml +++ b/schemas/4.6.0/Directorship.yaml @@ -25,6 +25,7 @@ Directorship: properties: director: label: "Director" + description: "The entity exercising control over another" reverse: name: directorshipDirector label: "Directorships" diff --git a/schemas/4.5.0/Document.yaml b/schemas/4.6.0/Document.yaml similarity index 100% rename from schemas/4.5.0/Document.yaml rename to schemas/4.6.0/Document.yaml diff --git a/schemas/4.5.0/Documentation.yaml b/schemas/4.6.0/Documentation.yaml similarity index 100% rename from schemas/4.5.0/Documentation.yaml rename to schemas/4.6.0/Documentation.yaml diff --git a/schemas/4.5.0/EconomicActivity.yaml b/schemas/4.6.0/EconomicActivity.yaml similarity index 98% rename from schemas/4.5.0/EconomicActivity.yaml rename to schemas/4.6.0/EconomicActivity.yaml index 0e687b7..05c8e5c 100644 --- a/schemas/4.5.0/EconomicActivity.yaml +++ b/schemas/4.6.0/EconomicActivity.yaml @@ -1,7 +1,7 @@ EconomicActivity: label: "Customs declaration" plural: "Customs declarations" - description: "A foreign economic activity" + description: "A foreign economic activity." matchable: false extends: - Interval diff --git a/schemas/4.5.0/Email.yaml b/schemas/4.6.0/Email.yaml similarity index 100% rename from schemas/4.5.0/Email.yaml rename to schemas/4.6.0/Email.yaml diff --git a/schemas/4.5.0/Employment.yaml b/schemas/4.6.0/Employment.yaml similarity index 100% rename from schemas/4.5.0/Employment.yaml rename to schemas/4.6.0/Employment.yaml diff --git a/schemas/4.5.0/Event.yaml b/schemas/4.6.0/Event.yaml similarity index 92% rename from schemas/4.5.0/Event.yaml rename to schemas/4.6.0/Event.yaml index ed4fca7..7ebde6e 100644 --- a/schemas/4.5.0/Event.yaml +++ b/schemas/4.6.0/Event.yaml @@ -22,9 +22,6 @@ Event: location: label: "Location" type: address - country: - label: "Country" - type: country important: label: "Important" organizer: diff --git a/schemas/4.5.0/Family.yaml b/schemas/4.6.0/Family.yaml similarity index 65% rename from schemas/4.5.0/Family.yaml rename to schemas/4.6.0/Family.yaml index 9127a7e..00ace99 100644 --- a/schemas/4.5.0/Family.yaml +++ b/schemas/4.6.0/Family.yaml @@ -1,7 +1,7 @@ Family: label: "Family" plural: "Family members" - description: "Family relationship between two people" + description: "Family relationship between two people." extends: - Interval matchable: false @@ -22,7 +22,7 @@ Family: properties: person: label: "Person" - description: "The subject of the familial relation." + description: "The subject of the familial relation" type: entity range: Person reverse: @@ -35,7 +35,10 @@ Family: reverse: name: familyRelative label: "Relatives" - description: "The relative of the subject person." + description: "The relative of the subject person" relationship: label: "Relationship" - description: "Nature of the relationship, from the person's perspective eg. 'mother', where 'relative' is mother of 'person'." + description: "Nature of the relationship from the `person`'s perspective, e.g. 'mother', where `relative` is the mother of `person`" + examples: + - mother + - sibling diff --git a/schemas/4.5.0/Folder.yaml b/schemas/4.6.0/Folder.yaml similarity index 100% rename from schemas/4.5.0/Folder.yaml rename to schemas/4.6.0/Folder.yaml diff --git a/schemas/4.5.0/HyperText.yaml b/schemas/4.6.0/HyperText.yaml similarity index 100% rename from schemas/4.5.0/HyperText.yaml rename to schemas/4.6.0/HyperText.yaml diff --git a/schemas/4.5.0/Identification.yaml b/schemas/4.6.0/Identification.yaml similarity index 69% rename from schemas/4.5.0/Identification.yaml rename to schemas/4.6.0/Identification.yaml index 71a77d0..c075cc0 100644 --- a/schemas/4.5.0/Identification.yaml +++ b/schemas/4.6.0/Identification.yaml @@ -2,8 +2,8 @@ Identification: label: "Identification" plural: "Identifications" description: > - An form of identification associated with its holder and some issuing country. This - can be used for national ID cards, voter enrollments and similar instruments. + A form of identification associated with its holder and some issuing country. This + can be used for national ID cards, voter enrollments, and similar instruments. extends: - Interval matchable: false @@ -29,6 +29,9 @@ Identification: name: identification type: label: "Type" + examples: + - Passport + - Driving license country: label: "Country" type: country @@ -38,3 +41,4 @@ Identification: maxLength: 64 authority: label: "Authority" + description: "Government body issuing the identification document" diff --git a/schemas/4.5.0/Image.yaml b/schemas/4.6.0/Image.yaml similarity index 91% rename from schemas/4.5.0/Image.yaml rename to schemas/4.6.0/Image.yaml index 5fb61c2..87b1c84 100644 --- a/schemas/4.5.0/Image.yaml +++ b/schemas/4.6.0/Image.yaml @@ -28,5 +28,5 @@ Image: range: Person credit: label: "Credit" - description: "The credit or attribution for the image." + description: "The credit or attribution for the image" type: string diff --git a/schemas/4.5.0/Interest.yaml b/schemas/4.6.0/Interest.yaml similarity index 100% rename from schemas/4.5.0/Interest.yaml rename to schemas/4.6.0/Interest.yaml diff --git a/schemas/4.5.0/Interval.yaml b/schemas/4.6.0/Interval.yaml similarity index 68% rename from schemas/4.5.0/Interval.yaml rename to schemas/4.6.0/Interval.yaml index 8e1abb5..9a6e240 100644 --- a/schemas/4.5.0/Interval.yaml +++ b/schemas/4.6.0/Interval.yaml @@ -4,7 +4,7 @@ Interval: # Intervals are not graph edges. # # Yes, many interval child schemata (e.g. Directorship, Ownership) can - # be interpreted as an edge between to Things. But that isn't intrinsic. + # be interpreted as an edge between two Things. But that isn't intrinsic. # If you write any code that assumes that Intervals == edges, it will # be buggy and wrong. You will find there are intervals that link to # only one thing (e.g. Sanction) or to much more than two (e.g. FEA). @@ -23,12 +23,15 @@ Interval: properties: startDate: label: "Start date" + description: "The date of issue of a document, or on which a relationship, sanctioned status, occupation, etc. started" type: date endDate: label: "End date" + description: "The date of expiry of a document, or on which a relationship, sanctioned status, occupation, etc. ended" type: date date: label: "Date" + description: "Date associated with an Interval that isn't explicitly its `startDate` or `endDate` (prefer those when available)" type: date summary: label: "Summary" @@ -38,8 +41,10 @@ Interval: type: text recordId: label: "Record ID" + description: Identifier of a record upon which this link is based sourceUrl: label: "Source link" + description: "A deep link to a source website for the profile" type: url matchable: false proof: @@ -74,8 +79,10 @@ Interval: type: text modifiedAt: label: "Modified on" + description: "The date on which the entity (like the ID document) was modified, not to be confused with an internal 'last updated'-style metadata field" type: date retrievedAt: label: "Retrieved on" + description: "Retrieval date generated by a data gathering system, not to be confused with an internal 'first found'-style metadata field" type: date matchable: false diff --git a/schemas/4.5.0/LegalEntity.yaml b/schemas/4.6.0/LegalEntity.yaml similarity index 68% rename from schemas/4.5.0/LegalEntity.yaml rename to schemas/4.6.0/LegalEntity.yaml index 823baeb..2c16673 100644 --- a/schemas/4.5.0/LegalEntity.yaml +++ b/schemas/4.6.0/LegalEntity.yaml @@ -6,7 +6,7 @@ LegalEntity: description: > Any party to legal proceedings, such as asset ownership, corporate governance or social interactions. Often used when raw data does not specify if something - is a person or company. + is a person, organization or company. matchable: true featured: - name @@ -37,7 +37,7 @@ LegalEntity: # TODO: is un-matchable wise? The idea is to handle it like `weakAlias` rather than `alias`. matchable: false email: - label: E-Mail + label: Email type: email description: "Email address" phone: @@ -51,7 +51,9 @@ LegalEntity: description: "Website address" legalForm: label: Legal form - # description: "" + description: "Company or organization type" + examples: + - Joint Stock Company matchable: false incorporationDate: label: Incorporation date @@ -63,19 +65,36 @@ LegalEntity: description: "The date the legal entity was dissolved, if applicable" taxStatus: label: Tax status - # description: "Tax status, eg. ??" + examples: + - Non-Habitual Resident + - Compliant as at March 2022 matchable: false status: label: Status - # description: "Status, eg. ??" + description: "A short string describing how 'active' (broadly defined) an entity is" + examples: + - Current / Former / Sitting / Retired + - Active / Inactive + - Dissolved (last known activity October 2024) + - Liquidated on 12 November 2022 matchable: false sector: label: Sector - # description: "Sector, eg. ??" + description: "Industrial or trade sector as provided by the data source" + examples: + - Registered Nurse + - Retail and wholesale + - Sea and coastal freight water transport matchable: false classification: + # OS note: We use this with PEPs to summarize their exposure. label: Classification - # description: "Classification, eg. ??" + description: "Classification as provided by the data source or inferred based on other provided data; prefer `sector` if relevant" + examples: + - Local government (current) + - Banking operations license + - 4. Priority Sector Apparel + - Entities Directly Serving the Defense and Security Sectors matchable: false registrationNumber: label: Registration number @@ -101,11 +120,11 @@ LegalEntity: jurisdiction: label: Jurisdiction type: country - description: "Country or region in which this entity operates" + description: "Country or region in which this entity operates; prefer over broader `country` when relevant" mainCountry: label: Country of origin type: country - description: "Primary country of this entity" + description: "Primary country of this entity; prefer over broader `country` when relevant" opencorporatesUrl: label: OpenCorporates URL type: url @@ -126,7 +145,7 @@ LegalEntity: uscCode: # cf. https://en.wikipedia.org/wiki/Unified_Social_Credit_Identifier label: "USCC" - description: "Unified Social Credit Identifier" + description: "Chinese Unified Social Credit Identifier" type: identifier format: uscc icijId: @@ -139,13 +158,13 @@ LegalEntity: matchable: false innCode: label: "INN" - description: "Russian tax identification number (Russian: ИНН). Issued to businesses and individuals in Russia" + description: "(RU, ИНН) Russian tax identification number. Issued to businesses and individuals in Russia." type: identifier format: inn maxLength: 32 ogrnCode: label: "OGRN" - description: "Identification number used in Russia's Unified State Register of Legal Entities (EGRUL) (Russian: ОГРН)" + description: "(RU, ОГРН) Registration number used in Russia's Unified State Register of Legal Entities (EGRUL)" type: identifier format: ogrn maxLength: 32 @@ -164,6 +183,9 @@ LegalEntity: uniqueEntityId: label: "Unique Entity ID" description: "UEI from SAM.gov" + # This is a scheme the US federal government (peace be upon its remains) introduced to replace + # DUNS numbers, which had previously been used as an ID in procurement. DUNS was basically killing + # them with license fees. type: identifier format: uei maxLength: 32 @@ -175,15 +197,16 @@ LegalEntity: maxLength: 16 swiftBic: label: "SWIFT/BIC" - description: "Bank identifier code" + description: "SWIFT Bank identifier code from ISO9362" + # OS note: BIC exist as bank codes (8 characters) and branch codes (11 characters). OpenSanctions + # currently cuts everything down to 8, meaning that all branches will match the same bank. type: identifier format: bic maxLength: 16 parent: - # Use `Ownership` link instead. deprecated: true label: "Parent company" - description: "If this entity is a subsidiary, another entity (company or organisation) is its parent" + description: "Deprecated, use `Ownership` link instead" reverse: label: "Subsidiaries" name: subsidiaries diff --git a/schemas/4.5.0/License.yaml b/schemas/4.6.0/License.yaml similarity index 85% rename from schemas/4.5.0/License.yaml rename to schemas/4.6.0/License.yaml index 84f19eb..7d48123 100644 --- a/schemas/4.5.0/License.yaml +++ b/schemas/4.6.0/License.yaml @@ -1,7 +1,7 @@ License: label: License plural: Licenses - description: "A grant of land, rights or property. A type of Contract" + description: "A grant of land, rights or property. A type of `Contract`." extends: - Contract matchable: false diff --git a/schemas/4.5.0/Membership.yaml b/schemas/4.6.0/Membership.yaml similarity index 100% rename from schemas/4.5.0/Membership.yaml rename to schemas/4.6.0/Membership.yaml diff --git a/schemas/4.5.0/Mention.yaml b/schemas/4.6.0/Mention.yaml similarity index 100% rename from schemas/4.5.0/Mention.yaml rename to schemas/4.6.0/Mention.yaml diff --git a/schemas/4.5.0/Message.yaml b/schemas/4.6.0/Message.yaml similarity index 100% rename from schemas/4.5.0/Message.yaml rename to schemas/4.6.0/Message.yaml diff --git a/schemas/4.5.0/Note.yaml b/schemas/4.6.0/Note.yaml similarity index 100% rename from schemas/4.5.0/Note.yaml rename to schemas/4.6.0/Note.yaml diff --git a/schemas/4.5.0/Occupancy.yaml b/schemas/4.6.0/Occupancy.yaml similarity index 68% rename from schemas/4.5.0/Occupancy.yaml rename to schemas/4.6.0/Occupancy.yaml index bc95e15..ca4c59b 100644 --- a/schemas/4.5.0/Occupancy.yaml +++ b/schemas/4.6.0/Occupancy.yaml @@ -44,8 +44,19 @@ Occupancy: range: Position declarationDate: label: "Declaration date" + description: "If established by an asset declaration" type: date matchable: false + constituency: + # https://www.popoloproject.com/specs/membership.html#classes-and-properties + label: "Constituency" + description: "The geographic area/distict represented by the holder" + politicalGroup: + label: "Political group" + description: "Caucus, faction or parliamentary group of the holder" status: label: "Status" + examples: + - current + - ended type: string diff --git a/schemas/4.5.0/Organization.yaml b/schemas/4.6.0/Organization.yaml similarity index 97% rename from schemas/4.5.0/Organization.yaml rename to schemas/4.6.0/Organization.yaml index 944ca4e..91821cd 100644 --- a/schemas/4.5.0/Organization.yaml +++ b/schemas/4.6.0/Organization.yaml @@ -4,7 +4,7 @@ Organization: label: Organization plural: Organizations description: > - Any type of incorporated entity that cannot be owned by another (see Company). This + Any type of incorporated entity that cannot be owned by another (see `Company`). This might include charities, foundations or state-owned enterprises, depending on their jurisdiction. matchable: true diff --git a/schemas/4.5.0/Ownership.yaml b/schemas/4.6.0/Ownership.yaml similarity index 91% rename from schemas/4.5.0/Ownership.yaml rename to schemas/4.6.0/Ownership.yaml index 951dc56..cb0effb 100644 --- a/schemas/4.5.0/Ownership.yaml +++ b/schemas/4.6.0/Ownership.yaml @@ -49,4 +49,8 @@ Ownership: label: "Legal basis" ownershipType: label: "Type of ownership" - # e.g. "beneficial", "direct", "indirect", "ultimate" + examples: + - beneficial + - direct + - indirect + - ultimate diff --git a/schemas/4.5.0/Package.yaml b/schemas/4.6.0/Package.yaml similarity index 100% rename from schemas/4.5.0/Package.yaml rename to schemas/4.6.0/Package.yaml diff --git a/schemas/4.5.0/Page.yaml b/schemas/4.6.0/Page.yaml similarity index 100% rename from schemas/4.5.0/Page.yaml rename to schemas/4.6.0/Page.yaml diff --git a/schemas/4.5.0/Pages.yaml b/schemas/4.6.0/Pages.yaml similarity index 100% rename from schemas/4.5.0/Pages.yaml rename to schemas/4.6.0/Pages.yaml diff --git a/schemas/4.5.0/Passport.yaml b/schemas/4.6.0/Passport.yaml similarity index 66% rename from schemas/4.5.0/Passport.yaml rename to schemas/4.6.0/Passport.yaml index f1e163d..526b74b 100644 --- a/schemas/4.5.0/Passport.yaml +++ b/schemas/4.6.0/Passport.yaml @@ -2,7 +2,7 @@ Passport: label: "Passport" plural: "Passports" description: > - An passport held by a person. + A passport held by a person. extends: - Identification matchable: false @@ -21,14 +21,19 @@ Passport: - number properties: passportNumber: - # FIXME: Use `number` from `Identification` instead!! label: "Passport number" + description: "Deprecated, use `Identification:number` instead" + deprecated: true type: identifier hidden: true surname: label: "Surname" + description: "Deprecated, use `Identification:holder` link's `lastName` instead" + deprecated: true givenName: label: "Given name" + description: "Deprecated, use `Identification:holder` link's `firstName` / `middleName` instead" + deprecated: true birthDate: label: "Birth date" type: date diff --git a/schemas/4.5.0/Payment.yaml b/schemas/4.6.0/Payment.yaml similarity index 100% rename from schemas/4.5.0/Payment.yaml rename to schemas/4.6.0/Payment.yaml diff --git a/schemas/4.5.0/Person.yaml b/schemas/4.6.0/Person.yaml similarity index 84% rename from schemas/4.5.0/Person.yaml rename to schemas/4.6.0/Person.yaml index f2e11b7..e775e7e 100644 --- a/schemas/4.5.0/Person.yaml +++ b/schemas/4.6.0/Person.yaml @@ -38,7 +38,7 @@ Person: description: "The part of a name that indicates the person, also often called given name or forename" secondName: label: Second name - description: "Deprecated, use one of the other more specific name properties instead." + description: "Deprecated, use one of the other more specific name properties instead" deprecated: true middleName: label: Middle name @@ -54,6 +54,8 @@ Person: description: "The part of a name that indicates one's family, also often called surname or family name" nameSuffix: label: Name suffix + examples: + - OBE birthDate: label: Birth date type: date @@ -61,13 +63,19 @@ Person: label: Place of birth birthCountry: label: Country of birth + # nb. Sometimes a territory which is historical, eg. Soviet Union, Yugoslavia, Zaire. type: country deathDate: label: Death date + description: Joined the choir invisible. type: date position: label: Position matchable: false + # OS note: the distinction between nationality and citizenship is pretty fine, the two props + # exist mainly so that we can preserve the distinction if it exists in source data. + # Nationality is a broader concept of being "of a country", citizenship narrower (as in holding + # the passport and/or right to vote). nationality: label: Nationality type: country diff --git a/schemas/4.5.0/PlainText.yaml b/schemas/4.6.0/PlainText.yaml similarity index 100% rename from schemas/4.5.0/PlainText.yaml rename to schemas/4.6.0/PlainText.yaml diff --git a/schemas/4.5.0/Position.yaml b/schemas/4.6.0/Position.yaml similarity index 73% rename from schemas/4.5.0/Position.yaml rename to schemas/4.6.0/Position.yaml index 7d1f018..de59701 100644 --- a/schemas/4.5.0/Position.yaml +++ b/schemas/4.6.0/Position.yaml @@ -9,12 +9,7 @@ Position: A post, role or position within an organization or body. This describes a position one or more people may occupy and not the occupation of the post by a specific individual at a - specific point in time. - - 'subnationalArea' should be used to further restrict the scope of the - position. It should not simply represent some regional aspect of the - role - e.g. the constituency of a national member of parliament - when - their legislative jurisdiction is nationwide. + specific point in time (see `Occupancy`). featured: - name - country @@ -43,7 +38,8 @@ Position: label: Dissolution date type: date subnationalArea: - label: Subnational jurisdiction name or code + label: Subnational area + description: "The name or code of a subnational jurisdiction, only when the position is geographically limited. Prefer `Occupancy:constituency` where relevant." type: string numberOfSeats: label: Total number of seats diff --git a/schemas/4.5.0/Project.yaml b/schemas/4.6.0/Project.yaml similarity index 87% rename from schemas/4.5.0/Project.yaml rename to schemas/4.6.0/Project.yaml index 4fa77a9..50180e7 100644 --- a/schemas/4.5.0/Project.yaml +++ b/schemas/4.6.0/Project.yaml @@ -6,7 +6,7 @@ Project: - Thing - Value description: > - An activity carried out by a group of participants. + An activity carried out by a group of `participants`. matchable: false featured: - name diff --git a/schemas/4.5.0/ProjectParticipant.yaml b/schemas/4.6.0/ProjectParticipant.yaml similarity index 92% rename from schemas/4.5.0/ProjectParticipant.yaml rename to schemas/4.6.0/ProjectParticipant.yaml index d4e0ae2..5160b53 100644 --- a/schemas/4.5.0/ProjectParticipant.yaml +++ b/schemas/4.6.0/ProjectParticipant.yaml @@ -4,7 +4,7 @@ ProjectParticipant: extends: - Interest description: > - An activity carried out by a group of participants. + A participant in a `Project`. matchable: false featured: - project diff --git a/schemas/4.5.0/PublicBody.yaml b/schemas/4.6.0/PublicBody.yaml similarity index 100% rename from schemas/4.5.0/PublicBody.yaml rename to schemas/4.6.0/PublicBody.yaml diff --git a/schemas/4.5.0/RealEstate.yaml b/schemas/4.6.0/RealEstate.yaml similarity index 100% rename from schemas/4.5.0/RealEstate.yaml rename to schemas/4.6.0/RealEstate.yaml diff --git a/schemas/4.5.0/Representation.yaml b/schemas/4.6.0/Representation.yaml similarity index 100% rename from schemas/4.5.0/Representation.yaml rename to schemas/4.6.0/Representation.yaml diff --git a/schemas/4.5.0/Risk.yaml b/schemas/4.6.0/Risk.yaml similarity index 93% rename from schemas/4.5.0/Risk.yaml rename to schemas/4.6.0/Risk.yaml index d9e771e..b15a91e 100644 --- a/schemas/4.5.0/Risk.yaml +++ b/schemas/4.6.0/Risk.yaml @@ -1,7 +1,7 @@ Risk: label: Risk plural: Risks - description: "A risk associated with an entity" + description: "A risk associated with an entity." extends: - Interval matchable: false diff --git a/schemas/4.5.0/Sanction.yaml b/schemas/4.6.0/Sanction.yaml similarity index 71% rename from schemas/4.5.0/Sanction.yaml rename to schemas/4.6.0/Sanction.yaml index 189afa2..d3a7457 100644 --- a/schemas/4.5.0/Sanction.yaml +++ b/schemas/4.6.0/Sanction.yaml @@ -1,7 +1,7 @@ Sanction: label: Sanction plural: Sanctions - description: "A sanction designation" + description: "A sanction designation." extends: - Interval matchable: false @@ -27,9 +27,11 @@ Sanction: label: "Authority" authorityId: label: "Authority-issued identifier" + # eg. OFAC IDs, FCDO IDs, etc. type: identifier unscId: label: "UN SC identifier" + description: "Identifier issued by the UN Security Council for sanctions designations" type: identifier maxLength: 16 program: @@ -47,15 +49,22 @@ Sanction: label: "Scope of sanctions" status: label: "Status" + examples: + - Active + - Inactive + - Expired + - Suspended duration: label: "Duration" type: number reason: label: "Reason" + description: An explanation of the designation's justification. type: text country: label: "Country" type: country listingDate: label: "Listing date" + description: "The date on which the designation is listed; distinct from the `startDate`, which is the date on which the designation goes into effect" type: date diff --git a/schemas/4.5.0/Security.yaml b/schemas/4.6.0/Security.yaml similarity index 100% rename from schemas/4.5.0/Security.yaml rename to schemas/4.6.0/Security.yaml diff --git a/schemas/4.5.0/Similar.yaml b/schemas/4.6.0/Similar.yaml similarity index 100% rename from schemas/4.5.0/Similar.yaml rename to schemas/4.6.0/Similar.yaml diff --git a/schemas/4.5.0/Succession.yaml b/schemas/4.6.0/Succession.yaml similarity index 100% rename from schemas/4.5.0/Succession.yaml rename to schemas/4.6.0/Succession.yaml diff --git a/schemas/4.5.0/Table.yaml b/schemas/4.6.0/Table.yaml similarity index 100% rename from schemas/4.5.0/Table.yaml rename to schemas/4.6.0/Table.yaml diff --git a/schemas/4.5.0/TaxRoll.yaml b/schemas/4.6.0/TaxRoll.yaml similarity index 92% rename from schemas/4.5.0/TaxRoll.yaml rename to schemas/4.6.0/TaxRoll.yaml index 406a5c6..7557546 100644 --- a/schemas/4.5.0/TaxRoll.yaml +++ b/schemas/4.6.0/TaxRoll.yaml @@ -1,7 +1,7 @@ TaxRoll: label: "Tax roll" plural: "Tax rolls" - description: "A tax declaration of an individual" + description: "A tax declaration of an individual." extends: - Interval icon: fa-bank diff --git a/schemas/4.5.0/Thing.yaml b/schemas/4.6.0/Thing.yaml similarity index 62% rename from schemas/4.5.0/Thing.yaml rename to schemas/4.6.0/Thing.yaml index 10880a5..34b0a94 100644 --- a/schemas/4.5.0/Thing.yaml +++ b/schemas/4.6.0/Thing.yaml @@ -13,29 +13,42 @@ Thing: properties: name: label: Name + description: "The primary name of the entity" type: name - summary: # a short one-liner kind of description - label: Summary - type: text - description: # a longer description - label: Description - type: text - country: - label: Country - type: country alias: label: Alias + description: "An alternative or secondary name" type: name previousName: label: Previous name + description: "A former name of the entity" type: name weakAlias: label: Weak alias type: name description: "A relatively broad or generic alias that should not be used for matching in screening systems. It may still may be useful for identification purposes, particularly in confirming a possible match triggered by other identifier information." matchable: false + country: + label: Country + description: "An association between the entity and a country that is not covered by a more specific property (e.g. `jurisdiction`, `birthCountry`, `mainCountry`)" + type: country + summary: + label: Summary + description: "A short one-liner description; see also `description`, `notes`" + type: text + # OS notes: discouraged in favor of `notes` in most cases. + notes: + label: Notes + description: "Narrative description of the entity; see also `description`, `summary`" + type: text + description: + label: Description + description: "A longer description; see also `notes`, `summary`" + type: text + # OS notes: discouraged in favor of `notes` in most cases. sourceUrl: label: Source link + description: "A deep link to a source website for the profile" type: url matchable: false publisher: @@ -58,16 +71,26 @@ Thing: type: identifier format: wikidata maxLength: 32 + examples: + - Q7747 keywords: label: Keywords + description: "Plain text keywords provided for the entity; prefer more specific `type`, `status`, etc. as appropriate" topics: label: Topics + description: "Controlled tags used to qualify the entity and associate it with a risk category" + examples: + - sanction + - debarment + - role.pep type: topic address: label: Address + description: "A textual description of an address linked to the entity" type: address addressEntity: label: Address + description: "A reference to an `Address` entity with structured place information" reverse: name: things label: "Located there" @@ -75,7 +98,7 @@ Thing: range: Address program: # Used by sanctions label: Program - description: Regulatory program or sanctions list on which an entity is listed. + description: Regulatory program or sanctions list on which an entity is listed programId: # This is a unique identifier for the program issued by OpenSanctions, but # could also be used for authority-issued IDs in other usage scenarios. @@ -84,9 +107,6 @@ Thing: maxLength: 64 hidden: true matchable: false - notes: - label: Notes - type: text proof: label: Source document reverse: @@ -104,13 +124,16 @@ Thing: type: text createdAt: label: "Created at" + description: "The date on which the entity was created, not to be confused with an internal 'first saved'-style metadata field" type: date matchable: false modifiedAt: label: "Modified on" + description: "The date on which the entity was modified, not to be confused with an internal 'last updated'-style metadata field" type: date matchable: false retrievedAt: label: "Retrieved on" + description: "Retrieval date generated by a data gathering system, not to be confused with an internal 'first found'-style metadata field" type: date matchable: false diff --git a/schemas/4.5.0/Trip.yaml b/schemas/4.6.0/Trip.yaml similarity index 100% rename from schemas/4.5.0/Trip.yaml rename to schemas/4.6.0/Trip.yaml diff --git a/schemas/4.5.0/UnknownLink.yaml b/schemas/4.6.0/UnknownLink.yaml similarity index 100% rename from schemas/4.5.0/UnknownLink.yaml rename to schemas/4.6.0/UnknownLink.yaml diff --git a/schemas/4.5.0/UserAccount.yaml b/schemas/4.6.0/UserAccount.yaml similarity index 97% rename from schemas/4.5.0/UserAccount.yaml rename to schemas/4.6.0/UserAccount.yaml index 6d5f8e9..eb9731d 100644 --- a/schemas/4.5.0/UserAccount.yaml +++ b/schemas/4.6.0/UserAccount.yaml @@ -28,7 +28,7 @@ UserAccount: label: "Service" type: string email: - label: E-Mail + label: Email type: email description: "Email address" phone: diff --git a/schemas/4.5.0/Value.yaml b/schemas/4.6.0/Value.yaml similarity index 100% rename from schemas/4.5.0/Value.yaml rename to schemas/4.6.0/Value.yaml diff --git a/schemas/4.5.0/Vehicle.yaml b/schemas/4.6.0/Vehicle.yaml similarity index 90% rename from schemas/4.5.0/Vehicle.yaml rename to schemas/4.6.0/Vehicle.yaml index 3c5ec80..591314f 100644 --- a/schemas/4.5.0/Vehicle.yaml +++ b/schemas/4.6.0/Vehicle.yaml @@ -25,12 +25,14 @@ Vehicle: type: identifier type: label: Type + examples: + - Bulk carrier model: label: Model owner: - # Use `Ownership` link instead. deprecated: true label: Owner + description: "Deprecated, use `Ownership` link instead" type: entity range: LegalEntity reverse: diff --git a/schemas/4.5.0/Vessel.yaml b/schemas/4.6.0/Vessel.yaml similarity index 94% rename from schemas/4.5.0/Vessel.yaml rename to schemas/4.6.0/Vessel.yaml index f1316cd..1a87bbf 100644 --- a/schemas/4.5.0/Vessel.yaml +++ b/schemas/4.6.0/Vessel.yaml @@ -40,6 +40,7 @@ Vessel: type: number deadweightTonnage: label: Deadweight Tonnage + description: "Weight of the vessel when not carrying freight" type: number nameChangeDate: label: Date of Name Change @@ -52,8 +53,6 @@ Vessel: type: country pastTypes: label: Past Types - #buildDate: - # label: Build Date mmsi: label: MMSI type: identifier diff --git a/schemas/4.5.0/Video.yaml b/schemas/4.6.0/Video.yaml similarity index 100% rename from schemas/4.5.0/Video.yaml rename to schemas/4.6.0/Video.yaml diff --git a/schemas/4.5.0/Workbook.yaml b/schemas/4.6.0/Workbook.yaml similarity index 100% rename from schemas/4.5.0/Workbook.yaml rename to schemas/4.6.0/Workbook.yaml diff --git a/src/generated/entities.rs b/src/generated/entities.rs index 32779d8..817142e 100644 --- a/src/generated/entities.rs +++ b/src/generated/entities.rs @@ -3490,12 +3490,13 @@ pub struct Company { )] pub cage_code: Option>, ///Property: Capital - #[serde(skip_serializing_if = "Option::is_none")] - #[cfg_attr( - feature = "builder", - builder(with = |value:impl Into|vec![value.into()]) + #[serde( + skip_serializing_if = "Option::is_none", + deserialize_with = "deserialize_opt_f64_vec", + default )] - pub capital: Option>, + #[cfg_attr(feature = "builder", builder(with = |value:f64|vec![value]))] + pub capital: Option>, ///Property: SEC Central Index Key #[serde(skip_serializing_if = "Option::is_none")] #[cfg_attr( @@ -3559,7 +3560,7 @@ pub struct Company { builder(with = |value:impl Into|vec![value.into()]) )] pub duns_code: Option>, - ///Property: E-Mail + ///Property: Email #[serde(skip_serializing_if = "Option::is_none")] #[cfg_attr( feature = "builder", @@ -10381,7 +10382,7 @@ pub struct LegalEntity { builder(with = |value:impl Into|vec![value.into()]) )] pub duns_code: Option>, - ///Property: E-Mail + ///Property: Email #[serde(skip_serializing_if = "Option::is_none")] #[cfg_attr( feature = "builder", @@ -12463,6 +12464,13 @@ pub struct Occupancy { builder(with = |value:impl Into|vec![value.into()]) )] pub aleph_url: Option>, + ///Property: Constituency + #[serde(skip_serializing_if = "Option::is_none")] + #[cfg_attr( + feature = "builder", + builder(with = |value:impl Into|vec![value.into()]) + )] + pub constituency: Option>, ///Property: Date #[serde(skip_serializing_if = "Option::is_none")] #[cfg_attr( @@ -12519,6 +12527,13 @@ pub struct Occupancy { builder(with = |value:impl Into|vec![value.into()]) )] pub names_mentioned: Option>, + ///Property: Political group + #[serde(skip_serializing_if = "Option::is_none")] + #[cfg_attr( + feature = "builder", + builder(with = |value:impl Into|vec![value.into()]) + )] + pub political_group: Option>, ///Property: Position occupied #[serde(default)] #[cfg_attr( @@ -12598,6 +12613,7 @@ impl Occupancy { id: id.into(), schema: "Occupancy".to_string(), aleph_url: None, + constituency: None, date: None, declaration_date: None, description: None, @@ -12606,6 +12622,7 @@ impl Occupancy { index_text: None, modified_at: None, names_mentioned: None, + political_group: None, post: Vec::new(), proof: None, publisher: None, @@ -12755,7 +12772,7 @@ pub struct Organization { builder(with = |value:impl Into|vec![value.into()]) )] pub duns_code: Option>, - ///Property: E-Mail + ///Property: Email #[serde(skip_serializing_if = "Option::is_none")] #[cfg_attr( feature = "builder", @@ -15265,7 +15282,7 @@ pub struct Person { builder(with = |value:impl Into|vec![value.into()]) )] pub education: Option>, - ///Property: E-Mail + ///Property: Email #[serde(skip_serializing_if = "Option::is_none")] #[cfg_attr( feature = "builder", @@ -16550,7 +16567,7 @@ pub struct Position { builder(with = |value:impl Into|vec![value.into()]) )] pub source_url: Option>, - ///Property: Subnational jurisdiction name or code + ///Property: Subnational area #[serde(skip_serializing_if = "Option::is_none")] #[cfg_attr( feature = "builder", @@ -17312,7 +17329,7 @@ pub struct PublicBody { builder(with = |value:impl Into|vec![value.into()]) )] pub duns_code: Option>, - ///Property: E-Mail + ///Property: Email #[serde(skip_serializing_if = "Option::is_none")] #[cfg_attr( feature = "builder", @@ -20866,7 +20883,7 @@ pub struct UserAccount { builder(with = |value:impl Into|vec![value.into()]) )] pub description: Option>, - ///Property: E-Mail + ///Property: Email #[serde(skip_serializing_if = "Option::is_none")] #[cfg_attr( feature = "builder",