Field mapping normalization

From aifinlab/FinClaw · View interactive version

Field mapping normalization is an AI agent skill from the GitHub repository aifinlab/FinClaw. 用于异构字段统一的字段映射与标准化原子 skill,适用于通用行业数据接入场景。

How to use this skill

Skill file

字段映射与标准化 Skill

数据来源

本 Skill 支持多种异构数据输入格式,核心数据来源包括:

1. 数据源类型

2. 字段特征

3. 数据格式要求

4. 映射特征

说明:本 Skill 不包含数据采集功能,需要用户提供源数据和映射规则。建议映射规则清晰明确,以便进行准确的字段映射和标准化。


功能

本 Skill 提供全面的字段映射与标准化能力,涵盖多种映射功能:

1. 字段映射

2. 字段标准化

3. 数据转换

4. 映射规则管理

5. 数据验证

6. 高级处理功能


使用示例

输出示例

{
  "source_info": {
    "source_data": "financial_data.csv",
    "source_format": "csv",
    "field_count": 20
  },
  "target_info": {
    "target_format": "standard_financial",
    "target_schema": "financial_schema_v1"
  },
  "mapping_rules": [
    {
      "source_field": "revenue",
      "target_field": "营业收入",
      "standard_field": "revenue",
      "mapping_type": "direct",
      "transformation": {
        "type": "unit_conversion",
        "from_unit": "USD",
        "to_unit": "CNY",
        "exchange_rate": 7.2
      }
    },
    {
      "source_field": "profit",
      "target_field": "净利润",
      "standard_field": "net_income",
      "mapping_type": "direct",
      "transformation": null
    }
  ],
  "mapping_results": {
    "total_fields": 20,
    "mapped_fields": 18,
    "unmapped_fields": 2,
    "mapping_time": "2024-03-15T10:00:00",
    "duration": "5s"
  },
  "normalized_data": {
    "sample_records": [
      {
        "revenue": 7200000000,
        "net_income": 200000000,
        "standard_format": true
      }
    ]
  },
  "statistics": {
    "fields_mapped": 18,
    "fields_normalized": 18,
    "mapping_accuracy": 0.95,
    "normalization_accuracy": 0.97
  }
}

注意事项与限制

1. 映射规则要求

2. 数据转换准确性

3. 字段标准化

4. 数据一致性

5. 使用限制


参考资料

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.