serialization

Guide .NET serialization format selection and implementation for AOT compatibility.

10|Updated Jan 28, 2026
One-click install
npx skills add https://github.com/AGIBuild/Agibuild.Fulora --skill serialization-agibuild
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: serialization
Source: https://github.com/AGIBuild/Agibuild.Fulora/tree/main/.cursor/skills/serialization
Command: npx skills add https://github.com/AGIBuild/Agibuild.Fulora --skill serialization-agibuild

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill addresses the complexities of choosing and implementing efficient, AOT-compatible serialization formats in .NET applications, ensuring optimal performance and compatibility.

Core Features & Use Cases

  • Format Selection Guidance: Provides a clear comparison of JSON (System.Text.Json, Newtonsoft.Json), Protocol Buffers, and MessagePack, detailing their pros and cons regarding AOT compatibility, performance, and payload size.
  • AOT-Safe Implementation: Demonstrates how to use System.Text.Json source generators and MessagePack's AOT resolver for Native AOT compatibility.
  • Use Case: When building a new microservice that needs to communicate efficiently with other services, this Skill helps you select and implement Protocol Buffers for high-performance, low-latency data exchange.

Quick Start

Use the serialization skill to implement System.Text.Json source generators for a Product class.

Frequently Asked Questions about serialization

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I use System.Text.Json source generators for Native AOT compatibility in .NET?

System.Text.Json source generators provide Native AOT-compatible serialization by generating serialization logic at compile time. This skill demonstrates how to implement them for classes like Product to ensure AOT safety and optimal performance without runtime reflection.

What is the best serialization format for high-performance microservice communication in .NET?

Protocol Buffers is recommended for high-performance, low-latency data exchange between microservices. This skill provides a comparison of Protocol Buffers, MessagePack, and JSON to help you select the optimal format based on payload size and speed.

How do I migrate from Newtonsoft.Json to System.Text.Json?

Migrating from Newtonsoft.Json to System.Text.Json involves adapting to its stricter defaults and AOT-friendly source generators. This skill outlines migration strategies to ensure performance optimization and compatibility during the transition.

Does MessagePack support Native AOT deployments in .NET?

MessagePack supports Native AOT deployments through its dedicated AOT resolver. This skill explains how to configure MessagePack for AOT compatibility, ensuring efficient binary serialization without dynamic code generation.

When should I choose MessagePack over JSON for data persistence in .NET?

MessagePack offers smaller payload sizes and faster processing than JSON for cross-process communication and data persistence. This skill compares these formats to determine when MessagePack's binary format is more efficient for your use case.