Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/tomevault-io/skills-registry --skill agent-elements명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
| Use when this capability is needed.
> Use when this capability is needed.
Review architecture and API design for the vfs-s3 project. Use when the user mentions @architect, asks to review an issue's design, discuss module boundaries, API shape, or architectural decisions for vfs-s3. Also trigger when the user wants to create an ADR (Architecture Decision Record) or evaluate a technical approach for the project. Intended for dispatch from Codex automation or Claude routines; GitHub trigger phrase: @vfs-s3-bot please prepare design doc Use when this capability is needed.
SKILL.md 표시 중
SOC 직업 분류 기준
| name | agent-elements |
| description | | Use when this capability is needed. |
Project-aware context for building chat and agent UIs with Agent Elements —
an open-source shadcn registry at https://agent-elements.21st.dev.
When this skill loads, you know:
npx shadcn@latest add https://agent-elements.21st.dev/r/<component>.json.
Files land under components/agent-elements/ (the library's internal
components/ prefix is stripped — see Paths below).UIMessage[] from ai, status is ChatStatus. useChat() plugs in
directly.Consider this project "Agent Elements-ready" if any of these are true:
components/agent-elements/ exists on diskcomponents.json includes an alias or registry reference to Agent Elementspackage.json dependencies include ai + @tabler/icons-react and the user
mentions Agent ElementsIf the folder does not exist yet, install on demand with:
npx shadcn@latest add https://agent-elements.21st.dev/r/agent-chat.json
agent-chat transitively pulls every other component it needs via
registryDependencies (MessageList, InputBar, tool renderers, shared utils).
After shadcn add, files sit under @/components/agent-elements/ with this
shape:
components/agent-elements/
agent-chat.tsx
message-list.tsx
input-bar.tsx
markdown.tsx
user-message.tsx
error-message.tsx
text-shimmer.tsx
spiral-loader.tsx
input/
attachment-button.tsx
send-button.tsx
file-attachment.tsx
suggestions.tsx
model-picker.tsx
mode-selector.tsx
tools/
bash-tool.tsx
edit-tool.tsx
search-tool.tsx
todo-tool.tsx
plan-tool.tsx
tool-group.tsx
subagent-tool.tsx
mcp-tool.tsx
thinking-tool.tsx
generic-tool.tsx
question/
question-tool.tsx
hooks/use-tool-complete.ts
utils/cn.ts
types.ts
Import rule: always import from the exact file, never from a barrel.
// ✅
import { AgentChat } from "@/components/agent-elements/agent-chat";
import { BashTool } from "@/components/agent-elements/tools/bash-tool";
// ❌ — no barrel exists
import { AgentChat } from "@/components/agent-elements";
MessageList + InputBar,
handles tool invocations via toolRenderers, shows an empty state with
optional suggestions. Props: messages, status, onSend, onStop,
toolRenderers?, suggestions?, attachments?, classNames?, slots?.toolRenderers and showCopyToolbar.Markdown streams safely (external links get rel="noreferrer" by default).status, onSend({ content }), onStop,
value? + onChange? (controlled), attachedImages/attachedFiles with
their remove handlers, leftActions/rightActions slots, suggestions?,
questionBar?, infoBar?.leftActions. Both
accept a simple { id, name, version? } / { id, label, icon?, description? }
shape. Do not import CLAUDE_MODELS — it was removed; supply your own array.All tool cards accept a part prop of type
Extract<UIMessage["parts"][number], { type: \tool-` }>from the AI SDK. Register them viatoolRenderersonAgentChat/MessageList`:
<AgentChat
toolRenderers={{
Bash: BashTool,
Edit: EditTool,
Write: EditTool, // Write reuses EditTool
Search: SearchTool,
WebSearch: SearchTool,
TodoWrite: TodoTool,
PlanWrite: PlanTool,
Task: SubagentTool,
Thinking: ThinkingTool,
}}
/>
Cards available:
input.old_string/input.new_string or
output.structuredPatch, plus an approval footer via input.approval.results or use output.results.input.todos vs output.oldTodos.parseMcpToolType from
@/components/agent-elements/tools/tool-registry to get mcpInfo."use client";
import { AgentChat } from "@/components/agent-elements/agent-chat";
import { BashTool } from "@/components/agent-elements/tools/bash-tool";
import { EditTool } from "@/components/agent-elements/tools/edit-tool";
import { SearchTool } from "@/components/agent-elements/tools/search-tool";
import { useChat } from "@ai-sdk/react";
export default function Chat() {
const { messages, status, sendMessage, stop } = useChat();
return (
<AgentChat
messages={messages}
status={status}
onSend={({ content }) => sendMessage({ text: content })}
onStop={stop}
toolRenderers={{
Bash: BashTool,
Edit: EditTool,
Write: EditTool,
Search: SearchTool,
}}
/>
);
}
import { InputBar } from "@/components/agent-elements/input-bar";
import { ModeSelector } from "@/components/agent-elements/input/mode-selector";
import { ModelPicker } from "@/components/agent-elements/input/model-picker";
import { IconBulb, IconCursor } from "@tabler/icons-react";
const modes = [
{ id: "agent", label: "Agent", icon: IconCursor },
{ id: "plan", label: "Plan", icon: IconBulb },
];
const models = [
{ id: "sonnet", name: "Sonnet", version: "4.6" },
{ id: "opus", name: "Opus", version: "4.7" },
];
<InputBar
status="ready"
onSend={handleSend}
onStop={handleStop}
leftActions={
<>
< = = />
}
/>
toolRenderers values are React components that receive { part, chatStatus }.
Return whatever UI you want; reuse GenericTool as a fallback shell.
Agent Elements reads these Tailwind CSS vars (shadcn-style). Do not remove or rename them in the consumer theme:
--an-foreground, --an-background, --an-primary-color--background, --foreground, --border,
--muted, --muted-foreground, --accent, --primary, etc.Customising a component is just editing the installed file. Prefer that over wrapping — the code is yours now.
assistant-ui, ai-elements, copilotkit, or another kit —
don't mix.InputBar + your own
message rendering may be enough; skip AgentChat.npx shadcn@latest init if
components.json is missing, then
npx shadcn@latest add https://agent-elements.21st.dev/r/agent-chat.json.components/agent-elements/input/send-button.tsx directly. Tokens live on
--an-* CSS vars.toolRenderers; fall back to
GenericTool for unknown tools.messages and status straight through,
translate sendMessage/stop to onSend({ content })/onStop.https://agent-elements.21st.dev/r/index.jsonhttps://agent-elements.21st.dev/r/<id>.jsonhttps://agent-elements.21st.dev/llms-full.txtSource: 21st-dev/agent-elements — distributed by TomeVault.