Skip to content
Build with Mammoth › CLI reference: open the docs menu

mammoth dataset

Generated from mammoth-cli 2.4.2, released 2026-11-02: mammoth schema list, mammoth capability list and the CLI's own --help. Do not edit by hand; run npm run docs:capabilities.

Create, inspect, and manage datasets. 37 commands.

Every command also takes the global flags (--output, --yes, --confirm, --dry-run, --input, --profile, ...), which are not repeated below. --input takes a JSON or YAML document of the input fields; mammoth schema get COMMAND_ID prints a command's full input schema.

Confirmation. Commands marked --yes --confirm TARGET or --yes always need those flags, even at a terminal: they never prompt. Commands marked "--yes or prompt" ask at an interactive terminal (table output, no --no-input) and otherwise need --yes. --dry-run skips confirmation and sends nothing.

Summary

CommandWhat it doesEffectConfirmation
dataset batch-dataFetch data for a specific dataset batch.Read—
dataset bulk-deletePermanently delete the listed datasets. 'dataset_ids' from '--input'; '--yes' required.Destructive--yes or prompt
dataset bulk-updateApply a bulk patch across the active project's datasets. High-impact.High impact--yes --confirm TARGET
dataset column-statsEvery column's blanks, type and distinct count for each dataset in the project.Read—
dataset createCreate a dataset (web URL, clone, or import from a connection such as SFTP).Benign mutation—
dataset create-from-pdfCreate dataset(s) from tables extracted out of a PDF file.Benign mutation—
dataset dataFetch a dataset's data, waiting for the backing job to complete.Read—
dataset deletePermanently delete one dataset by id. Prompt or '--yes' required.Destructive--yes or prompt
dataset downloadDownload several datasets, views and folders as one csv, zip of csvs or xlsx file.Benign mutation—
dataset download-planSay what downloading several datasets, views and folders would hold.Read—
dataset findSearch dataset names for a substring across every visible project.Read—
dataset getGet one dataset by id in the active project.Read—
dataset listList datasets in the active project, newest first, each with what tells them apart.Read—
dataset refreshFetch a URL dataset's link again into the same dataset. Prompt or '--yes' required.Benign mutation--yes or prompt
dataset renameRename a dataset. Dataset id is positional; new name comes from '--input'.Benign mutation—
dataset restoreRestore a trashed dataset.Benign mutation—
dataset schema-diffCompare two datasets' columns and propose the 'batch create' mapping.Read—
dataset searchFind the project's datasets whose name, column names or sampled values hold TERM.Read—
dataset trashMove one dataset to the project trash (reversible).Benign mutation—
dataset updateReject untyped dataset patches; use a typed dataset command instead.High impact--yes --confirm TARGET
dataset broken-rows listList the lines of a dataset's uploaded file that could not be parsed.Read—
dataset broken-rows resolveAdd corrected set-aside lines to a dataset, or discard them. Prompt or '--yes'.Destructive--yes or prompt
dataset definition addSave what a term means for a dataset ('term' and 'definition' from '--input').Benign mutation--yes --confirm TARGET
dataset definition listList what terms mean for one dataset, as its users saved them.Read—
dataset definition removeRemove one definition from a dataset by its id. Prompt or '--yes' required.Benign mutation--yes or prompt
dataset file-settings getGet file settings (delimiter, header, dates, ...) for a dataset.Read—
dataset file-settings undoUndo the last file settings change for a dataset. Prompt or '--yes' required.Destructive--yes or prompt
dataset file-settings updateUpdate a dataset's file settings from '--input'.Benign mutation—
dataset from-url followMake a dataset made from a link follow it again, or turn it into a copy.Benign mutation—
dataset from-url linksShow which of the project's datasets follow a link, with their last fetch.Read—
dataset from-url previewRead the CSV, Excel or JSON file at a link and show its tables, keeping nothing.Read—
dataset interpretation confirmPreview or confirm how a file that can be read several ways is interpreted.Benign mutation—
dataset interpretation previewPreview or confirm how a file that can be read several ways is interpreted.Benign mutation—
dataset tool-claim getSay what an emailed Open tables link opens.Read—
dataset tool-claim redeemAdd the tables of an emailed Open tables link to a project, in a new folder.Benign mutation—
dataset update-method getSay whether a new file replaces this dataset's rows or adds to them.Read—
dataset update-method setSet whether a new file replaces this dataset's rows ('replace') or adds to them.Benign mutation—

