dedup-openai
OfficialStreamline Java code by de-duplicating OpenAI models.
AuthorAzure
Version1.0.0
Installs0
System Documentation
What problem does it solve?
This Skill resolves the issue of redundant Java classes generated by TypeSpec that duplicate models already present in the openai-java library, preventing code bloat and simplifying maintenance.
Core Features & Use Cases
- Model Suppression: Identifies and suppresses generated Java classes that are structurally identical to
openai-javamodels. - Type Mapping: Uses TypeSpec's
@@alternateTypedirective to map generated types to theiropenai-javaequivalents, ensuring correct serialization and deserialization. - Serialization Bridging: Provides helper methods (
OpenAIJsonHelper) to correctly serialize and deserializeopenai-javaobjects, bypassing Jackson's limitations with Kotlin internals. - Use Case: When generating an Azure SDK client that interacts with OpenAI APIs, this skill ensures that you don't generate duplicate model classes for common OpenAI entities like
ReasoningorComparisonFilter, instead leveraging the existingopenai-javalibrary.
Quick Start
Use the dedup-openai skill after dup-classes has identified actionable duplicates to suppress generated Java classes and bridge to openai-java equivalents.
Dependency Matrix
Required Modules
None requiredComponents
references
💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: dedup-openai Download link: https://github.com/Azure/azure-sdk-for-java/archive/main.zip#dedup-openai Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.