@hashbrownai/core

中文文档
0.8.3发布于 2026/10/27MITTypeScriptESM + CJS构建来源已验证近 30 天下载 2.6万

Runtime helpers for Hashbrown AI

原始使用文档
文档目录5 节
  1. Features
  2. Getting Started with Angular
  3. Getting Started with React
  4. Connect a Model
  5. Need a Complete Chat UI?

Hashbrown

Hashbrown Logo
AI chat and agents for your React or Angular app.
Hashbrown is a headless TypeScript framework. The model renders your
components and calls your tools, in the browser, with any provider.

hashbrown.dev

@hashbrownai/core holds the framework-agnostic primitives that Hashbrown's React and Angular packages build on: the Skillet schema language, the streaming JSON parser, and the chat state that talks to your server. Install it next to a framework package and a model adapter.

Features

  • Generative UI. The model composes your components. Bundle them into UI kits.
  • Client-side tools. The model calls functions in your app. Connect MCP servers too.
  • Structured output. Skillet schemas turn model output into typed JSON.
  • Streaming. Strings, arrays, and objects parse as they arrive. Magic Text streams Markdown.
  • Any model. OpenAI, Anthropic, Gemini, Bedrock, Azure, Ollama, or a model in the browser.
  • Code execution. Run model-written JavaScript in a sandbox.

Getting Started with Angular

npm install @hashbrownai/{core,angular,openai}

Point Hashbrown at your server:

export const appConfig: ApplicationConfig = {
  providers: [provideHashbrown({ baseUrl: '/run' })],
};

Then follow the Angular quick start.

Getting Started with React

npm install @hashbrownai/{core,react,openai}

Point Hashbrown at your server:

<HashbrownProvider url="/run">{children}</HashbrownProvider>

Then follow the React quick start.

Connect a Model

Your server keeps the API key and streams from a Hashbrown adapter:

Need a Complete Chat UI?

Hashbrown is headless. threadplane is the full agent UI for React and Angular, built on Hashbrown: threads, approvals, and tool progress. Free and MIT, with enterprise support from the team behind Hashbrown.

Stuck? Ask Brian at https://hashbrown.dev/unstuck.

版本与发布记录

@hashbrownai/core 共发布 38 个版本,首次发布于 2025/05/01;过去 12 个月发布了 17 个版本。最新版本附带 npm provenance 构建来源证明,可追溯到公开的 CI 构建记录。

版本发布日期距今
0.8.3latest2026/10/2721 天前
0.8.22026/10/2622 天前
0.8.12026/10/2523 天前
0.8.02026/10/2325 天前
0.7.02026/10/091 个月前
0.6.12026/09/241 个月前

其他发布通道:rc → 0.4.0-rc.1,alpha → 0.4.1-alpha.2,beta → 0.5.0-beta.4。

关于 @hashbrownai/core 的常见问题

@hashbrownai/core 是什么?

Runtime helpers for Hashbrown AI

如何安装 @hashbrownai/core?

在项目目录运行 npm install @hashbrownai/core,或使用 pnpm add / yarn add / bun add。

@hashbrownai/core 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@hashbrownai/core 支持 ESM 还是 CommonJS?

同时提供 ES Module 与 CommonJS 入口,import 和 require() 都可以使用,打包工具会自动选择合适的版本。

@hashbrownai/core 需要什么版本的 Node.js?

package.json 的 engines 字段要求 Node.js >=20。版本不符时 npm 默认只给出警告,开启 engine-strict 后会拒绝安装。

@hashbrownai/core 可以商用吗?

@hashbrownai/core 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@hashbrownai/core 的下载量有多少?

根据 npm 官方下载统计,@hashbrownai/core 在 2026/10/18 – 2026/11/16 这 30 天内被下载 26,028 次,日均约 868 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@hashbrownai/core 还在维护吗?

最新版本 0.8.3 发布于 2026/10/27(21 天前);至今共发布 38 个版本,其中过去 12 个月发布了 17 个;首次发布于 2025/05/01。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。