dataset commands

mammoth dataset batch-data

Fetch data for a specific dataset batch.

mammoth dataset batch-data 123 456
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
BATCH_IDpositionalyes—intID of the batch.
columns--input fieldno—str | list[str] | None
limit--input fieldno50int
offset--input fieldno0int
timeout--input fieldno—int
poll_interval--input fieldno—float
  • Effect: Read, scope project · Confirmation: none · Pages: offset
  • Preconditions: Dataset and batch parent are explicit; limit is 0..100 and offset is non-negative.
  • Id: dataset.batch-data · Result: DatasetBatchDataResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.get_batch_data, API GET /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/batches/{batch_id}/data (GetBatchData)

mammoth dataset bulk-delete

Permanently delete the listed datasets. 'dataset_ids' from '--input'; '--yes' required.

mammoth dataset bulk-delete --input '{"dataset_ids": [456, 457]}' --yes
NamePassed asRequiredDefaultTypeNotes
dataset_ids--input fieldno—list[int]
  • Effect: Destructive, scope project · Confirmation: --yes, or answer the prompt at an interactive terminal
  • Preconditions: Deletes every listed dataset for good and cannot be undone. A dataset that another view uses as a lookup or join source is kept, and the result says so. List them first (dataset list). Needs a prompt or --yes.
  • Id: dataset.bulk-delete · Result: DatasetBulkDeleteResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.bulk_delete, API DELETE /workspaces/{workspace_id}/projects/{project_id}/datasets (DeleteDatasets)

mammoth dataset bulk-update

Apply a bulk patch across the active project's datasets. High-impact.

mammoth dataset bulk-update --input '{"patch_data": {"name": "Status"}}' --yes
NamePassed asRequiredDefaultTypeNotes
patch_data--input fieldyes—dict[str, any]
  • Effect: High impact, scope project · Confirmation: always --yes --confirm TARGET, even at a terminal (TARGET is the exact id or name acted on; the confirmation_required error's hint names it)
  • Id: dataset.bulk-update · Result: DatasetBulkUpdateResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.bulk_update, API PATCH /workspaces/{workspace_id}/projects/{project_id}/datasets (UpdateDatasets)

mammoth dataset column-stats

Every column's blanks, type and distinct count for each dataset in the project.

mammoth dataset column-stats
  • Effect: Read, scope project · Confirmation: none
  • Preconditions: Needs a project. Use this instead of profiling each view when the question spans datasets ("missing values", "blanks", "data quality across the project"): one call returns every dataset's columns with their blank count and share, type and distinct count, from stats stored at the last load or pipeline run. Rank columns by blank_pct (or blank_count) and name the worst dataset and column.
  • Id: dataset.column-stats · Result: DatasetColumnStatsResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.column_stats, API GET /workspaces/{workspace_id}/projects/{project_id}/datasets/column-stats (GetProjectColumnStats)

mammoth dataset create

Create a dataset (web URL, clone, or import from a connection such as SFTP).

Allowed values: dataset_spec.query_properties.data_pull_file: 'Pull same file', 'Pull next file based on name pattern'

mammoth dataset create --input '{"dataset_spec": {"url": "https://sampledata.mammoth.io/Multi-Store_Retail_Sales.csv"}, "ds_creation_type": "weburl"}'
NamePassed asRequiredDefaultTypeNotes
dataset_spec--input fieldyes—dict[str, any]
ds_creation_type--input fieldyes—str
folder_resource_id--input fieldno—str
  • Effect: Benign mutation, scope project · Confirmation: none · Waits: waits for the job to finish (--job-timeout, --return-running)
  • Preconditions: ds_creation_type=weburl (dataset_spec.url), clone, or cloud (a file, REST API or database query from a connection); the command waits for the job and returns the new dataset_id. A weburl dataset keeps its link and can be refreshed on demand (dataset refresh DATASET_ID --yes, or Refresh from URL in the web app; a single CSV only), but never on a schedule: automation's run_data_retrieval task cannot refresh it (only a cloud-connected dataset can be refreshed); for a scheduled pull from a URL use the REST API connector. Say so rather than scheduling a refresh for it. The result's name is the dataset's real name; when the requested name was taken the server adds a suffix, and requested_name and note say so. Use name, not the name you asked for. To copy a dataset as a new independent one: {"ds_creation_type": "clone", "dataset_spec": {"ds_name": NEW_NAME, "source_ds_id": ID, "clone_dataview_ids": [DEFAULT_VIEW_ID], "exclude_data": false}}, DEFAULT_VIEW_ID being the id in dataset's default_view from view list (other views only when asked); an empty clone_dataview_ids is refused here because it makes a blank view. A clone waits and returns the new dataset_id; never use view export dataset for a plain copy, which leaves a live export on the source. A weburl import names the dataset after the downloaded file: follow it with dataset rename to the name the user picked. To import a file from an SFTP server (or another file connector) as a new dataset: connector connection create sftp, then {"ds_creation_type": "cloud", "dataset_spec": {"connector_key": "sftp", "connection_key": KEY, "query_properties": {"ds_name": NAME, "file_path": PATH_ON_SERVER, "data_pull_file": "Pull same file"}}}. data_pull_file is a string and may be left out, which means "Pull same file" (what the web app does); its only other value is "Pull next file based on name pattern", which also needs folder_path and name_pattern. A pull that finds no file at the path fails the create with the server's reason; the recipe is recipes/file-import.md. To import from a REST API or Elasticsearch: the connection must exist first (connector connection create generic_rest_api, in the same project); try the query with connector ds-config create (data_sample, creates no dataset; connector connection query takes SQL only and refuses a REST config); then {"ds_creation_type": "cloud", "dataset_spec": {"connector_key": "generic_rest_api", "connection_key": KEY, "query_properties": {"ds_name": NAME, "table_name": TABLE, "query": "<JSON string of the endpoint config>"}, "schedule_properties": {"schedule_type": "moment", "first_pull_at": "now", "on_refresh_action": "replace"}, "recurrence_info": {"interval": 1, "start_at": "<future ISO time>"}}}. schedule_properties and recurrence_info are required (without them the job fails with Invalid parameters); on_refresh_action combine appends every refresh, so rows duplicate. The recipe is recipes/rest-api-import.md. To make a dataset from a database query (SQL Server, MySQL, Postgres, ...): connector connection create for the database, try the SELECT with connector connection query (read-only, saves nothing), then connector ds-config create CONNECTOR_KEY CONNECTION_KEY with {"query": SELECT, "table": NAME}; the recipe is recipes/database-import.md. Other ds_creation_type values and dataset_spec shapes: variants beyond the documented path are not qualified.
  • Id: dataset.create · Result: DatasetCreateResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.create, API POST /workspaces/{workspace_id}/projects/{project_id}/datasets (CreateDatasets)

mammoth dataset create-from-pdf

Create dataset(s) from tables extracted out of a PDF file.

mammoth dataset create-from-pdf 123 --input '{"file_name": "./sales.csv"}'
NamePassed asRequiredDefaultTypeNotes
FILE_OBJECT_IDpositionalyes—intID of the file object.
file_name--input fieldyes—str
file_id--input fieldno—str
table_list--input fieldno—list[int]
delete_file_after_extract--input fieldnofalsebool
is_preview_needed--input fieldno—bool
user_instruction--input fieldno—str
  • Effect: Benign mutation, scope project · Confirmation: none
  • Preconditions: Add table_list (table indices to extract) to the input: {"file_name": "report.pdf", "table_list": [0]}. The API refuses a call with no table_list. user_instruction cannot be combined with table_list.
  • Id: dataset.create-from-pdf · Result: DatasetCreateFromPdfResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.create_from_pdf, API POST /workspaces/{workspace_id}/projects/{project_id}/datasets-from-pdf (CreateDatasetFromPdf)

mammoth dataset data

Fetch a dataset's data, waiting for the backing job to complete.

mammoth dataset data 123
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
timeout--input fieldno300int
poll_interval--input fieldno—float
  • Effect: Read, scope project · Confirmation: none · Waits: waits for the job to finish (--job-timeout, --return-running)
  • Preconditions: Required inputs: DATASET_ID.
  • Id: dataset.data · Result: DatasetDataResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.get_data, API GET /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/data (GetDatasetData)

mammoth dataset delete

Permanently delete one dataset by id. Prompt or '--yes' required.

mammoth dataset delete 123 --yes
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
  • Effect: Destructive, scope project · Confirmation: --yes, or answer the prompt at an interactive terminal
  • Preconditions: Immutable dataset-ID confirmation.
  • Id: dataset.delete · Result: DatasetDeleteResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.delete, API DELETE /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id} (DeleteDataset)

