farseer-cli 1.13.0 → 1.14.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (83) hide show
  1. package/README.md +23 -8
  2. package/dist/commands/pipeline.js +158 -0
  3. package/dist/commands/pipeline.js.map +7 -0
  4. package/dist/commands/variables.js +17 -8
  5. package/dist/commands/variables.js.map +2 -2
  6. package/dist/index.js +40 -46
  7. package/dist/index.js.map +2 -2
  8. package/dist/mcp/prompts/workflows.js +13 -68
  9. package/dist/mcp/prompts/workflows.js.map +2 -2
  10. package/dist/mcp/resources/documentation.js +14 -0
  11. package/dist/mcp/resources/documentation.js.map +2 -2
  12. package/dist/mcp/server.js +14 -2
  13. package/dist/mcp/server.js.map +2 -2
  14. package/dist/mcp/skills.js +59 -0
  15. package/dist/mcp/skills.js.map +7 -0
  16. package/dist/mcp/tools/appTools.js +4 -0
  17. package/dist/mcp/tools/appTools.js.map +2 -2
  18. package/dist/mcp/tools/dataTools.js +2 -0
  19. package/dist/mcp/tools/dataTools.js.map +2 -2
  20. package/dist/mcp/tools/modelTools.js +6 -41
  21. package/dist/mcp/tools/modelTools.js.map +2 -2
  22. package/dist/mcp/tools/pipelineContract.js +317 -0
  23. package/dist/mcp/tools/pipelineContract.js.map +7 -0
  24. package/dist/mcp/tools/pipelineTools.js +111 -0
  25. package/dist/mcp/tools/pipelineTools.js.map +7 -0
  26. package/dist/mcp/tools/runTools.js +2 -0
  27. package/dist/mcp/tools/runTools.js.map +2 -2
  28. package/dist/mcp/tools/syncTools.js +4 -0
  29. package/dist/mcp/tools/syncTools.js.map +2 -2
  30. package/dist/pipeline/compatibility.js +53 -0
  31. package/dist/pipeline/compatibility.js.map +7 -0
  32. package/dist/pipeline/connect.js +139 -0
  33. package/dist/pipeline/connect.js.map +7 -0
  34. package/dist/pipeline/create.js +158 -0
  35. package/dist/pipeline/create.js.map +7 -0
  36. package/dist/pipeline/errors.js +45 -0
  37. package/dist/pipeline/errors.js.map +7 -0
  38. package/dist/pipeline/generated-reference.json +115 -0
  39. package/dist/pipeline/guide.js +33 -0
  40. package/dist/pipeline/guide.js.map +7 -0
  41. package/dist/pipeline/init.js +204 -0
  42. package/dist/pipeline/init.js.map +7 -0
  43. package/dist/pipeline/operations.js +103 -0
  44. package/dist/pipeline/operations.js.map +7 -0
  45. package/dist/pipeline/query.js +103 -0
  46. package/dist/pipeline/query.js.map +7 -0
  47. package/dist/pipeline/queryWorker.js +119 -0
  48. package/dist/pipeline/queryWorker.js.map +7 -0
  49. package/dist/pipeline/readiness.js +55 -0
  50. package/dist/pipeline/readiness.js.map +7 -0
  51. package/dist/pipeline/reference.js +72 -0
  52. package/dist/pipeline/reference.js.map +7 -0
  53. package/dist/pipeline/requests.js +122 -0
  54. package/dist/pipeline/requests.js.map +7 -0
  55. package/dist/pipeline/runArguments.js +68 -0
  56. package/dist/pipeline/runArguments.js.map +7 -0
  57. package/dist/pipeline/runtime.js +105 -0
  58. package/dist/pipeline/runtime.js.map +7 -0
  59. package/dist/pipeline/service.js +967 -0
  60. package/dist/pipeline/service.js.map +7 -0
  61. package/dist/services/agentApprovalFetch.js +86 -0
  62. package/dist/services/agentApprovalFetch.js.map +7 -0
  63. package/dist/services/configService.js +29 -0
  64. package/dist/services/configService.js.map +2 -2
  65. package/dist/services/credentials.js +2 -0
  66. package/dist/services/credentials.js.map +2 -2
  67. package/dist/services/farseerService.js +10 -3
  68. package/dist/services/farseerService.js.map +2 -2
  69. package/dist/services/preflight.js +4 -0
  70. package/dist/services/preflight.js.map +2 -2
  71. package/dist/services/syncService.js +6 -0
  72. package/dist/services/syncService.js.map +2 -2
  73. package/dist/skills/pipeline.js +71 -0
  74. package/dist/skills/pipeline.js.map +7 -0
  75. package/dist/utils/helpers.js +2 -1
  76. package/dist/utils/helpers.js.map +2 -2
  77. package/dist/utils/variableValues.js +78 -0
  78. package/dist/utils/variableValues.js.map +7 -0
  79. package/docs/pipeline-client-guide.md +67 -0
  80. package/docs/pipeline-reference.md +2064 -0
  81. package/package.json +5 -1
  82. package/skills/pipeline-authoring/SKILL.md +95 -0
  83. package/skills/pipeline-authoring/practices.md +325 -0
@@ -0,0 +1,2064 @@
1
+ # Pipeline YAML reference: engine 2.9.1
2
+
3
+ Generated file. Regenerate with `tools/pipeline/generate_docs.py`.
4
+
5
+ Generated from Pydantic's validation schema using YAML aliases. This describes rendered dataset definitions, not discovery/template directives. Descriptions come from the models; Python validators may impose additional cross-field rules. Read the method guide for the supported pipeline subset. Optional fields without a literal default may use a default factory. Runtime-derived fields are listed separately and must not be authored in YAML.
6
+
7
+ Read a topic through `farseer pipeline guide --topic NAME` or MCP `farseer_pipeline` with `{"operation":"guide","topic":"NAME"}`.
8
+
9
+ - [DatasetDefinition](#datasetdefinition)
10
+ - [BusinessCentralExtractConfig](#businesscentralextractconfig)
11
+ - [CSVWriteOptions](#csvwriteoptions)
12
+ - [CellsOptions](#cellsoptions)
13
+ - [ColumnSchema](#columnschema)
14
+ - [ConflictBehavior](#conflictbehavior)
15
+ - [Connection](#connection)
16
+ - [CsvParseOptions](#csvparseoptions)
17
+ - [CustomField](#customfield)
18
+ - [DataFormat](#dataformat)
19
+ - [DataSchema](#dataschema)
20
+ - [DateColumn](#datecolumn)
21
+ - [DimensionTableEntryOptions](#dimensiontableentryoptions)
22
+ - [DimensionTableOptions](#dimensiontableoptions)
23
+ - [DimensionTablesConfig](#dimensiontablesconfig)
24
+ - [ExportConfig](#exportconfig)
25
+ - [ExportFormat](#exportformat)
26
+ - [ExportTarget](#exporttarget)
27
+ - [ExtractConfig](#extractconfig)
28
+ - [ExtractType](#extracttype)
29
+ - [FarseerDatasetsExtractConfig](#farseerdatasetsextractconfig)
30
+ - [FarseerDimensionsConnection](#farseerdimensionsconnection)
31
+ - [FarseerDimensionsDateColumn](#farseerdimensionsdatecolumn)
32
+ - [FarseerDimensionsExtractConfig](#farseerdimensionsextractconfig)
33
+ - [FarseerDimensionsFileColumn](#farseerdimensionsfilecolumn)
34
+ - [FarseerDimensionsMapping](#farseerdimensionsmapping)
35
+ - [FarseerDimensionsNumberColumn](#farseerdimensionsnumbercolumn)
36
+ - [FarseerDimensionsTextColumn](#farseerdimensionstextcolumn)
37
+ - [FarseerExtractConfig](#farseerextractconfig)
38
+ - [FarseerFilesExportConfig](#farseerfilesexportconfig)
39
+ - [FarseerFilesExtractConfig](#farseerfilesextractconfig)
40
+ - [FarseerImportsExtractConfig](#farseerimportsextractconfig)
41
+ - [FarseerLoadConfig](#farseerloadconfig)
42
+ - [FarseerSource](#farseersource)
43
+ - [FarseerVariablesDimensionMapping](#farseervariablesdimensionmapping)
44
+ - [FarseerVariablesExtractConfig](#farseervariablesextractconfig)
45
+ - [FarseerVariablesFilter](#farseervariablesfilter)
46
+ - [FileColumn](#filecolumn)
47
+ - [FixedDimension](#fixeddimension)
48
+ - [GoogleDriveExtractConfig](#googledriveextractconfig)
49
+ - [GoogleDrivePublicExtractConfig](#googledrivepublicextractconfig)
50
+ - [HubspotAssociationsExtractConfig](#hubspotassociationsextractconfig)
51
+ - [HubspotExtractConfig](#hubspotextractconfig)
52
+ - [HubspotObjectsExtractConfig](#hubspotobjectsextractconfig)
53
+ - [HubspotOwnersExtractConfig](#hubspotownersextractconfig)
54
+ - [HubspotPipelinesExtractConfig](#hubspotpipelinesextractconfig)
55
+ - [HubspotPropertyCatalogConfig](#hubspotpropertycatalogconfig)
56
+ - [HubspotSource](#hubspotsource)
57
+ - [IntercomAdminsExtractConfig](#intercomadminsextractconfig)
58
+ - [IntercomContactsExtractConfig](#intercomcontactsextractconfig)
59
+ - [IntercomConversationPartsExtractConfig](#intercomconversationpartsextractconfig)
60
+ - [IntercomConversationsExtractConfig](#intercomconversationsextractconfig)
61
+ - [IntercomExtractConfig](#intercomextractconfig)
62
+ - [IntercomRegion](#intercomregion)
63
+ - [IntercomSource](#intercomsource)
64
+ - [JsonParseOptions](#jsonparseoptions)
65
+ - [LoadCellDescriptionMapping](#loadcelldescriptionmapping)
66
+ - [LoadCellsConfig](#loadcellsconfig)
67
+ - [LoadConfig](#loadconfig)
68
+ - [LoadDateMapping](#loaddatemapping)
69
+ - [LoadDimensionMapping](#loaddimensionmapping)
70
+ - [LoadDimensionTableEntry](#loaddimensiontableentry)
71
+ - [LoadMappingConfig](#loadmappingconfig)
72
+ - [LoadTableMapping](#loadtablemapping)
73
+ - [LoadTarget](#loadtarget)
74
+ - [LoadVariableMapping](#loadvariablemapping)
75
+ - [MissingMemberDescription](#missingmemberdescription)
76
+ - [NotionDatabaseExtractConfig](#notiondatabaseextractconfig)
77
+ - [NotionExtractConfig](#notionextractconfig)
78
+ - [NotionPageContentExtractConfig](#notionpagecontentextractconfig)
79
+ - [NotionSource](#notionsource)
80
+ - [NumberColumn](#numbercolumn)
81
+ - [ParseConfig](#parseconfig)
82
+ - [QualityRuleEntry](#qualityruleentry)
83
+ - [QualityRuleMeta](#qualityrulemeta)
84
+ - [ReviewGateConfig](#reviewgateconfig)
85
+ - [S3ExtractConfig](#s3extractconfig)
86
+ - [SapOdataCursor](#sapodatacursor)
87
+ - [SapOdataExtractConfig](#sapodataextractconfig)
88
+ - [SapOdataOdp](#sapodataodp)
89
+ - [SharePointExportConfig](#sharepointexportconfig)
90
+ - [SharePointExtractConfig](#sharepointextractconfig)
91
+ - [SqlDatabaseExtractConfig](#sqldatabaseextractconfig)
92
+ - [StepType](#steptype)
93
+ - [TenantCredentialsConfig](#tenantcredentialsconfig)
94
+ - [TextColumn](#textcolumn)
95
+ - [TimePoint](#timepoint)
96
+ - [TimepointVariableMapping](#timepointvariablemapping)
97
+ - [TldvExtractConfig](#tldvextractconfig)
98
+ - [TldvMeetingsFilter](#tldvmeetingsfilter)
99
+ - [TldvSource](#tldvsource)
100
+ - [TransformConfig](#transformconfig)
101
+ - [TransformEngine](#transformengine)
102
+ - [WriteMode](#writemode)
103
+ - [XLSXWriteOptions](#xlsxwriteoptions)
104
+ - [XlsxParseOptions](#xlsxparseoptions)
105
+
106
+ ## DatasetDefinition
107
+
108
+ Validated representation of a single dataset YAML file.
109
+
110
+ - Set exactly the configuration block matching type: extract, transform, load or export.
111
+ - For load/export, deps must match the explicitly referenced source_dataset names in both directions. Use qualified names verbatim.
112
+ - Authored pipelines are validated before any source is read: sql_file and farseer_credentials are refused; read the method guide before using this full engine reference.
113
+ - Steps run in dependency order, and steps at the same depth run in name order, so a quality check or reconciliation runs before a load only if the load's source dataset depends on it.
114
+
115
+ Unknown fields are rejected.
116
+
117
+ | YAML field | Type | Required | Default | Constraints / description |
118
+ | --- | --- | --- | --- | --- |
119
+ | `schema_version` | integer | no | `1` | minimum=`1` |
120
+ | `name` | string | yes | none | |
121
+ | `type` | [StepType](#steptype) | yes | none | |
122
+ | `deps` | array of string | no | none | |
123
+ | `description` | string | no | `""` | |
124
+ | `extract` | [ExtractConfig](#extractconfig) or null | no | `null` | |
125
+ | `transform` | [TransformConfig](#transformconfig) or null | no | `null` | |
126
+ | `load` | [LoadConfig](#loadconfig) or null | no | `null` | |
127
+ | `export` | [ExportConfig](#exportconfig) or null | no | `null` | |
128
+ | `schema` | [DataSchema](#dataschema) or null | no | `null` | |
129
+ | `quality_rules` | array of [QualityRuleEntry](#qualityruleentry) | no | none | |
130
+ | `write_mode` | [WriteMode](#writemode) | no | `"overwrite"` | |
131
+ | `merge_keys` | array of string | no | none | |
132
+
133
+ Runtime-derived; do not set in YAML: `qualified_name`, `namespace`, `source_path`, `render_context`.
134
+
135
+ ## BusinessCentralExtractConfig
136
+
137
+ Extraction settings for Microsoft Dynamics 365 Business Central.
138
+
139
+ Reads through the OData V4 API, authenticating with the OAuth2
140
+ client-credentials flow against Azure AD. Requires an Azure AD app
141
+ registration consented in the BC tenant (typical permission:
142
+ `Dynamics 365 Business Central / app_access`). Credentials (`tenant_id`,
143
+ `client_id`, `client_secret`) are supplied as YAML fields — typically
144
+ templated via `{{ pipeline_args.NAME }}` so a Remote Job's secret
145
+ `expectedArguments` flow through at discovery time.
146
+
147
+ A BC URL is composed as:
148
+
149
+ {api_base}/{bc_tenant_id}/{environment}/api/{publisher}/{api_group}/{api_version}/companies({company_guid})/{entity}
150
+
151
+ The four URL-path fields (`publisher`, `api_group`, `entity`,
152
+ `api_version`) are kept separate so that authors can't accidentally
153
+ glue them into a malformed path; the same structure also lets the
154
+ extractor log one stable summary regardless of which entity is fetched.
155
+
156
+ `bc_tenant_id` is the *BC* tenant GUID (the one that appears in the
157
+ API URL) and may differ from `tenant_id` (the Azure AD tenant GUID
158
+ used for the token endpoint), although in practice they are usually
159
+ the same.
160
+
161
+ `filter` is an OData `$filter` expression (e.g.
162
+ `"postingDateYear eq 2025"`) — server-side filtering, so it scales
163
+ independent of pagination. `select` projects a subset of fields
164
+ server-side; useful when the response payload is dominated by
165
+ columns the pipeline does not need.
166
+
167
+ Pagination follows `@odata.nextLink` until exhausted. `page_size`
168
+ is forwarded to BC as `?$top=` — leave unset to accept BC's default
169
+ (20,000 rows per page); set it to a smaller value when running
170
+ against a slow connection or to force a multi-page test on a small
171
+ entity.
172
+
173
+ Unknown fields are rejected.
174
+
175
+ | YAML field | Type | Required | Default | Constraints / description |
176
+ | --- | --- | --- | --- | --- |
177
+ | `bc_tenant_id` | string | yes | none | |
178
+ | `environment` | string | yes | none | |
179
+ | `publisher` | string | yes | none | |
180
+ | `api_group` | string | yes | none | |
181
+ | `company_guid` | string | yes | none | |
182
+ | `entity` | string | yes | none | |
183
+ | `api_version` | string | no | `"v1.0"` | |
184
+ | `filter` | string or null | no | `null` | |
185
+ | `select` | string or null | no | `null` | |
186
+ | `page_size` | integer or null | no | `null` | integer: exclusiveMinimum=`0` |
187
+ | `tenant_id` | string or null | no | `null` | |
188
+ | `client_id` | string or null | no | `null` | |
189
+ | `client_secret` | string or null | no | `null` | |
190
+
191
+ ## CSVWriteOptions
192
+
193
+ Options for DataFrame → CSV serialization on export.
194
+
195
+ Unknown fields are rejected.
196
+
197
+ | YAML field | Type | Required | Default | Constraints / description |
198
+ | --- | --- | --- | --- | --- |
199
+ | `separator` | string | no | `","` | |
200
+ | `decimal` | string | no | `"."` | |
201
+ | `encoding` | string | no | `"utf-8"` | |
202
+ | `include_header` | boolean | no | `true` | |
203
+ | `lineterminator` | string | no | `"\n"` | minLength=`1` |
204
+
205
+ ## CellsOptions
206
+
207
+ Per-entry options for cell value import.
208
+
209
+ Rows that land on the same coordinates in one import are summed, so the
210
+ source should already hold one row per cell.
211
+
212
+ Unknown fields are rejected.
213
+
214
+ | YAML field | Type | Required | Default | Constraints / description |
215
+ | --- | --- | --- | --- | --- |
216
+ | `overwrite_cells` | boolean | yes | none | true replaces the existing value of every coordinate in this import; cells for coordinates not in the import keep their values. false refuses the whole import if any target cell already holds a value, so a rerun fails. |
217
+ | `import_zeros` | boolean | no | `true` | false drops rows whose value is 0, so a value that fell to zero keeps its old number. |
218
+ | `create_missing_members` | boolean | no | `false` | When true, members that appear in mapped source columns but not in the model are created during the import. Fixed dimension members are not created: each must already exist, or be written by a dimension load earlier in the same run. |
219
+ | `missing_member_policy` | `"DISALLOW"`, `"USE_DEFAULT"`, `"SKIP_ROW"` | no | `"DISALLOW"` | What happens to a source value a dimension does not have: DISALLOW fails the whole import, USE_DEFAULT books the row to the table's default member, SKIP_ROW drops the row without counting it. |
220
+ | `labels` | array of string | no | none | Stored on the import job; the engine adds pipeline:<load qualified name>. undo_previous finds earlier imports by all of them, so name exactly the slice one run owns. |
221
+ | `undo_previous` | boolean | no | `false` | After this import commits, undo every earlier import carrying all the same labels. Undo deletes that import's cells and never restores the values they replaced; a failed undo is only a warning. |
222
+ | `review_gate` | [ReviewGateConfig](#reviewgateconfig) or null | no | `null` | |
223
+ | `allow_empty` | boolean | no | `false` | true turns a source with zero rows into a no-op instead of an error. Mapped columns must still be present, and nothing is undone. |
224
+
225
+ ## ColumnSchema
226
+
227
+ Schema definition for a single column.
228
+
229
+ `quality_rules:` carries the column's single-column quality rules —
230
+ each one applies to *this* column with no further reference needed.
231
+ Relational rules (which span multiple columns) sit in the top-level
232
+ `quality_rules:` block on the dataset, not here.
233
+
234
+ Unknown fields are rejected.
235
+
236
+ | YAML field | Type | Required | Default | Constraints / description |
237
+ | --- | --- | --- | --- | --- |
238
+ | `name` | string | yes | none | |
239
+ | `type` | `"str"`, `"int"`, `"float"`, `"datetime"`, `"bool"`, `"list[str]"` or null | no | `null` | |
240
+ | `not_null` | boolean | no | `false` | |
241
+ | `quality_rules` | array of [QualityRuleEntry](#qualityruleentry) | no | none | |
242
+
243
+ ## ConflictBehavior
244
+
245
+ How the target should resolve an existing file at the destination path.
246
+
247
+ Mirrors Microsoft Graph's `@microsoft.graph.conflictBehavior` values
248
+ since SharePoint is the first target; other targets adapt to their
249
+ own semantics (e.g. SFTP may have no equivalent of `rename`).
250
+
251
+ Values: `"replace"`, `"rename"`, `"fail"`
252
+
253
+ ## Connection
254
+
255
+ Maps a source column to a target dimension table (foreign key).
256
+
257
+ Unknown fields are rejected.
258
+
259
+ | YAML field | Type | Required | Default | Constraints / description |
260
+ | --- | --- | --- | --- | --- |
261
+ | `source_column` | string | yes | none | |
262
+ | `target_dimension_table` | string | yes | none | |
263
+
264
+ ## CsvParseOptions
265
+
266
+ csv-specific parse options (passed to `pd.read_csv`).
267
+
268
+ Unknown fields are rejected.
269
+
270
+ | YAML field | Type | Required | Default | Constraints / description |
271
+ | --- | --- | --- | --- | --- |
272
+ | `encoding` | string | no | `"utf-8"` | |
273
+ | `separator` | string or null | no | `null` | |
274
+ | `decimal` | string or null | no | `null` | |
275
+ | `has_header` | boolean | no | `true` | |
276
+ | `columns` | string or null | no | `null` | |
277
+
278
+ ## CustomField
279
+
280
+ Maps a DataFrame column to a CUSTOM column meta.
281
+
282
+ Each imported cell receives the column's value in a per-cell JSON blob,
283
+ keyed by the column's header name (= `source_column`). Typical uses:
284
+ source-system IDs, processing notes, confidence scores.
285
+
286
+ Unknown fields are rejected.
287
+
288
+ | YAML field | Type | Required | Default | Constraints / description |
289
+ | --- | --- | --- | --- | --- |
290
+ | `source_column` | string | yes | none | |
291
+
292
+ ## DataFormat
293
+
294
+ Values: `"parquet"`, `"csv"`, `"json"`
295
+
296
+ ## DataSchema
297
+
298
+ Top-level `schema:` block in a dataset YAML.
299
+
300
+ Unknown fields are rejected.
301
+
302
+ | YAML field | Type | Required | Default | Constraints / description |
303
+ | --- | --- | --- | --- | --- |
304
+ | `columns` | array of [ColumnSchema](#columnschema) | yes | none | minItems=`1` |
305
+
306
+ ## DateColumn
307
+
308
+ Maps a DataFrame column to a DATE attribute column on a RAMA dim table.
309
+
310
+ Values are converted to Excel serial numbers at load time via
311
+ `farseer_client.date_utils.to_excel_serial`.
312
+
313
+ Unknown fields are rejected.
314
+
315
+ | YAML field | Type | Required | Default | Constraints / description |
316
+ | --- | --- | --- | --- | --- |
317
+ | `source_column` | string | yes | none | |
318
+ | `target_dimension_table_column` | string | yes | none | |
319
+
320
+ ## DimensionTableEntryOptions
321
+
322
+ Per-entry options for one dimension-table sync (this table only).
323
+
324
+ Distinct from `DimensionTableOptions`, which carries options for the
325
+ whole `model.load` call (all tables at once); these govern a single
326
+ table's source frame.
327
+
328
+ Unknown fields are rejected.
329
+
330
+ | YAML field | Type | Required | Default | Constraints / description |
331
+ | --- | --- | --- | --- | --- |
332
+ | `allow_empty` | boolean | no | `false` | |
333
+
334
+ ## DimensionTableOptions
335
+
336
+ Shared options for dimension table sync (applies to all tables in one API call).
337
+
338
+ Unknown fields are rejected.
339
+
340
+ | YAML field | Type | Required | Default | Constraints / description |
341
+ | --- | --- | --- | --- | --- |
342
+ | `delete_missing` | boolean | no | `false` | |
343
+
344
+ ## DimensionTablesConfig
345
+
346
+ Configuration for dimension member sync.
347
+
348
+ `tables` lists the dimension tables to sync, each with its own
349
+ data source and column mapping. `options` applies to all tables
350
+ (RAMA's model.load() processes them in a single API call).
351
+
352
+ Unknown fields are rejected.
353
+
354
+ | YAML field | Type | Required | Default | Constraints / description |
355
+ | --- | --- | --- | --- | --- |
356
+ | `options` | [DimensionTableOptions](#dimensiontableoptions) | no | none | |
357
+ | `tables` | array of [LoadDimensionTableEntry](#loaddimensiontableentry) | yes | none | minItems=`1` |
358
+
359
+ ## ExportConfig
360
+
361
+ Configuration for a `type: export` dataset step.
362
+
363
+ `target` selects the destination system. The target-specific
364
+ config block must match (e.g. `target: sharepoint` requires a
365
+ `sharepoint:` section). Export steps are terminal sinks — no
366
+ downstream dataset depends on their output.
367
+
368
+ Unknown fields are rejected.
369
+
370
+ | YAML field | Type | Required | Default | Constraints / description |
371
+ | --- | --- | --- | --- | --- |
372
+ | `target` | [ExportTarget](#exporttarget) | yes | none | |
373
+ | `sharepoint` | [SharePointExportConfig](#sharepointexportconfig) or null | no | `null` | |
374
+ | `farseer_files` | [FarseerFilesExportConfig](#farseerfilesexportconfig) or null | no | `null` | |
375
+ | `allow_empty` | boolean | no | `false` | |
376
+
377
+ ## ExportFormat
378
+
379
+ Values: `"csv"`, `"xlsx"`, `"parquet"`
380
+
381
+ ## ExportTarget
382
+
383
+ Values: `"sharepoint"`, `"farseer_files"`
384
+
385
+ ## ExtractConfig
386
+
387
+ Configuration for a `type: extract` dataset step.
388
+
389
+ Unknown fields are rejected.
390
+
391
+ | YAML field | Type | Required | Default | Constraints / description |
392
+ | --- | --- | --- | --- | --- |
393
+ | `type` | [ExtractType](#extracttype) | yes | none | |
394
+ | `google_drive_public` | [GoogleDrivePublicExtractConfig](#googledrivepublicextractconfig) or null | no | `null` | |
395
+ | `google_drive` | [GoogleDriveExtractConfig](#googledriveextractconfig) or null | no | `null` | |
396
+ | `sharepoint` | [SharePointExtractConfig](#sharepointextractconfig) or null | no | `null` | |
397
+ | `sql_database` | [SqlDatabaseExtractConfig](#sqldatabaseextractconfig) or null | no | `null` | |
398
+ | `farseer` | [FarseerExtractConfig](#farseerextractconfig) or null | no | `null` | |
399
+ | `business_central` | [BusinessCentralExtractConfig](#businesscentralextractconfig) or null | no | `null` | |
400
+ | `tldv` | [TldvExtractConfig](#tldvextractconfig) or null | no | `null` | |
401
+ | `intercom` | [IntercomExtractConfig](#intercomextractconfig) or null | no | `null` | |
402
+ | `notion` | [NotionExtractConfig](#notionextractconfig) or null | no | `null` | |
403
+ | `hubspot` | [HubspotExtractConfig](#hubspotextractconfig) or null | no | `null` | |
404
+ | `sap_odata` | [SapOdataExtractConfig](#sapodataextractconfig) or null | no | `null` | |
405
+ | `s3` | [S3ExtractConfig](#s3extractconfig) or null | no | `null` | |
406
+ | `parse` | [ParseConfig](#parseconfig) | no | none | |
407
+ | `optional` | boolean | no | `false` | When true, a source that does not exist (404, no such table, no such file) skips this dataset instead of failing the run. The skip propagates to every step that depends on it, loads and exports included, and the run still finishes successfully. Network errors, authentication failures, timeouts and 5xx responses still fail the run. |
408
+
409
+ ## ExtractType
410
+
411
+ Values: `"google_drive_public"`, `"google_drive"`, `"sharepoint"`, `"sql_database"`, `"farseer"`, `"business_central"`, `"tldv"`, `"intercom"`, `"notion"`, `"hubspot"`, `"sap_odata"`, `"s3"`
412
+
413
+ ## FarseerDatasetsExtractConfig
414
+
415
+ `extract.farseer.source: datasets` — read a versioned dataset.
416
+
417
+ Reads from the Labs Datasets API: the symmetric counterpart to
418
+ `DatasetDataStore` writes — same control-plane API, same GCS data-plane,
419
+ just the read half.
420
+
421
+ `qualified_name` is the dataset's registered name (the writer's
422
+ qualified name maps 1:1 to the API `name` field). `version_id`
423
+ pins the read to a specific completed version for reproducibility;
424
+ when omitted the extractor reads the dataset's currently promoted
425
+ version. An unpromoted dataset (created but never promoted) is
426
+ treated as a missing source so `optional: true` can absorb it.
427
+
428
+ Unknown fields are rejected.
429
+
430
+ | YAML field | Type | Required | Default | Constraints / description |
431
+ | --- | --- | --- | --- | --- |
432
+ | `qualified_name` | string | yes | none | |
433
+ | `version_id` | string or null | no | `null` | |
434
+
435
+ ## FarseerDimensionsConnection
436
+
437
+ Projects a foreign-key column on a dim table to a DataFrame column.
438
+
439
+ Inverse of the load side's `dimension_tables.tables[].mapping.connections`.
440
+ The DataFrame cell receives a list of connected-member names
441
+ (`/model/export` resolves FK ids to names server-side via
442
+ `PK_MEMBER_EXTRACTOR`).
443
+
444
+ Unknown fields are rejected.
445
+
446
+ | YAML field | Type | Required | Default | Constraints / description |
447
+ | --- | --- | --- | --- | --- |
448
+ | `source_dimension_table` | string | yes | none | |
449
+ | `target_column` | string | yes | none | |
450
+
451
+ ## FarseerDimensionsDateColumn
452
+
453
+ Projects a DATE attribute column on a dim table to a DataFrame column.
454
+
455
+ The DataFrame value is the raw Excel serial number Rama stores — days
456
+ since 1899-12-30 with the 1900 leap-year bug preserved. See
457
+ `clients/python/src/farseer_client/date_utils.py` for the formula
458
+ (only the forward conversion `to_excel_serial` ships in the client
459
+ today) if a downstream transform needs a Python date.
460
+
461
+ Unknown fields are rejected.
462
+
463
+ | YAML field | Type | Required | Default | Constraints / description |
464
+ | --- | --- | --- | --- | --- |
465
+ | `source_dimension_table_column` | string | yes | none | |
466
+ | `target_column` | string | yes | none | |
467
+
468
+ ## FarseerDimensionsExtractConfig
469
+
470
+ `extract.farseer.source: dimensions` — read members of one dim table.
471
+
472
+ Inverse of the `dimension_tables.tables[]` block on
473
+ `FarseerLoadConfig`. One step → one DataFrame of members; to read
474
+ several dim tables, declare multiple extracts (`expand:` templates them).
475
+
476
+ Unknown fields are rejected.
477
+
478
+ | YAML field | Type | Required | Default | Constraints / description |
479
+ | --- | --- | --- | --- | --- |
480
+ | `source_dimension_table` | string | yes | none | |
481
+ | `mapping` | [FarseerDimensionsMapping](#farseerdimensionsmapping) | yes | none | |
482
+
483
+ ## FarseerDimensionsFileColumn
484
+
485
+ Projects a FILE attribute column on a dim table to two DataFrame columns.
486
+
487
+ Rama stores FILE values as `{"farseerFileId", "filename"}` JSON strings
488
+ (the same shape the load side's `file_columns` writes). The extractor
489
+ parses the JSON and fans each FILE column into two output columns: a UUID
490
+ file id and the display filename.
491
+
492
+ Unknown fields are rejected.
493
+
494
+ | YAML field | Type | Required | Default | Constraints / description |
495
+ | --- | --- | --- | --- | --- |
496
+ | `source_dimension_table_column` | string | yes | none | |
497
+ | `target_file_id_column` | string | yes | none | |
498
+ | `target_filename_column` | string | yes | none | |
499
+
500
+ ## FarseerDimensionsMapping
501
+
502
+ Projects Farseer dimension-member fields onto DataFrame columns.
503
+
504
+ Mirrors `dimension_tables.tables[].mapping` on the load side with the
505
+ data direction flipped: where load writes `source_*_column` (DataFrame
506
+ → Rama), extract writes `target_*_column` (Rama → DataFrame). Reserved
507
+ Rama fields (Name, Description, Order, Active) are scalars under
508
+ `mapping:`; columns the author can name (connections + typed attribute
509
+ columns) are lists of source/target pairs.
510
+
511
+ Unknown fields are rejected.
512
+
513
+ | YAML field | Type | Required | Default | Constraints / description |
514
+ | --- | --- | --- | --- | --- |
515
+ | `target_primary_key_column` | string | yes | none | |
516
+ | `target_description_column` | string or null | no | `null` | |
517
+ | `target_order_column` | string or null | no | `null` | |
518
+ | `target_active_column` | string or null | no | `null` | |
519
+ | `connections` | array of [FarseerDimensionsConnection](#farseerdimensionsconnection) | no | none | |
520
+ | `text_columns` | array of [FarseerDimensionsTextColumn](#farseerdimensionstextcolumn) | no | none | |
521
+ | `number_columns` | array of [FarseerDimensionsNumberColumn](#farseerdimensionsnumbercolumn) | no | none | |
522
+ | `date_columns` | array of [FarseerDimensionsDateColumn](#farseerdimensionsdatecolumn) | no | none | |
523
+ | `file_columns` | array of [FarseerDimensionsFileColumn](#farseerdimensionsfilecolumn) | no | none | |
524
+
525
+ ## FarseerDimensionsNumberColumn
526
+
527
+ Projects a NUMBER attribute column on a dim table to a DataFrame column.
528
+
529
+ Unknown fields are rejected.
530
+
531
+ | YAML field | Type | Required | Default | Constraints / description |
532
+ | --- | --- | --- | --- | --- |
533
+ | `source_dimension_table_column` | string | yes | none | |
534
+ | `target_column` | string | yes | none | |
535
+
536
+ ## FarseerDimensionsTextColumn
537
+
538
+ Projects a TEXT attribute column on a dim table to a DataFrame column.
539
+
540
+ Unknown fields are rejected.
541
+
542
+ | YAML field | Type | Required | Default | Constraints / description |
543
+ | --- | --- | --- | --- | --- |
544
+ | `source_dimension_table_column` | string | yes | none | |
545
+ | `target_column` | string | yes | none | |
546
+
547
+ ## FarseerExtractConfig
548
+
549
+ `extract.type: farseer` — multi-source family.
550
+
551
+ `source:` picks which Farseer concept to extract from; the
552
+ matching inner block carries source-specific config. Cross-tenant
553
+ credentials are shared across all sources via `farseer_credentials:`.
554
+
555
+ Unknown fields are rejected.
556
+
557
+ | YAML field | Type | Required | Default | Constraints / description |
558
+ | --- | --- | --- | --- | --- |
559
+ | `source` | [FarseerSource](#farseersource) | yes | none | |
560
+ | `variables` | [FarseerVariablesExtractConfig](#farseervariablesextractconfig) or null | no | `null` | |
561
+ | `files` | [FarseerFilesExtractConfig](#farseerfilesextractconfig) or null | no | `null` | |
562
+ | `imports` | [FarseerImportsExtractConfig](#farseerimportsextractconfig) or null | no | `null` | |
563
+ | `dimensions` | [FarseerDimensionsExtractConfig](#farseerdimensionsextractconfig) or null | no | `null` | |
564
+ | `datasets` | [FarseerDatasetsExtractConfig](#farseerdatasetsextractconfig) or null | no | `null` | |
565
+ | `farseer_credentials` | [TenantCredentialsConfig](#tenantcredentialsconfig) or null | no | `null` | |
566
+
567
+ ## FarseerFilesExportConfig
568
+
569
+ Farseer Files export target: the source DataFrame as a user-chosen file.
570
+
571
+ Writes to the tenant's own Files folder (the tree shown in the UI's left
572
+ nav). The write-side mirror of `extract.farseer source: files`.
573
+
574
+ Distinct from the `Data/` folder the `farseer_files` *data store*
575
+ writes intermediate step outputs to: that location is addressed by
576
+ qualified name and is meant for developers / product-services, whereas
577
+ this target writes a single, user-readable report to a path the author
578
+ picks (`file_path`, relative to the Files root — the leading `Files/`
579
+ is implied, exactly like the extractor's `file:`).
580
+
581
+ **Parquet only — deliberately.** This target exists so the exported file
582
+ faithfully reproduces the in-memory DataFrame, and parquet is the only
583
+ format that does: it stores dtypes, float precision, null-vs-NaN,
584
+ datetimes, and leading-zero string codes in the file's own metadata, so
585
+ the round-trip is lossless. CSV would coerce every value back to text —
586
+ the classic `0000042100` account-code → `int64` corruption the
587
+ extract side already sidesteps by persisting typed CSVs as parquet — and
588
+ XLSX would impose Excel's numeric model (int/float collapse, >15-digit
589
+ precision loss, dropped leading zeros). Because the Farseer Files UI
590
+ previews parquet natively, reading the typed schema (`hyparquet` in
591
+ `FilePreview`), the author sees exactly the DataFrame — so parquet is
592
+ both the faithful *and* the user-readable choice, and there is no reason
593
+ to ship a lossy one. `format: csv | xlsx` can be added later as an
594
+ opt-in for the "download and open outside Farseer" case, with the
595
+ lossiness documented at that point.
596
+
597
+ `source_dataset` names the single dep whose DataFrame is written to the
598
+ file -- the same source-naming field SharePoint export uses. An export
599
+ writes exactly one dataset to one file, so the step's single dep must
600
+ equal `source_dataset` (enforced on `DatasetDefinition`).
601
+
602
+ Unknown fields are rejected.
603
+
604
+ | YAML field | Type | Required | Default | Constraints / description |
605
+ | --- | --- | --- | --- | --- |
606
+ | `source_dataset` | string | yes | none | |
607
+ | `file_path` | string | yes | none | Path under Files, ending in the file name. The folder must already exist: the export does not create folders. |
608
+ | `conflict_behavior` | [ConflictBehavior](#conflictbehavior) | no | `"fail"` | |
609
+ | `farseer_credentials` | [TenantCredentialsConfig](#tenantcredentialsconfig) or null | no | `null` | |
610
+
611
+ ## FarseerFilesExtractConfig
612
+
613
+ `extract.farseer.source: files` — pick a file from Farseer Files.
614
+
615
+ Reads from the source tenant's store. Specify exactly one of `file`
616
+ (slash-separated path under Files) or `file_id` (opaque ID). Cross-tenant
617
+ access lives on `FarseerExtractConfig`.
618
+
619
+ Unknown fields are rejected.
620
+
621
+ | YAML field | Type | Required | Default | Constraints / description |
622
+ | --- | --- | --- | --- | --- |
623
+ | `file` | string or null | no | `null` | |
624
+ | `file_id` | string or null | no | `null` | |
625
+
626
+ ### Example
627
+
628
+ ```yaml
629
+ # Models/sales_raw.yaml: a file's name must match its `name:`.
630
+ # Reads one month's CSV from Files. The run argument picks the file, so each run
631
+ # reads its own month.
632
+ name: sales_raw
633
+ type: extract
634
+ extract:
635
+ type: farseer
636
+ farseer:
637
+ source: files
638
+ files:
639
+ file: "Imports/{{ pipeline_args.SOURCE_FILE }}"
640
+ parse:
641
+ format: csv
642
+ ```
643
+
644
+ ## FarseerImportsExtractConfig
645
+
646
+ `extract.farseer.source: imports` — source-row audit of a variable.
647
+
648
+ One row per `import_cell`, preserving the `description` set when each
649
+ row was imported.
650
+
651
+ Counterpart to `FarseerVariablesExtractConfig`, which
652
+ aggregates to one row per Rama cell (current state). Same variable
653
+ surface (`variable` + `dimensions` + `filters`) with an
654
+ additional `target_description_column` for the per-row description;
655
+ cells without import provenance (manual entries, calculated cells)
656
+ are excluded. This is the audit view: one row per imported cell with
657
+ the description it was imported with. For the current value of each
658
+ cell, use `source: variables`.
659
+
660
+ Unknown fields are rejected.
661
+
662
+ | YAML field | Type | Required | Default | Constraints / description |
663
+ | --- | --- | --- | --- | --- |
664
+ | `variable` | string | yes | none | |
665
+ | `target_value_column` | string | yes | none | |
666
+ | `target_description_column` | string | yes | none | |
667
+ | `dimensions` | array of [FarseerVariablesDimensionMapping](#farseervariablesdimensionmapping) | yes | none | minItems=`1` |
668
+ | `filters` | array of [FarseerVariablesFilter](#farseervariablesfilter) | no | none | |
669
+
670
+ ## FarseerLoadConfig
671
+
672
+ `load.target: farseer` — push cells and/or dimension members.
673
+
674
+ Writes into a Farseer tenant's model.
675
+ One atomic `/model/load` call can carry both `dimension_tables`
676
+ (member sync) and `cells` (variable-cell import); at least one
677
+ is required, and dim tables sync before cells when both are set.
678
+ No inner `entity:` discriminator because Farseer has a single
679
+ load operation; if a second mode appears later it can add one.
680
+ Cross-tenant pushes are configured via `farseer_credentials:`.
681
+
682
+ Unknown fields are rejected.
683
+
684
+ | YAML field | Type | Required | Default | Constraints / description |
685
+ | --- | --- | --- | --- | --- |
686
+ | `dimension_tables` | [DimensionTablesConfig](#dimensiontablesconfig) or null | no | `null` | |
687
+ | `cells` | array of [LoadCellsConfig](#loadcellsconfig) | no | none | |
688
+ | `farseer_credentials` | [TenantCredentialsConfig](#tenantcredentialsconfig) or null | no | `null` | |
689
+
690
+ ## FarseerSource
691
+
692
+ Sub-discriminator on `extract.farseer.source`.
693
+
694
+ Values: `"variables"`, `"files"`, `"imports"`, `"dimensions"`, `"datasets"`
695
+
696
+ ## FarseerVariablesDimensionMapping
697
+
698
+ Maps a Farseer dim table to an output column on a variables extract.
699
+
700
+ Unknown fields are rejected.
701
+
702
+ | YAML field | Type | Required | Default | Constraints / description |
703
+ | --- | --- | --- | --- | --- |
704
+ | `source_dimension_table` | string | yes | none | |
705
+ | `target_column` | string | yes | none | |
706
+
707
+ ## FarseerVariablesExtractConfig
708
+
709
+ `extract.farseer.source: variables` — read one variable's cells.
710
+
711
+ Aggregated cells, inverse of the `cells:` block on `FarseerLoadConfig`.
712
+ Returns cells as currently persisted, not re-evaluated: one row per cell
713
+ that exists, with one output column per entry in `dimensions` (time tables
714
+ such as `Years` and `Months` included, when the variable has them) and the
715
+ value in `target_value_column`. `filters` restrict members: OR within one
716
+ entry, AND across entries. One variable per step; to read several,
717
+ declare several extracts and combine them in a transform.
718
+
719
+ Unknown fields are rejected.
720
+
721
+ | YAML field | Type | Required | Default | Constraints / description |
722
+ | --- | --- | --- | --- | --- |
723
+ | `variable` | string | yes | none | |
724
+ | `target_value_column` | string | yes | none | |
725
+ | `dimensions` | array of [FarseerVariablesDimensionMapping](#farseervariablesdimensionmapping) | yes | none | minItems=`1` |
726
+ | `filters` | array of [FarseerVariablesFilter](#farseervariablesfilter) | no | none | |
727
+
728
+ ## FarseerVariablesFilter
729
+
730
+ Keeps only cells whose member for `dimension_table` is in `members`.
731
+
732
+ Unknown fields are rejected.
733
+
734
+ | YAML field | Type | Required | Default | Constraints / description |
735
+ | --- | --- | --- | --- | --- |
736
+ | `dimension_table` | string | yes | none | |
737
+ | `members` | array of string | yes | none | minItems=`1` |
738
+
739
+ ## FileColumn
740
+
741
+ Maps two DataFrame columns to a FILE attribute column on a RAMA dim table.
742
+
743
+ RAMA stores FILE cell values as `{farseerFileId, filename}` JSON strings —
744
+ the UI uses the filename to render the cell. The load step combines the
745
+ two source columns into that shape before sending.
746
+
747
+ `source_file_id_column` holds the UUID returned by
748
+ `FarseerClient.upload_file(...).id` — matches the `farseerFileId` key
749
+ in the stored JSON. `source_filename_column` holds the display name.
750
+
751
+ Unknown fields are rejected.
752
+
753
+ | YAML field | Type | Required | Default | Constraints / description |
754
+ | --- | --- | --- | --- | --- |
755
+ | `source_file_id_column` | string | yes | none | |
756
+ | `source_filename_column` | string | yes | none | |
757
+ | `target_dimension_table_column` | string | yes | none | |
758
+
759
+ ## FixedDimension
760
+
761
+ Pin a dimension member for a variable column.
762
+
763
+ Unknown fields are rejected.
764
+
765
+ | YAML field | Type | Required | Default | Constraints / description |
766
+ | --- | --- | --- | --- | --- |
767
+ | `dimension_table` | string | yes | none | |
768
+ | `dimension_member` | string | yes | none | |
769
+
770
+ ## GoogleDriveExtractConfig
771
+
772
+ Extraction settings for private Google Drive files (service account).
773
+
774
+ Authenticates as a Google Cloud service account; the client shares the
775
+ folder (or Shared Drive) with the service account's e-mail as a Viewer,
776
+ so no domain-wide delegation and no per-user OAuth is involved.
777
+
778
+ `service_account_json` is the service account's full JSON key,
779
+ templated via `{{ pipeline_args.NAME }}` so a Remote Job's secret
780
+ `expectedArguments` flow through at discovery time. Its shape is
781
+ validated at extract time, not here — a schema-load error would echo
782
+ the offending input back into logs (`hide_input_in_errors` guards
783
+ the pydantic side of that).
784
+
785
+ Two addressing modes, mutually exclusive:
786
+
787
+ - `file_id` — opaque Drive file ID.
788
+ - `folder_id` + `file_path` — anchor folder ID (the folder the
789
+ client shared) plus a slash-separated path below it, resolved one
790
+ segment at a time. Folder IDs are stable across renames, so the
791
+ anchor survives the client tidying up folder names. The final
792
+ segment may contain `*` wildcards (e.g. `REPORT2502AC.*` for a
793
+ source whose extension flips between `.xlsx` and `.xls` across
794
+ periods); exactly one file must match.
795
+
796
+ Unknown fields are rejected.
797
+
798
+ | YAML field | Type | Required | Default | Constraints / description |
799
+ | --- | --- | --- | --- | --- |
800
+ | `service_account_json` | string or null | no | `null` | |
801
+ | `file_id` | string or null | no | `null` | |
802
+ | `folder_id` | string or null | no | `null` | |
803
+ | `file_path` | string or null | no | `null` | |
804
+
805
+ ## GoogleDrivePublicExtractConfig
806
+
807
+ Extraction settings for public Google Drive files.
808
+
809
+ Only works with files shared as "Anyone with the link" — no auth required.
810
+
811
+ Unknown fields are rejected.
812
+
813
+ | YAML field | Type | Required | Default | Constraints / description |
814
+ | --- | --- | --- | --- | --- |
815
+ | `file_id` | string | yes | none | |
816
+
817
+ ## HubspotAssociationsExtractConfig
818
+
819
+ One row per (record of `object_type`, associated record) pair.
820
+
821
+ The link table between two HubSpot object types -- which company a deal
822
+ belongs to, which contacts a note was logged against. A record extract
823
+ carries no such information: HubSpot keeps associations beside the
824
+ record, not on it, and reports them only when a crawl asks for the
825
+ `to_object_types` by name. This grain does that ask over the same record
826
+ crawl `objects` uses, and explodes what comes back to one row per pair.
827
+
828
+ `association_type` is HubSpot's own label for the link
829
+ (`deal_to_company`, `note_to_contact`, ...). The same pair often arrives
830
+ twice, once as the typed link and once as its `_unlabeled` twin, which is
831
+ HubSpot's representation of an unlabelled association rather than a
832
+ duplicate; keep both or dedupe in a transform, as the model needs.
833
+
834
+ Unknown fields are rejected.
835
+
836
+ | YAML field | Type | Required | Default | Constraints / description |
837
+ | --- | --- | --- | --- | --- |
838
+ | `object_type` | string | yes | none | |
839
+ | `to_object_types` | array of string | yes | none | minItems=`1` |
840
+ | `archived` | boolean | no | `false` | |
841
+ | `page_size` | integer | no | `100` | maximum=`100`; exclusiveMinimum=`0` |
842
+
843
+ ## HubspotExtractConfig
844
+
845
+ `extract.type: hubspot` — multi-source family over the HubSpot CRM API.
846
+
847
+ Authentication is a `pat-<region>-...` bearer token — either an
848
+ **account service key** (the current developer platform's credential
849
+ for single-account API access) or a **legacy private app token**. Both
850
+ are account-level, carry the same object-specific scopes, and go over
851
+ the wire identically, so `access_token` is validated only for presence
852
+ and not for shape: a token format check here would reject a
853
+ HubSpot-issued credential the moment they add a fourth variant. The
854
+ token is supplied as a YAML field, typically templated via
855
+ `{{ pipeline_args.HUBSPOT_ACCESS_TOKEN }}` so a Remote Job's secret
856
+ `expectedArguments` flow through at discovery time.
857
+
858
+ `source:` picks the grain; the matching inner block carries its
859
+ config. One token covers every source, so it lives out here.
860
+
861
+ Every source lands parquet, so a surrounding `parse:` block is never
862
+ consulted — same as `business_central` and `sql_database`. A declared
863
+ `schema:` therefore checks the result rather than instructing the read.
864
+
865
+ HubSpot serializes every record property as a JSON *string*, including
866
+ numbers, booleans and dates. The extractor reads the object's property
867
+ catalog and coerces each column to the type HubSpot declares for it,
868
+ because leaving it alone would make `amount` a text column that sums
869
+ by concatenation, and `"false"` a truthy value. Record ids stay
870
+ strings deliberately: they exceed 2^53 in some portals, so any numeric
871
+ dtype would corrupt them.
872
+
873
+ Timestamps land as timezone-naive UTC. HubSpot documents every time as
874
+ UTC and date-only properties as midnight UTC; dropping the marker
875
+ rather than converting keeps the values as HubSpot stated them and
876
+ matches the physical type the platform's `type: datetime` declares.
877
+ Localizing them to a negative-offset zone downstream would move a
878
+ close date — and its revenue — into the previous month.
879
+
880
+ Unknown fields are rejected.
881
+
882
+ | YAML field | Type | Required | Default | Constraints / description |
883
+ | --- | --- | --- | --- | --- |
884
+ | `source` | [HubspotSource](#hubspotsource) | yes | none | |
885
+ | `access_token` | string or null | no | `null` | |
886
+ | `objects` | [HubspotObjectsExtractConfig](#hubspotobjectsextractconfig) or null | no | `null` | |
887
+ | `pipelines` | [HubspotPipelinesExtractConfig](#hubspotpipelinesextractconfig) or null | no | `null` | |
888
+ | `properties` | [HubspotPropertyCatalogConfig](#hubspotpropertycatalogconfig) or null | no | `null` | |
889
+ | `property_options` | [HubspotPropertyCatalogConfig](#hubspotpropertycatalogconfig) or null | no | `null` | |
890
+ | `associations` | [HubspotAssociationsExtractConfig](#hubspotassociationsextractconfig) or null | no | `null` | |
891
+ | `owners` | [HubspotOwnersExtractConfig](#hubspotownersextractconfig) or null | no | `null` | |
892
+
893
+ ## HubspotObjectsExtractConfig
894
+
895
+ One row per CRM record of `object_type`, one column per requested property.
896
+
897
+ `object_type` is HubSpot's own plural object name as it appears in the
898
+ API path (`deals`, `companies`, `contacts`, `line_items`, `tickets`),
899
+ or a custom object's `p<portalId>_<name>` / `2-xxxxxxx` identifier.
900
+
901
+ `properties` is required and has no wildcard form, which is the single
902
+ most consequential choice in this config. HubSpot returns only about
903
+ eight default properties when the parameter is omitted — a portal with
904
+ 400 deal properties answers a propertyless request with eight columns
905
+ and no warning — so an implicit "everything" would make the dataset's
906
+ column set a function of whatever a HubSpot admin last added, silently
907
+ for undeclared columns and as a hard failure for anything downstream
908
+ declaring a `schema:`. Declaring the list keeps the frame's shape owned
909
+ by the pipeline. Extract `source: properties` first to discover what the
910
+ portal actually has, then name the ones the model needs.
911
+
912
+ Property names are checked against the portal's own catalog before the
913
+ crawl starts: HubSpot ignores an unknown property rather than
914
+ rejecting it, so a typo would otherwise land a frame quietly missing
915
+ that column.
916
+
917
+ `archived` selects HubSpot's archived (soft-deleted, recoverable)
918
+ records *instead of* the live ones — it is the API's own parameter, not
919
+ a union. Reading both means two datasets.
920
+
921
+ `page_size` is HubSpot's `limit`. It defaults to the documented
922
+ maximum rather than HubSpot's own default of 10, which would make ten
923
+ times as many requests for the same data.
924
+
925
+ Unknown fields are rejected.
926
+
927
+ | YAML field | Type | Required | Default | Constraints / description |
928
+ | --- | --- | --- | --- | --- |
929
+ | `object_type` | string | yes | none | |
930
+ | `properties` | array of string | yes | none | minItems=`1` |
931
+ | `archived` | boolean | no | `false` | |
932
+ | `page_size` | integer | no | `100` | maximum=`100`; exclusiveMinimum=`0` |
933
+
934
+ ## HubspotOwnersExtractConfig
935
+
936
+ One row per HubSpot owner.
937
+
938
+ `archived` selects deactivated owners instead of active ones. It
939
+ matters more here than on other sources: a record's
940
+ `hubspot_owner_id` keeps pointing at the owner who left, so a
941
+ dimension built from active owners alone leaves every deal that rep
942
+ ever touched with an unresolvable owner — disproportionately the
943
+ oldest records. Extract both and concatenate.
944
+
945
+ Unknown fields are rejected.
946
+
947
+ | YAML field | Type | Required | Default | Constraints / description |
948
+ | --- | --- | --- | --- | --- |
949
+ | `archived` | boolean | no | `false` | |
950
+ | `page_size` | integer | no | `500` | maximum=`500`; exclusiveMinimum=`0` |
951
+
952
+ ## HubspotPipelinesExtractConfig
953
+
954
+ One row per (pipeline, stage) for `object_type`.
955
+
956
+ Denormalized without fan-out: a HubSpot stage belongs to exactly one
957
+ pipeline, so the row count is the number of stages rather than a cross
958
+ product — plus one row per pipeline that has no stages at all, which is
959
+ kept with the stage columns null rather than dropped, so an empty
960
+ pipeline still reaches the dimension.
961
+
962
+ Note that stage labels are only unique *within* a pipeline ("Closed
963
+ Won" exists in every pipeline) and stage ids are only meaningful
964
+ inside their own pipeline, so the join key back to a record's
965
+ `dealstage` is the composite `(pipeline_id, stage_id)`.
966
+
967
+ Unknown fields are rejected.
968
+
969
+ | YAML field | Type | Required | Default | Constraints / description |
970
+ | --- | --- | --- | --- | --- |
971
+ | `object_type` | string | yes | none | |
972
+ | `archived` | boolean | no | `false` | |
973
+
974
+ ## HubspotPropertyCatalogConfig
975
+
976
+ Addresses `object_type`'s property definitions.
977
+
978
+ Shared by `source: properties` (one row per definition) and
979
+ `source: property_options` (one row per enumeration option) — the same
980
+ HubSpot payload projected at two different grains.
981
+
982
+ Unknown fields are rejected.
983
+
984
+ | YAML field | Type | Required | Default | Constraints / description |
985
+ | --- | --- | --- | --- | --- |
986
+ | `object_type` | string | yes | none | |
987
+ | `archived` | boolean | no | `false` | |
988
+
989
+ ## HubspotSource
990
+
991
+ Sub-discriminator on `extract.hubspot.source`.
992
+
993
+ Each value is a distinct grain, not a variation of one shape:
994
+ `objects` is one row per CRM record, `pipelines` one row per
995
+ (pipeline, stage), `properties` one row per property definition,
996
+ `property_options` one row per enumeration option, `owners` one row
997
+ per owner, `associations` one row per (record, associated record) pair.
998
+
999
+ Values: `"objects"`, `"pipelines"`, `"properties"`, `"property_options"`, `"associations"`, `"owners"`
1000
+
1001
+ ## IntercomAdminsExtractConfig
1002
+
1003
+ One row per admin (teammate), so an author id resolves to a person.
1004
+
1005
+ Unknown fields are rejected.
1006
+
1007
+ | YAML field | Type | Required | Default | Constraints / description |
1008
+ | --- | --- | --- | --- | --- |
1009
+
1010
+ ## IntercomContactsExtractConfig
1011
+
1012
+ One row per contact (users and leads alike).
1013
+
1014
+ Unknown fields are rejected.
1015
+
1016
+ | YAML field | Type | Required | Default | Constraints / description |
1017
+ | --- | --- | --- | --- | --- |
1018
+ | `page_size` | integer | no | `150` | maximum=`150`; exclusiveMinimum=`0` |
1019
+
1020
+ ## IntercomConversationPartsExtractConfig
1021
+
1022
+ One row per message in a conversation, across every conversation.
1023
+
1024
+ Costs one request per conversation on top of the list, so this is the
1025
+ grain that sets a run's length.
1026
+
1027
+ `plaintext` asks Intercom to render message bodies as plain text instead
1028
+ of HTML. On by default: the rendering is Intercom's own, and a text
1029
+ corpus is what a reader of support conversations wants.
1030
+
1031
+ Unknown fields are rejected.
1032
+
1033
+ | YAML field | Type | Required | Default | Constraints / description |
1034
+ | --- | --- | --- | --- | --- |
1035
+ | `page_size` | integer | no | `150` | maximum=`150`; exclusiveMinimum=`0` |
1036
+ | `plaintext` | boolean | no | `true` | |
1037
+
1038
+ ## IntercomConversationsExtractConfig
1039
+
1040
+ One row per conversation, with its opening message inline.
1041
+
1042
+ The opening message (the `source` block) is on the conversation itself;
1043
+ the replies are a different grain (`conversation_parts`) because they
1044
+ cost one request per conversation.
1045
+
1046
+ Unknown fields are rejected.
1047
+
1048
+ | YAML field | Type | Required | Default | Constraints / description |
1049
+ | --- | --- | --- | --- | --- |
1050
+ | `page_size` | integer | no | `150` | maximum=`150`; exclusiveMinimum=`0` |
1051
+
1052
+ ## IntercomExtractConfig
1053
+
1054
+ `extract.type: intercom` — multi-source family over the Intercom REST API.
1055
+
1056
+ Authentication is an access token from an Intercom app installed in the
1057
+ workspace (a "private" app for this one workspace is the usual shape);
1058
+ it is supplied as a YAML field, typically templated via
1059
+ `{{ pipeline_args.INTERCOM_ACCESS_TOKEN }}`. `region` picks the API host.
1060
+
1061
+ Every source lands parquet, so a surrounding `parse:` block is never
1062
+ consulted, and a declared `schema:` checks the result rather than
1063
+ instructing the read. Timestamps arrive as seconds since the epoch and
1064
+ land as timezone-naive UTC datetimes. Lists on a record (contact ids,
1065
+ tag names) land as `|`-joined text; structures with no fixed shape
1066
+ (custom attributes) land as JSON text.
1067
+
1068
+ Unknown fields are rejected.
1069
+
1070
+ | YAML field | Type | Required | Default | Constraints / description |
1071
+ | --- | --- | --- | --- | --- |
1072
+ | `source` | [IntercomSource](#intercomsource) | yes | none | |
1073
+ | `access_token` | string or null | no | `null` | |
1074
+ | `region` | [IntercomRegion](#intercomregion) | no | `"us"` | |
1075
+ | `conversations` | [IntercomConversationsExtractConfig](#intercomconversationsextractconfig) or null | no | `null` | |
1076
+ | `conversation_parts` | [IntercomConversationPartsExtractConfig](#intercomconversationpartsextractconfig) or null | no | `null` | |
1077
+ | `contacts` | [IntercomContactsExtractConfig](#intercomcontactsextractconfig) or null | no | `null` | |
1078
+ | `admins` | [IntercomAdminsExtractConfig](#intercomadminsextractconfig) or null | no | `null` | |
1079
+
1080
+ ## IntercomRegion
1081
+
1082
+ Where an Intercom workspace's data lives, which picks the API host.
1083
+
1084
+ Intercom hosts each workspace in one region and serves it from a
1085
+ region-specific host; a token presented to the wrong host answers 401
1086
+ rather than redirecting, so the region is configuration rather than
1087
+ something the extractor can discover.
1088
+
1089
+ Values: `"us"`, `"eu"`, `"au"`
1090
+
1091
+ ## IntercomSource
1092
+
1093
+ Sub-discriminator on `extract.intercom.source`.
1094
+
1095
+ Values: `"conversations"`, `"conversation_parts"`, `"contacts"`, `"admins"`
1096
+
1097
+ ## JsonParseOptions
1098
+
1099
+ json-specific parse options (passed to `pd.read_json`).
1100
+
1101
+ Unknown fields are rejected.
1102
+
1103
+ | YAML field | Type | Required | Default | Constraints / description |
1104
+ | --- | --- | --- | --- | --- |
1105
+ | `encoding` | string | no | `"utf-8"` | |
1106
+
1107
+ ## LoadCellDescriptionMapping
1108
+
1109
+ Maps a DataFrame column to per-cell DESCRIPTION column metas.
1110
+
1111
+ Each imported cell gets a description value pulled from the named source
1112
+ column. Distinct from the job-level `import_job_description` scalar,
1113
+ which attaches a single note to the whole import job.
1114
+
1115
+ Unknown fields are rejected.
1116
+
1117
+ | YAML field | Type | Required | Default | Constraints / description |
1118
+ | --- | --- | --- | --- | --- |
1119
+ | `source_column` | string | yes | none | |
1120
+
1121
+ ## LoadCellsConfig
1122
+
1123
+ Configuration for a single cell value import source.
1124
+
1125
+ `source_dataset` names the dependency whose DataFrame contains the cell values.
1126
+ `import_job_title` is an optional scalar that populates the Import Job's
1127
+ title. When unset, the title defaults to `{step_name} — {source_dataset}`
1128
+ so entries within the same load step stay distinguishable in the Farseer UI.
1129
+ `import_job_description` is an optional scalar that populates the Import
1130
+ Job's top-level description field (distinct from per-row `cell_description`).
1131
+ `mapping` defines how DataFrame columns map to RAMA dimensions and variables.
1132
+ `options` controls import behavior (overwrite, missing members, undo, etc.).
1133
+
1134
+ Unknown fields are rejected.
1135
+
1136
+ | YAML field | Type | Required | Default | Constraints / description |
1137
+ | --- | --- | --- | --- | --- |
1138
+ | `source_dataset` | string | yes | none | |
1139
+ | `import_job_title` | string or null | no | `null` | string: maxLength=`255` |
1140
+ | `import_job_description` | string or null | no | `null` | |
1141
+ | `mapping` | [LoadMappingConfig](#loadmappingconfig) | yes | none | |
1142
+ | `options` | [CellsOptions](#cellsoptions) | yes | none | |
1143
+
1144
+ ### Example
1145
+
1146
+ ```yaml
1147
+ # Models/sales_load.yaml: a file's name must match its `name:`.
1148
+ # Writes the totals into Revenue, Actual version. The run argument is in the
1149
+ # labels, so undo_previous replaces only this month's earlier import.
1150
+ # source_dataset repeats a deps entry exactly. A model in a subfolder goes by
1151
+ # its qualified name (Models/silver/sales_monthly.yaml is silver.sales_monthly)
1152
+ # in both places, not the leaf name a transform's SQL uses.
1153
+ name: sales_load
1154
+ type: load
1155
+ deps: [sales_monthly]
1156
+ load:
1157
+ target: farseer
1158
+ farseer:
1159
+ cells:
1160
+ - source_dataset: sales_monthly
1161
+ mapping:
1162
+ dimension_tables:
1163
+ - source_column: product
1164
+ target_dimension_table: Product
1165
+ - source_column: region
1166
+ target_dimension_table: Region
1167
+ variables:
1168
+ - source_column: amount
1169
+ target_variable: Revenue
1170
+ fixed_dimension_members:
1171
+ - dimension_table: Versions
1172
+ dimension_member: Actual
1173
+ date:
1174
+ source_column: month
1175
+ format: YYYY_MM_DD
1176
+ options:
1177
+ overwrite_cells: true
1178
+ labels: [sales, "{{ pipeline_args.SOURCE_FILE }}"]
1179
+ undo_previous: true
1180
+ ```
1181
+
1182
+ ## LoadConfig
1183
+
1184
+ Configuration for a `type: load` dataset step.
1185
+
1186
+ `target` selects the destination system. The target-specific config
1187
+ block must match (e.g. `target: farseer` requires a `farseer:` section).
1188
+
1189
+ Unknown fields are rejected.
1190
+
1191
+ | YAML field | Type | Required | Default | Constraints / description |
1192
+ | --- | --- | --- | --- | --- |
1193
+ | `target` | [LoadTarget](#loadtarget) | yes | none | |
1194
+ | `farseer` | [FarseerLoadConfig](#farseerloadconfig) or null | no | `null` | |
1195
+
1196
+ ## LoadDateMapping
1197
+
1198
+ Maps a DataFrame column to RAMA time dimensions.
1199
+
1200
+ Unknown fields are rejected.
1201
+
1202
+ | YAML field | Type | Required | Default | Constraints / description |
1203
+ | --- | --- | --- | --- | --- |
1204
+ | `source_column` | string | yes | none | |
1205
+ | `format` | `"UNIX"`, `"ISO"`, `"EXCEL"`, `"DD_MM_YYYY"`, `"MM_DD_YYYY"`, `"YYYY_MM_DD"`, `"MM_YYYY"`, `"YYYY_MM"` | no | `"YYYY_MM_DD"` | |
1206
+
1207
+ ## LoadDimensionMapping
1208
+
1209
+ Maps a DataFrame column to a RAMA dimension table.
1210
+
1211
+ Unknown fields are rejected.
1212
+
1213
+ | YAML field | Type | Required | Default | Constraints / description |
1214
+ | --- | --- | --- | --- | --- |
1215
+ | `source_column` | string | yes | none | |
1216
+ | `target_dimension_table` | string | yes | none | |
1217
+
1218
+ ## LoadDimensionTableEntry
1219
+
1220
+ Maps a single dimension table to its source dataset.
1221
+
1222
+ `source_dataset` names the dependency whose DataFrame contains members
1223
+ for this table. `target_dimension_table` is the RAMA dimension table name.
1224
+ `mapping` defines the column structure. `options` carries per-table
1225
+ behavior toggles (empty-frame handling).
1226
+
1227
+ Unknown fields are rejected.
1228
+
1229
+ | YAML field | Type | Required | Default | Constraints / description |
1230
+ | --- | --- | --- | --- | --- |
1231
+ | `source_dataset` | string | yes | none | |
1232
+ | `target_dimension_table` | string | yes | none | |
1233
+ | `options` | [DimensionTableEntryOptions](#dimensiontableentryoptions) | no | none | |
1234
+ | `mapping` | [LoadTableMapping](#loadtablemapping) | yes | none | |
1235
+
1236
+ ## LoadMappingConfig
1237
+
1238
+ Schema-to-dimension mapping for cell import.
1239
+
1240
+ Unknown fields are rejected.
1241
+
1242
+ | YAML field | Type | Required | Default | Constraints / description |
1243
+ | --- | --- | --- | --- | --- |
1244
+ | `dimension_tables` | array of [LoadDimensionMapping](#loaddimensionmapping) | yes | none | minItems=`1` |
1245
+ | `variables` | array of [LoadVariableMapping](#loadvariablemapping) | no | none | |
1246
+ | `timepoint_variables` | array of [TimepointVariableMapping](#timepointvariablemapping) | no | none | |
1247
+ | `date` | [LoadDateMapping](#loaddatemapping) or null | no | `null` | |
1248
+ | `cell_description` | [LoadCellDescriptionMapping](#loadcelldescriptionmapping) or null | no | `null` | |
1249
+ | `custom_fields` | array of [CustomField](#customfield) | no | none | |
1250
+ | `missing_member_descriptions` | array of [MissingMemberDescription](#missingmemberdescription) | no | none | |
1251
+
1252
+ ## LoadTableMapping
1253
+
1254
+ Maps DataFrame columns to a RAMA dimension table for member sync.
1255
+
1256
+ Unknown fields are rejected.
1257
+
1258
+ | YAML field | Type | Required | Default | Constraints / description |
1259
+ | --- | --- | --- | --- | --- |
1260
+ | `source_primary_key_column` | string | yes | none | |
1261
+ | `source_description_column` | string or null | no | `null` | |
1262
+ | `source_order_column` | string or null | no | `null` | |
1263
+ | `source_active_column` | string or null | no | `null` | |
1264
+ | `connections` | array of [Connection](#connection) | no | none | |
1265
+ | `text_columns` | array of [TextColumn](#textcolumn) | no | none | |
1266
+ | `number_columns` | array of [NumberColumn](#numbercolumn) | no | none | |
1267
+ | `date_columns` | array of [DateColumn](#datecolumn) | no | none | |
1268
+ | `file_columns` | array of [FileColumn](#filecolumn) | no | none | |
1269
+
1270
+ ## LoadTarget
1271
+
1272
+ Values: `"farseer"`
1273
+
1274
+ ## LoadVariableMapping
1275
+
1276
+ Maps a DataFrame column to a RAMA variable.
1277
+
1278
+ `fixed_dimension_members` pins dimension members that are not present
1279
+ in the DataFrame (e.g. `Versions=Actual`).
1280
+
1281
+ Unknown fields are rejected.
1282
+
1283
+ | YAML field | Type | Required | Default | Constraints / description |
1284
+ | --- | --- | --- | --- | --- |
1285
+ | `fixed_dimension_members` | array of [FixedDimension](#fixeddimension) | no | none | |
1286
+ | `source_column` | string | yes | none | |
1287
+ | `target_variable` | string | yes | none | |
1288
+
1289
+ ## MissingMemberDescription
1290
+
1291
+ Maps a DataFrame column to a TAG_DESCRIPTION column meta.
1292
+
1293
+ Paired with an IDENTIFIER column on the same `target_dimension_table`:
1294
+ when the Import Job auto-creates missing dim members
1295
+ (`create_missing_members: true`), the new member's description is pulled
1296
+ from this column.
1297
+
1298
+ Unknown fields are rejected.
1299
+
1300
+ | YAML field | Type | Required | Default | Constraints / description |
1301
+ | --- | --- | --- | --- | --- |
1302
+ | `source_column` | string | yes | none | |
1303
+ | `target_dimension_table` | string | yes | none | |
1304
+
1305
+ ## NotionDatabaseExtractConfig
1306
+
1307
+ One row per page (row) of a Notion database, one column per property.
1308
+
1309
+ The column set comes from the database's own property definitions, read
1310
+ before the first row, so an empty database still lands every column and
1311
+ two runs land the same shape whatever rows happen to hold. Column names
1312
+ are the property names as Notion shows them; the record envelope lands
1313
+ as `notion_id`, `notion_created_time`, `notion_last_edited_time`,
1314
+ `notion_archived` and `notion_url`, and a property that would collide
1315
+ with one of those fails the extract rather than overwriting it.
1316
+
1317
+ Unknown fields are rejected.
1318
+
1319
+ | YAML field | Type | Required | Default | Constraints / description |
1320
+ | --- | --- | --- | --- | --- |
1321
+ | `database_id` | string | yes | none | |
1322
+ | `page_size` | integer | no | `100` | maximum=`100`; exclusiveMinimum=`0` |
1323
+
1324
+ ## NotionExtractConfig
1325
+
1326
+ `extract.type: notion` — multi-source family over the Notion REST API.
1327
+
1328
+ Authentication is an internal integration token (`ntn_...`); the
1329
+ database must be connected to that integration in Notion's share menu,
1330
+ or the API answers 404 as if it did not exist. The token is a YAML
1331
+ field, typically templated via `{{ pipeline_args.NOTION_TOKEN }}`.
1332
+
1333
+ `api_version` is the `Notion-Version` header. The default addresses a
1334
+ database directly; Notion's later versions split a database from its
1335
+ data sources, and a database with more than one data source needs the
1336
+ query addressed to a data source, which this extractor does not do.
1337
+
1338
+ Every source lands parquet; a `parse:` block is never consulted.
1339
+
1340
+ Unknown fields are rejected.
1341
+
1342
+ | YAML field | Type | Required | Default | Constraints / description |
1343
+ | --- | --- | --- | --- | --- |
1344
+ | `source` | [NotionSource](#notionsource) | yes | none | |
1345
+ | `access_token` | string or null | no | `null` | |
1346
+ | `api_version` | string | no | `"2022-06-28"` | |
1347
+ | `database` | [NotionDatabaseExtractConfig](#notiondatabaseextractconfig) or null | no | `null` | |
1348
+ | `page_content` | [NotionPageContentExtractConfig](#notionpagecontentextractconfig) or null | no | `null` | |
1349
+
1350
+ ## NotionPageContentExtractConfig
1351
+
1352
+ One row per page of a database, holding the page body as Markdown.
1353
+
1354
+ Costs one request per page (more for a page with nested blocks), which
1355
+ is why this is a separate grain from `database`: the property table is
1356
+ cheap and the bodies are not. `max_depth` bounds how far nested blocks
1357
+ (toggles, columns, synced blocks) are followed.
1358
+
1359
+ Unknown fields are rejected.
1360
+
1361
+ | YAML field | Type | Required | Default | Constraints / description |
1362
+ | --- | --- | --- | --- | --- |
1363
+ | `database_id` | string | yes | none | |
1364
+ | `page_size` | integer | no | `100` | maximum=`100`; exclusiveMinimum=`0` |
1365
+ | `max_depth` | integer | no | `3` | minimum=`1`; maximum=`10` |
1366
+
1367
+ ## NotionSource
1368
+
1369
+ Sub-discriminator on `extract.notion.source`.
1370
+
1371
+ Values: `"database"`, `"page_content"`
1372
+
1373
+ ## NumberColumn
1374
+
1375
+ Maps a DataFrame column to a NUMBER attribute column on a RAMA dim table.
1376
+
1377
+ Unknown fields are rejected.
1378
+
1379
+ | YAML field | Type | Required | Default | Constraints / description |
1380
+ | --- | --- | --- | --- | --- |
1381
+ | `source_column` | string | yes | none | |
1382
+ | `target_dimension_table_column` | string | yes | none | |
1383
+
1384
+ ## ParseConfig
1385
+
1386
+ Parsing options for downloaded extract data.
1387
+
1388
+ Format-specific options live in per-format blocks (`csv_options` /
1389
+ `xlsx_options` / `json_options`); only the block matching `format`
1390
+ may be set, and the matching block defaults when omitted. `parquet` has
1391
+ no read options. Same per-format block *shape* as the export side, but
1392
+ stricter: a block that does not match `format` is rejected, not ignored.
1393
+
1394
+ Unknown fields are rejected.
1395
+
1396
+ | YAML field | Type | Required | Default | Constraints / description |
1397
+ | --- | --- | --- | --- | --- |
1398
+ | `format` | `"csv"`, `"parquet"`, `"json"`, `"xlsx"` | no | `"csv"` | |
1399
+ | `csv_options` | [CsvParseOptions](#csvparseoptions) or null | no | `null` | |
1400
+ | `xlsx_options` | [XlsxParseOptions](#xlsxparseoptions) or null | no | `null` | |
1401
+ | `json_options` | [JsonParseOptions](#jsonparseoptions) or null | no | `null` | |
1402
+
1403
+ ## QualityRuleEntry
1404
+
1405
+ One entry under a `quality_rules:` list.
1406
+
1407
+ Three fields make up the shape locked in the design doc:
1408
+
1409
+ - `type:` — the rule identifier. Either a Pandera built-in
1410
+ check name (e.g. `in_range`, `isin`, `str_matches`) or one
1411
+ of the custom checks we register (`custom__*`, including
1412
+ `custom__unique` / `custom__unique_composite` — see
1413
+ `quality.customs` for why uniqueness is a custom).
1414
+ - `params:` — kwargs forwarded verbatim to the rule. Field
1415
+ names mirror Pandera's parameter names.
1416
+ - `meta:` — rule metadata; carries `severity` for now.
1417
+
1418
+ Column rules go under a column's `quality_rules:`; dataset rules go
1419
+ under the dataset's top-level `quality_rules:`. The custom rules:
1420
+
1421
+ | type | scope | params |
1422
+ |---|---|---|
1423
+ | `custom__unique` | column | none; repeated nulls count as duplicates |
1424
+ | `custom__max_null_rate` | column | `max`: highest allowed share of nulls, 0 to 1 |
1425
+ | `custom__distinct_count` | column | `min` and/or `max` number of distinct values |
1426
+ | `custom__unique_composite` | dataset | `columns`: columns that must be unique together |
1427
+ | `custom__compare` | dataset | `left`, `right`: columns; `operator`: lt, lte, eq, gte, gt or ne |
1428
+ | `custom__sum_equals` | dataset | `total`: column; `parts`: columns; `tolerance`: optional, default 0 |
1429
+ | `custom__one_of_non_null` | dataset | `columns`: at least one must be non-null on every row |
1430
+
1431
+ Pandera's built-in checks (`in_range`, `isin`, `str_matches`,
1432
+ `equal_to`, `greater_than_or_equal_to` and the rest) take Pandera's own
1433
+ parameter names.
1434
+
1435
+ Unknown fields are rejected.
1436
+
1437
+ | YAML field | Type | Required | Default | Constraints / description |
1438
+ | --- | --- | --- | --- | --- |
1439
+ | `type` | string | yes | none | |
1440
+ | `params` | object | no | none | |
1441
+ | `meta` | [QualityRuleMeta](#qualityrulemeta) | no | none | |
1442
+
1443
+ ## QualityRuleMeta
1444
+
1445
+ Per-rule metadata.
1446
+
1447
+ Carries `severity` for now (default `error` — failed rule
1448
+ blocks the step; `warn` logs and proceeds). Future metadata
1449
+ keys land here without changing the rule shape.
1450
+
1451
+ Unknown fields are rejected.
1452
+
1453
+ | YAML field | Type | Required | Default | Constraints / description |
1454
+ | --- | --- | --- | --- | --- |
1455
+ | `severity` | `"error"`, `"warn"` | no | `"error"` | |
1456
+
1457
+ ## ReviewGateConfig
1458
+
1459
+ Leave the import uncommitted for manual review when the gate matches.
1460
+
1461
+ When any row's `column` value is in `block_values`, the load uploads
1462
+ and syncs as normal but skips the commit, leaving the job `CREATED`
1463
+ ("In progress") and ending the run red. `column` must be a declared
1464
+ `custom_fields` column so its values render in the Import review screen.
1465
+ A reviewer then accepts or discards the import in the Import review
1466
+ screen; nothing reaches the model until it is accepted.
1467
+
1468
+ Unknown fields are rejected.
1469
+
1470
+ | YAML field | Type | Required | Default | Constraints / description |
1471
+ | --- | --- | --- | --- | --- |
1472
+ | `column` | string | yes | none | |
1473
+ | `block_values` | array of string | yes | none | minItems=`1` |
1474
+
1475
+ ## S3ExtractConfig
1476
+
1477
+ Extraction settings for one object in an Amazon S3 bucket.
1478
+
1479
+ Authenticates with an IAM access key pair the YAML supplies, typically
1480
+ templated via `{{ pipeline_args.NAME }}` from a Remote Job's secret
1481
+ `expectedArguments`. There is deliberately no fallback to an ambient AWS
1482
+ identity: the runner serves every tenant, so whatever credentials its
1483
+ environment holds are not any one pipeline's to use.
1484
+
1485
+ `key` is the object key exactly as S3 stores it -- no leading-slash
1486
+ stripping, because `/a.csv` and `a.csv` are different objects. `region`
1487
+ is optional; without it botocore follows S3's redirect to the bucket's
1488
+ region at the cost of a round trip.
1489
+
1490
+ Unknown fields are rejected.
1491
+
1492
+ | YAML field | Type | Required | Default | Constraints / description |
1493
+ | --- | --- | --- | --- | --- |
1494
+ | `bucket` | string | yes | none | |
1495
+ | `key` | string | yes | none | |
1496
+ | `region` | string or null | no | `null` | |
1497
+ | `access_key_id` | string or null | no | `null` | |
1498
+ | `secret_access_key` | string or null | no | `null` | |
1499
+ | `session_token` | string or null | no | `null` | |
1500
+
1501
+ ## SapOdataCursor
1502
+
1503
+ The change stamp an incremental SAP OData read advances on.
1504
+
1505
+ `column` is a UTC change timestamp that SAP writes whenever a row
1506
+ changes, in ABAP's decimal form `YYYYMMDDhhmmss.fffffff`
1507
+ (`LASTCHANGEDATETIME` on the billing-document and product views). Each
1508
+ run reads the rows stamped from one second past the previous bound
1509
+ through the last whole second that ended `settle_lag` before `now`, the
1510
+ runner's clock, because SAP sends no clock of its own.
1511
+ Consecutive windows tile, so a run over a quiet source reads nothing and
1512
+ the run publishes no new version.
1513
+
1514
+ `settle_lag_seconds` is how long a stamped row gets to become visible. A
1515
+ row whose commit lags its stamp by more than this, less the amount SAP's
1516
+ clock runs behind the runner's, is never read by a window. The default
1517
+ is SAP's own safety interval for generic timestamp delta.
1518
+
1519
+ `zero_stamp` is the rule for rows whose stamp is ABAP's initial value 0,
1520
+ SAP's null, which no window can contain. It has no default, because on
1521
+ the billing header those rows are real documents -- cancellations are
1522
+ created with 0 and keep it:
1523
+
1524
+ * `refuse` fails the run when any such row exists: the first read counts
1525
+ them, and every later run probes for them.
1526
+ * `creation_date` reads them by `creation_date_column`, a day-grain
1527
+ `Edm.DateTime`, once each day has closed everywhere: a day `d` is read
1528
+ from `(d+1)T12:00Z + settle_lag`, which covers every time zone the
1529
+ date can have been written in.
1530
+
1531
+ `full_read_every_days` makes a run read the whole entity set again when
1532
+ the last whole read is that many days old. Under upsert that repairs
1533
+ what a window cannot see: a change that did not move the stamp, a row
1534
+ that committed later than the lag, a row that changes more often than
1535
+ the lag.
1536
+
1537
+ Unknown fields are rejected.
1538
+
1539
+ | YAML field | Type | Required | Default | Constraints / description |
1540
+ | --- | --- | --- | --- | --- |
1541
+ | `column` | string | yes | none | |
1542
+ | `zero_stamp` | `"refuse"`, `"creation_date"` | yes | none | |
1543
+ | `creation_date_column` | string or null | no | `null` | |
1544
+ | `settle_lag_seconds` | integer | no | `1800` | minimum=`60`; maximum=`86400` |
1545
+ | `full_read_every_days` | integer or null | no | `null` | integer: minimum=`1`; maximum=`366` |
1546
+
1547
+ ## SapOdataExtractConfig
1548
+
1549
+ Extraction settings for SAP S/4HANA via an OData V2 service.
1550
+
1551
+ Reads a CDS-view-backed entity set exposed through SAP Gateway,
1552
+ authenticating with HTTP basic against a read-only SAP service user.
1553
+ Credentials (`username`, `password`) are supplied as YAML fields,
1554
+ typically templated via `{{ pipeline_args.NAME }}`.
1555
+
1556
+ The entity URL is composed as `{base_url}{service_path}/{entity_set}`,
1557
+ kept as separate fields so authors can't glue them into a malformed path.
1558
+
1559
+ Without `cursor`, every run re-reads the whole entity set, so pair it
1560
+ with the dataset's `write_mode: overwrite` for a full refresh.
1561
+
1562
+ With `cursor` (see `SapOdataCursor`) the read is incremental: each run
1563
+ reads only the rows whose change stamp moved since the last published
1564
+ run, and the dataset's watermark, kept by the backend, remembers how far
1565
+ that was. Discovery then requires `write_mode: upsert` on the entity's
1566
+ key, because a changed row arrives again and has to replace the row it
1567
+ was, and `sap_client`, because the stream is one client's data. Nothing
1568
+ is registered in SAP -- the position lives only in the watermark.
1569
+
1570
+ What the cursor cannot see: a change that does not move the stamp, a
1571
+ row whose commit lagged its stamp by more than the settle lag, a column
1572
+ added to the view after a row was read, and a row deleted at the source
1573
+ (on these views, an archived document). `full_read_every_days` repairs
1574
+ all but the last; deleted rows stay.
1575
+
1576
+ **Changing the stream needs an operator step.** The stored progress is
1577
+ keyed by the Gateway origin and path, the entity set, the client, the
1578
+ cursor columns, the zero-stamp rule and a hash of `select`. Changing any of them makes every
1579
+ later run refuse, until `DELETE /labs/datasets/{id}/watermark` resets the
1580
+ progress and the next run reads the whole entity set again.
1581
+
1582
+ With `odp` (see `SapOdataOdp`) the read is incremental through SAP's own
1583
+ change tracking instead. It opens a subscription in SAP, so it needs a
1584
+ dedicated SAP user or service per dataset and environment. Discovery
1585
+ applies the same rules as for `cursor`, refuses both together, requires
1586
+ `odp.key` to equal `merge_keys`, and refuses `select`: how SAP applies
1587
+ the initial load's projection to a delta read is not verified.
1588
+
1589
+ `select` is OData `$select` passthrough. There is no `$filter`: SAP drops
1590
+ a filter its ODP translation cannot handle and answers with every row,
1591
+ and nothing checks a full load's rows, so a filter belongs downstream.
1592
+ `max_page_size` is sent as `Prefer: odata.maxpagesize` and sizes each page
1593
+ SAP returns; the pages are then followed through their `__next` links.
1594
+ It is not `$top`, which in SAP's V2 truncates the total result and is
1595
+ never sent. Memory scales with it: a 146-column view peaked at about
1596
+ 0.7 GB with the default of 10,000 and about 1.3 GB at 50,000. Unpatched
1597
+ SAP_BW 7.50-7.56 ignores a value above 50,000 (SAP note 3118751), so
1598
+ 50,000 is the ceiling that pages on every release.
1599
+
1600
+ Unknown fields are rejected.
1601
+
1602
+ | YAML field | Type | Required | Default | Constraints / description |
1603
+ | --- | --- | --- | --- | --- |
1604
+ | `base_url` | string | yes | none | |
1605
+ | `service_path` | string | yes | none | |
1606
+ | `entity_set` | string | yes | none | |
1607
+ | `max_page_size` | integer | no | `10000` | minimum=`1`; maximum=`50000` |
1608
+ | `sap_client` | string or null | no | `null` | |
1609
+ | `select` | string or null | no | `null` | |
1610
+ | `username` | string or null | no | `null` | |
1611
+ | `password` | string or null | no | `null` | |
1612
+ | `cursor` | [SapOdataCursor](#sapodatacursor) or null | no | `null` | |
1613
+ | `odp` | [SapOdataOdp](#sapodataodp) or null | no | `null` | |
1614
+
1615
+ ## SapOdataOdp
1616
+
1617
+ SAP's own change tracking (ODP delta) as the incremental read.
1618
+
1619
+ The first run sends `Prefer: odata.track-changes`, which opens a
1620
+ subscription in SAP's operational delta queue (ODQ), and takes the new
1621
+ initial-load token from `DeltaLinksOf<entity>`. Each later run reads the
1622
+ changes since the committed token and commits the new one SAP hands out,
1623
+ also from an empty read. SAP keeps the subscription, keyed by the SAP user
1624
+ and the OData service: one per pair, so every dataset and environment
1625
+ needs its own user or service. A new initial load for the same pair
1626
+ silently invalidates the tokens of whoever held it before.
1627
+
1628
+ `key` is the entity's key. One delta can carry a key more than once, and
1629
+ the last image in the response is the one kept. That is verified for a
1630
+ CDS view with change data capture, whose repeated images of one key are
1631
+ the same. A recovery sends its requests in the order SAP delivered them,
1632
+ but within one request SAP's order is not change order, so a source that
1633
+ sends two different images of one key in one request, as an extractor's
1634
+ after-image delta process may, can keep the older one. It is wrong for
1635
+ sources that send differences. `key` has to equal the dataset's
1636
+ `merge_keys`.
1637
+
1638
+ `deletes` is the rule for SAP's delete records. `ignore` is the only rule
1639
+ for now: they are dropped and counted, so an archived document stays in
1640
+ the dataset, as it does with the cursor.
1641
+
1642
+ `reset_subscription_until` and `release_until` are lifecycle steps, each
1643
+ in effect until the instant it names and refused after it, so a copied
1644
+ or forgotten setting stops acting. `reset_subscription_until` ends this
1645
+ user's subscription on the service before the initial load of a dataset
1646
+ with no committed position; without it such a run refuses, since the
1647
+ subscription may be another dataset's. `release_until` ends the
1648
+ subscription of a dataset that holds a committed position and publishes
1649
+ a released position, which every later run reads as nothing to do;
1650
+ nothing else ends it, because the backend holds no SAP credentials.
1651
+
1652
+ Unknown fields are rejected.
1653
+
1654
+ | YAML field | Type | Required | Default | Constraints / description |
1655
+ | --- | --- | --- | --- | --- |
1656
+ | `key` | array of string | yes | none | minItems=`1` |
1657
+ | `deletes` | `"ignore"` | yes | none | |
1658
+ | `reset_subscription_until` | string or null | no | `null` | string: format=`"date-time"` |
1659
+ | `release_until` | string or null | no | `null` | string: format=`"date-time"` |
1660
+
1661
+ ## SharePointExportConfig
1662
+
1663
+ SharePoint upload target via Microsoft Graph.
1664
+
1665
+ Serializes the source DataFrame to `format` (csv / xlsx / parquet)
1666
+ and writes the bytes to `file_path` under `site_url`. Reuses the
1667
+ exact OAuth client-credentials flow and site/library resolution the
1668
+ SharePoint extractor already ships with — same `tenant_id` /
1669
+ `client_id` / `client_secret` triple, same `{{ pipeline_args.* }}`
1670
+ templating, same `library_name` conventions.
1671
+
1672
+ Required Azure AD application permissions: either `Sites.ReadWrite.All`
1673
+ (tenant-wide) or `Sites.Selected` + per-site `write` grant.
1674
+
1675
+ `conflict_behavior=REPLACE` (default) is safe for SharePoint
1676
+ document libraries because versioning is on by default — prior
1677
+ uploads remain recoverable through the SharePoint UI. Targets
1678
+ without versioning (future: raw SFTP) should interpret `REPLACE`
1679
+ as a genuinely destructive overwrite and document that caveat on
1680
+ their own config class.
1681
+
1682
+ Unknown fields are rejected.
1683
+
1684
+ | YAML field | Type | Required | Default | Constraints / description |
1685
+ | --- | --- | --- | --- | --- |
1686
+ | `source_dataset` | string | yes | none | |
1687
+ | `site_url` | string | yes | none | |
1688
+ | `file_path` | string | yes | none | |
1689
+ | `library_name` | string or null | no | `null` | |
1690
+ | `tenant_id` | string or null | no | `null` | |
1691
+ | `client_id` | string or null | no | `null` | |
1692
+ | `client_secret` | string or null | no | `null` | |
1693
+ | `format` | [ExportFormat](#exportformat) | no | `"csv"` | |
1694
+ | `conflict_behavior` | [ConflictBehavior](#conflictbehavior) | no | `"replace"` | |
1695
+ | `csv_options` | [CSVWriteOptions](#csvwriteoptions) | no | none | |
1696
+ | `xlsx_options` | [XLSXWriteOptions](#xlsxwriteoptions) | no | none | |
1697
+
1698
+ ## SharePointExtractConfig
1699
+
1700
+ Extraction settings for SharePoint files via Microsoft Graph API.
1701
+
1702
+ Requires an Azure AD app registration with Sites.Read.All (or
1703
+ Sites.Selected) permission.
1704
+
1705
+ Credentials (`tenant_id`, `client_id`, `client_secret`) are
1706
+ supplied as YAML fields — typically templated via
1707
+ `{{ pipeline_args.NAME }}` so a Remote Job's secret
1708
+ `expectedArguments` flow through at discovery time.
1709
+
1710
+ Unknown fields are rejected.
1711
+
1712
+ | YAML field | Type | Required | Default | Constraints / description |
1713
+ | --- | --- | --- | --- | --- |
1714
+ | `site_url` | string | yes | none | |
1715
+ | `file_path` | string | yes | none | |
1716
+ | `library_name` | string or null | no | `null` | |
1717
+ | `tenant_id` | string or null | no | `null` | |
1718
+ | `client_id` | string or null | no | `null` | |
1719
+ | `client_secret` | string or null | no | `null` | |
1720
+
1721
+ ## SqlDatabaseExtractConfig
1722
+
1723
+ Extraction settings for SQL databases via SQLAlchemy.
1724
+
1725
+ Uses `pd.read_sql` / `pd.read_sql_table` under the hood. The
1726
+ *connection_string* must be a valid SQLAlchemy URL (e.g.
1727
+ `postgresql+psycopg2://user:pass@host/db`).
1728
+
1729
+ Specify exactly one of *query* or *table*.
1730
+
1731
+ `cursor_column` makes the extract incremental. It names a column of the
1732
+ query's result (or of the table) whose values only ever grow for new or
1733
+ changed rows: an `updated_at` timestamp, an autoincrement id, a log
1734
+ sequence number. Each run then reads only the rows past the position the
1735
+ previous run committed, and the dataset's watermark, kept by the backend,
1736
+ remembers that position across runs. The window is fixed before it is
1737
+ read: the run first asks the source for the column's current maximum, then
1738
+ reads `(committed, maximum]`. Each retry measures a new maximum; the bound
1739
+ is fixed within one attempt and does not provide a shared database snapshot.
1740
+ The tenant chooses `write_mode` independently: append and upsert accumulate
1741
+ rows, while overwrite retains only the latest published window. The store
1742
+ must support the requested mode and the extraction lifecycle (see `WriteMode`).
1743
+
1744
+ What the cursor cannot see: a row whose cursor value does not change when
1745
+ the row changes, and a row deleted at the source. Both stay as they were
1746
+ last read. An initial read (no committed bound) refuses null cursors, since
1747
+ no window can include them. Later runs only inspect rows past the committed
1748
+ bound, so historical nulls do not block progress; null rows remain excluded
1749
+ until assigned a cursor beyond that bound. Rows sharing the maximum value
1750
+ with a row still being written at the moment of the read are read once and
1751
+ never again, so the column should be one the source assigns at commit, not
1752
+ at the start of a transaction.
1753
+
1754
+ **Renaming the cursor column, or moving the source, needs an operator step.**
1755
+ The stored progress is keyed by the derivation's version, the driver name,
1756
+ the host and port, the database, the relation *and* the cursor column (for
1757
+ a `query`, the relation is a hash of its exact text), plus a hash of any
1758
+ driver options left in the URL. Changing any of them in this YAML makes
1759
+ every later run refuse:
1760
+ a position measured against one stream never applied to another. Answering
1761
+ that refusal is `PUT /labs/datasets/{id}/watermark`, which states the new
1762
+ key and the position to carry over. Nothing about the data already stored
1763
+ changes. The position carried over names the column it was measured on, and
1764
+ a run whose cursor is a different column refuses it rather than bounding on
1765
+ a value that was never compared against that column.
1766
+
1767
+ Unknown fields are rejected.
1768
+
1769
+ | YAML field | Type | Required | Default | Constraints / description |
1770
+ | --- | --- | --- | --- | --- |
1771
+ | `connection_string` | string | yes | none | |
1772
+ | `table` | string or null | no | `null` | |
1773
+ | `batch_size` | integer | no | `100000` | exclusiveMinimum=`0` |
1774
+ | `query` | string or null | no | `null` | |
1775
+ | `cursor_column` | string or null | no | `null` | |
1776
+
1777
+ ## StepType
1778
+
1779
+ Values: `"extract"`, `"transform"`, `"load"`, `"export"`
1780
+
1781
+ ## TenantCredentialsConfig
1782
+
1783
+ YAML-validated Farseer credentials, embedded as `farseer_credentials:` wherever needed.
1784
+
1785
+ `api_key` is `pydantic.SecretStr` — call `.get_secret_value()`
1786
+ at the boundary where the live string is needed. `hide_input_in_errors`
1787
+ keeps the key out of `pydantic.ValidationError` messages, which
1788
+ by default echo the raw input dict.
1789
+
1790
+ Shape: `tenant_id` + `api_key` are both required whenever the block
1791
+ is present. `base_url` is optional and defaults to the runner's
1792
+ `FARSEER_URL`. To use the runner's own tenant, omit the
1793
+ `farseer_credentials:` block entirely — pydantic enforces the
1794
+ required-pair invariant via the field types.
1795
+
1796
+ Unknown fields are rejected.
1797
+
1798
+ | YAML field | Type | Required | Default | Constraints / description |
1799
+ | --- | --- | --- | --- | --- |
1800
+ | `tenant_id` | string | yes | none | |
1801
+ | `api_key` | string | yes | none | format=`"password"`; secret / write-only |
1802
+ | `base_url` | string or null | no | `null` | |
1803
+
1804
+ ## TextColumn
1805
+
1806
+ Maps a DataFrame column to a TEXT attribute column on a RAMA dim table.
1807
+
1808
+ Unknown fields are rejected.
1809
+
1810
+ | YAML field | Type | Required | Default | Constraints / description |
1811
+ | --- | --- | --- | --- | --- |
1812
+ | `source_column` | string | yes | none | |
1813
+ | `target_dimension_table_column` | string | yes | none | |
1814
+
1815
+ ## TimePoint
1816
+
1817
+ A RAMA time point, identified by (year, month).
1818
+
1819
+ Client-side ID convention matches the backend: `timePointId = year * 100 + month`.
1820
+
1821
+ Unknown fields are rejected.
1822
+
1823
+ | YAML field | Type | Required | Default | Constraints / description |
1824
+ | --- | --- | --- | --- | --- |
1825
+ | `year` | integer | yes | none | minimum=`1900`; maximum=`9999` |
1826
+ | `month` | integer | yes | none | minimum=`1`; maximum=`12` |
1827
+
1828
+ ## TimepointVariableMapping
1829
+
1830
+ Maps a wide-format column to a RAMA variable pinned to a specific timepoint.
1831
+
1832
+ Unlike `LoadVariableMapping` (which maps long-format VALUES columns whose
1833
+ time is resolved per-row from `date:` or Years/Months IDENTIFIER columns),
1834
+ this mapping pins the column to one (year, month) via `timepoint` — the
1835
+ column becomes a TIMEPOINT columnMeta on the import job.
1836
+
1837
+ Unknown fields are rejected.
1838
+
1839
+ | YAML field | Type | Required | Default | Constraints / description |
1840
+ | --- | --- | --- | --- | --- |
1841
+ | `fixed_dimension_members` | array of [FixedDimension](#fixeddimension) | no | none | |
1842
+ | `source_column` | string | yes | none | |
1843
+ | `target_variable` | string | yes | none | |
1844
+ | `timepoint` | [TimePoint](#timepoint) | yes | none | |
1845
+
1846
+ ## TldvExtractConfig
1847
+
1848
+ `extract.type: tldv` — multi-source family over the tl;dv REST API.
1849
+
1850
+ Authentication is a personal API key from tl;dv's settings, sent as
1851
+ `x-api-key`; it is a YAML field, typically templated via
1852
+ `{{ pipeline_args.TLDV_API_KEY }}`. A key sees the meetings its owner
1853
+ can see, and a transcript is exported only for meetings whose organizer
1854
+ is on a paid plan -- tl;dv answers 403 for the others, which the
1855
+ extractor logs and skips per meeting rather than failing the run.
1856
+
1857
+ `meetings` is one row per meeting; `transcripts` one row per spoken
1858
+ segment; `notes` one row per meeting with tl;dv's generated notes as
1859
+ Markdown. The filter block is the same on all three. Every source
1860
+ lands parquet; a `parse:` block is never consulted.
1861
+
1862
+ Unknown fields are rejected.
1863
+
1864
+ | YAML field | Type | Required | Default | Constraints / description |
1865
+ | --- | --- | --- | --- | --- |
1866
+ | `source` | [TldvSource](#tldvsource) | yes | none | |
1867
+ | `api_key` | string or null | no | `null` | |
1868
+ | `meetings` | [TldvMeetingsFilter](#tldvmeetingsfilter) or null | no | `null` | |
1869
+ | `transcripts` | [TldvMeetingsFilter](#tldvmeetingsfilter) or null | no | `null` | |
1870
+ | `notes` | [TldvMeetingsFilter](#tldvmeetingsfilter) or null | no | `null` | |
1871
+
1872
+ ## TldvMeetingsFilter
1873
+
1874
+ Which meetings a tl;dv source reads: a date window.
1875
+
1876
+ Shared by every source, because transcripts and notes are addressed per
1877
+ meeting and so start from the same meeting list. `from_date` and
1878
+ `to_date` are ISO 8601 dates.
1879
+
1880
+ Unknown fields are rejected.
1881
+
1882
+ | YAML field | Type | Required | Default | Constraints / description |
1883
+ | --- | --- | --- | --- | --- |
1884
+ | `from_date` | string or null | no | `null` | |
1885
+ | `to_date` | string or null | no | `null` | |
1886
+ | `page_size` | integer | no | `50` | maximum=`50`; exclusiveMinimum=`0` |
1887
+
1888
+ ## TldvSource
1889
+
1890
+ Sub-discriminator on `extract.tldv.source`.
1891
+
1892
+ Values: `"meetings"`, `"transcripts"`, `"notes"`
1893
+
1894
+ ## TransformConfig
1895
+
1896
+ Configuration for a `type: transform` dataset step.
1897
+
1898
+ Choose the surface in this order and always set `engine`, because its
1899
+ default is `python`: SQL (`duckdb`) for anything set-based, `ibis` when the
1900
+ logic needs Python to compose, and `python` only for work with no lazy form.
1901
+ `duckdb` and `ibis` stream; `python` holds every input and its output in
1902
+ memory.
1903
+
1904
+ For `engine: duckdb`:
1905
+
1906
+ `query` (inline SQL) supplies the query. Upstream `deps` are exposed to
1907
+ the SQL as views named by their leaf name. Output is always parquet.
1908
+ `sql_file` (a `.sql` file in `Code/`) exists for engine-run pipelines but
1909
+ is refused for authored pipelines, which are validated before any source
1910
+ is read; use `query`.
1911
+
1912
+ For `engine: ibis`:
1913
+
1914
+ `script` names a `Code/` file holding an `@ibis_transform` function. The
1915
+ runner calls it with one lazy ibis `Table` per dep, named by the dep's leaf
1916
+ name, and it must return a `Table`; returning a DataFrame is refused. Rows
1917
+ come back in no fixed order unless the expression ends in `.order_by()`.
1918
+
1919
+ from farseer_simple_pipelines import ibis_transform
1920
+
1921
+ @ibis_transform
1922
+ def sales_clean(sales_lines, *, args):
1923
+ t = sales_lines
1924
+ for column in args["code_columns"]:
1925
+ t = t.mutate(**{column: t[column].strip().upper()})
1926
+ return t.order_by(args["code_columns"])
1927
+
1928
+ For `engine: python`:
1929
+
1930
+ `script` is the Python filename containing the `@transform` function.
1931
+ The runner calls it with one pandas DataFrame per dep, as a keyword
1932
+ argument named by the dep's leaf name, and the function returns one
1933
+ DataFrame.
1934
+
1935
+ For both script surfaces:
1936
+
1937
+ `function` optionally overrides which decorated function in the script
1938
+ backs this dataset. When unset, the runner binds the function whose name
1939
+ matches the dataset's leaf name. Setting this lets one shared function
1940
+ back many datasets (e.g. a single `tb_any` used by `tb_c4c`, `tb_cdg`,
1941
+ `tb_cih`). `args` is an arbitrary dict passed to the function's
1942
+ keyword-only `args` parameter, if it declares one. The script lives under
1943
+ `Code/`, mirroring the dataset's folder under `Models/`.
1944
+
1945
+ `format` must be parquet, which is also its default, so there is normally
1946
+ no reason to set it. A transform's output is typed and read back by
1947
+ scanning it, and neither survives csv or json; the rule is enforced at
1948
+ discovery by `validate_transform_declarations`, not here, so that a bad
1949
+ value fails the run rather than skipping the dataset.
1950
+
1951
+ Unknown fields are rejected.
1952
+
1953
+ | YAML field | Type | Required | Default | Constraints / description |
1954
+ | --- | --- | --- | --- | --- |
1955
+ | `engine` | [TransformEngine](#transformengine) | no | `"python"` | |
1956
+ | `script` | string or null | no | `null` | |
1957
+ | `function` | string or null | no | `null` | |
1958
+ | `query` | string or null | no | `null` | |
1959
+ | `sql_file` | string or null | no | `null` | |
1960
+ | `format` | [DataFormat](#dataformat) | no | `"parquet"` | |
1961
+ | `args` | object | no | none | |
1962
+ | `max_file_size` | string or integer or null | no | `null` | |
1963
+
1964
+ ### Example
1965
+
1966
+ ```yaml
1967
+ # Models/sales_monthly.yaml: a file's name must match its `name:`.
1968
+ # Totals the month by product and region in SQL. Each dep is a view named after
1969
+ # its leaf name; cast SUMs and dates, which DuckDB returns as DECIMAL and DATE.
1970
+ name: sales_monthly
1971
+ type: transform
1972
+ deps: [sales_raw]
1973
+ transform:
1974
+ engine: duckdb
1975
+ query: |
1976
+ SELECT
1977
+ product,
1978
+ region,
1979
+ strftime(CAST(sale_date AS DATE), '%Y-%m-01') AS month,
1980
+ CAST(SUM(amount) AS DOUBLE) AS amount
1981
+ FROM sales_raw
1982
+ GROUP BY ALL
1983
+ ```
1984
+
1985
+ ## TransformEngine
1986
+
1987
+ How a transform is authored, and therefore whether it materialises.
1988
+
1989
+ Not the compute engine, despite the name: there is one of those, DuckDB, and
1990
+ every surface here runs on it. What this selects is the authoring surface --
1991
+ and because exactly one surface holds a whole dataset in memory, it is also
1992
+ the step's resource envelope, declared where a scheduler can read it before
1993
+ the step has ever run. The name is kept because the field is a tenant's
1994
+ YAML.
1995
+
1996
+ `duckdb` runs author SQL over the dependency relations. Streams.
1997
+
1998
+ `ibis` runs an `@ibis_transform` function over lazy tables, returning one.
1999
+ Streams.
2000
+
2001
+ `python` runs a `@transform` function over DataFrames, returning one. **The
2002
+ only surface that materialises**, so a step declaring it is bounded by the
2003
+ container rather than by a memory limit.
2004
+
2005
+ Values: `"python"`, `"duckdb"`, `"ibis"`
2006
+
2007
+ ## WriteMode
2008
+
2009
+ Choose how an extract or transform writes its output to a dataset.
2010
+
2011
+ `overwrite` replaces the rows, `append` adds rows, and `upsert` replaces
2012
+ matching keys while retaining the others. The tenant chooses the mode on
2013
+ each run, independently of whether the source uses a cursor. Overwriting
2014
+ an incremental window and appending a complete result are both intentional
2015
+ choices we support. The store must implement the requested mode; currently
2016
+ only the Iceberg store supports append and upsert.
2017
+
2018
+ Quality rules and `schema:` see the accumulated dataset rather than this
2019
+ run's rows, because validation loads back what was persisted. A rule has to
2020
+ hold across runs. Schema-only checks avoid a cached copy, but quality rules
2021
+ materialize the full dataset; incremental reads do not make validation cost
2022
+ proportional to the new window.
2023
+
2024
+ A run whose window read no rows publishes no version and adds no file, so
2025
+ what a consumer reads tracks changes rather than runs. The exception is an
2026
+ extractor that returns its position as a `MovedPosition` (SAP ODP, which
2027
+ serves an older delta token only as a recovery of what it already
2028
+ delivered): that window is published, empty, to carry it. Declared validation
2029
+ still checks the published dataset: rules may have changed since the last
2030
+ publication. A first run over an empty source does publish, so a consumer
2031
+ finds an empty dataset rather than none, provided the step declares its
2032
+ column types under `schema:`. Without them the Iceberg store refuses that
2033
+ run: every column of an empty result arrives untyped, and a new table needs
2034
+ types.
2035
+
2036
+ The candidate that a quiet run opened is cancelled and its logical version
2037
+ number stays consumed. Physical cleanup and metadata retention are deferred;
2038
+ the abandonment sweep only marks eligible active attempts cancelled.
2039
+
2040
+ Values: `"overwrite"`, `"append"`, `"upsert"`
2041
+
2042
+ ## XLSXWriteOptions
2043
+
2044
+ Options for DataFrame → XLSX serialization on export.
2045
+
2046
+ Unknown fields are rejected.
2047
+
2048
+ | YAML field | Type | Required | Default | Constraints / description |
2049
+ | --- | --- | --- | --- | --- |
2050
+ | `sheet_name` | string | no | `"Sheet1"` | |
2051
+ | `include_header` | boolean | no | `true` | |
2052
+
2053
+ ## XlsxParseOptions
2054
+
2055
+ xlsx-specific parse options (passed to `pd.read_excel`).
2056
+
2057
+ Unknown fields are rejected.
2058
+
2059
+ | YAML field | Type | Required | Default | Constraints / description |
2060
+ | --- | --- | --- | --- | --- |
2061
+ | `sheet_name` | string or integer | no | `0` | |
2062
+ | `columns` | string or null | no | `null` | |
2063
+ | `has_header` | boolean | no | `true` | |
2064
+ | `start_row` | integer or null | no | `null` | |