惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Apple Machine Learning Research
Apple Machine Learning Research
Google DeepMind News
Google DeepMind News
小众软件
小众软件
GbyAI
GbyAI
酷 壳 – CoolShell
酷 壳 – CoolShell
F
Fortinet All Blogs
博客园 - 三生石上(FineUI控件)
B
Blog
量子位
B
Blog RSS Feed
Vercel News
Vercel News
Blog — PlanetScale
Blog — PlanetScale
Last Week in AI
Last Week in AI
博客园 - 叶小钗
MongoDB | Blog
MongoDB | Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
爱范儿
爱范儿
Jina AI
Jina AI
C
Check Point Blog
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
IT之家
IT之家
H
Hackread – Cybersecurity News, Data Breaches, AI and More
云风的 BLOG
云风的 BLOG

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant
Dev Log: The first public API, and the type graph that wo...
Ernesto Herrera Salinas · 2026-06-19 · via DEV Community

I’m reviving Munchausen, a C# NuGet package I started 9 years ago. This is part 4 of an 8-part series documenting both the development process and the engineering decisions behind bringing the project back to life.

This is the Dev Log: the practical work, cleanup, implementation steps, and day-to-day progress behind this part of the project.

M3 is a milestone with a flag on it: the first public surface. Lie.Define<T>(),
the fluent builder, the options records. Up to now everything was internal
plumbing nobody could call. Now I'm testing the API I designed by committing to
shapes that users will eventually depend on. Once a public member ships, changing
it becomes expensive.

The builder is deliberately lazy

The fun design decision here is that the builder does almost nothing. You call
.With(...), .Ignore(...), .Derive(...) and it just appends a little record
and hands you back this. No validation, no parsing. All of that is deferred to
Build(). It feels almost too lazy until you see why: you want all your
definition errors reported together, in one exception, not dribbled out one
throw at a time as you chain methods. So the builder's job is purely to remember
what you said, in order, and Build() is where judgment happens. Cheap builder,
smart compile.

"Wait, I have to declare half the library"

Here's the thing that caught me. To write the builder's method signatures, I need
the types they mention. With(...) takes a Func<GenerationContext, T>. Build()
returns a LieDefinition<T>. Explain() returns an InferenceReport. None of
those are built yet, they're milestones away. But you can't have a public method
whose parameter type doesn't exist.

So M3 quietly drags a chunk of the type graph into existence as stubs: public
types, fully documented, whose bodies just throw new NotImplementedException().
When I divided the work into stages, I allowed those placeholders until M6. It
still feels strange to add a GenerationContext that does nothing and a
Generate() that refuses to run, but it lets me test the complete API shape
before every behavior exists.

Falling in love with dotnet format

Maintaining the locked-surface text file by hand is miserable, you have to write
each entry in the analyzer's exact dialect, down to how int.MinValue is spelled
and where the ! nullability markers go. I discovered that
dotnet format analyzers --diagnostics RS0016 just generates all of it
correctly. Run it, review the generated surface against the API I designed, move
the lines into the shipped file. This will become a recurring character in the
story, including the episode two milestones from now where it inexplicably stops
working and I waste real time before figuring out why.

A small principled stand

The analyzer also complained (RS0026) about the two Generate overloads both
having optional parameters, a legitimate general warning, but it conflicted with
the API shape I had chosen. This forced me to revisit that choice rather than
blindly obey either side. I still preferred the overloads, so I suppressed the
rule with a comment explaining why. A linter is useful evidence, not the designer.

Where it leaves things

You can now write the fluent thing:

Lie.Define<Car>()
   .WithName("cars")
   .With(c => c.Make, "Saab")
   .With(c => c.Model, ctx => "900")
   .Derive(c => c.Year, (ctx, c) => 1989)
   .WithSeed(42);

…and it compiles, captures everything correctly, and rejects x => x.Owner.Name
with a clear LIE001. Build() still throws, there's no compiler yet, but the
ergonomics are real, and the public surface is locked and reviewed.

What's next

M4: inference. This is the milestone with opinions, the catalog that decides
FirstName should be a first name and Price should be money. It's also where I
find the first genuine contradiction in my design and have to decide which
behavior better serves the user.