Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions pkg/chip/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,7 @@ func WithReplacementInstructions(text string) ServerOption {

type Tool[In, Out any] struct {
Name string
Title string
Description string
Handler ToolHandlerFunc[In, Out]
Permissions []string
Expand Down Expand Up @@ -221,6 +222,7 @@ func RegisterTool[In, Out any](s *Server, tool *Tool[In, Out]) {

mcp.AddTool(&s.Server, &mcp.Tool{
Name: tool.Name,
Title: tool.Title,
Description: tool.Description,
InputSchema: buildSchema[In](),
OutputSchema: buildSchema[Out](),
Expand Down
3 changes: 2 additions & 1 deletion pkg/skills/list_tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ type listedSkill struct {
// NewListTool returns the list_collibra_skills tool wired to the given catalog.
func NewListTool(catalog *Catalog) *chip.Tool[listInput, listOutput] {
return &chip.Tool[listInput, listOutput]{
Name: listToolName,
Name: listToolName,
Title: "List Collibra Skills",
Description: "List available Collibra skill guides. Skills document multi-step workflows, " +
"ID-bridging rules, and required permissions for chip's tools. Call this before " +
"load_collibra_skill when you do not already know the exact skill name; skill names " +
Expand Down
3 changes: 2 additions & 1 deletion pkg/skills/load_tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ type loadOutput struct {
// NewLoadTool returns the load_collibra_skill tool wired to the given catalog.
func NewLoadTool(catalog *Catalog) *chip.Tool[loadInput, loadOutput] {
return &chip.Tool[loadInput, loadOutput]{
Name: loadToolName,
Name: loadToolName,
Title: "Load Collibra Skill",
Description: "Load a Collibra skill guide before using related tools (e.g. load " +
"'collibra/lineage' before calling get_lineage_*, or 'collibra/asset-create' before " +
"create_asset). Skills document the right tool sequences, ID-bridging rules, and " +
Expand Down
3 changes: 2 additions & 1 deletion pkg/tools/add_data_classification_match/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,10 @@ type Output struct {
func NewTool(collibraClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "add_data_classification_match",
Title: "Add Data Classification Match",
Description: "Associate a data classification (data class) with a specific data asset in Collibra. Requires both the asset UUID and the classification UUID.",
Handler: handler(collibraClient),
Permissions: []string{"dgc.classify", "dgc.catalog"},
Permissions: []string{"dgc.classify", "dgc.catalog"},
Annotations: &mcp.ToolAnnotations{DestructiveHint: chip.Ptr(true)},
}
}
Expand Down
3 changes: 2 additions & 1 deletion pkg/tools/create_asset/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,8 @@ type AttributeResult struct {
// NewTool returns the registered tool.
func NewTool(collibraClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "create_asset",
Name: "create_asset",
Title: "Create Asset",
Description: "Create a new Collibra asset of any type. " +
"Inputs accept human-friendly identifiers: assetType resolves from UUID, publicId, or display name; domain from UUID or display name; status from UUID or status name; attributes by name or typeId. " +
"Markdown in RICH_TEXT attribute values (e.g. 'Definition') is converted to HTML server-side so it renders correctly in Collibra. " +
Expand Down
1 change: 1 addition & 0 deletions pkg/tools/discover_business_glossary/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ type Output struct {
func NewTool(collibraHttpClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "discover_business_glossary",
Title: "Discover Business Glossary",
Description: "Perform a semantic search across business glossary content in Collibra. Ask natural language questions to discover business terms, acronyms, KPIs, and other business glossary content.",
Handler: handler(collibraHttpClient),
Permissions: []string{"dgc.ai-copilot"},
Expand Down
1 change: 1 addition & 0 deletions pkg/tools/discover_data_assets/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ type Output struct {
func NewTool(collibraClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "discover_data_assets",
Title: "Discover Data Assets",
Description: "Perform a semantic search across available data assets in Collibra. Ask natural language questions to discover tables, columns, datasets, and other data assets.",
Handler: handler(collibraClient),
Permissions: []string{"dgc.ai-copilot"},
Expand Down
31 changes: 16 additions & 15 deletions pkg/tools/edit_asset/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -125,26 +125,27 @@ type AssetSummary struct {

// OperationResult is the outcome of a single operation in the input array.
type OperationResult struct {
Operation OperationType `json:"operation"`
Status string `json:"status" jsonschema:"'success' or 'error'."`
AttributeName string `json:"attributeName,omitempty"`
Field string `json:"field,omitempty"`
RelationType string `json:"relationType,omitempty"`
RelationID string `json:"relationId,omitempty"`
TargetAssetID string `json:"targetAssetId,omitempty"`
Tag string `json:"tag,omitempty"`
Role string `json:"role,omitempty"`
UserID string `json:"userId,omitempty"`
PreviousValue string `json:"previousValue,omitempty"`
NewValue string `json:"newValue,omitempty"`
CascadedDisplayName bool `json:"cascadedDisplayName,omitempty" jsonschema:"True when update_property field=name also updated displayName because the asset's previous displayName matched its previous name (Collibra's create-time default). Only set on update_property results."`
Error string `json:"error,omitempty"`
Operation OperationType `json:"operation"`
Status string `json:"status" jsonschema:"'success' or 'error'."`
AttributeName string `json:"attributeName,omitempty"`
Field string `json:"field,omitempty"`
RelationType string `json:"relationType,omitempty"`
RelationID string `json:"relationId,omitempty"`
TargetAssetID string `json:"targetAssetId,omitempty"`
Tag string `json:"tag,omitempty"`
Role string `json:"role,omitempty"`
UserID string `json:"userId,omitempty"`
PreviousValue string `json:"previousValue,omitempty"`
NewValue string `json:"newValue,omitempty"`
CascadedDisplayName bool `json:"cascadedDisplayName,omitempty" jsonschema:"True when update_property field=name also updated displayName because the asset's previous displayName matched its previous name (Collibra's create-time default). Only set on update_property results."`
Error string `json:"error,omitempty"`
}

// NewTool returns the registered tool.
func NewTool(collibraClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "edit_asset",
Name: "edit_asset",
Title: "Edit Asset",
Description: "Edit an existing Collibra asset by submitting a list of typed operations against a single assetId. " +
"Supported operations: " +
"update_attribute / add_attribute / remove_attribute (change, append, or clear an attribute value such as 'Definition' or 'Note', identified by attribute type name); " +
Expand Down
1 change: 1 addition & 0 deletions pkg/tools/get_asset_details/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ type AssetResponsibility struct {
func NewTool(collibraClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "get_asset_details",
Title: "Get Asset Details",
Description: "Get detailed information about a specific asset by its UUID, including attributes, relations, responsibilities (owners, stewards, and other role assignments), and metadata. Returns up to 100 attributes per type and supports cursor-based pagination for relations (50 per page).",
Handler: handler(collibraClient),
Permissions: []string{},
Expand Down
5 changes: 3 additions & 2 deletions pkg/tools/get_business_term_data/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ type Input struct {
}

type Output struct {
BusinessTermID string `json:"businessTermId" jsonschema:"The Business Term asset ID."`
BusinessTermID string `json:"businessTermId" jsonschema:"The Business Term asset ID."`
ConnectedPhysicalData []Attribute `json:"connectedPhysicalData" jsonschema:"The data attributes with their connected columns and tables."`
Error string `json:"error,omitempty" jsonschema:"Error message if the operation failed."`
Error string `json:"error,omitempty" jsonschema:"Error message if the operation failed."`
}

type Attribute struct {
Expand All @@ -46,6 +46,7 @@ type Attribute struct {
func NewTool(collibraClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "get_business_term_data",
Title: "Get Business Term Data",
Description: "Retrieve the physical data assets (Columns and Tables) associated with a Business Term via the path Business Term → Data Attribute → Column → Table.",
Handler: handler(collibraClient),
Permissions: []string{},
Expand Down
1 change: 1 addition & 0 deletions pkg/tools/get_column_semantics/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ type DataAttributeSemantics struct {
func NewTool(collibraClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "get_column_semantics",
Title: "Get Column Semantics",
Description: "Retrieve all connected Data Attribute assets for a Column, including descriptions and related Measures and generic business assets with their descriptions.",
Handler: handler(collibraClient),
Permissions: []string{},
Expand Down
1 change: 1 addition & 0 deletions pkg/tools/get_debug_mcp_init_request/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ type Output = mcp.InitializeParams
func NewTool(_ *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "get_debug_mcp_init_request",
Title: "Get Debug MCP Init Request",
Description: "Returns the MCP initialize request the connected client sent during the handshake, including protocolVersion, clientInfo, and declared capabilities (e.g. whether elicitation, sampling, or roots are supported). Useful for debugging MCP client/server compatibility.",
Handler: handler(),
Permissions: []string{},
Expand Down
3 changes: 2 additions & 1 deletion pkg/tools/get_lineage_downstream/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@ type Input struct {

func NewTool(collibraClient *http.Client) *chip.Tool[Input, clients.GetLineageDirectionalOutput] {
return &chip.Tool[Input, clients.GetLineageDirectionalOutput]{
Name: "get_lineage_downstream",
Name: "get_lineage_downstream",
Title: "Get Downstream Lineage",
Description: `WORKFLOW: Call this AFTER search_lineage_entities has given you an entity ID. This is the tool for impact analysis and tracing data consumers.
Use when the user asks: "what depends on this data?", "what uses this table?", "what breaks if this column changes?", "what reports use this data?", "what is the impact of changing this?".
Typical workflow: (1) search_lineage_entities to find the entity ID → (2) get_lineage_downstream with that ID → (3) optionally get_lineage_entity for the most relevant consumer entities only.
Expand Down
3 changes: 2 additions & 1 deletion pkg/tools/get_lineage_entity/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ type Input struct {

func NewTool(collibraClient *http.Client) *chip.Tool[Input, clients.GetLineageEntityOutput] {
return &chip.Tool[Input, clients.GetLineageEntityOutput]{
Name: "get_lineage_entity",
Name: "get_lineage_entity",
Title: "Get Lineage Entity",
Description: `WORKFLOW: This is a FOLLOW-UP tool for resolving entity IDs you already have. Do not call this as a first step — start with search_lineage_entities instead.
Use when you have an entity ID from get_lineage_upstream or get_lineage_downstream results and need to know the entity's name, type, or other metadata. Returns: name, type, source systems, parent entity, and linked DGC identifier.
IMPORTANT: Upstream/downstream results return entity IDs only. You do NOT need to resolve every ID — summarize based on entity IDs and only call this tool for the most relevant entities the user asked about. Resolving all IDs wastes tool calls.
Expand Down
3 changes: 2 additions & 1 deletion pkg/tools/get_lineage_transformation/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ type Input struct {

func NewTool(collibraClient *http.Client) *chip.Tool[Input, clients.GetLineageTransformationOutput] {
return &chip.Tool[Input, clients.GetLineageTransformationOutput]{
Name: "get_lineage_transformation",
Name: "get_lineage_transformation",
Title: "Get Lineage Transformation",
Description: `WORKFLOW: This is a TERMINAL tool — only call it when the user explicitly wants to see the actual SQL, script, or transformation logic. Requires a transformation ID from a prior get_lineage_upstream or get_lineage_downstream result.
Use when the user asks: "show me the SQL", "what logic transforms this data?", "how is this ETL job defined?".
Do NOT call this just to understand the lineage graph — get_lineage_upstream and get_lineage_downstream already show which transformations connect entities, which is sufficient for most lineage questions. Only call this when the user wants the actual code or logic.
Expand Down
3 changes: 2 additions & 1 deletion pkg/tools/get_lineage_upstream/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@ type Input struct {

func NewTool(collibraClient *http.Client) *chip.Tool[Input, clients.GetLineageDirectionalOutput] {
return &chip.Tool[Input, clients.GetLineageDirectionalOutput]{
Name: "get_lineage_upstream",
Name: "get_lineage_upstream",
Title: "Get Upstream Lineage",
Description: `WORKFLOW: Call this AFTER search_lineage_entities has given you an entity ID. This is the tool for tracing data sources.
Use when the user asks: "where does this data come from?", "what are the sources for this table?", "how is this column calculated?", "what feeds into this report?".
Typical workflow: (1) search_lineage_entities to find the entity ID → (2) get_lineage_upstream with that ID → (3) optionally get_lineage_entity for the most relevant source entities only.
Expand Down
3 changes: 2 additions & 1 deletion pkg/tools/get_measure_data/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ type Input struct {

type Output struct {
DataHierarchy []Attribute `json:"dataHierarchy" jsonschema:"The list of data attributes with their connected columns and tables."`
Error string `json:"error,omitempty" jsonschema:"Error message if the operation failed."`
Error string `json:"error,omitempty" jsonschema:"Error message if the operation failed."`
}

type Attribute struct {
Expand All @@ -45,6 +45,7 @@ type Attribute struct {
func NewTool(collibraClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "get_measure_data",
Title: "Get Measure Data",
Description: "Retrieve all underlying Column assets connected to a Measure via the path Measure → Data Attribute → Column, including each Column's description and parent Table.",
Handler: handler(collibraClient),
Permissions: []string{},
Expand Down
1 change: 1 addition & 0 deletions pkg/tools/get_table_semantics/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ type DataAttributeWithMeasures struct {
func NewTool(collibraClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "get_table_semantics",
Title: "Get Table Semantics",
Description: "Retrieve the semantic layer for a Table asset: Columns, their Data Attributes, and connected Measures. Answers 'What is the semantic context of this table?' or 'Which metrics use data from this table?'.",
Handler: handler(collibraClient),
Permissions: []string{},
Expand Down
1 change: 1 addition & 0 deletions pkg/tools/list_asset_types/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ type AssetType struct {
func NewTool(collibraClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "list_asset_types",
Title: "List Asset Types",
Description: "List asset types available in Collibra with their properties and metadata.",
Handler: handler(collibraClient),
Permissions: []string{},
Expand Down
1 change: 1 addition & 0 deletions pkg/tools/list_data_contracts/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ type Contract struct {
func NewTool(collibraClient *http.Client) *chip.Tool[Input, Output] {
return &chip.Tool[Input, Output]{
Name: "list_data_contract",
Title: "List Data Contracts",
Description: "List data contracts available in Collibra. Returns a paginated list of data contract metadata, sorted by the last modified date in descending order.",
Handler: handler(collibraClient),
Permissions: []string{},
Expand Down
Loading
Loading