mirror of
https://github.com/getcompanion-ai/co-mono.git
synced 2026-04-19 05:02:41 +00:00
feat(coding-agent): show tool input schema in /export HTML
Include tool parameter names, types, descriptions in a collapsible section under each tool in the export HTML. Also adds parameters to pi.getAllTools() return value. closes #1407, closes #1416
This commit is contained in:
parent
83931c53fd
commit
afb7e5ed4c
6 changed files with 91 additions and 7 deletions
|
|
@ -56,6 +56,7 @@ import {
|
|||
type SessionBeforeTreeResult,
|
||||
type ShutdownHandler,
|
||||
type ToolDefinition,
|
||||
type ToolInfo,
|
||||
type TreePreparation,
|
||||
type TurnEndEvent,
|
||||
type TurnStartEvent,
|
||||
|
|
@ -535,12 +536,13 @@ export class AgentSession {
|
|||
}
|
||||
|
||||
/**
|
||||
* Get all configured tools with name and description.
|
||||
* Get all configured tools with name, description, and parameter schema.
|
||||
*/
|
||||
getAllTools(): Array<{ name: string; description: string }> {
|
||||
getAllTools(): ToolInfo[] {
|
||||
return Array.from(this._toolRegistry.values()).map((t) => ({
|
||||
name: t.name,
|
||||
description: t.description,
|
||||
parameters: t.parameters,
|
||||
}));
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue