yifanfeng97/hyper-extract/template-optimizer

Claude Code and agent skill by yifanfeng97/hyper-extract

Trust tier 2
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Optimize YAML templates for Hyper-Extract. Use when: "optimize template", "fix YAML issues", "improve quality", "lint template" Trigger: After creating templates or during review Skip: Creating new templates (use brainstorm + designer instead)

Install

npx vskill@latest install yifanfeng97/hyper-extract/template-optimizer

SKILL.md

Template Optimizer

Automatically analyze and optimize YAML templates by applying best practices and fixing common issues.

Workflow

1. Parse YAML → 2. Analyze Issues → 3. Apply Fixes → 4. Generate Report
Step 1: Parse YAML

Load the YAML template and validate basic structure.

Step 2: Analyze Issues

Check against these rules:

RuleWhat to Check
rules-naming.mdField naming standardization
rules-multilingual.mdLanguage consistency
rules-field-count.mdInformation density
rules-consistency.mdSchema vs Guideline separation
rules-hypergraph-grouping.mdHypergraph grouping strategy
Step 3: Apply Fixes

Apply fixes based on optimization level:

LevelDescriptionExample
Auto-fixSafe changes that always improverelation_type → type
SuggestChanges that may need reviewField count > 5
ReviewDesign decisionsRelation type openness
Step 4: Generate Report

Output changes with explanations for learning.


Detection Rules

Rule 1: Multi-language Consistency
❌ Pattern: [a-zA-Z]+\([^)]+\) in zh fields
❌ Pattern: Chinese chars in en fields

Fix: Separate language content, use pure Chinese in zh, pure English in en.

Rule 2: Field Naming
❌ relation_type → type
❌ event_date → time
❌ entity_type → type

Fix: Standardize to concise names.

Rule 3: Field Count
⚠️ entities.fields > 5 → Flag for review
⚠️ relations.fields > 5 → Flag for review

Fix: Simplify to essential fields, use priority: Essential → Important → Optional.

Rule 4: Schema-Guideline Separation
❌ Repetition of field definitions in guideline
❌ Schema descriptions in rules

Fix: Schema defines WHAT, Guideline defines HOW TO DO WELL.

Rule 5: Hypergraph Grouping
❌ relation_members: participants (string) + role field exists
❌ relation_id contains participant field

Fix: Use nested grouping relation_members: [group_a, group_b] when entities partition by roles.


Design Principles

Schema vs Guideline
Schema DefinesGuideline Defines
Field namesExtraction strategy
Field typesQuality requirements
Field descriptionsCreation conditions
Required/optionalCommon mistakes

❌ Wrong: Guideline repeats schema definitions ✅ Correct: Guideline explains how to extract well

Information Density

For entities and relations:

Field PriorityExamples
Essentialsource, target, participants
Importanttype, time, location
Optionaldescription, metadata

Max: 5 fields per component

Naming Conventions
ForUseExample
Template nameCamelCaseEarningsSummary
Field namessnake_casecompany_name
Tagslowercasefinance, investor

Reference Files

TopicWhen to Check
rules-naming.mdField naming issues
rules-multilingual.mdLanguage consistency
rules-field-count.mdToo many fields
rules-consistency.mdSchema-guideline overlap
rules-hypergraph-grouping.mdRole field vs nested grouping

Output Format

markdown
# Optimization Report
## Changes Made
| File | Issue | Fix | Level |
|------|-------|-----|-------|
| template.yaml | `relation_type` | renamed to `type` | Auto-fix |
| template.yaml | Mixed language | Fixed zh/en separation | Auto-fix |
| template.yaml | 7 relation fields | Suggested simplification | Suggest |
## Summary
-Auto-fix: 2
-Suggestions: 1
-Manual review: 0

Integration

Full workflow: brainstorm → designer → optimizer → validator
↓
Apply best practices
Auto-fix common issues

When to use:

  • After creating new templates
  • Before validator
  • During template review
  • Batch optimization of existing templates

Security

  • Security scanPassed, 100 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

Repository stars
654
Repository forks
69
7-day trend score
32

Stars and forks are for the whole GitHub repository, not this skill alone. Refreshed 29 Apr 2026, 6 months ago.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/yifanfeng97/hyper-extract/template-optimizer/badge)](https://verified-skill.com/skills/yifanfeng97/hyper-extract/template-optimizer)

Something wrong with this skill or its page? Tell us.