AIエンティティの作成
AIの支援でカスタムエンティティパターンを作成
AIを使用して、組み込みの認識器ではカバーされていないカスタムエンティティタイプを検出するための正規表現パターンを生成します。
AIエンティティの作成はベーシックプラン以上で利用可能です。無料プランのユーザーは、正規表現パターンを使用して手動でカスタムエンティティを作成できます。
AI Entity Creation is available on Basic plan and above. Free plan users can create custom entities manually using regex patterns.
仕組み
検出したいパターンの例を3〜5件提供してください
AIに検出したい内容を平易な言葉で伝えます
AIが例を分析し、正規表現パターンを生成します
AIがあなたの説明に基づいて正規表現パターンを作成します
サンプルテキストでパターンをテストします
サンプルテキストでパターンをテストし、必要に応じて調整します
品質指標を確認し、必要に応じて改善します
分析で使用するためにカスタムエンティティを保存します
AIエンティティの作成
ステップ1:カスタムエンティティを開く
- Go to Settings → Custom Entities
- Click Create New Entity
- Select AI-Assisted mode
ステップ2:パターンを説明する
検出したい内容の明確な説明を入力します。フォーマットについて具体的に記述してください。
良い例
- "Employee IDs in the format EMP-12345 where 12345 is a 5-digit number"
- "Order numbers starting with ORD followed by 8 digits, like ORD12345678"
- "German postal codes - 5 digit numbers between 01000 and 99999"
- "Internal project codes: 3 uppercase letters, a dash, and 4 digits (e.g., ABC-1234)"
曖昧な説明は避ける
- "ID numbers" - Too vague, what format?
- "Customer data" - What specific pattern?
- "Codes" - Need more specifics about format
ステップ3:生成されたパターンを確認する
AIがあなたの説明に基づいて正規表現パターンを生成します。それを確認してください:
// For "Employee IDs: EMP-12345"
EMP-\d{5}
ステップ4:パターンをテストする
- Enter sample text in the test area
- Click Test Pattern
- Verify that matches are highlighted correctly
- Check for false positives and false negatives
ステップ5:エンティティを保存する
- Enter a name for your entity (e.g., EMPLOYEE_ID)
- Add an optional description
- Choose a category (Personal, Technical, Custom, etc.)
- Click Save Entity
トークンコスト
これはパターンの複雑さに関係なく固定コストです。手動の正規表現入力は無料です。
コストを最小限に抑えるために:
- Be as specific as possible in your first description
- Use manual regex if you already know the pattern
- Test thoroughly before saving to avoid recreating
手動正規表現の作成
正規表現を知っている場合は、トークンを使用せずにカスタムエンティティを手動で作成できます:
- Go to Settings → Custom Entities
- Click Create New Entity
- Select Manual mode
- Enter your regex pattern directly
- Test and save
正規表現のヒント
| パターン | 意味 | 例の一致 |
|---|---|---|
| \d | Any digit (0-9) | 5 |
| \d{3} | Exactly 3 digits | 123 |
| [A-Z] | Uppercase letter | A |
| [A-Z]{3} | 3 uppercase letters | ABC |
| \w | Letter, digit, or underscore | a, 1, _ |
| - | Literal dash | - |
| ? | Optional (0 or 1) | |
| + | One or more | |
| * | Zero or more |
例パターン
Employee ID (EMP-12345)
EMP-\d{5}
Order Number (ORD12345678)
ORD\d{8}
Project Code (ABC-1234)
[A-Z]{3}-\d{4}
License Plate (ABC 123 or ABC-123)
[A-Z]{3}[\s-]?\d{3}
カスタムエンティティの使用
作成後、カスタムエンティティは組み込みエンティティのように機能します:
アナライザー内で
- Open the entity selection panel
- Find your custom entity under the Custom category
- Check the box to include it in detection
- Run analysis as normal
プリセット内で
- Create or edit a preset
- Select your custom entity from the entity list
- Save the preset
Tip
カスタムエンティティは、組み込みエンティティと区別するために「カスタム」バッジが表示されます。
カスタムエンティティの管理
エンティティの編集
- Go to Settings → Custom Entities
- Find your entity and click Edit
- Modify the name, description, or pattern
- Test the updated pattern
- Save changes
エンティティの削除
- Go to Settings → Custom Entities
- Find your entity and click Delete
- Confirm deletion
Note
カスタムエンティティを削除すると、それを使用するすべてのプリセットから削除されます。プリセットは機能し続けますが、そのエンティティタイプを検出しません。
ベストプラクティス
Related Documentation
最終更新日: 2026年3月