agent-devkit 0.2.0 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +66 -13
- package/bin/agent.mjs +133 -7
- package/package.json +1 -1
- package/runtime/README.md +205 -13
- package/runtime/agent +31 -5
- package/runtime/agents/README.md +18 -0
- package/runtime/agents/contribution-reviewer/AGENTS.md +8 -0
- package/runtime/agents/contribution-reviewer/README.md +8 -0
- package/runtime/agents/contribution-reviewer/agent.yaml +40 -0
- package/runtime/agents/contribution-reviewer/capabilities/plan-contribution-pr/capability.yaml +27 -0
- package/runtime/agents/contribution-reviewer/capabilities/plan-contribution-pr/decision-rules.md +5 -0
- package/runtime/agents/contribution-reviewer/capabilities/plan-contribution-pr/workflow.md +6 -0
- package/runtime/agents/contribution-reviewer/capabilities/review-contribution/capability.yaml +25 -0
- package/runtime/agents/contribution-reviewer/capabilities/review-contribution/decision-rules.md +5 -0
- package/runtime/agents/contribution-reviewer/capabilities/review-contribution/workflow.md +5 -0
- package/runtime/agents/contribution-reviewer/capabilities/validate-local-contribution/capability.yaml +26 -0
- package/runtime/agents/contribution-reviewer/capabilities/validate-local-contribution/decision-rules.md +5 -0
- package/runtime/agents/contribution-reviewer/capabilities/validate-local-contribution/workflow.md +6 -0
- package/runtime/agents/contribution-reviewer/infra/README.md +6 -0
- package/runtime/agents/contribution-reviewer/knowledge/context.md +8 -0
- package/runtime/agents/contribution-reviewer/knowledge/system.md +8 -0
- package/runtime/agents/contribution-reviewer/templates/README.md +3 -0
- package/runtime/agents/knowledge-author/AGENTS.md +7 -0
- package/runtime/agents/knowledge-author/README.md +7 -0
- package/runtime/agents/knowledge-author/agent.yaml +37 -0
- package/runtime/agents/knowledge-author/capabilities/create-knowledge-snapshot/capability.yaml +30 -0
- package/runtime/agents/knowledge-author/capabilities/create-knowledge-snapshot/decision-rules.md +6 -0
- package/runtime/agents/knowledge-author/capabilities/create-knowledge-snapshot/workflow.md +7 -0
- package/runtime/agents/knowledge-author/infra/.gitkeep +1 -0
- package/runtime/agents/knowledge-author/knowledge/context.md +4 -0
- package/runtime/agents/knowledge-author/knowledge/system.md +4 -0
- package/runtime/agents/knowledge-author/templates/.gitkeep +1 -0
- package/runtime/agents/knowledge-curator/AGENTS.md +7 -0
- package/runtime/agents/knowledge-curator/README.md +6 -0
- package/runtime/agents/knowledge-curator/agent.yaml +37 -0
- package/runtime/agents/knowledge-curator/capabilities/curate-knowledge-base/capability.yaml +29 -0
- package/runtime/agents/knowledge-curator/capabilities/curate-knowledge-base/decision-rules.md +6 -0
- package/runtime/agents/knowledge-curator/capabilities/curate-knowledge-base/workflow.md +7 -0
- package/runtime/agents/knowledge-curator/infra/.gitkeep +1 -0
- package/runtime/agents/knowledge-curator/knowledge/context.md +4 -0
- package/runtime/agents/knowledge-curator/knowledge/system.md +4 -0
- package/runtime/agents/knowledge-curator/templates/.gitkeep +1 -0
- package/runtime/agents/knowledge-infra-builder/AGENTS.md +8 -0
- package/runtime/agents/knowledge-infra-builder/README.md +8 -0
- package/runtime/agents/knowledge-infra-builder/agent.yaml +38 -0
- package/runtime/agents/knowledge-infra-builder/capabilities/create-knowledge-base/capability.yaml +30 -0
- package/runtime/agents/knowledge-infra-builder/capabilities/create-knowledge-base/decision-rules.md +6 -0
- package/runtime/agents/knowledge-infra-builder/capabilities/create-knowledge-base/workflow.md +7 -0
- package/runtime/agents/knowledge-infra-builder/infra/.gitkeep +1 -0
- package/runtime/agents/knowledge-infra-builder/knowledge/context.md +4 -0
- package/runtime/agents/knowledge-infra-builder/knowledge/system.md +4 -0
- package/runtime/agents/knowledge-infra-builder/templates/.gitkeep +1 -0
- package/runtime/agents/knowledge-owner/AGENTS.md +7 -0
- package/runtime/agents/knowledge-owner/README.md +6 -0
- package/runtime/agents/knowledge-owner/agent.yaml +37 -0
- package/runtime/agents/knowledge-owner/capabilities/publish-knowledge-snapshot/capability.yaml +28 -0
- package/runtime/agents/knowledge-owner/capabilities/publish-knowledge-snapshot/decision-rules.md +6 -0
- package/runtime/agents/knowledge-owner/capabilities/publish-knowledge-snapshot/workflow.md +7 -0
- package/runtime/agents/knowledge-owner/infra/.gitkeep +1 -0
- package/runtime/agents/knowledge-owner/knowledge/context.md +4 -0
- package/runtime/agents/knowledge-owner/knowledge/system.md +4 -0
- package/runtime/agents/knowledge-owner/templates/.gitkeep +1 -0
- package/runtime/agents/knowledge-reviewer/AGENTS.md +7 -0
- package/runtime/agents/knowledge-reviewer/README.md +7 -0
- package/runtime/agents/knowledge-reviewer/agent.yaml +36 -0
- package/runtime/agents/knowledge-reviewer/capabilities/review-knowledge-snapshot/capability.yaml +26 -0
- package/runtime/agents/knowledge-reviewer/capabilities/review-knowledge-snapshot/decision-rules.md +6 -0
- package/runtime/agents/knowledge-reviewer/capabilities/review-knowledge-snapshot/workflow.md +7 -0
- package/runtime/agents/knowledge-reviewer/infra/.gitkeep +1 -0
- package/runtime/agents/knowledge-reviewer/knowledge/context.md +4 -0
- package/runtime/agents/knowledge-reviewer/knowledge/system.md +4 -0
- package/runtime/agents/knowledge-reviewer/templates/.gitkeep +1 -0
- package/runtime/agents/local-memory-manager/AGENTS.md +5 -0
- package/runtime/agents/local-memory-manager/README.md +7 -0
- package/runtime/agents/local-memory-manager/agent.yaml +38 -0
- package/runtime/agents/local-memory-manager/capabilities/curate-local-memory/capability.yaml +19 -0
- package/runtime/agents/local-memory-manager/capabilities/curate-local-memory/decision-rules.md +5 -0
- package/runtime/agents/local-memory-manager/capabilities/curate-local-memory/workflow.md +6 -0
- package/runtime/agents/local-memory-manager/capabilities/inspect-local-memory/capability.yaml +19 -0
- package/runtime/agents/local-memory-manager/capabilities/inspect-local-memory/decision-rules.md +5 -0
- package/runtime/agents/local-memory-manager/capabilities/inspect-local-memory/workflow.md +5 -0
- package/runtime/agents/local-memory-manager/infra/.gitkeep +1 -0
- package/runtime/agents/local-memory-manager/knowledge/context.md +4 -0
- package/runtime/agents/local-memory-manager/knowledge/system.md +4 -0
- package/runtime/agents/local-memory-manager/templates/.gitkeep +1 -0
- package/runtime/agents/memory-sync-manager/AGENTS.md +7 -0
- package/runtime/agents/memory-sync-manager/README.md +7 -0
- package/runtime/agents/memory-sync-manager/agent.yaml +37 -0
- package/runtime/agents/memory-sync-manager/capabilities/plan-memory-backup/capability.yaml +29 -0
- package/runtime/agents/memory-sync-manager/capabilities/plan-memory-backup/decision-rules.md +6 -0
- package/runtime/agents/memory-sync-manager/capabilities/plan-memory-backup/workflow.md +7 -0
- package/runtime/agents/memory-sync-manager/infra/.gitkeep +1 -0
- package/runtime/agents/memory-sync-manager/knowledge/context.md +4 -0
- package/runtime/agents/memory-sync-manager/knowledge/system.md +4 -0
- package/runtime/agents/memory-sync-manager/templates/.gitkeep +1 -0
- package/runtime/agents/shared-memory-curator/AGENTS.md +5 -0
- package/runtime/agents/shared-memory-curator/README.md +6 -0
- package/runtime/agents/shared-memory-curator/agent.yaml +38 -0
- package/runtime/agents/shared-memory-curator/capabilities/create-shared-memory/capability.yaml +19 -0
- package/runtime/agents/shared-memory-curator/capabilities/create-shared-memory/decision-rules.md +5 -0
- package/runtime/agents/shared-memory-curator/capabilities/create-shared-memory/workflow.md +5 -0
- package/runtime/agents/shared-memory-curator/capabilities/publish-shared-submission/capability.yaml +19 -0
- package/runtime/agents/shared-memory-curator/capabilities/publish-shared-submission/decision-rules.md +5 -0
- package/runtime/agents/shared-memory-curator/capabilities/publish-shared-submission/workflow.md +5 -0
- package/runtime/agents/shared-memory-curator/capabilities/review-shared-submission/capability.yaml +19 -0
- package/runtime/agents/shared-memory-curator/capabilities/review-shared-submission/decision-rules.md +5 -0
- package/runtime/agents/shared-memory-curator/capabilities/review-shared-submission/workflow.md +5 -0
- package/runtime/agents/shared-memory-curator/infra/.gitkeep +1 -0
- package/runtime/agents/shared-memory-curator/knowledge/context.md +5 -0
- package/runtime/agents/shared-memory-curator/knowledge/system.md +4 -0
- package/runtime/agents/shared-memory-curator/templates/.gitkeep +1 -0
- package/runtime/cli/README.md +47 -8
- package/runtime/cli/aikit/__init__.py +1 -1
- package/runtime/cli/aikit/agent_registry.py +4 -2
- package/runtime/cli/aikit/agentic_commands.py +158 -0
- package/runtime/cli/aikit/app_home.py +2 -0
- package/runtime/cli/aikit/audit.py +16 -6
- package/runtime/cli/aikit/catalog.py +278 -8
- package/runtime/cli/aikit/cli_dispatch.py +489 -13
- package/runtime/cli/aikit/cli_parser.py +146 -8
- package/runtime/cli/aikit/contribution.py +132 -2
- package/runtime/cli/aikit/doctor_runtime.py +85 -0
- package/runtime/cli/aikit/embedded_mini_brain.py +351 -0
- package/runtime/cli/aikit/eval.py +356 -10
- package/runtime/cli/aikit/human_output.py +310 -4
- package/runtime/cli/aikit/interactive_wizard.py +146 -0
- package/runtime/cli/aikit/knowledge_base.py +1067 -0
- package/runtime/cli/aikit/llm.py +40 -6
- package/runtime/cli/aikit/local_artifacts.py +444 -0
- package/runtime/cli/aikit/local_llm.py +176 -0
- package/runtime/cli/aikit/local_llm_operator.py +15 -5
- package/runtime/cli/aikit/main.py +15 -0
- package/runtime/cli/aikit/mcp_manifest.py +798 -0
- package/runtime/cli/aikit/mcp_tools.py +643 -5
- package/runtime/cli/aikit/memory.py +405 -0
- package/runtime/cli/aikit/mini_brain.py +56 -25
- package/runtime/cli/aikit/model_router.py +42 -9
- package/runtime/cli/aikit/natural_prompt_runtime.py +194 -2
- package/runtime/cli/aikit/ollama.py +64 -15
- package/runtime/cli/aikit/onboarding.py +551 -0
- package/runtime/cli/aikit/output.py +67 -0
- package/runtime/cli/aikit/prompt_injection.py +12 -1
- package/runtime/cli/aikit/review_gate.py +14 -2
- package/runtime/cli/aikit/roadmap_cli.py +1 -1
- package/runtime/cli/aikit/secrets.py +3 -2
- package/runtime/cli/aikit/setup_wizard_payload.py +3 -0
- package/runtime/cli/aikit/shared_memory.py +415 -0
- package/runtime/cli/aikit/specialist_readiness.py +152 -0
- package/runtime/cli/aikit/tasks.py +104 -1
- package/runtime/cli/aikit/team.py +380 -0
- package/runtime/cli/aikit/toolchain.py +7 -2
- package/runtime/cli/aikit/workflows.py +115 -14
- package/runtime/models/qwen2.5-0.5b-instruct/manifest.json +30 -0
- package/runtime/providers/knowledge-github.yaml +40 -0
- package/runtime/providers/knowledge-google-drive.yaml +32 -0
- package/runtime/providers/knowledge-local.yaml +26 -0
- package/runtime/providers/knowledge-notion.yaml +32 -0
- package/runtime/providers/knowledge-obsidian.yaml +24 -0
- package/runtime/providers/knowledge-onedrive.yaml +36 -0
- package/runtime/providers/knowledge-s3.yaml +45 -0
- package/runtime/providers/knowledge-sharepoint.yaml +39 -0
- package/runtime/providers/knowledge-supabase.yaml +43 -0
- package/runtime/providers/knowledge-vector.yaml +39 -0
- package/runtime/requirements.txt +6 -0
- package/runtime/scripts/docker-cli-qa.sh +453 -0
- package/runtime/scripts/release-catalog-snapshot.json +55 -4
- package/runtime/scripts/release-gate.py +54 -13
- package/runtime/tooling/toolchain.yaml +92 -0
- package/runtime/vendor/skills/napkin/napkin.md +21 -7
- package/runtime/workflows/azure-card-analysis/README.md +3 -0
- package/runtime/workflows/azure-card-analysis/workflow.yaml +30 -0
- package/runtime/workflows/daily-pr-review/README.md +3 -0
- package/runtime/workflows/daily-pr-review/workflow.yaml +31 -0
- package/runtime/workflows/incident-analysis/README.md +3 -0
- package/runtime/workflows/incident-analysis/workflow.yaml +33 -0
- package/runtime/workflows/release-prep/README.md +3 -0
- package/runtime/workflows/release-prep/workflow.yaml +30 -0
|
@@ -3,10 +3,12 @@
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
5
|
import json
|
|
6
|
+
from pathlib import Path
|
|
6
7
|
from typing import Any, Callable
|
|
7
8
|
|
|
8
9
|
from cli.aikit.audit import redact_value, try_record_audit
|
|
9
|
-
from cli.aikit.
|
|
10
|
+
from cli.aikit.agentic_commands import agentic_plan
|
|
11
|
+
from cli.aikit.catalog import catalog_list, catalog_search, catalog_show
|
|
10
12
|
from cli.aikit.core.requests import CapabilityRunRequest
|
|
11
13
|
from cli.aikit.core.runtime import (
|
|
12
14
|
inspect_capability_request,
|
|
@@ -17,13 +19,90 @@ from cli.aikit.core.runtime import (
|
|
|
17
19
|
from cli.aikit.doctor_runtime import doctor
|
|
18
20
|
from cli.aikit.eval import eval_list, eval_run
|
|
19
21
|
from cli.aikit.errors import DevKitError
|
|
22
|
+
from cli.aikit.local_artifacts import (
|
|
23
|
+
local_agent_list,
|
|
24
|
+
local_agent_create,
|
|
25
|
+
local_agent_show,
|
|
26
|
+
local_agent_validate,
|
|
27
|
+
local_automation_create,
|
|
28
|
+
local_automation_enable,
|
|
29
|
+
local_automation_list,
|
|
30
|
+
local_automation_show,
|
|
31
|
+
local_automation_validate,
|
|
32
|
+
script_create,
|
|
33
|
+
script_list,
|
|
34
|
+
script_run,
|
|
35
|
+
skill_create,
|
|
36
|
+
skill_list,
|
|
37
|
+
skill_show,
|
|
38
|
+
)
|
|
39
|
+
from cli.aikit.local_llm import local_llm_doctor, local_llm_list, local_llm_models
|
|
40
|
+
from cli.aikit.knowledge_base import (
|
|
41
|
+
knowledge_base_create,
|
|
42
|
+
knowledge_base_join,
|
|
43
|
+
knowledge_base_rotate_token,
|
|
44
|
+
knowledge_base_status,
|
|
45
|
+
knowledge_base_tokens,
|
|
46
|
+
knowledge_curate,
|
|
47
|
+
knowledge_doctor,
|
|
48
|
+
knowledge_index,
|
|
49
|
+
knowledge_init,
|
|
50
|
+
knowledge_publish,
|
|
51
|
+
knowledge_review,
|
|
52
|
+
knowledge_review_list,
|
|
53
|
+
knowledge_search,
|
|
54
|
+
knowledge_sync,
|
|
55
|
+
knowledge_snapshot_create,
|
|
56
|
+
knowledge_snapshot_list,
|
|
57
|
+
knowledge_snapshot_score,
|
|
58
|
+
knowledge_snapshot_show,
|
|
59
|
+
knowledge_snapshot_submit,
|
|
60
|
+
)
|
|
61
|
+
from cli.aikit.memory import (
|
|
62
|
+
create_memory_backup,
|
|
63
|
+
delete_memory_backup,
|
|
64
|
+
list_memory_backups,
|
|
65
|
+
memory_path_payload,
|
|
66
|
+
reset_memory,
|
|
67
|
+
restore_memory_backup,
|
|
68
|
+
show_memory,
|
|
69
|
+
)
|
|
20
70
|
from cli.aikit.mcp_manifest import mcp_tools
|
|
71
|
+
from cli.aikit.notifications import (
|
|
72
|
+
format_notification_event,
|
|
73
|
+
list_notification_channels,
|
|
74
|
+
list_notification_events,
|
|
75
|
+
notification_doctor,
|
|
76
|
+
)
|
|
77
|
+
from cli.aikit.onboarding import onboarding_status
|
|
21
78
|
from cli.aikit.orchestrator import build_execution_plan
|
|
79
|
+
from cli.aikit.personality import load_personality, reset_personality, update_personality
|
|
22
80
|
from cli.aikit.roadmap_cli import roadmap_payload
|
|
23
81
|
from cli.aikit.router_explain import explain_route
|
|
24
82
|
from cli.aikit.runtime_paths import ROOT
|
|
25
83
|
from cli.aikit.secrets import secrets_doctor
|
|
84
|
+
from cli.aikit.shared_memory import (
|
|
85
|
+
shared_memory_create,
|
|
86
|
+
shared_memory_list,
|
|
87
|
+
shared_memory_publish,
|
|
88
|
+
shared_memory_read,
|
|
89
|
+
shared_memory_review,
|
|
90
|
+
shared_memory_status,
|
|
91
|
+
shared_memory_submit,
|
|
92
|
+
)
|
|
26
93
|
from cli.aikit.sources import SourceRegistryError, list_sources, source_status
|
|
94
|
+
from cli.aikit.tasks import list_tasks, run_task, scheduler_run_once, show_task
|
|
95
|
+
from cli.aikit.team import (
|
|
96
|
+
team_doctor,
|
|
97
|
+
team_init,
|
|
98
|
+
team_onboard,
|
|
99
|
+
team_profile_export,
|
|
100
|
+
team_profile_import,
|
|
101
|
+
team_profile_list,
|
|
102
|
+
team_profile_show,
|
|
103
|
+
team_status,
|
|
104
|
+
)
|
|
105
|
+
from cli.aikit.workflows import workflow_list, workflow_run, workflow_show
|
|
27
106
|
from cli.aikit.wizard_state import WizardStateError, answer_wizard, show_wizard
|
|
28
107
|
|
|
29
108
|
|
|
@@ -41,12 +120,91 @@ def call_mcp_tool(name: str, arguments: dict[str, Any] | None) -> dict[str, Any]
|
|
|
41
120
|
"agent_devkit_capability_inspect": tool_capability_inspect,
|
|
42
121
|
"agent_devkit_capability_run": tool_capability_run,
|
|
43
122
|
"agent_devkit_doctor": tool_doctor,
|
|
123
|
+
"agent_devkit_onboarding_status": tool_onboarding_status,
|
|
124
|
+
"agent_devkit_memory_show": tool_memory_show,
|
|
125
|
+
"agent_devkit_memory_path": tool_memory_path,
|
|
126
|
+
"agent_devkit_memory_reset": tool_memory_reset,
|
|
127
|
+
"agent_devkit_memory_backup_create": tool_memory_backup_create,
|
|
128
|
+
"agent_devkit_memory_backup_list": tool_memory_backup_list,
|
|
129
|
+
"agent_devkit_memory_backup_restore": tool_memory_backup_restore,
|
|
130
|
+
"agent_devkit_memory_backup_delete": tool_memory_backup_delete,
|
|
131
|
+
"agent_devkit_shared_memory_list": tool_shared_memory_list,
|
|
132
|
+
"agent_devkit_shared_memory_status": tool_shared_memory_status,
|
|
133
|
+
"agent_devkit_shared_memory_create": tool_shared_memory_create,
|
|
134
|
+
"agent_devkit_shared_memory_read": tool_shared_memory_read,
|
|
135
|
+
"agent_devkit_shared_memory_submit": tool_shared_memory_submit,
|
|
136
|
+
"agent_devkit_shared_memory_review": tool_shared_memory_review,
|
|
137
|
+
"agent_devkit_shared_memory_publish": tool_shared_memory_publish,
|
|
138
|
+
"agent_devkit_personality_show": tool_personality_show,
|
|
139
|
+
"agent_devkit_personality_update": tool_personality_update,
|
|
140
|
+
"agent_devkit_personality_reset": tool_personality_reset,
|
|
141
|
+
"agent_devkit_task_list": tool_task_list,
|
|
142
|
+
"agent_devkit_task_show": tool_task_show,
|
|
143
|
+
"agent_devkit_task_run_dry_run": tool_task_run_dry_run,
|
|
144
|
+
"agent_devkit_scheduler_run_once_dry_run": tool_scheduler_run_once_dry_run,
|
|
145
|
+
"agent_devkit_notifications_doctor": tool_notifications_doctor,
|
|
146
|
+
"agent_devkit_notifications_list_events": tool_notifications_list_events,
|
|
147
|
+
"agent_devkit_notifications_list_channels": tool_notifications_list_channels,
|
|
148
|
+
"agent_devkit_notifications_format": tool_notifications_format,
|
|
149
|
+
"agent_devkit_catalog_list": tool_catalog_list,
|
|
44
150
|
"agent_devkit_catalog_search": tool_catalog_search,
|
|
151
|
+
"agent_devkit_catalog_show": tool_catalog_show,
|
|
45
152
|
"agent_devkit_route_explain": tool_route_explain,
|
|
46
153
|
"agent_devkit_agent_prompt_dry_run": tool_agent_prompt_dry_run,
|
|
154
|
+
"agent_devkit_agentic_plan": tool_agentic_plan,
|
|
47
155
|
"agent_devkit_eval_list": tool_eval_list,
|
|
48
156
|
"agent_devkit_eval_run": tool_eval_run,
|
|
49
157
|
"agent_devkit_secrets_doctor": tool_secrets_doctor,
|
|
158
|
+
"agent_devkit_workflow_list": tool_workflow_list,
|
|
159
|
+
"agent_devkit_workflow_show": tool_workflow_show,
|
|
160
|
+
"agent_devkit_workflow_run_dry_run": tool_workflow_run_dry_run,
|
|
161
|
+
"agent_devkit_local_llm_list": tool_local_llm_list,
|
|
162
|
+
"agent_devkit_local_llm_doctor": tool_local_llm_doctor,
|
|
163
|
+
"agent_devkit_local_llm_models": tool_local_llm_models,
|
|
164
|
+
"agent_devkit_local_artifacts_list": tool_local_artifacts_list,
|
|
165
|
+
"agent_devkit_local_skill_create": tool_local_skill_create,
|
|
166
|
+
"agent_devkit_local_skill_list": tool_local_skill_list,
|
|
167
|
+
"agent_devkit_local_skill_show": tool_local_skill_show,
|
|
168
|
+
"agent_devkit_local_script_create": tool_local_script_create,
|
|
169
|
+
"agent_devkit_local_script_list": tool_local_script_list,
|
|
170
|
+
"agent_devkit_local_script_run_dry_run": tool_local_script_run_dry_run,
|
|
171
|
+
"agent_devkit_local_agent_create": tool_local_agent_create,
|
|
172
|
+
"agent_devkit_local_agent_list": tool_local_agent_list,
|
|
173
|
+
"agent_devkit_local_agent_show": tool_local_agent_show,
|
|
174
|
+
"agent_devkit_local_agent_validate": tool_local_agent_validate,
|
|
175
|
+
"agent_devkit_local_automation_create": tool_local_automation_create,
|
|
176
|
+
"agent_devkit_local_automation_list": tool_local_automation_list,
|
|
177
|
+
"agent_devkit_local_automation_show": tool_local_automation_show,
|
|
178
|
+
"agent_devkit_local_automation_enable": tool_local_automation_enable,
|
|
179
|
+
"agent_devkit_local_automation_disable": tool_local_automation_disable,
|
|
180
|
+
"agent_devkit_local_automation_validate": tool_local_automation_validate,
|
|
181
|
+
"agent_devkit_team_status": tool_team_status,
|
|
182
|
+
"agent_devkit_team_doctor": tool_team_doctor,
|
|
183
|
+
"agent_devkit_team_init": tool_team_init,
|
|
184
|
+
"agent_devkit_team_onboard": tool_team_onboard,
|
|
185
|
+
"agent_devkit_team_profile_list": tool_team_profile_list,
|
|
186
|
+
"agent_devkit_team_profile_show": tool_team_profile_show,
|
|
187
|
+
"agent_devkit_team_profile_export": tool_team_profile_export,
|
|
188
|
+
"agent_devkit_team_profile_import": tool_team_profile_import,
|
|
189
|
+
"agent_devkit_knowledge_doctor": tool_knowledge_doctor,
|
|
190
|
+
"agent_devkit_knowledge_init": tool_knowledge_init,
|
|
191
|
+
"agent_devkit_knowledge_index": tool_knowledge_index,
|
|
192
|
+
"agent_devkit_knowledge_search": tool_knowledge_search,
|
|
193
|
+
"agent_devkit_knowledge_curate": tool_knowledge_curate,
|
|
194
|
+
"agent_devkit_knowledge_sync": tool_knowledge_sync,
|
|
195
|
+
"agent_devkit_knowledge_snapshot_create": tool_knowledge_snapshot_create,
|
|
196
|
+
"agent_devkit_knowledge_snapshot_list": tool_knowledge_snapshot_list,
|
|
197
|
+
"agent_devkit_knowledge_snapshot_show": tool_knowledge_snapshot_show,
|
|
198
|
+
"agent_devkit_knowledge_snapshot_score": tool_knowledge_snapshot_score,
|
|
199
|
+
"agent_devkit_knowledge_snapshot_submit": tool_knowledge_snapshot_submit,
|
|
200
|
+
"agent_devkit_knowledge_review_list": tool_knowledge_review_list,
|
|
201
|
+
"agent_devkit_knowledge_review": tool_knowledge_review,
|
|
202
|
+
"agent_devkit_knowledge_publish": tool_knowledge_publish,
|
|
203
|
+
"agent_devkit_knowledge_base_create": tool_knowledge_base_create,
|
|
204
|
+
"agent_devkit_knowledge_base_join": tool_knowledge_base_join,
|
|
205
|
+
"agent_devkit_knowledge_base_status": tool_knowledge_base_status,
|
|
206
|
+
"agent_devkit_knowledge_base_tokens": tool_knowledge_base_tokens,
|
|
207
|
+
"agent_devkit_knowledge_base_rotate_token": tool_knowledge_base_rotate_token,
|
|
50
208
|
"agent_devkit_roadmap": tool_roadmap,
|
|
51
209
|
"agent_devkit_source_list": tool_source_list,
|
|
52
210
|
"agent_devkit_source_status": tool_source_status,
|
|
@@ -139,13 +297,193 @@ def tool_doctor(args: dict[str, Any]) -> dict[str, Any]:
|
|
|
139
297
|
)
|
|
140
298
|
|
|
141
299
|
|
|
300
|
+
def tool_onboarding_status(_args: dict[str, Any]) -> dict[str, Any]:
|
|
301
|
+
return onboarding_status(ROOT)
|
|
302
|
+
|
|
303
|
+
|
|
304
|
+
def tool_memory_show(args: dict[str, Any]) -> dict[str, Any]:
|
|
305
|
+
return show_memory(ROOT, agent_id=optional_string(args, "agent_id"), source_id=optional_string(args, "source_id"))
|
|
306
|
+
|
|
307
|
+
|
|
308
|
+
def tool_memory_path(_args: dict[str, Any]) -> dict[str, Any]:
|
|
309
|
+
return memory_path_payload()
|
|
310
|
+
|
|
311
|
+
|
|
312
|
+
def tool_memory_reset(args: dict[str, Any]) -> dict[str, Any]:
|
|
313
|
+
payload = reset_memory(
|
|
314
|
+
all_memory=optional_bool(args, "all", default=False),
|
|
315
|
+
agent_id=optional_string(args, "agent_id"),
|
|
316
|
+
source_id=optional_string(args, "source_id"),
|
|
317
|
+
reset_sessions=optional_bool(args, "sessions", default=False),
|
|
318
|
+
reset_tasks=optional_bool(args, "tasks", default=False),
|
|
319
|
+
reset_cache=optional_bool(args, "cache", default=False),
|
|
320
|
+
)
|
|
321
|
+
attach_mcp_audit(payload, tool="agent_devkit_memory_reset", args=args)
|
|
322
|
+
return payload
|
|
323
|
+
|
|
324
|
+
|
|
325
|
+
def tool_memory_backup_create(args: dict[str, Any]) -> dict[str, Any]:
|
|
326
|
+
payload = create_memory_backup(
|
|
327
|
+
title=optional_string(args, "title"),
|
|
328
|
+
encrypted=optional_bool(args, "encrypted", default=False),
|
|
329
|
+
passphrase_env=optional_string(args, "passphrase_env"),
|
|
330
|
+
)
|
|
331
|
+
attach_mcp_audit(payload, tool="agent_devkit_memory_backup_create", args=args)
|
|
332
|
+
return payload
|
|
333
|
+
|
|
334
|
+
|
|
335
|
+
def tool_memory_backup_list(_args: dict[str, Any]) -> dict[str, Any]:
|
|
336
|
+
return list_memory_backups()
|
|
337
|
+
|
|
338
|
+
|
|
339
|
+
def tool_memory_backup_restore(args: dict[str, Any]) -> dict[str, Any]:
|
|
340
|
+
backup_id = optional_string(args, "backup_id")
|
|
341
|
+
backup_file = optional_string(args, "file")
|
|
342
|
+
if not backup_id and not backup_file:
|
|
343
|
+
raise ValueError("agent_devkit_memory_backup_restore requires backup_id or file")
|
|
344
|
+
payload = restore_memory_backup(
|
|
345
|
+
backup_id,
|
|
346
|
+
yes=optional_bool(args, "yes", default=False),
|
|
347
|
+
backup_file=backup_file,
|
|
348
|
+
passphrase_env=optional_string(args, "passphrase_env"),
|
|
349
|
+
)
|
|
350
|
+
attach_mcp_audit(payload, tool="agent_devkit_memory_backup_restore", args=args)
|
|
351
|
+
return payload
|
|
352
|
+
|
|
353
|
+
|
|
354
|
+
def tool_memory_backup_delete(args: dict[str, Any]) -> dict[str, Any]:
|
|
355
|
+
payload = delete_memory_backup(required_string(args, "backup_id"), yes=optional_bool(args, "yes", default=False))
|
|
356
|
+
attach_mcp_audit(payload, tool="agent_devkit_memory_backup_delete", args=args)
|
|
357
|
+
return payload
|
|
358
|
+
|
|
359
|
+
|
|
360
|
+
def tool_shared_memory_list(_args: dict[str, Any]) -> dict[str, Any]:
|
|
361
|
+
return shared_memory_list()
|
|
362
|
+
|
|
363
|
+
|
|
364
|
+
def tool_shared_memory_status(args: dict[str, Any]) -> dict[str, Any]:
|
|
365
|
+
return shared_memory_status(required_string(args, "memory_id"))
|
|
366
|
+
|
|
367
|
+
|
|
368
|
+
def tool_shared_memory_create(args: dict[str, Any]) -> dict[str, Any]:
|
|
369
|
+
payload = shared_memory_create(optional_string(args, "title"))
|
|
370
|
+
attach_mcp_audit(payload, tool="agent_devkit_shared_memory_create", args=args)
|
|
371
|
+
return payload
|
|
372
|
+
|
|
373
|
+
|
|
374
|
+
def tool_shared_memory_read(args: dict[str, Any]) -> dict[str, Any]:
|
|
375
|
+
return shared_memory_read(
|
|
376
|
+
required_string(args, "memory_id"),
|
|
377
|
+
optional_string(args, "entry_id"),
|
|
378
|
+
contributor_key=optional_string(args, "key"),
|
|
379
|
+
)
|
|
380
|
+
|
|
381
|
+
|
|
382
|
+
def tool_shared_memory_submit(args: dict[str, Any]) -> dict[str, Any]:
|
|
383
|
+
payload = shared_memory_submit(
|
|
384
|
+
required_string(args, "memory_id"),
|
|
385
|
+
title=optional_string(args, "title"),
|
|
386
|
+
content=required_string(args, "content"),
|
|
387
|
+
contributor_key=required_string(args, "key"),
|
|
388
|
+
)
|
|
389
|
+
attach_mcp_audit(payload, tool="agent_devkit_shared_memory_submit", args=args)
|
|
390
|
+
return payload
|
|
391
|
+
|
|
392
|
+
|
|
393
|
+
def tool_shared_memory_review(args: dict[str, Any]) -> dict[str, Any]:
|
|
394
|
+
return shared_memory_review(required_string(args, "memory_id"), required_string(args, "submission_id"))
|
|
395
|
+
|
|
396
|
+
|
|
397
|
+
def tool_shared_memory_publish(args: dict[str, Any]) -> dict[str, Any]:
|
|
398
|
+
payload = shared_memory_publish(
|
|
399
|
+
required_string(args, "memory_id"),
|
|
400
|
+
required_string(args, "submission_id"),
|
|
401
|
+
yes=optional_bool(args, "yes", default=False),
|
|
402
|
+
owner_key=optional_string(args, "owner_key"),
|
|
403
|
+
)
|
|
404
|
+
attach_mcp_audit(payload, tool="agent_devkit_shared_memory_publish", args=args)
|
|
405
|
+
return payload
|
|
406
|
+
|
|
407
|
+
|
|
408
|
+
def tool_personality_show(_args: dict[str, Any]) -> dict[str, Any]:
|
|
409
|
+
return load_personality()
|
|
410
|
+
|
|
411
|
+
|
|
412
|
+
def tool_personality_update(args: dict[str, Any]) -> dict[str, Any]:
|
|
413
|
+
payload = update_personality(
|
|
414
|
+
agent_name=optional_string(args, "agent_name"),
|
|
415
|
+
user_name=optional_string(args, "user_name"),
|
|
416
|
+
language=optional_string(args, "language"),
|
|
417
|
+
tone=optional_string(args, "tone"),
|
|
418
|
+
detail_level=optional_string(args, "detail_level"),
|
|
419
|
+
)
|
|
420
|
+
attach_mcp_audit(payload, tool="agent_devkit_personality_update", args=args)
|
|
421
|
+
return payload
|
|
422
|
+
|
|
423
|
+
|
|
424
|
+
def tool_personality_reset(args: dict[str, Any]) -> dict[str, Any]:
|
|
425
|
+
payload = reset_personality()
|
|
426
|
+
attach_mcp_audit(payload, tool="agent_devkit_personality_reset", args=args)
|
|
427
|
+
return payload
|
|
428
|
+
|
|
429
|
+
|
|
430
|
+
def tool_task_list(_args: dict[str, Any]) -> dict[str, Any]:
|
|
431
|
+
return list_tasks()
|
|
432
|
+
|
|
433
|
+
|
|
434
|
+
def tool_task_show(args: dict[str, Any]) -> dict[str, Any]:
|
|
435
|
+
return show_task(required_string(args, "task_id"))
|
|
436
|
+
|
|
437
|
+
|
|
438
|
+
def tool_task_run_dry_run(args: dict[str, Any]) -> dict[str, Any]:
|
|
439
|
+
return run_task(required_string(args, "task_id"), dry_run=True, origin="mcp")
|
|
440
|
+
|
|
441
|
+
|
|
442
|
+
def tool_scheduler_run_once_dry_run(_args: dict[str, Any]) -> dict[str, Any]:
|
|
443
|
+
return scheduler_run_once(dry_run=True)
|
|
444
|
+
|
|
445
|
+
|
|
446
|
+
def tool_notifications_doctor(_args: dict[str, Any]) -> dict[str, Any]:
|
|
447
|
+
return notification_doctor()
|
|
448
|
+
|
|
449
|
+
|
|
450
|
+
def tool_notifications_list_events(_args: dict[str, Any]) -> dict[str, Any]:
|
|
451
|
+
return list_notification_events()
|
|
452
|
+
|
|
453
|
+
|
|
454
|
+
def tool_notifications_list_channels(_args: dict[str, Any]) -> dict[str, Any]:
|
|
455
|
+
return list_notification_channels()
|
|
456
|
+
|
|
457
|
+
|
|
458
|
+
def tool_notifications_format(args: dict[str, Any]) -> dict[str, Any]:
|
|
459
|
+
payload = {
|
|
460
|
+
"title": optional_string(args, "title") or "Agent DevKit",
|
|
461
|
+
"message": optional_string(args, "message") or "",
|
|
462
|
+
"summary": optional_string(args, "summary"),
|
|
463
|
+
"event": optional_string(args, "event") or "task.completed",
|
|
464
|
+
"status": optional_string(args, "status"),
|
|
465
|
+
"severity": optional_string(args, "severity") or "info",
|
|
466
|
+
"task_id": optional_string(args, "task_id"),
|
|
467
|
+
"origin": optional_string(args, "origin") or "mcp",
|
|
468
|
+
}
|
|
469
|
+
return format_notification_event(payload)
|
|
470
|
+
|
|
471
|
+
|
|
472
|
+
def tool_catalog_list(args: dict[str, Any]) -> dict[str, Any]:
|
|
473
|
+
item_type = optional_catalog_type(args)
|
|
474
|
+
return catalog_list(ROOT, item_type=item_type, filters=catalog_filters(args))
|
|
475
|
+
|
|
476
|
+
|
|
142
477
|
def tool_catalog_search(args: dict[str, Any]) -> dict[str, Any]:
|
|
143
|
-
item_type =
|
|
144
|
-
if item_type not in {None, "agent", "capability", "provider"}:
|
|
145
|
-
raise McpToolError("type must be agent, capability or provider")
|
|
478
|
+
item_type = optional_catalog_type(args)
|
|
146
479
|
return catalog_search(required_string(args, "query"), ROOT, item_type=item_type)
|
|
147
480
|
|
|
148
481
|
|
|
482
|
+
def tool_catalog_show(args: dict[str, Any]) -> dict[str, Any]:
|
|
483
|
+
item_type = optional_catalog_type(args)
|
|
484
|
+
return catalog_show(required_string(args, "id"), ROOT, item_type=item_type)
|
|
485
|
+
|
|
486
|
+
|
|
149
487
|
def tool_route_explain(args: dict[str, Any]) -> dict[str, Any]:
|
|
150
488
|
return explain_route(required_string(args, "prompt"), ROOT)
|
|
151
489
|
|
|
@@ -154,6 +492,10 @@ def tool_agent_prompt_dry_run(args: dict[str, Any]) -> dict[str, Any]:
|
|
|
154
492
|
return build_execution_plan(ROOT, required_string(args, "prompt"), dry_run=True)
|
|
155
493
|
|
|
156
494
|
|
|
495
|
+
def tool_agentic_plan(args: dict[str, Any]) -> dict[str, Any]:
|
|
496
|
+
return agentic_plan(ROOT, [required_string(args, "prompt")])
|
|
497
|
+
|
|
498
|
+
|
|
157
499
|
def tool_eval_list(_args: dict[str, Any]) -> dict[str, Any]:
|
|
158
500
|
return eval_list()
|
|
159
501
|
|
|
@@ -166,6 +508,267 @@ def tool_secrets_doctor(_args: dict[str, Any]) -> dict[str, Any]:
|
|
|
166
508
|
return secrets_doctor()
|
|
167
509
|
|
|
168
510
|
|
|
511
|
+
def tool_workflow_list(_args: dict[str, Any]) -> dict[str, Any]:
|
|
512
|
+
return workflow_list(ROOT)
|
|
513
|
+
|
|
514
|
+
|
|
515
|
+
def tool_workflow_show(args: dict[str, Any]) -> dict[str, Any]:
|
|
516
|
+
return workflow_show(required_string(args, "workflow_id"), ROOT)
|
|
517
|
+
|
|
518
|
+
|
|
519
|
+
def tool_workflow_run_dry_run(args: dict[str, Any]) -> dict[str, Any]:
|
|
520
|
+
return workflow_run(required_string(args, "workflow_id"), dry_run=True, root=ROOT)
|
|
521
|
+
|
|
522
|
+
|
|
523
|
+
def tool_local_llm_list(_args: dict[str, Any]) -> dict[str, Any]:
|
|
524
|
+
return local_llm_list()
|
|
525
|
+
|
|
526
|
+
|
|
527
|
+
def tool_local_llm_doctor(_args: dict[str, Any]) -> dict[str, Any]:
|
|
528
|
+
return local_llm_doctor()
|
|
529
|
+
|
|
530
|
+
|
|
531
|
+
def tool_local_llm_models(_args: dict[str, Any]) -> dict[str, Any]:
|
|
532
|
+
return local_llm_models()
|
|
533
|
+
|
|
534
|
+
|
|
535
|
+
def tool_local_artifacts_list(_args: dict[str, Any]) -> dict[str, Any]:
|
|
536
|
+
return {
|
|
537
|
+
"kind": "local-artifacts",
|
|
538
|
+
"status": "ok",
|
|
539
|
+
"skills": skill_list(),
|
|
540
|
+
"scripts": script_list(),
|
|
541
|
+
"agents": local_agent_list(),
|
|
542
|
+
"automations": local_automation_list(),
|
|
543
|
+
}
|
|
544
|
+
|
|
545
|
+
|
|
546
|
+
def tool_local_skill_create(args: dict[str, Any]) -> dict[str, Any]:
|
|
547
|
+
return skill_create(
|
|
548
|
+
optional_string(args, "id"),
|
|
549
|
+
description=optional_string(args, "description"),
|
|
550
|
+
force=optional_bool(args, "force", default=False),
|
|
551
|
+
)
|
|
552
|
+
|
|
553
|
+
|
|
554
|
+
def tool_local_skill_list(_args: dict[str, Any]) -> dict[str, Any]:
|
|
555
|
+
return skill_list()
|
|
556
|
+
|
|
557
|
+
|
|
558
|
+
def tool_local_skill_show(args: dict[str, Any]) -> dict[str, Any]:
|
|
559
|
+
return skill_show(required_string(args, "id"))
|
|
560
|
+
|
|
561
|
+
|
|
562
|
+
def tool_local_script_create(args: dict[str, Any]) -> dict[str, Any]:
|
|
563
|
+
return script_create(
|
|
564
|
+
optional_string(args, "id"),
|
|
565
|
+
command=optional_string(args, "command"),
|
|
566
|
+
force=optional_bool(args, "force", default=False),
|
|
567
|
+
)
|
|
568
|
+
|
|
569
|
+
|
|
570
|
+
def tool_local_script_list(_args: dict[str, Any]) -> dict[str, Any]:
|
|
571
|
+
return script_list()
|
|
572
|
+
|
|
573
|
+
|
|
574
|
+
def tool_local_script_run_dry_run(args: dict[str, Any]) -> dict[str, Any]:
|
|
575
|
+
return script_run(required_string(args, "id"), dry_run=True)
|
|
576
|
+
|
|
577
|
+
|
|
578
|
+
def tool_local_agent_create(args: dict[str, Any]) -> dict[str, Any]:
|
|
579
|
+
return local_agent_create(
|
|
580
|
+
optional_string(args, "id"),
|
|
581
|
+
description=optional_string(args, "description"),
|
|
582
|
+
force=optional_bool(args, "force", default=False),
|
|
583
|
+
)
|
|
584
|
+
|
|
585
|
+
|
|
586
|
+
def tool_local_agent_list(_args: dict[str, Any]) -> dict[str, Any]:
|
|
587
|
+
return local_agent_list()
|
|
588
|
+
|
|
589
|
+
|
|
590
|
+
def tool_local_agent_show(args: dict[str, Any]) -> dict[str, Any]:
|
|
591
|
+
return local_agent_show(required_string(args, "id"))
|
|
592
|
+
|
|
593
|
+
|
|
594
|
+
def tool_local_agent_validate(args: dict[str, Any]) -> dict[str, Any]:
|
|
595
|
+
return local_agent_validate(required_string(args, "id"))
|
|
596
|
+
|
|
597
|
+
|
|
598
|
+
def tool_local_automation_create(args: dict[str, Any]) -> dict[str, Any]:
|
|
599
|
+
return local_automation_create(
|
|
600
|
+
optional_string(args, "id"),
|
|
601
|
+
title=optional_string(args, "title"),
|
|
602
|
+
prompt=optional_string(args, "prompt"),
|
|
603
|
+
command=optional_string(args, "command"),
|
|
604
|
+
every=optional_string(args, "every"),
|
|
605
|
+
cron=optional_string(args, "cron"),
|
|
606
|
+
force=optional_bool(args, "force", default=False),
|
|
607
|
+
)
|
|
608
|
+
|
|
609
|
+
|
|
610
|
+
def tool_local_automation_list(_args: dict[str, Any]) -> dict[str, Any]:
|
|
611
|
+
return local_automation_list()
|
|
612
|
+
|
|
613
|
+
|
|
614
|
+
def tool_local_automation_show(args: dict[str, Any]) -> dict[str, Any]:
|
|
615
|
+
return local_automation_show(required_string(args, "id"))
|
|
616
|
+
|
|
617
|
+
|
|
618
|
+
def tool_local_automation_enable(args: dict[str, Any]) -> dict[str, Any]:
|
|
619
|
+
return local_automation_enable(required_string(args, "id"), True)
|
|
620
|
+
|
|
621
|
+
|
|
622
|
+
def tool_local_automation_disable(args: dict[str, Any]) -> dict[str, Any]:
|
|
623
|
+
return local_automation_enable(required_string(args, "id"), False)
|
|
624
|
+
|
|
625
|
+
|
|
626
|
+
def tool_local_automation_validate(args: dict[str, Any]) -> dict[str, Any]:
|
|
627
|
+
return local_automation_validate(required_string(args, "id"))
|
|
628
|
+
|
|
629
|
+
|
|
630
|
+
def tool_team_status(args: dict[str, Any]) -> dict[str, Any]:
|
|
631
|
+
return team_status(mcp_project(args))
|
|
632
|
+
|
|
633
|
+
|
|
634
|
+
def tool_team_doctor(args: dict[str, Any]) -> dict[str, Any]:
|
|
635
|
+
return team_doctor(mcp_project(args))
|
|
636
|
+
|
|
637
|
+
|
|
638
|
+
def tool_team_init(args: dict[str, Any]) -> dict[str, Any]:
|
|
639
|
+
return team_init(mcp_project(args), force=optional_bool(args, "force", default=False))
|
|
640
|
+
|
|
641
|
+
|
|
642
|
+
def tool_team_onboard(args: dict[str, Any]) -> dict[str, Any]:
|
|
643
|
+
return team_onboard(mcp_project(args))
|
|
644
|
+
|
|
645
|
+
|
|
646
|
+
def tool_team_profile_list(args: dict[str, Any]) -> dict[str, Any]:
|
|
647
|
+
return team_profile_list(mcp_project(args))
|
|
648
|
+
|
|
649
|
+
|
|
650
|
+
def tool_team_profile_show(args: dict[str, Any]) -> dict[str, Any]:
|
|
651
|
+
return team_profile_show(optional_string(args, "profile_id"), mcp_project(args))
|
|
652
|
+
|
|
653
|
+
|
|
654
|
+
def tool_team_profile_export(args: dict[str, Any]) -> dict[str, Any]:
|
|
655
|
+
return team_profile_export(optional_string(args, "profile_id"), optional_string(args, "path"), mcp_project(args))
|
|
656
|
+
|
|
657
|
+
|
|
658
|
+
def tool_team_profile_import(args: dict[str, Any]) -> dict[str, Any]:
|
|
659
|
+
return team_profile_import(required_string(args, "path"), mcp_project(args))
|
|
660
|
+
|
|
661
|
+
|
|
662
|
+
def tool_knowledge_doctor(args: dict[str, Any]) -> dict[str, Any]:
|
|
663
|
+
return knowledge_doctor(mcp_project(args))
|
|
664
|
+
|
|
665
|
+
|
|
666
|
+
def tool_knowledge_init(args: dict[str, Any]) -> dict[str, Any]:
|
|
667
|
+
return knowledge_init(mcp_project(args), force=optional_bool(args, "force", default=False))
|
|
668
|
+
|
|
669
|
+
|
|
670
|
+
def tool_knowledge_index(args: dict[str, Any]) -> dict[str, Any]:
|
|
671
|
+
return knowledge_index(mcp_project(args))
|
|
672
|
+
|
|
673
|
+
|
|
674
|
+
def tool_knowledge_search(args: dict[str, Any]) -> dict[str, Any]:
|
|
675
|
+
return knowledge_search(required_string(args, "query"), mcp_project(args))
|
|
676
|
+
|
|
677
|
+
|
|
678
|
+
def tool_knowledge_curate(args: dict[str, Any]) -> dict[str, Any]:
|
|
679
|
+
return knowledge_curate(mcp_project(args))
|
|
680
|
+
|
|
681
|
+
|
|
682
|
+
def tool_knowledge_sync(args: dict[str, Any]) -> dict[str, Any]:
|
|
683
|
+
return knowledge_sync(mcp_project(args))
|
|
684
|
+
|
|
685
|
+
|
|
686
|
+
def tool_knowledge_snapshot_create(args: dict[str, Any]) -> dict[str, Any]:
|
|
687
|
+
payload = knowledge_snapshot_create(
|
|
688
|
+
title=required_string(args, "title"),
|
|
689
|
+
content=optional_string(args, "content"),
|
|
690
|
+
from_file=optional_string(args, "from_file"),
|
|
691
|
+
entry_type=optional_string(args, "type"),
|
|
692
|
+
project=mcp_project(args),
|
|
693
|
+
)
|
|
694
|
+
attach_mcp_audit(payload, tool="agent_devkit_knowledge_snapshot_create", args=args)
|
|
695
|
+
return payload
|
|
696
|
+
|
|
697
|
+
|
|
698
|
+
def tool_knowledge_snapshot_list(args: dict[str, Any]) -> dict[str, Any]:
|
|
699
|
+
return knowledge_snapshot_list(mcp_project(args))
|
|
700
|
+
|
|
701
|
+
|
|
702
|
+
def tool_knowledge_snapshot_show(args: dict[str, Any]) -> dict[str, Any]:
|
|
703
|
+
return knowledge_snapshot_show(required_string(args, "snapshot_id"), mcp_project(args))
|
|
704
|
+
|
|
705
|
+
|
|
706
|
+
def tool_knowledge_snapshot_score(args: dict[str, Any]) -> dict[str, Any]:
|
|
707
|
+
return knowledge_snapshot_score(required_string(args, "snapshot_id"), mcp_project(args))
|
|
708
|
+
|
|
709
|
+
|
|
710
|
+
def tool_knowledge_snapshot_submit(args: dict[str, Any]) -> dict[str, Any]:
|
|
711
|
+
payload = knowledge_snapshot_submit(required_string(args, "snapshot_id"), mcp_project(args))
|
|
712
|
+
attach_mcp_audit(payload, tool="agent_devkit_knowledge_snapshot_submit", args=args)
|
|
713
|
+
return payload
|
|
714
|
+
|
|
715
|
+
|
|
716
|
+
def tool_knowledge_review_list(args: dict[str, Any]) -> dict[str, Any]:
|
|
717
|
+
return knowledge_review_list(mcp_project(args))
|
|
718
|
+
|
|
719
|
+
|
|
720
|
+
def tool_knowledge_review(args: dict[str, Any]) -> dict[str, Any]:
|
|
721
|
+
payload = knowledge_review(required_string(args, "snapshot_id"), mcp_project(args))
|
|
722
|
+
attach_mcp_audit(payload, tool="agent_devkit_knowledge_review", args=args)
|
|
723
|
+
return payload
|
|
724
|
+
|
|
725
|
+
|
|
726
|
+
def tool_knowledge_publish(args: dict[str, Any]) -> dict[str, Any]:
|
|
727
|
+
payload = knowledge_publish(
|
|
728
|
+
required_string(args, "snapshot_id"),
|
|
729
|
+
mcp_project(args),
|
|
730
|
+
yes=optional_bool(args, "yes", default=False),
|
|
731
|
+
owner_agent=optional_string(args, "owner_agent"),
|
|
732
|
+
)
|
|
733
|
+
attach_mcp_audit(payload, tool="agent_devkit_knowledge_publish", args=args)
|
|
734
|
+
return payload
|
|
735
|
+
|
|
736
|
+
|
|
737
|
+
def tool_knowledge_base_create(args: dict[str, Any]) -> dict[str, Any]:
|
|
738
|
+
payload = knowledge_base_create(
|
|
739
|
+
mcp_project(args),
|
|
740
|
+
provider=optional_string(args, "provider"),
|
|
741
|
+
force=optional_bool(args, "force", default=False),
|
|
742
|
+
)
|
|
743
|
+
attach_mcp_audit(payload, tool="agent_devkit_knowledge_base_create", args=args)
|
|
744
|
+
return payload
|
|
745
|
+
|
|
746
|
+
|
|
747
|
+
def tool_knowledge_base_join(args: dict[str, Any]) -> dict[str, Any]:
|
|
748
|
+
payload = knowledge_base_join(
|
|
749
|
+
required_string(args, "kb_id"),
|
|
750
|
+
mcp_project(args),
|
|
751
|
+
provider=optional_string(args, "provider"),
|
|
752
|
+
force=optional_bool(args, "force", default=False),
|
|
753
|
+
)
|
|
754
|
+
attach_mcp_audit(payload, tool="agent_devkit_knowledge_base_join", args=args)
|
|
755
|
+
return payload
|
|
756
|
+
|
|
757
|
+
|
|
758
|
+
def tool_knowledge_base_status(args: dict[str, Any]) -> dict[str, Any]:
|
|
759
|
+
return knowledge_base_status(mcp_project(args))
|
|
760
|
+
|
|
761
|
+
|
|
762
|
+
def tool_knowledge_base_tokens(args: dict[str, Any]) -> dict[str, Any]:
|
|
763
|
+
return knowledge_base_tokens(mcp_project(args))
|
|
764
|
+
|
|
765
|
+
|
|
766
|
+
def tool_knowledge_base_rotate_token(args: dict[str, Any]) -> dict[str, Any]:
|
|
767
|
+
payload = knowledge_base_rotate_token(required_string(args, "scope"), mcp_project(args))
|
|
768
|
+
attach_mcp_audit(payload, tool="agent_devkit_knowledge_base_rotate_token", args=args)
|
|
769
|
+
return payload
|
|
770
|
+
|
|
771
|
+
|
|
169
772
|
def tool_roadmap(_args: dict[str, Any]) -> dict[str, Any]:
|
|
170
773
|
return roadmap_payload(ROOT)
|
|
171
774
|
|
|
@@ -191,7 +794,7 @@ def tool_wizard_answer(args: dict[str, Any]) -> dict[str, Any]:
|
|
|
191
794
|
def attach_mcp_audit(payload: dict[str, Any], *, tool: str, args: dict[str, Any]) -> None:
|
|
192
795
|
audit_result = try_record_audit(
|
|
193
796
|
command=tool,
|
|
194
|
-
args={"command": "mcp", "tool": tool, "arguments": redact_value(args)},
|
|
797
|
+
args={"command": "mcp", "tool": tool, "arguments": redact_value(args, redact_access_keys=True)},
|
|
195
798
|
result=payload,
|
|
196
799
|
error=None,
|
|
197
800
|
origin="mcp",
|
|
@@ -239,6 +842,11 @@ def optional_string(args: dict[str, Any], key: str) -> str | None:
|
|
|
239
842
|
return value.strip() or None
|
|
240
843
|
|
|
241
844
|
|
|
845
|
+
def mcp_project(args: dict[str, Any]) -> Path | None:
|
|
846
|
+
project = optional_string(args, "project")
|
|
847
|
+
return Path(project).expanduser().resolve() if project else None
|
|
848
|
+
|
|
849
|
+
|
|
242
850
|
def string_list(value: Any) -> list[str]:
|
|
243
851
|
if value is None:
|
|
244
852
|
return []
|
|
@@ -260,3 +868,33 @@ def optional_bool(args: dict[str, Any], key: str, *, default: bool) -> bool:
|
|
|
260
868
|
if not isinstance(value, bool):
|
|
261
869
|
raise McpToolError(f"{key} must be a boolean")
|
|
262
870
|
return value
|
|
871
|
+
|
|
872
|
+
|
|
873
|
+
def optional_catalog_type(args: dict[str, Any]) -> str | None:
|
|
874
|
+
item_type = optional_string(args, "type")
|
|
875
|
+
allowed = {
|
|
876
|
+
None,
|
|
877
|
+
"agent",
|
|
878
|
+
"capability",
|
|
879
|
+
"provider",
|
|
880
|
+
"workflow",
|
|
881
|
+
"tool",
|
|
882
|
+
"skill",
|
|
883
|
+
"plugin",
|
|
884
|
+
"extension",
|
|
885
|
+
"script",
|
|
886
|
+
"local-agent",
|
|
887
|
+
"automation",
|
|
888
|
+
}
|
|
889
|
+
if item_type not in allowed:
|
|
890
|
+
raise McpToolError("type must be a known Agent DevKit catalog type")
|
|
891
|
+
return item_type
|
|
892
|
+
|
|
893
|
+
|
|
894
|
+
def catalog_filters(args: dict[str, Any]) -> dict[str, Any]:
|
|
895
|
+
return {
|
|
896
|
+
"provider": optional_string(args, "provider"),
|
|
897
|
+
"status": optional_string(args, "status"),
|
|
898
|
+
"write_policy": optional_string(args, "write_policy"),
|
|
899
|
+
"readiness": optional_string(args, "readiness"),
|
|
900
|
+
}
|