diff --git a/frameworks/fac/packages/fac-traits/v1/taxonomy.jsonld b/frameworks/fac/packages/fac-traits/v1/taxonomy.jsonld index 3d9aa8eae..9258996ca 100644 --- a/frameworks/fac/packages/fac-traits/v1/taxonomy.jsonld +++ b/frameworks/fac/packages/fac-traits/v1/taxonomy.jsonld @@ -345,7 +345,7 @@ "format": "XBRL metamodel (traits + domains + members)" }, "forked_at": "2026-04-20", - "description": "Universal accounting-element trait vocabulary — 24 orthogonal classification axes (elementsOfFinancialStatements, liquidity, activityType, operatingNonoperating, recordedValue, realizationStatus, hedging, leaseType, …) covering 95 trait members, plus the flowClassification axis (inflow/outflow/accrual/contra) derived from FASB's instant-* arcroles. Seeds the `traits` table — each member is a (category, identifier) pair. Forked from the FASB us-gaap 2026 metamodel; the axes themselves describe how *any* accounting element gets classified, not just us-gaap, so the vocabulary lives in the fac framework as the dependency root and is inherited by every rs-* curation that depends on fac. Per-element trait bindings (seeding the `element_traits` junction) live in each framework's `*-traits/v1/` package — today: `rs-gaap-traits/v1/`.", + "description": "Universal accounting-element trait vocabulary — 24 orthogonal classification axes (elementsOfFinancialStatements, liquidity, activityType, operatingNonoperating, recordedValue, realizationStatus, hedging, leaseType, …) covering 95 trait members, plus the flowClassification axis (inflow/outflow/accrual/contra) derived from FASB's instant-* arcroles, plus the RS analytical-extension axis `recurrence` (nonrecurring) for earnings-persistence / NOPAT normalization — 26 categories, 100 members in total. Seeds the `traits` table — each member is a (category, identifier) pair. Forked from the FASB us-gaap 2026 metamodel; the axes themselves describe how *any* accounting element gets classified, not just us-gaap, so the vocabulary lives in the fac framework as the dependency root and is inherited by every rs-* curation that depends on fac. Per-element trait bindings (seeding the `element_traits` junction) live in each framework's `*-traits/v1/` package — today: `rs-gaap-traits/v1/`.", "@graph": [ { "@id": "trait:statisticalMeasurement/arithmeticAverage", @@ -1747,6 +1747,31 @@ } ] }, + { + "@id": "trait:recurrence/nonrecurring", + "@type": "rs:Trait", + "https://robosystems.ai/vocab/category": [ + { + "@value": "recurrence" + } + ], + "https://robosystems.ai/vocab/identifier": [ + { + "@value": "nonrecurring" + } + ], + "https://robosystems.ai/vocab/source": [ + { + "@value": "fac-traits" + } + ], + "rdfs:label": [ + { + "@value": "nonrecurring", + "@language": "en" + } + ] + }, { "@id": "trait:recordedValue/reportedAtFairValue", "@type": "rs:Trait", diff --git a/frameworks/rs-gaap/bridges/fac-to-rs-gaap/v1/taxonomy.jsonld b/frameworks/rs-gaap/bridges/fac-to-rs-gaap/v1/taxonomy.jsonld index faa3681a9..f527fdb27 100644 --- a/frameworks/rs-gaap/bridges/fac-to-rs-gaap/v1/taxonomy.jsonld +++ b/frameworks/rs-gaap/bridges/fac-to-rs-gaap/v1/taxonomy.jsonld @@ -474,6 +474,9 @@ }, { "@id": "rs-gaap:TechnologyServicesCosts" + }, + { + "@id": "rs-gaap:OtherCostOfOperatingRevenue" } ] }, @@ -515,6 +518,30 @@ "http://www.w3.org/2002/07/owl#equivalentClass": [ { "@id": "rs-gaap:AssetsCurrent" + }, + { + "@id": "rs-gaap:CashAndCashEquivalentsAtCarryingValue" + }, + { + "@id": "rs-gaap:InventoryNetOfAllowancesCustomerAdvancesAndProgressBillings" + }, + { + "@id": "rs-gaap:OtherAssetsCurrent" + }, + { + "@id": "rs-gaap:PrepaidExpenseCurrent" + }, + { + "@id": "rs-gaap:ReceivablesNetCurrent" + }, + { + "@id": "rs-gaap:RestrictedCashAndInvestmentsCurrent" + }, + { + "@id": "rs-gaap:ShortTermInvestments" + }, + { + "@id": "rs-gaap:CashCashEquivalentsAndShortTermInvestments" } ] }, @@ -523,6 +550,30 @@ "http://www.w3.org/2002/07/owl#equivalentClass": [ { "@id": "rs-gaap:LiabilitiesCurrent" + }, + { + "@id": "rs-gaap:AccountsPayableCurrent" + }, + { + "@id": "rs-gaap:AccruedLiabilitiesCurrent" + }, + { + "@id": "rs-gaap:DebtCurrent" + }, + { + "@id": "rs-gaap:DeferredRevenueCurrent" + }, + { + "@id": "rs-gaap:FinanceLeaseLiabilityCurrent" + }, + { + "@id": "rs-gaap:OtherLiabilitiesCurrent" + }, + { + "@id": "rs-gaap:AccountsPayableAndAccruedLiabilitiesCurrent" + }, + { + "@id": "rs-gaap:LongTermDebtAndCapitalLeaseObligationsCurrent" } ] }, @@ -589,6 +640,24 @@ }, { "@id": "rs-gaap:StockholdersEquity" + }, + { + "@id": "rs-gaap:AccumulatedOtherComprehensiveIncomeLossNetOfTax" + }, + { + "@id": "rs-gaap:AdditionalPaidInCapital" + }, + { + "@id": "rs-gaap:CommonStockValue" + }, + { + "@id": "rs-gaap:PreferredStockValue" + }, + { + "@id": "rs-gaap:RetainedEarningsAccumulatedDeficit" + }, + { + "@id": "rs-gaap:TreasuryStockValue" } ] }, @@ -961,6 +1030,45 @@ "http://www.w3.org/2002/07/owl#equivalentClass": [ { "@id": "rs-gaap:NetCashProvidedByUsedInFinancingActivities" + }, + { + "@id": "rs-gaap:PaymentsForRepurchaseOfCommonStock" + }, + { + "@id": "rs-gaap:ProceedsFromIssuanceOfCommonStock" + }, + { + "@id": "rs-gaap:ProceedsFromIssuanceOfLongTermDebt" + }, + { + "@id": "rs-gaap:RepaymentsOfLongTermDebt" + }, + { + "@id": "rs-gaap:PaymentsForRepurchaseOfEquity" + }, + { + "@id": "rs-gaap:ProceedsFromIssuanceOfLongTermDebtAndCapitalSecuritiesNet" + }, + { + "@id": "rs-gaap:ProceedsFromIssuanceOrSaleOfEquity" + }, + { + "@id": "rs-gaap:ProceedsFromRepaymentsOfDebt" + }, + { + "@id": "rs-gaap:ProceedsFromRepaymentsOfLongTermDebtAndCapitalSecurities" + }, + { + "@id": "rs-gaap:ProceedsFromRepurchaseOfEquity" + }, + { + "@id": "rs-gaap:RepaymentsOfLongTermDebtAndCapitalSecurities" + }, + { + "@id": "rs-gaap:PaymentsOfDividends" + }, + { + "@id": "rs-gaap:ProceedsFromPartnershipContribution" } ] }, @@ -985,6 +1093,36 @@ "http://www.w3.org/2002/07/owl#equivalentClass": [ { "@id": "rs-gaap:NetCashProvidedByUsedInInvestingActivities" + }, + { + "@id": "rs-gaap:PaymentsToAcquireIntangibleAssets" + }, + { + "@id": "rs-gaap:PaymentsToAcquireInvestments" + }, + { + "@id": "rs-gaap:PaymentsToAcquirePropertyPlantAndEquipment" + }, + { + "@id": "rs-gaap:ProceedsFromSaleMaturityAndCollectionsOfInvestments" + }, + { + "@id": "rs-gaap:ProceedsFromSaleOfIntangibleAssets" + }, + { + "@id": "rs-gaap:ProceedsFromSaleOfPropertyPlantAndEquipment" + }, + { + "@id": "rs-gaap:PaymentsForProceedsFromInvestments" + }, + { + "@id": "rs-gaap:PaymentsForProceedsFromProductiveAssets" + }, + { + "@id": "rs-gaap:PaymentsToAcquireProductiveAssets" + }, + { + "@id": "rs-gaap:ProceedsFromSaleOfProductiveAssets" } ] }, @@ -1009,6 +1147,60 @@ "http://www.w3.org/2002/07/owl#equivalentClass": [ { "@id": "rs-gaap:NetCashProvidedByUsedInOperatingActivities" + }, + { + "@id": "rs-gaap:DepreciationDepletionAndAmortization" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInAccountsPayableAndAccruedLiabilities" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInAccountsReceivable" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInAccruedIncomeTaxesPayable" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInAccruedLiabilities" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInInventories" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInOtherOperatingCapitalNet" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInPrepaidExpense" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInAccountsAndNotesReceivable" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInAccruedTaxesPayable" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInOperatingAssets" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInOperatingCapital" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInOperatingLiabilities" + }, + { + "@id": "rs-gaap:IncreaseDecreaseInReceivables" + }, + { + "@id": "rs-gaap:AdjustmentsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivities" + }, + { + "@id": "rs-gaap:AdjustmentsNoncashItemsToReconcileNetIncomeLossToCashProvidedByUsedInOperatingActivities" + }, + { + "@id": "rs-gaap:ShareBasedCompensation" + }, + { + "@id": "rs-gaap:EmployeeBenefitsAndShareBasedCompensationNoncash" } ] }, @@ -1116,6 +1308,33 @@ "http://www.w3.org/2002/07/owl#equivalentClass": [ { "@id": "rs-gaap:AssetsNoncurrent" + }, + { + "@id": "rs-gaap:FinanceLeaseRightOfUseAsset" + }, + { + "@id": "rs-gaap:Goodwill" + }, + { + "@id": "rs-gaap:IntangibleAssetsNetExcludingGoodwill" + }, + { + "@id": "rs-gaap:IntangibleAssetsNetIncludingGoodwill" + }, + { + "@id": "rs-gaap:LongTermInvestmentsAndReceivablesNet" + }, + { + "@id": "rs-gaap:OperatingLeaseRightOfUseAsset" + }, + { + "@id": "rs-gaap:OtherAssetsNoncurrent" + }, + { + "@id": "rs-gaap:PropertyPlantAndEquipmentGross" + }, + { + "@id": "rs-gaap:AccumulatedDepreciationDepletionAndAmortizationPropertyPlantAndEquipment" } ] }, @@ -1124,6 +1343,21 @@ "http://www.w3.org/2002/07/owl#equivalentClass": [ { "@id": "rs-gaap:LiabilitiesNoncurrent" + }, + { + "@id": "rs-gaap:DeferredIncomeTaxLiabilitiesNet" + }, + { + "@id": "rs-gaap:DeferredRevenueNoncurrent" + }, + { + "@id": "rs-gaap:OperatingLeaseLiabilityNoncurrent" + }, + { + "@id": "rs-gaap:OtherLiabilitiesNoncurrent" + }, + { + "@id": "rs-gaap:LiabilitiesOtherThanLongtermDebtNoncurrent" } ] }, @@ -1162,6 +1396,36 @@ "http://www.w3.org/2002/07/owl#equivalentClass": [ { "@id": "rs-gaap:NonoperatingIncomeExpense" + }, + { + "@id": "rs-gaap:ForeignCurrencyTransactionGainLossBeforeTax" + }, + { + "@id": "rs-gaap:GainLossOnDispositionOfAssets" + }, + { + "@id": "rs-gaap:GainLossOnDispositionOfAssets1" + }, + { + "@id": "rs-gaap:GainLossOnSaleOfPropertyPlantEquipment" + }, + { + "@id": "rs-gaap:GainsLossesOnExtinguishmentOfDebt" + }, + { + "@id": "rs-gaap:InvestmentIncomeInterest" + }, + { + "@id": "rs-gaap:OtherNonoperatingIncomeExpense" + }, + { + "@id": "rs-gaap:InvestmentIncomeInterestAndDividend" + }, + { + "@id": "rs-gaap:InvestmentIncomeNet" + }, + { + "@id": "rs-gaap:InvestmentIncomeNonoperating" } ] }, @@ -1358,6 +1622,30 @@ }, { "@id": "rs-gaap:UtilitiesOperatingExpense" + }, + { + "@id": "rs-gaap:AssetImpairmentCharges" + }, + { + "@id": "rs-gaap:OtherCostAndExpenseOperating" + }, + { + "@id": "rs-gaap:ResearchAndDevelopmentExpense" + }, + { + "@id": "rs-gaap:RestructuringCharges" + }, + { + "@id": "rs-gaap:SellingAndMarketingExpense" + }, + { + "@id": "rs-gaap:RestructuringCosts" + }, + { + "@id": "rs-gaap:RestructuringCostsAndAssetImpairmentCharges" + }, + { + "@id": "rs-gaap:RestructuringSettlementAndImpairmentProvisions" } ] }, diff --git a/frameworks/rs-gaap/packages/rs-gaap-traits/v1/taxonomy.jsonld b/frameworks/rs-gaap/packages/rs-gaap-traits/v1/taxonomy.jsonld index 5aec74c21..874bf3b10 100644 --- a/frameworks/rs-gaap/packages/rs-gaap-traits/v1/taxonomy.jsonld +++ b/frameworks/rs-gaap/packages/rs-gaap-traits/v1/taxonomy.jsonld @@ -1723,6 +1723,12 @@ { "@id": "rs-gaap:AssetImpairmentCharges", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:recurrence/nonrecurring" + }, + { + "@id": "trait:use/remeasurement" + }, { "@id": "trait:elementsOfFinancialStatements/loss" }, @@ -5732,6 +5738,9 @@ { "@id": "rs-gaap:GainLossOnDispositionOfAssets", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:recurrence/nonrecurring" + }, { "@id": "trait:elementsOfFinancialStatements/gain" }, @@ -5746,6 +5755,9 @@ { "@id": "rs-gaap:GainLossOnDispositionOfAssets1", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:recurrence/nonrecurring" + }, { "@id": "trait:elementsOfFinancialStatements/gain" }, @@ -6029,6 +6041,9 @@ { "@id": "rs-gaap:GainLossOnSaleOfPropertyPlantEquipment", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:recurrence/nonrecurring" + }, { "@id": "trait:elementsOfFinancialStatements/gain" }, @@ -6200,6 +6215,9 @@ { "@id": "rs-gaap:GainsLossesOnExtinguishmentOfDebt", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:recurrence/nonrecurring" + }, { "@id": "trait:elementsOfFinancialStatements/gain" }, @@ -6895,6 +6913,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInAccountsAndNotesReceivable", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -6911,6 +6932,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInAccountsPayableAndAccruedLiabilities", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -6943,6 +6967,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInAccountsReceivable", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -6975,6 +7002,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInAccruedIncomeTaxesPayable", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -6999,6 +7029,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInAccruedLiabilities", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -7015,6 +7048,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInAccruedTaxesPayable", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -7593,6 +7629,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInInventories", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -7745,6 +7784,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInOperatingAssets", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -7753,6 +7795,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInOperatingCapital", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -7761,6 +7806,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInOperatingLiabilities", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -7911,6 +7959,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInOtherOperatingCapitalNet", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -8055,6 +8106,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInPrepaidExpense", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -8151,6 +8205,9 @@ { "@id": "rs-gaap:IncreaseDecreaseInReceivables", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:indirectCashFlowReconcilingItem/indirectCashFlowMethodReconcilingItem" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -18466,6 +18523,9 @@ { "@id": "rs-gaap:RestructuringCharges", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:recurrence/nonrecurring" + }, { "@id": "trait:elementsOfFinancialStatements/expense" }, @@ -18480,6 +18540,9 @@ { "@id": "rs-gaap:RestructuringCosts", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:recurrence/nonrecurring" + }, { "@id": "trait:operatingNonoperating/operating" }, @@ -18491,6 +18554,12 @@ { "@id": "rs-gaap:RestructuringCostsAndAssetImpairmentCharges", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:recurrence/nonrecurring" + }, + { + "@id": "trait:use/remeasurement" + }, { "@id": "trait:operatingNonoperating/operating" } @@ -18521,6 +18590,12 @@ { "@id": "rs-gaap:RestructuringSettlementAndImpairmentProvisions", "https://robosystems.ai/vocab/hasTrait": [ + { + "@id": "trait:recurrence/nonrecurring" + }, + { + "@id": "trait:use/remeasurement" + }, { "@id": "trait:elementsOfFinancialStatements/loss" }, diff --git a/migrations/extensions/versions/0002_taxonomy_library.py b/migrations/extensions/versions/0002_taxonomy_library.py index 239465573..d71cadb97 100644 --- a/migrations/extensions/versions/0002_taxonomy_library.py +++ b/migrations/extensions/versions/0002_taxonomy_library.py @@ -17,8 +17,8 @@ - CREATE TABLE public.element_labels (XBRL label linkbase) - CREATE TABLE public.element_references (XBRL reference linkbase) -- CREATE TABLE public.traits (FASB metamodel vocabulary — 25 element-side - categories: 24 trait axes + flowClassification) +- CREATE TABLE public.traits (FASB metamodel vocabulary — 26 element-side + categories: 24 trait axes + flowClassification + the RS `recurrence` axis) - CREATE TABLE public.element_traits (element ↔ trait many-to-many junction) - CREATE TABLE public.classifications (association structural patterns — 3 categories: concept_arrangement, member_arrangement, named_disclosure) @@ -34,7 +34,7 @@ - DELETE 0001-seeded library rows - INSERT from JSON-LD seeds: fac, rs-gaap (concept taxonomies); - fac-traits (trait vocabulary, 99 traits across 25 categories; + fac-traits (trait vocabulary, 100 traits across 26 categories; inherited from fac framework via depends_on); rs-gaap-traits (per-element trait bindings, ~1.7k arcs); rs-gaap-hierarchy (class-subclass); fac-to-rs-gaap, fac-calculations, @@ -275,8 +275,14 @@ ")" ) -# 25 FASB metamodel trait axes (24 axes + flowClassification). -# Matches check_trait_category on public.traits.category. +# 25 FASB metamodel trait axes (24 axes + flowClassification) + the RS +# `recurrence` analytical extension. Matches check_trait_category on +# public.traits.category (robosystems/models/extensions/trait.py). The +# content-driven library seed in this same migration inserts the +# `recurrence/nonrecurring` member from fac-traits.jsonld, so the CHECK +# created here must already admit it on a fresh DB. No deployment had run an +# earlier version of this migration when `recurrence` was added, so no +# separate widen migration for existing DBs was needed. _TRAIT_CATEGORY_CHECK = ( "category IN (" "'elementsOfFinancialStatements', 'liquidity', 'activityType', " @@ -287,7 +293,8 @@ "'accrualOrPayable', 'priority', 'estimatedFutureActivity', " "'statisticalMeasurement', 'taxComponents', 'threshold', 'use', " "'indirectCashFlowReconcilingItem', " - "'flowClassification'" + "'flowClassification', " + "'recurrence'" ")" ) @@ -663,7 +670,7 @@ def _create_tenant_library_tables(conn, schema: str) -> None: ) ) - # traits: FASB metamodel vocabulary (25 element-side categories). + # traits: FASB metamodel vocabulary (26 element-side categories). conn.execute( text(f""" CREATE TABLE IF NOT EXISTS {schema}.traits ( @@ -1106,7 +1113,7 @@ def upgrade() -> None: # ────────────────────────────────────────────────────────────────────── # 6. Trait vocabulary + element_traits junction + classification + assoc junction. # ────────────────────────────────────────────────────────────────────── - # traits: FASB metamodel vocabulary (25 element-side categories). + # traits: FASB metamodel vocabulary (26 element-side categories). op.create_table( "traits", sa.Column("id", sa.String(), nullable=False), diff --git a/robosystems/models/extensions/trait.py b/robosystems/models/extensions/trait.py index 18cbb6db6..782d5abb5 100644 --- a/robosystems/models/extensions/trait.py +++ b/robosystems/models/extensions/trait.py @@ -5,8 +5,9 @@ ``(category='liquidity', identifier='current')``, ``(category='flowClassification', identifier='inflow')``, etc. -The 25 categories cover the 24 orthogonal FASB metamodel trait axes plus -``flowClassification`` (derived from FASB instant-* arcroles). Element +The 26 categories cover the 24 orthogonal FASB metamodel trait axes plus +``flowClassification`` (derived from FASB instant-* arcroles) and the RS +``recurrence`` analytical axis (earnings persistence / NOPAT). Element assignments live in ``element_traits`` via :class:`ElementTrait`. This is distinct from :class:`Classification` (association-side), which @@ -57,7 +58,9 @@ class Trait(ExtensionsBase): "'statisticalMeasurement', 'taxComponents', 'threshold', 'use', " "'indirectCashFlowReconcilingItem', " # Flow classification (FASB instant-* arcroles) - "'flowClassification'" + "'flowClassification', " + # RS analytical extension — earnings persistence (normalized earnings / NOPAT) + "'recurrence'" ")", name="check_trait_category", ), diff --git a/tests/taxonomy/test_framework_bridge_seed.py b/tests/taxonomy/test_framework_bridge_seed.py index 98a48a751..2aea7be69 100644 --- a/tests/taxonomy/test_framework_bridge_seed.py +++ b/tests/taxonomy/test_framework_bridge_seed.py @@ -157,7 +157,10 @@ class _G: pin = resolve_pin(_G()) # type: ignore[arg-type] assert pin["rs-gaap"] == "v999" - assert pin["fac"] == "v1" # untouched by override + # The depends_on fac chain still expands (fac-traits is copied) and is + # untouched by the override. The `fac` package itself is tenant_copy:false, + # so it is intentionally omitted from the copy-pin (see discovery.py). + assert pin["fac-traits"] == "v1" def test_legacy_flat_dict_returned_asis(self) -> None: from robosystems.taxonomy.pins import resolve_pin