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

推荐订阅源

F
Fortinet All Blogs
爱范儿
爱范儿
P
Proofpoint News Feed
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
T
Tailwind CSS Blog
J
Java Code Geeks
宝玉的分享
宝玉的分享
Jina AI
Jina AI
B
Blog
N
Netflix TechBlog - Medium
Recent Announcements
Recent Announcements
aimingoo的专栏
aimingoo的专栏
腾讯CDC
C
Check Point Blog
The Cloudflare Blog
阮一峰的网络日志
阮一峰的网络日志
博客园 - Franky
罗磊的独立博客
B
Blog RSS Feed
WordPress大学
WordPress大学
小众软件
小众软件
博客园 - 叶小钗
M
MIT News - Artificial intelligence
GbyAI
GbyAI

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
Adding the anime side without holding my breath
Anthony Viard · 2026-05-28 · via DEV Community

A week later, OtakuShelf has a few franchises and their manga in it. Now Sam wants the other half: anime. That means new entities — Anime, Season, Episode — wired into the existing Franchise. The difference from last time is important: this is a live project with data and a model Sam cares about. Running the generator blind on it is how you end up with a clobbered entity and a bad afternoon. So Sam slows down by exactly one habit: preview first.

A quick gut-check before anything else

Before even applying, Sam sketches the new shape and asks the agent to validate it:

Validate this without changing anything: an Anime (title, studio) linked many-to-one to Franchise, a Season (number, title, episode count) under an anime, and an Episode (number, title, air date, duration in minutes) under a season.

The validate_jdl tool runs a fast local lint first (is the JDL even well-formed?), then generates the whole thing in a throwaway directory and reports any error — all without touching OtakuShelf. It comes back clean. Good: the idea is sound. Now, what would it actually do to the project?

The dry run that's actually dry

Here's the part every JHipster veteran needs to hear, because it bit us too: in JHipster 9, --dry-run still writes files. It only prints conflicts. So you cannot trust that flag to keep your project pristine.

The MCP sidesteps the whole problem. When Sam asks for a preview:

In /Users/sam/projects/otakushelf, show me what adding the anime entities and their relationships would change — don't write anything yet.

…the agent calls the apply tool with dryRun: true, and the server does something more honest than a flag: it makes a temp directory, copies OtakuShelf's .yo-rc.json and existing entities into it for fidelity, generates there, lists what would change, and throws the temp away. The real project sees zero writes. Sam reads the file list — new Anime, Season, Episode sources, updated Liquibase changelogs, a couple of Vue components — nods, and only then drops the dryRun. The exact same call, now for real.

This is the rhythm Sam settles into for the rest of the project: validate → dry-run → apply. It costs a few seconds and removes all the adrenaline.

The agent already knows the shelf

There's a quieter thing happening that makes this safe. When Sam says "link Anime to Franchise," the agent doesn't guess what Franchise looks like — it reads the project's current entities through a resource (jhipster://project/entities). So it knows Franchise already exists with its title/synopsis/status/startYear, and it adds the relationship without redefining and accidentally trimming those fields. It's working from the real model, not from a fuzzy memory of last week's chat.

For this batch Sam lets the agent do it all in one shot — three new entities and their relationships belong together, so the agent composes a single import_jdl call instead of three separate ones:

entity Anime { title String required, studio String }
entity Season { number Integer required min(1), title String, episodeCount Integer min(0) }
entity Episode { number Integer required min(1), title String, airDate LocalDate, durationMinutes Integer min(0) }

relationship OneToMany {
  Franchise{animes} to Anime{franchise}
  Anime{seasons} to Season{anime}
  Season{episodes} to Episode{season}
}

One generator run, one diff to review. (If Sam had wanted just a single entity, there's an add_entity tool that builds the JDL from a plain description — handy for one-offs. For a coordinated batch like this, one import_jdl is tidier and faster.)

Why the preview habit pays off here specifically

The anime side touches the manga side — Franchise gains an animes collection. That's precisely the kind of cross-cutting change where a blind regeneration makes you nervous. With the dry run, Sam saw in advance that Franchise.java and its Vue views would be regenerated, confirmed nothing surprising was in the list, and proceeded with a clear conscience. The MCP didn't make the change safe by being clever; it made it safe by letting Sam look first, for free, as many times as wanted.

Where this is going

OtakuShelf now models both halves of a franchise — manga and anime — from Franchise down to individual Episodes. It works, but it's a little rough: no DTOs, and Sam already realized a field is missing. Next, the polish pass — and a look at how to read what the agent actually did to your code.

Next in the series: "Polishing the catalog (and reading the agent's receipts)" — options, a forgotten field with a backup, and trusting what the agent did.