refactor: Remove agent_test command-line tool and associated files to streamline project structure and eliminate unused components

This commit is contained in:
wizardchen
2025-12-01 17:24:57 +08:00
parent 60241a2d29
commit 93af4460d6
40 changed files with 387 additions and 1692 deletions
@@ -168,6 +168,7 @@ func (t *ListKnowledgeChunksTool) Execute(ctx context.Context, args map[string]i
}, nil
}
// lookupKnowledgeTitle looks up the title of a knowledge document
func (t *ListKnowledgeChunksTool) lookupKnowledgeTitle(ctx context.Context, knowledgeID string) string {
if t.knowledgeService == nil {
return ""
@@ -179,6 +180,7 @@ func (t *ListKnowledgeChunksTool) lookupKnowledgeTitle(ctx context.Context, know
return strings.TrimSpace(knowledge.Title)
}
// buildOutput builds the output for the list knowledge chunks tool
func (t *ListKnowledgeChunksTool) buildOutput(
knowledgeID string,
knowledgeTitle string,
@@ -226,6 +228,7 @@ func (t *ListKnowledgeChunksTool) buildOutput(
return builder.String()
}
// summarizeContent summarizes the content of a chunk
func summarizeContent(content string) string {
cleaned := strings.TrimSpace(content)
if cleaned == "" {