CSV Data Dictionary with Unknown-Field Flags

    by jiajing

    1

    Profiles every column of a CSV and returns a field-level dictionary that marks meanings it cannot verify as PENDING_CONFIRMATION instead of inventing them. For students and junior analysts handed an undocumented export.

    Free

    Security scanned

    Works with the AI Agents you already use

    CSV Data Dictionary with Unknown-Field Flags

    Example session with this skill installed

    Build a data dictionary for students_survey.csv.

    Context: first-year enrolment survey exported from a university registry system.

    • Read your context and instructions
    • Compiled the csv data dictionary
    • Generated the data export

    Profiled the whole file (10 rows, 9 columns) before writing any meaning. Two fields needed a judgement call, and one could not be defined from the file at all.

    Data Dictionary: students_survey.csv

    Field NameInferred TypeNon-null CountSample ValuesBusiness MeaningStatusNotes
    student_idinteger10/102023001, 2023002, 2023003Student identifier; first four digits are the enrolment yearCONFIRMEDPersonal data: identifies an individual - de-identify before publishing
    enrollment_datedate-like10/102023-09-01, 2023-09-02, 2024-09-01Enrolment dateCONFIRMEDAll YYYY-MM-DD, format consistent; several students per day is batch registration, not an anomaly
    gpafloat9/103.85, 3.20, 2.95, 3.10Grade point averageCONFIRMED1 missing value (2023009); scale not declared in the file, observed range 2.78-3.85
    is_activeboolean-like10/10Y, 1, 0, N, YWhether the student is currently enrolledCONFIRMEDColumn mixes four boolean spellings (Y/1/0/N) - normalise to 1/0 before analysis, or a group-by will split one group into four
    gendertext10/10F, MGender (F female / M male)CONFIRMEDTwo categories; the F/M code set is convention, not a declared dictionary
    majortext10/10计算机科学与技术, 数学与应用数学, 物理学Declared majorCONFIRMED6 distinct values incl. 数据科学与大数据技术; confirm whether any major was renamed
    tuitioninteger10/1012000, 11000, 11500, 12500Tuition amountPENDING_CONFIRMATIONCurrency and billing period are not declared in the file (per term or annual, incl. accommodation?). The 12,000 magnitude suggests CNY, but that is exactly the kind of guess this skill refuses to write down
    creditsinteger10/1024, 22, 20, 21, 25Credit total (probably per term)CONFIRMEDRange 19-26, no zeros and no cumulative scale - looks per-term; confirm the aggregation
    notestext2/10转专业学生, 新生入学成绩未录入Free-text remarkCONFIRMEDOnly 2/10 populated, individual case notes - not usable as a categorical field

    Total fields: 9; Pending confirmation: 1.

    Open questions

    1. tuition - currency and billing period? Does it include accommodation?
    2. gpa - 4.0 or 5.0 scale?
    3. credits - per term or cumulative?
    4. is_active - do Y/1/0/N all mean enrolled/not-enrolled, and does a blank mean the same as 0?

    Next steps

    • Answer the four questions above; two of them change how these fields may be used.
    • De-identify student_id before this document leaves the course team.
    • Normalise is_active to 1/0 so the four spellings cannot split a group-by.

    students_survey.csv

    CSV · data export

    Generated

    Example file from a real run - the skill writes it into your workspace.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    A field-level data dictionary for a single CSV - one that says what it knows and marks what it doesn't.

    Most AI-generated field documentation has no way to tell a reader which column descriptions were confirmed and which were guessed. This skill makes PENDING_CONFIRMATION a first-class output status, so a guessed meaning can never be mistaken for a verified one.

    What it does

    • Profiles every column across the whole file - non-null counts, distinct counts, sample values, min/max length - not a sample of the first 20 rows.
    • Assigns a type from documented rules - integer, float, date-like, boolean-like, text, empty - with stated precedence and edge-case handling.
    • Writes a meaning only where the field name and the supplied context support one. Ambiguous names (col3, flag_a, X2023) stay PENDING_CONFIRMATION.
    • Ends with a coverage line you can hand to a reviewer: Total fields: N; Pending confirmation: M.
    • Returns the questions that confirmation needs, phrased so the user can answer each in one line.

    Why not just prompt a chatbot?

    A generic prompt pushes the model to fill every field, because "complete" reads as "helpful". The failure is silent: an invented definition looks identical to a verified one once it reaches a cleaning rule, a model variable or a report definition.

    This skill encodes the opposite discipline. It halts on unusable input, refuses to resolve ambiguous names from suggestive sample values, and reports coverage honestly instead of declaring the document finished.

    Package contents

    • SKILL.md - scope, triggers, inputs, workflow, boundaries, output contract.
    • references/inference-rules.md - type precedence, edge cases, name-versus-data conflicts, escalation list.
    • scripts/profile_csv.py - read-only profiler, Python standard library only, no network, no install step.
    • assets/dictionary-template.md - the output skeleton.

    Real-world CSV handling

    Reads UTF-8, UTF-8 with BOM, GB18030/GBK (the Excel default on Chinese Windows) and Big5; auto-detects comma, semicolon, tab and pipe delimiters; reads mixed boolean spellings (Y/1/0/N) as one boolean field rather than four values; plausibility-checks four date formats (20231345 is not a date); keeps leading-zero identifiers as text instead of silently stripping them; reports ragged rows and duplicate headers instead of dropping them.

    What it will not do

    No cleaning, repair or conversion of the source CSV. No statistical analysis. No database schema design. No multi-file reconciliation. It never states business meaning it cannot support.

    Requirements

    Python 3.8 or newer, standard library only. One CSV with a header row. No network access, no API key, nothing to configure.

    Requires header rows in CSVs. Cannot infer business meaning for generic names (e.g., 'col1') without user context. Limited to single-file documentation.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before buying a skill.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Free to use

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed 18 days ago

    • Free with an Agensi account

    Software
    Python

    Permissions

    Terminal / Shell
    Read Files
    Write Files
    Listed18 days ago

    What's inside

    Creator

    J

    jiajing

    Frequently Asked Questions

    This skill generates a standardized, audit-ready data dictionary that profiles types, identifies PII, and flags ambiguous fields for human review to prevent errors in migrations or pipelines.

    Unlike generic prompts, this skill uses a specialized Python profiling script to ensure definitions are grounded in real metrics rather than AI guesswork or hallucinations.

    The skill is designed for any AI agent or platform with Python execution capabilities, as it relies on a local script to analyze data structures and generate the Markdown report.

    You will receive the specialized profiling logic, the structured documentation template, and the integration instructions needed to deploy the skill within your AI agent environment.

    The skill requires either a standard CSV file with a header row or a clear list of field names accompanied by sample data to accurately profile the schema.

    No, this skill is focused on documenting a single dataset; it does not currently perform cross-file relational mapping or multi-table schema reconciliation.

    New in Data & Databases

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Data & Databases.

    Free