mammoth dataset download

Download several datasets, views and folders as one csv, zip of csvs or xlsx file.

mammoth dataset download --input '{"resource_ids": [12, 13], "name": "sales", "file_type": "csv"}'
NamePassed asRequiredDefaultTypeNotes
resource_ids--input fieldyes—list[int]
name--input fieldyes—str
output_path--input fieldno—str | Path | None
file_type--input fieldnocsvLiteral['csv', 'xlsx']One of csv, xlsx.
stack--input fieldnofalsebool
numbered--input fieldnofalsebool
views--input fieldno—dict[int, int]
timeout--input fieldno300int
  • Effect: Benign mutation, scope project · Confirmation: none · Waits: waits for the job to finish (--job-timeout, --return-running)
  • Preconditions: Input: resource_ids (dataset, view and folder ids, in file order) and name (the file name without extension) are required; file_type is csv (a zip of CSVs when there are several) or xlsx (one workbook, a sheet per dataset); stack, numbered, views ({dataset id: view id}), output_path and timeout are optional. An existing output file is refused with file_exists unless --overwrite is given. Check the size first with dataset download-plan.
  • Id: dataset.download · Result: DatasetDownloadResult

mammoth dataset download-plan

Say what downloading several datasets, views and folders would hold.

mammoth dataset download-plan --input '{"resource_ids": [12, 13]}'
NamePassed asRequiredDefaultTypeNotes
resource_ids--input fieldyes—list[int]
views--input fieldno—dict[int, int]
  • Effect: Read, scope project · Confirmation: none
  • Preconditions: Reads headers only: how many datasets a download holds and how many files it is with same-column datasets stacked.
  • Id: dataset.download-plan · Result: DatasetDownloadPlanResult

mammoth dataset find

Search dataset names for a substring across every visible project.

mammoth dataset find sales
NamePassed asRequiredDefaultTypeNotes
NAME_SUBSTRINGpositionalno—strCase-insensitive substring to match against dataset names; optional when --input gives 'columns'. Matches in other projects are listed too, marked in_project when --project is given.
all_projects--input fieldnofalsebool
  • Effect: Read, scope project · Confirmation: none
  • Id: dataset.find · Result: DatasetFindResult

mammoth dataset get

Get one dataset by id in the active project.

mammoth dataset get 123
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
  • Effect: Read, scope project · Confirmation: none
  • Preconditions: Required inputs: DATASET_ID.
  • Id: dataset.get · Result: DatasetGetResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.get, API GET /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id} (GetDataset)

mammoth dataset list

List datasets in the active project, newest first, each with what tells them apart.

