Skip to content

Autopilot Resource

Note: This capability is now provided as an installable component. See the Components guide for how to install and use it.

Install: kdeps component install autopilot

Usage: run: { component: { name: autopilot, with: { task: "...", context: "...", model: "gpt-4o" } } }

The Autopilot component is kdeps' goal-directed task execution engine. Describe what you want to achieve in plain language; autopilot uses an LLM to plan and execute the task.

Component Inputs

InputTypeRequiredDefaultDescription
taskstringyesPlain-language description of the goal
contextstringnoAdditional context or constraints for the task
modelstringnogpt-4oLLM model to use for planning and execution

Using the Autopilot Component

yaml
run:
  component:
    name: autopilot
    with:
      task: "Research the top 5 open-source LLM frameworks and summarize their strengths"
      context: "Focus on frameworks that support local inference"
      model: "gpt-4o"

Access the result via output('<callerActionId>').

When to use Autopilot

Use autopilot when the exact sequence of steps is not known ahead of time. For well-understood, repeatable pipelines, declarative resources are faster and more predictable.


Result Map

FieldTypeDescription
successbooltrue if the task completed successfully
resultanyOutput of the executed task
modelstringModel used for planning

Expression Support

All fields support KDeps expressions:

yaml
run:
  component:
    name: autopilot
    with:
      task: "{{ get('user_task') }}"
      context: "{{ get('user_context') }}"
      model: gpt-4o

Examples

Research and Summarize

yaml
apiVersion: kdeps.io/v1
kind: Resource

metadata:
  actionId: research
  name: Autopilot Researcher

run:
  component:
    name: autopilot
    with:
      task: "Search the web for '{{ get('q') }}' and return a 3-paragraph summary."
      model: "gpt-4o"

Data Analysis

yaml
apiVersion: kdeps.io/v1
kind: Resource

metadata:
  actionId: analyze
  name: Autopilot Data Analysis

run:
  component:
    name: autopilot
    with:
      task: |
        Analyze the following data and return key insights as JSON:
        {{ get('data') }}
      context: "Focus on trends and anomalies."
      model: gpt-4o

Differences from agent:

agent:autopilot:
WorkflowPre-written, staticLLM-directed at runtime
StepsKnown ahead of timeDetermined by model
PredictabilityHighVariable
Use caseProduction pipelinesExploratory / dynamic tasks

See Also

Released under the Apache 2.0 License.