npx skills add ...
npx skills add pydantic/skills --skill migrating-google-adk-to-pydantic-ai
Migrate Python Google Agent Development Kit (ADK) applications to Pydantic AI. Use for `LlmAgent`, `Runner`, sessions, state, memory, tools, callbacks, plugins, graph or dynamic workflows, resumability, events, artifacts, MCP, and ADK deployment boundaries.
npx skills add pydantic/skills --skill migrating-google-adk-to-pydantic-ai
Preserve caller-visible behavior, not ADK's class tree. Migrate the smallest complete request path and leave product infrastructure in the application.
pydantic-ai-harness versions.Runner.run_async() or the deployed endpoint through the root agent, instructions, collaboration mode, model calls, tools, workflow nodes, callbacks/plugins, session service, emitted events, state/artifact deltas, and final response. Record only behavior that path uses.Session.events used as model context;LlmAgent: normally one reusable Agent with typed dependencies, tools, and output.pydantic_graph when explicit typed nodes, branching, or graph inspection remain valuable.mode in Python 2.x; 1.x sub_agents use chat behavior. Use core multi-agent patterns for chat transfer semantics. Harness SubAgents can fit task or single_turn only when their isolated context, return, interaction, and concurrency behavior match.unverified; similar names are not equivalence evidence.Read Concept Mapping for the features the slice uses. Read Semantic Gaps for workflows, state, resume, confirmation, callbacks/plugins, event streams, skills, or execution environments. Read Verification and Cutover before removing ADK or changing production traffic.
Session objects or mutable state dictionaries through model-chosen tool arguments. Put authenticated identity and service clients in typed dependencies; persist product and workflow state through application-owned stores.message_history continues model context. It does not replace ADK session state, memory, artifacts, event records, node checkpoints, or invocation resume.instruction to instructions; use a RunContext instructions function when it depends on trusted runtime data.output_schema to output_type when the terminal output contract is structured. Preserve an existing wire adapter if changing response shape would widen the migration.ModelMessage histories separately from workflow and product state. Reuse the application's current stores before adding a new persistence subsystem.Hooks for local lifecycle interception or a custom capability for reusable policy that also owns tools, instructions, settings, or events.The slice is complete only when every observed caller contract is preserved by executable evidence, explicitly accepted as changed, or not applicable. Treat unverified and blocked contracts as unfinished. Do not remove google-adk while a retained runtime, session migration, deployment command, evaluation, or compatibility path still imports or invokes it.