mammoth dataset list
NamePassed asRequiredDefaultTypeNotes
limit--input fieldno100int
offset--input fieldno0int
sort--input fieldno(created_at:desc)str
ids--input fieldno—list[int]
full--input fieldnofalsebool
name--input fieldno—str
names--input fieldnofalsebool
  • Effect: Read, scope project · Confirmation: none · Pages: single_page
  • Preconditions: B01. Newest first. Each item carries rows and cols, created and updated time (updated is left out when it equals created), the source kind (file, connector, created in Mammoth, export of a view), and its column names with types, from the list route's stored stats, sources and data_schema, cut to fit the agent tool output cap: more is true with next_offset when the page was cut. full true returns the raw id and name list. name (input field, a case-insensitive substring) reads every page and returns only the matching datasets as short rows (id, name, rows, cols; no column lists) with matched, and more with next_offset when cut; limit and offset then page over the matches. limit must be at most 100. names true returns up to 500 bare id and name rows of the project in ONE call, newest first, with total and more: use it for a list of names (which files can I see), never page offsets. Without a project use dataset find NAME_SUBSTRING.
  • Id: dataset.list · Result: DatasetListResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.list, API GET /workspaces/{workspace_id}/projects/{project_id}/datasets (GetDatasets)

mammoth dataset refresh

Fetch a URL dataset's link again into the same dataset. Prompt or '--yes' required.

mammoth dataset refresh 123 --yes
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
  • Effect: Benign mutation, scope project · Confirmation: --yes, or answer the prompt at an interactive terminal · Waits: waits for the job to finish (--job-timeout, --return-running)
  • Preconditions: Fetches the link of a dataset made from a URL (dataset create with ds_creation_type weburl; dataset list shows it as source url with the link host) again into the same dataset, and waits for the job. Whether the new data replaces or adds to the old follows the dataset's own data addition setting. A dataset not made from a URL is refused, and so is a URL that serves JSON; the server's reason is shown. A single CSV only. It never refreshes on a schedule, and automation run_data_retrieval cannot refresh it; for a scheduled pull from a URL use the REST API connector.
  • Id: dataset.refresh · Result: DatasetRefreshResult

mammoth dataset rename

Rename a dataset. Dataset id is positional; new name comes from '--input'.

mammoth dataset rename 123 --input '{"name": "Revenue report"}'
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
name--input fieldyes—str
unique--input fieldnofalsebool
  • Effect: Benign mutation, scope project · Confirmation: none
  • Preconditions: Convenience alias implemented through DatasetsAPI.update but registered as its own canonical command.
  • Id: dataset.rename · Result: DatasetRenameResult

mammoth dataset restore

Restore a trashed dataset.

mammoth dataset restore 123
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
  • Effect: Benign mutation, scope project · Confirmation: none
  • Preconditions: Required inputs: DATASET_ID.
  • Id: dataset.restore · Result: DatasetRestoreResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.restore, API POST /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/restore (RestoreDataset)

mammoth dataset schema-diff

Compare two datasets' columns and propose the 'batch create' mapping.

mammoth dataset schema-diff 10 11
NamePassed asRequiredDefaultTypeNotes
DESTINATION_IDpositionalyes—intDataset the rows would be appended into (the DATASET_ID of batch create).
SOURCE_IDpositionalyes—intDataset whose rows would be appended (the SOURCE_ID of batch create).
  • Effect: Read, scope project · Confirmation: none
  • Preconditions: Required inputs: DESTINATION_ID, SOURCE_ID.
  • Id: dataset.schema-diff · Result: DatasetSchemaDiffResult

Find the project's datasets whose name, column names or sampled values hold TERM.

mammoth dataset search 'New Year Sale'
NamePassed asRequiredDefaultTypeNotes
TERMpositionalyes—strText to find in dataset names, column names or sampled column values (case-insensitive, at least 2 characters).
  • Effect: Read, scope project · Confirmation: none
  • Preconditions: Required inputs: TERM.
  • Id: dataset.search · Result: DatasetSearchResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.search, API GET /workspaces/{workspace_id}/projects/{project_id}/datasets/search (SearchDatasetsByContent)

mammoth dataset trash

Move one dataset to the project trash (reversible).

mammoth dataset trash 123
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
  • Effect: Benign mutation, scope project · Confirmation: none
  • Preconditions: Required inputs: DATASET_ID.
  • Id: dataset.trash · Result: DatasetTrashResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.trash, API POST /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/trash (TrashDataset)

mammoth dataset update

Reject untyped dataset patches; use a typed dataset command instead.

