Interface SkillProvider


@CopilotExperimental public interface SkillProvider
Provides session-scoped skills to the Copilot runtime.

A skill provider is registered through SessionConfig or ResumeSessionConfig. The runtime may invoke provider callbacks concurrently, so implementations should be thread-safe and avoid relying on callback ordering.

When the runtime cancels a call, for example after its time limit or when the session disconnects, the SDK cancels the returned future with cancel(true) and the runtime ignores any later result. Cancellation does not interrupt running work; observe it with CompletableFuture.isCancelled() or a completion callback to stop early.

Since:
1.0.0
  • Method Details

    • listSkills

      Lists the skills currently available for the session.
      Returns:
      a future resolving to the provider's skill descriptors
    • readSkill

      CompletableFuture<String> readSkill(String name)
      Reads the Markdown content for one skill.
      Parameters:
      name - the skill invocation name
      Returns:
      a future resolving to the skill Markdown, or null when the skill is not found