UP-15: Agent capabilities declaration with A2A-compatible skills#21
Merged
Killea merged 2 commits intoKillea:mainfrom Mar 1, 2026
Merged
UP-15: Agent capabilities declaration with A2A-compatible skills#21Killea merged 2 commits intoKillea:mainfrom
Killea merged 2 commits intoKillea:mainfrom
Conversation
Expose capabilities (string tags) and add structured skills[] metadata
to agent registration, enabling A2A AgentCard-compatible routing.
Backend (Python/FastAPI):
- AgentInfo: add skills field (Optional[str], JSON, backward-compatible)
- DB migration: ALTER TABLE agents ADD COLUMN skills TEXT
- agent_register: accept skills parameter, store as JSON
- agent_get: new function returning a single agent by ID
- agent_update: new token-authenticated partial update function
- _row_to_agent: populate skills from DB row
MCP Tools:
- agent_register: add skills to input schema (A2A-aligned object structure)
- agent_list: now returns capabilities and skills in response
- agent_update (new tool): token-gated post-registration metadata update
- chat://agents/active resource: include skills array
REST API:
- AgentRegister: add skills field
- AgentUpdate (new Pydantic model)
- POST /api/agents/register: pass skills, return capabilities + skills
- GET /api/agents: include capabilities + skills per agent
- GET /api/agents/{id} (new): single agent detail with 404
- PUT /api/agents/{id} (new): partial update, token-authenticated
Web UI:
- acb-agent-status-item.js: show skills-badge pill when skills > 0
- main.css: .skills-badge styles (dark + light theme)
Tests:
- tests/test_agent_capabilities.py: 19 pytest (11 unit + 8 HTTP integration)
- frontend/src/__tests__/agent-capabilities.test.js: 6 Vitest DOM tests
All tests pass: 73/73 pytest + 30/30 Vitest
bertheto
added a commit
to bertheto/AgentChatBus
that referenced
this pull request
Mar 1, 2026
The feat/structured-metadata branch inherited crud.py changes that reference agents.skills (from UP-15 work), but the corresponding DB migration was missing, causing sqlite3.OperationalError in CI. UP-15 (PR Killea#21) is still pending review; this migration makes UP-17 self-contained regardless of merge order.
bertheto
added a commit
to bertheto/AgentChatBus
that referenced
this pull request
Mar 1, 2026
crud.py (inherited from UP-15 work) passes skills=skills_json to AgentInfo() but the field was missing from the dataclass, causing TypeError in CI. This makes UP-17 self-contained regardless of UP-15 (PR Killea#21) merge order.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
skills[]metadata to agent registration (A2A AgentCard-compatible), alongside existingcapabilitiesstring tagsagent_updateMCP tool andPUT /api/agents/{id}REST endpoint for post-registration metadata updates (token-authenticated)GET /api/agents/{id}REST endpoint for single-agent detailcapabilitiesandskillsinagent_listMCP tool,GET /api/agents, andchat://agents/activeresource.skills-badgepill in agent status item when skills are declaredSkill Schema (A2A AgentCard compatible)
Each skill object requires
idandname;description,tags, andexamplesare optional:{ "id": "code-review", "name": "Code Review", "description": "Reviews code for style, security, and best practices", "tags": ["review", "security"], "examples": ["Review this PR for security issues"] }Changes
Backend
src/db/models.py:AgentInfo.skillsfield (optional, after existing optional fields — backward-compatible)src/db/database.py: safe migrationALTER TABLE agents ADD COLUMN skills TEXTsrc/db/crud.py:agent_register+skills, newagent_get, newagent_updatesrc/mcp_server.py:agent_registerschema extended,agent_updatetool added,agent_listdescription updated,chat://agents/activeresource includes skillssrc/tools/dispatch.py:handle_agent_register,handle_agent_list, newhandle_agent_updatesrc/main.py:AgentRegister+ skills, newAgentUpdatemodel,GET /api/agents+ skills, newGET /api/agents/{id}, newPUT /api/agents/{id}Web UI
acb-agent-status-item.js:.skills-badgepill (count badge, supports array or JSON string)main.css:.skills-badgestyles (dark + light theme)Tests
tests/test_agent_capabilities.py: 19 pytest (11 unit in-memory + 8 HTTP integration)frontend/src/__tests__/agent-capabilities.test.js: 6 Vitest DOM testsAll tests pass: 73/73 pytest + 30/30 Vitest
Test plan
agent_registerwithskills=[]→ response includes parsed skills arrayagent_list→ each agent includescapabilitiesandskillsagent_updatewith valid token → skills updated, responseok: trueagent_updatewith wrong token → error returnedGET /api/agents/{id}→ full agent detail with skillsGET /api/agents/{id}for unknown ID → 404PUT /api/agents/{id}→ updates skills, returns updated agentN skillsvisible in agent status panel