mammoth dataset update --input '{"patch_data": [{"name": "Status"}]}' --yes
NamePassed asRequiredDefaultTypeNotes
patch_data--input fieldyes—list[dict[str, any]]
  • Effect: High impact, scope project · Confirmation: always --yes --confirm TARGET, even at a terminal (TARGET is the exact id or name acted on; the confirmation_required error's hint names it)
  • Id: dataset.update · Result: DatasetUpdateResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.update, API PATCH /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id} (UpdateDataset)

dataset broken-rows

mammoth dataset broken-rows list

List the lines of a dataset's uploaded file that could not be parsed.

mammoth dataset broken-rows list 123
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
  • Effect: Read, scope project · Confirmation: none
  • Preconditions: Returns the first 100 lines the upload could not parse, each with its line number, upload (batch_id) and why it does not fit the columns; row_count is the total. A dataset not made from a file upload has none.
  • Id: dataset.broken-rows.list · Result: DatasetBrokenRowsListResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.get_unstructured_rows, API GET /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/unstructured_rows (GetUnstructuredRows)

mammoth dataset broken-rows resolve

Add corrected set-aside lines to a dataset, or discard them. Prompt or '--yes'.

mammoth dataset broken-rows resolve 123 --input '{"op": "add", "batch_id": 1, "rows": [{"line_num": 2, "line": "corrected,line,here"}]}' --yes
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
op--input fieldyes—Literal['add', 'remove']One of add, remove.
batch_id--input fieldyes—int
rows--input fieldyes—list[dict[str, any]]
  • Effect: Destructive, scope project · Confirmation: --yes, or answer the prompt at an interactive terminal
  • Preconditions: op "add" takes each corrected line (line_num, batch_id and the original line from dataset broken-rows list, edited so its column count matches) into the dataset; op "remove" discards the lines for good. Returns a job: run job wait on it, then read broken-rows list (row_count 0 and dataset status ready mean it is finished). Confirm with the user first, and say that discarded lines do not come back.
  • Id: dataset.broken-rows.resolve · Result: DatasetBrokenRowsResolveResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.resolve_unstructured_rows, API PATCH /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/unstructured_rows (PatchUnstructuredRows)

dataset definition

mammoth dataset definition add

Save what a term means for a dataset ('term' and 'definition' from '--input').

