Skip to content

Public API

Use import fieldwork as fw. The signatures below are generated from the documented implementation. Discovery functions return InvestigationResult; suggest_paths returns PathResult; foundational analyses return ExplorerResult. All accept pandas dataframes and preserve source values.

Need Operation
Compact orientation explore
Availability and entity summaries missingness
Candidate grain and approximate/conditional mappings discover_dependencies
Browsing order suggest_paths
String, numeric and indexed-family evidence value_patterns
Independent counts / ordered prefixes levels / census
Supplied candidate exact grain grain
Associations and absence / selected joint counts pairs / joint_counts
Role proposals infer_schema
Saved evidence export render_plaintext, render_svg, render_html, visualization_data
Availability deltas compare

See results and configuration for contracts and guides for complete workflows. All budgets in these signatures are independent of the input row population unless an explicit scope or foundation preselection mode is used.

fw.explore(df, dimensions=None, *, discovery=None, **options)
fw.missingness(df, *, features=None, by=None, entity=None, unit='rows', entity_presence='any', missing=None, scope=None, table_id='table', min_implication=0.9, min_similarity=0.8, max_pairs=200, max_signatures=50, max_contexts=32, example_limit=5)
fw.discover_dependencies(df, *, features=None, max_key_size=2, max_candidates=100, min_accuracy=0.95, by=None, max_contexts=32, dropna=True, scope=None, missing=None, table_id='table', example_limit=5)
fw.suggest_paths(df, *, objective='structure', features=None, start_with=None, before=None, exclude=None, target=None, max_dimensions=4, max_candidates=200, max_features=20, max_pairs=200, beam_width=12, n_paths=3, display_budget=40, scope=None, missing=None, table_id='table')
fw.value_patterns(df, *, features=None, by=None, missing=None, scope=None, table_id='table', max_pairs=100, max_patterns=10, example_limit=5)
fw.levels(df: 'pd.DataFrame', features: 'Iterable[Any] | None' = None, *, top_n: 'int | None' = None, max_levels: 'int | None' = 100, min_count: 'int' = 1, dropna: 'bool' = False, schema: 'dict[Any, str] | None' = None, engine_metadata: 'bool' = False, scope_metadata: 'dict[str, Any] | None' = None) -> 'ExplorerResult'
fw.census(df, dimensions, *, scope=None, missing=None, table_id='table', **options)
fw.grain(df: 'pd.DataFrame', candidate_keys: 'Iterable[Any]', *, dropna: 'bool' = False, schema: 'dict[Any, str] | None' = None, engine_metadata: 'bool' = False, scope_metadata: 'dict[str, Any] | None' = None) -> 'ExplorerResult'
fw.pairs(df: 'pd.DataFrame', dimensions: 'Iterable[Any]', *, dropna: 'bool' = False, include_absence: 'bool' = False, reference_domains: 'Mapping[Any, Iterable[Any]] | None' = None, pair_contexts: 'Iterable[Mapping[Any, Any]] | None' = None, max_absence_cells: 'int | None' = 1000, max_contexts: 'int | None' = 32, max_pairs: 'int | None' = 15, scope_metadata: 'dict[str, Any] | None' = None) -> 'ExplorerResult'
fw.joint_counts(df: 'pd.DataFrame', dimensions: 'Iterable[Any]', *, context: 'Mapping[Any, Any] | None' = None, dropna: 'bool' = False, max_cells: 'int' = 2500) -> 'ExplorerResult'
fw.infer_schema(df: 'pd.DataFrame', candidate_keys: 'Iterable[Any] | None' = None) -> 'ExplorerResult'
fw.render_plaintext(result, *, width=100, max_lines=200, max_nodes=1000, detail='full', missing_label='<NA>', unicode_mode='safe')
fw.render_svg(result, *, section=None, detail='full', view=None, show_exceptions=False, max_findings=12)
fw.render_html(result, *, section=None, detail='full', max_findings=100)
fw.visualization_data(result, *, section=None, detail='full')
fw.compare(before, after)