A step-by-step guide to building an AI task planner using Semantic Kernel in C# with a sequential three-step pipeline. Covers using KernelFunctionFactory.CreateFromPrompt() for inline prompt authoring, Kernel.InvokeAsync() for direct function invocation, and KernelArguments to pass typed context between steps. Explains when to choose a sequential pipeline over an agent-based approach, how to enforce JSON output with ResponseFormat = "json_object", and how to disable auto tool-calling with FunctionChoiceBehavior.None(). Includes full project structure, code samples, and a runnable example that produces a prioritized task plan with effort estimates.
Table of contents
Why a Sequential Pipeline Instead of an Agent?Project SetupDefining Prompt Functions Inline with KernelFunctionFactoryInvoking Functions with Kernel.InvokeAsync and KernelArgumentsPassing Context Between Pipeline StepsOrchestrating the Three-Step PipelineRunning the AI Task PlannerSequential Pipelines vs Agents -- Which Should You Choose?Frequently Asked QuestionsSort: