The files an assistant reads, each saying where it is.
Every shadcn style · one file
v2.0 · Updated Oct 13pnpm dlx shadcn@latest add @notchset-pro/knowledge-filespnpm dlx shadcn@latest add @notchset-pro/knowledge-filesNeeds your registry key. Every components.json style gets the same files.
Works with React 18.3 or 19 on Tailwind CSS v4, in any shadcn project. What's tested
The CLI adds the styles to the CSS file named in components.json (tailwind.css). Check that it points at your global stylesheet, that the project uses Tailwind CSS v4, and that the file is imported in your root layout. Installed by hand: paste styles.css into that file.
Import it and pass your content. The props that matter most are listed next.
"use client";
import * as React from "react";
import { KnowledgeFiles, type KnowledgeFile } from "@/components/ui/notchset/blocks/knowledge-files";
const START: KnowledgeFile[] = [
{ id: "f1", name: "Launch brief v3.pdf", size: 412_000, state: "ready", pages: 6 },
{ id: "f2", name: "Interview notes, October.docx", size: 1_840_000, state: "reading", pages: 40, read: 12 },
{ id: "f3", name: "Scanned contract.pdf", size: 8_200_000, state: "failed", reason: "Scanned pages with no text: export it with text, or paste the text in" },
];
export default function KnowledgeFilesDemo() {
const [files, setFiles] = React.useState(START);
/* the sample uploads in steps and reads a page every half second; the template's adapter reports real progress */
React.useEffect(() => {
const t = setInterval(() => {
setFiles((fs) =>
fs.map((f): KnowledgeFile => {
if (f.state === "uploading") return (f.progress ?? 0) >= 100 ? { ...f, state: "reading", pages: 8, read: 0 } : { ...f, progress: (f.progress ?? 0) + 25 };
if (f.state === "reading" && f.pages) return (f.read ?? 0) + 1 >= f.pages ? { ...f, state: "ready", read: f.pages } : { ...f, read: (f.read ?? 0) + 1 };
return f;
}),
);
}, 500);
return () => clearInterval(t);
}, []);
return (
<div className="max-w-[520px]">
<KnowledgeFiles
files={files}
cap={20}
onAdd={(added) => setFiles((fs) => [...fs, ...added.map((f, i): KnowledgeFile => ({ id: `n${Date.now()}${i}`, name: f.name, size: f.size, state: "uploading", progress: 0 }))])}
onRemove={(id) => setFiles((fs) => fs.filter((f) => f.id !== id))}
onRetry={(id) => setFiles((fs) => fs.map((f): KnowledgeFile => (f.id === id ? { id: f.id, name: f.name, size: f.size, state: "uploading", progress: 0 } : f)))}
/>
</div>
);
}components/ui/notchset/blocks/knowledge-files.tsx
This component is included with Pro.
Try the live preview above. Get Pro to install the source.
files–
KnowledgeFile[]Required.
onAdd–
(files: File[]) => voidRequired.
onRemove–
(id: string) => voidRequired.
onRetry–
(id: string) => voidcap–
numberhow many files it can use
accept".pdf,.docx,.md,.txt,.csv"
stringwhat kinds it reads, for the file chooser and the empty line
emptyLine"No files yet. Add what it should read: PDFs, documents, text and spreadsheets."
stringthe empty line: what to add and the limits
Give your coding assistant the Markdown guide instead of screenshots.
https://notchset.dev/api/mcp (setup)v2.0.0 · 2026-10-13
Released with the Notchset system.
The same file, at work in a finished app. Open it live and find it on its pages.
Pro is in early access.