Skip to main content
Glama

Edit a knowledge source

cs_edit_knowledge

Update a Copilot Studio knowledge source by modifying name, description, site URL, subpage inclusion, trigger conditions, or search terms. Preview the exact diff before applying changes with confirmation.

Instructions

Change a knowledge source file: name, description, site URL, includeSubPages, trigger condition (null removes it), additional search terms. The first call changes nothing: it returns the files it would write, as a diff against what is there now, for the user to approve. Call it again with the same arguments plus confirm: true to write them.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
siteNo
renameNo
confirmNoRequired to write the change to the file. Without it the tool returns a preview - the changed lines against the current ones, and the character count - and writes nothing.
knowledgeYes
workspaceNoPath to (or inside) the agent workspace. Defaults to CPS_WORKSPACE or the current directory.
descriptionNo
includeSubPagesNo
triggerConditionNo
additionalSearchTermsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.1.7
    • addedInput schema / properties / confirm
      Added value: +{
      +  "description": "Required to write the change to the file. Without it the tool returns a preview - the changed lines against the current ones, and the character count - and writes nothing.",
      +  "type": "boolean"
      +}
  2. First observedv0.1.5

TDQS

A4.1/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden. It reveals that the first call is a dry-run that returns a diff, that confirm:true is required to write, and that triggerCondition with null removes a condition. This is substantive behavioral disclosure, though it omits error handling details and the exact return format beyond 'diff'.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three sentences with the core purpose front-loaded. The preview behavior and the confirm flow are each explained in a separate, focused sentence. No redundant or filler content.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool has 9 parameters (only 1 required) and no output schema. The description explains the preview/confirm pattern and modifiable fields, but it does not define the 'knowledge' parameter, which is essential for targeting the correct file. It also doesn't clarify whether this tool is strictly for existing files vs creating new ones, leaving ambiguity that an agent must resolve.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is only 22%, so the description must compensate. It lists all editable fields but does not explain the required 'knowledge' parameter (likely the identifier of the target file), and 'rename' is not mapped to 'name'. It does add the nuance that triggerCondition null removes it, and clarifies additionalSearchTerms. Partial compensation only.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states 'Change a knowledge source file' and enumerates the exact modifiable fields: name, description, site URL, includeSubPages, trigger condition, and additional search terms. This precisely identifies the resource (knowledge source) and the action (edit/change), making it distinct from sibling tools like cs_add_knowledge_source.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description clearly explains the two-step workflow: the first call returns a diff for approval, and the second call with confirm:true writes the changes. It does not explicitly name alternatives, but the edit-vs-add distinction is obvious from the tool name and sibling list. The guidance on when to call again is explicit and actionable.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools