← Back to list

thread-list
by ThinkEx-OSS
Rethinking the User Interface of AI
⭐ 22🍴 4📅 Jan 24, 2026
SKILL.md
name: thread-list description: Guide for multi-thread management in assistant-ui. Use when implementing thread lists, switching threads, or managing conversation history. version: 0.0.1 license: MIT
assistant-ui Thread List
Always consult assistant-ui.com/llms.txt for latest API.
Manage multiple chat threads with built-in or custom UI.
References
- ./references/management.md -- Thread CRUD operations
- ./references/custom-ui.md -- Custom thread list UI
Quick Start
Thread list is available with useChatRuntime + cloud:
import { AssistantCloud } from "assistant-cloud";
import { useChatRuntime, AssistantChatTransport } from "@assistant-ui/react-ai-sdk";
import { AssistantRuntimeProvider, Thread, ThreadList } from "@assistant-ui/react";
const cloud = new AssistantCloud({
baseUrl: process.env.NEXT_PUBLIC_ASSISTANT_BASE_URL,
authToken: async () => getAuthToken(),
});
function Chat() {
const runtime = useChatRuntime({
transport: new AssistantChatTransport({ api: "/api/chat" }),
cloud,
});
return (
<AssistantRuntimeProvider runtime={runtime}>
<div className="flex h-screen">
<ThreadList className="w-64 border-r" />
<Thread className="flex-1" />
</div>
</AssistantRuntimeProvider>
);
}
Thread Operations
import { useAssistantApi, useAssistantState } from "@assistant-ui/react";
const api = useAssistantApi();
const { threads, mainThreadId } = useAssistantState(s => s.threadList);
// Switch to thread
api.threads().switchToThread(threadId);
// Create new thread
api.threads().switchToNewThread();
// Thread item operations
const item = api.threads().item({ id: threadId });
await item.rename("New Title");
await item.archive();
await item.delete();
Custom Thread List
import { ThreadListPrimitive, ThreadListItemPrimitive } from "@assistant-ui/react";
function CustomThreadList() {
return (
<ThreadListPrimitive.Root className="w-64">
<ThreadListPrimitive.New className="w-full p-2 bg-blue-500 text-white">
+ New Chat
</ThreadListPrimitive.New>
<ThreadListPrimitive.Items>
<ThreadListItemPrimitive.Root className="flex p-2 hover:bg-gray-100">
<ThreadListItemPrimitive.Trigger className="flex-1">
<ThreadListItemPrimitive.Title />
</ThreadListItemPrimitive.Trigger>
<ThreadListItemPrimitive.Archive>Archive</ThreadListItemPrimitive.Archive>
<ThreadListItemPrimitive.Delete>Delete</ThreadListItemPrimitive.Delete>
</ThreadListItemPrimitive.Root>
</ThreadListPrimitive.Items>
</ThreadListPrimitive.Root>
);
}
Without Cloud (Local)
import { useRemoteThreadListRuntime, InMemoryThreadListAdapter } from "@assistant-ui/react";
const runtime = useRemoteThreadListRuntime({
adapter: new InMemoryThreadListAdapter(),
runtimeHook: () => useLocalRuntime({ model: myModel }),
});
Common Gotchas
ThreadList not showing
- Pass
cloudto runtime - Check authentication
Threads not persisting
- Verify cloud connection
- Check network requests
Score
Total Score
65/100
Based on repository quality metrics
✓SKILL.md
SKILL.mdファイルが含まれている
+20
✓LICENSE
ライセンスが設定されている
+10
○説明文
100文字以上の説明がある
0/10
○人気
GitHub Stars 100以上
0/15
✓最近の活動
1ヶ月以内に更新
+10
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
✓タグ
1つ以上のタグが設定されている
+5
Reviews
💬
Reviews coming soon