mammoth dataset definition add 123 --input '{"term": "late", "definition": "delivered more than 5 days after shipped_date"}' --yes --confirm 123
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
term--input fieldyes—str
definition--input fieldyes—str
  • Effect: Benign mutation, scope project · Confirmation: always --yes --confirm TARGET, even at a terminal (TARGET is the exact id or name acted on; the confirmation_required error's hint names it)
  • Preconditions: Saves what a term means for this dataset: term (1-60 characters) and definition (1-300 characters) from --input. A definition is shared by everyone's chats on this dataset, so the user confirms each save. Save one only when the user states what a term means for this data, not to answer a one-off question. Write the definition in terms of the dataset's real column names. A definition for an existing term (any case) replaces it; at most 20 per dataset. The project's definitions already appear in every turn's context, so there is no need to list them before answering.
  • Id: dataset.definition.add · Result: DatasetDefinitionAddResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.add_definition, API POST /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/definitions (AddDatasetDefinition)

mammoth dataset definition list

List what terms mean for one dataset, as its users saved them.

mammoth dataset definition list 123
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
  • Effect: Read, scope project · Confirmation: none
  • Preconditions: Lists what terms mean for this dataset (id, term, definition), shared by everyone's chats on it. The project's definitions already appear in every turn's context, so there is no need to list them before answering; list them to find the id to remove.
  • Id: dataset.definition.list · Result: DatasetDefinitionListResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.list_definitions, API GET /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/definitions (GetDatasetDefinitions)

mammoth dataset definition remove

Remove one definition from a dataset by its id. Prompt or '--yes' required.

mammoth dataset definition remove 123 a1b2c3d4 --yes
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
DEFINITION_IDpositionalyes—strID of the definition.
  • Effect: Benign mutation, scope project · Confirmation: --yes, or answer the prompt at an interactive terminal
  • Preconditions: Removes one definition by the id dataset definition list returns; use it when the user asks to drop or forget what a term means for this dataset. Everyone's chats on the dataset stop using it.
  • Id: dataset.definition.remove · Result: DatasetDefinitionRemoveResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.remove_definition, API DELETE /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/definitions/{definition_id} (RemoveDatasetDefinition)

dataset file-settings

mammoth dataset file-settings get

Get file settings (delimiter, header, dates, ...) for a dataset.

mammoth dataset file-settings get 123
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
  • Effect: Read, scope project · Confirmation: none
  • Preconditions: Required inputs: DATASET_ID.
  • Id: dataset.file-settings.get · Result: DatasetFileSettingsGetResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.get_file_settings, API GET /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/file_settings (GetFileSettings)

mammoth dataset file-settings undo

Undo the last file settings change for a dataset. Prompt or '--yes' required.

mammoth dataset file-settings undo 123 --yes
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
  • Effect: Destructive, scope project · Confirmation: --yes, or answer the prompt at an interactive terminal
  • Preconditions: Required inputs: DATASET_ID.
  • Id: dataset.file-settings.undo · Result: DatasetFileSettingsUndoResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.file_settings_undo, API DELETE /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/file_settings (UndoFileSettings)

mammoth dataset file-settings update

Update a dataset's file settings from '--input'.

mammoth dataset file-settings update 123 --input '{"initial_skip_count": 2}'
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
delimiter--input fieldno—str
has_header--input fieldno—bool
initial_skip_count--input fieldno—int
quotechar--input fieldno—str
date_format--input fieldno—str
preview_mode--input fieldnofalsebool
skip_auto_process_check--input fieldnotruebool
date_formats--input fieldno—dict[str, str]
set_project_level_date_format--input fieldnofalsebool
  • Effect: Benign mutation, scope project · Confirmation: none · Waits: waits for the job to finish (--job-timeout, --return-running)
  • Preconditions: Required inputs: DATASET_ID.
  • Id: dataset.file-settings.update · Result: DatasetFileSettingsUpdateResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.file_settings_update, API POST /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/file_settings (UpdateFileSettings)

dataset from-url

mammoth dataset from-url follow

Make a dataset made from a link follow it again, or turn it into a copy.

mammoth dataset from-url follow 123 --input '{"follow": false}'
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
follow--input fieldnotruebool
  • Effect: Benign mutation, scope project · Confirmation: none
  • Preconditions: Follow true keeps the dataset refreshing from its link; follow false makes it a copy.
  • Id: dataset.from-url.follow · Result: DatasetFromUrlFollowResult

Show which of the project's datasets follow a link, with their last fetch.

mammoth dataset from-url links
  • Effect: Read, scope project · Confirmation: none
  • Id: dataset.from-url.links · Result: DatasetFromUrlLinksResult

mammoth dataset from-url preview

Read the CSV, Excel or JSON file at a link and show its tables, keeping nothing.

mammoth dataset from-url preview https://example.com/data.csv
NamePassed asRequiredDefaultTypeNotes
URLpositionalyes—strURL slug identifying the resource.
  • Effect: Read, scope project · Confirmation: none
  • Preconditions: Reads the file at the link and keeps nothing; use it before creating a dataset from a URL.
  • Id: dataset.from-url.preview · Result: DatasetFromUrlPreviewResult

dataset interpretation

mammoth dataset interpretation confirm

Preview or confirm how a file that can be read several ways is interpreted.

mammoth dataset interpretation confirm 123
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
user_instruction--input fieldno—str
structure_map--input fieldno—dict[str, any]
destination_dataset_id--input fieldno—int
mode--input fieldno—str
  • Effect: Benign mutation, scope project · Confirmation: none
  • Preconditions: Finalizes a dataset whose file has more than one plausible reading (status has_unstructured_data): applies the interpretation to the whole file and creates the table. Run interpretation preview first and pass the same input here, or the structure_map it returned. The suggestions stored on the dataset are under additional_info.interpretation.instruction_suggestions in dataset get. Pass mode "original" (alone: it takes no reshape field) to keep the file in the layout it was uploaded in; later files for the dataset are then ingested the same way, without review. The result state shows the dataset afterwards. Example: --input '{"user_instruction": "Skip preamble rows, row 5 is the header"}'.
  • Id: dataset.interpretation.confirm · Result: DatasetInterpretationConfirmResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.interpretation_confirm, API PATCH /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/interpretation (ConfirmDatasetInterpretation)

mammoth dataset interpretation preview

Preview or confirm how a file that can be read several ways is interpreted.

mammoth dataset interpretation preview 123
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
user_instruction--input fieldno—str
structure_map--input fieldno—dict[str, any]
destination_dataset_id--input fieldno—int
  • Effect: Benign mutation, scope project · Confirmation: none
  • Preconditions: Shows the rows the dataset would have under an interpretation, without finalizing it: preview_rows (header plus up to 50 rows), total_row_count, structure_map and header_types. --input needs user_instruction (plain English; the suggestions stored on the dataset are in dataset get under additional_info.interpretation.instruction_suggestions), a structure_map from an earlier preview, or destination_dataset_id. Nothing is applied to the file until interpretation confirm. Example: --input '{"user_instruction": "Skip preamble rows, row 5 is the header"}'.
  • Id: dataset.interpretation.preview · Result: DatasetInterpretationPreviewResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.interpretation_preview, API POST /workspaces/{workspace_id}/projects/{project_id}/datasets/{dataset_id}/interpretation/preview (PreviewDatasetInterpretation)

dataset tool-claim

mammoth dataset tool-claim get

Say what an emailed Open tables link opens.

mammoth dataset tool-claim get --input '{"token": "replace-with-secret"}'
NamePassed asRequiredDefaultTypeNotes
token--input fieldyes—str
  • Effect: Read, scope project · Confirmation: none
  • Id: dataset.tool-claim.get · Result: DatasetToolClaimGetResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.tool_claim_get, API GET /tool-claims (GetToolClaim)

mammoth dataset tool-claim redeem

Add the tables of an emailed Open tables link to a project, in a new folder.

mammoth dataset tool-claim redeem --input '{"token": "replace-with-secret"}'
NamePassed asRequiredDefaultTypeNotes
token--input fieldyes—str
  • Effect: Benign mutation, scope project · Confirmation: none
  • Preconditions: The link must have been emailed to the signed-in user. Redeeming it again adds nothing and returns where the tables already are.
  • Id: dataset.tool-claim.redeem · Result: DatasetToolClaimRedeemResult · Backed by: SDK mammoth.api.datasets.DatasetsAPI.tool_claim_redeem, API POST /workspaces/{workspace_id}/projects/{project_id}/tool-claims (RedeemToolClaim)

dataset update-method

mammoth dataset update-method get

Say whether a new file replaces this dataset's rows or adds to them.

mammoth dataset update-method get 123
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
  • Effect: Read, scope project · Confirmation: none
  • Preconditions: mode "add" means each new file (an upload with append_to_ds_id, or a folder automation) adds its rows to the dataset; "replace" means it takes the place of the rows already there. A dataset with no setting stored adds.
  • Id: dataset.update-method.get · Result: DatasetUpdateMethodGetResult

mammoth dataset update-method set

Set whether a new file replaces this dataset's rows ('replace') or adds to them.

mammoth dataset update-method set 123 --input '{"mode": "replace"}'
NamePassed asRequiredDefaultTypeNotes
DATASET_IDpositionalyes—intID of the dataset.
mode--input fieldyes—str
schema_mapping--input fieldno—dict[str, list[str]]
  • Effect: Benign mutation, scope project · Confirmation: none
  • Preconditions: mode "replace" or "add". It stays on the dataset: every later upload into it (file upload with append_to_ds_id) and every folder automation feeding it follows it, until it is set again. Optional schema_mapping {"dataset column": ["file column"]} matches a new file's columns to the dataset's. The other settings for new rows are kept as stored.
  • Id: dataset.update-method.set · Result: DatasetUpdateMethodSetResult

Report an issue · support@mammoth.io