npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

hexo-plugin-postchat

v2.0.0

Published

站点AI增强工具,实现文章摘要与知识库对话

Readme

简介

quickshot.webp

PostChat是一个专为中小开发者与站长开发的AI增强工具,可以在网站中插入聊天机器人和智能摘要生成的功能。本项目提供专为Hexo博客系统的插件安装包,你可以在Hexo博客中安装使用,避免了插入代码的繁琐。

功能

这个插件支持PostChat用户和文章摘要用户使用。文章摘要用户可以在插件设置中关闭“智能对话”功能即可。

  • 文章摘要生成功能
  • 文章知识库功能
  • 文章知识库对话功能
  • 文章AI搜索功能

更多功能可以参见:https://ai.tianli0.top/

本插件在Hexo中的表现

预览地址

PostChat在更多网站中的表现

张洪Heo

Tianli

安装方式

使用命令行工具或终端cd进入你的Hexo博客根目录。

cd /Users/这是一个例子/HexoDemo

然后在博客根目录下执行

npm install hexo-plugin-postchat --save

然后根据下面的插件配置进行配置即可。

插件配置

编辑根目录下的_config.yaml,在plugin中添加PostChat:

plugins:
  - hexo-plugin-postchat

然后在配置文件最后添加配置项目:

postchat:
  account:
    key: "70b649f150276f289d1025508f60c5f58a" # 使用PostChat的用户请前往 https://ai.tianli0.top/ 获取 KEY,只使用文章摘要的用户前往 https://summary.zhheo.com/ 获取 KEY 。示例的Key不支持文章摘要和自定义的知识库问答,但可以使用作者的知识库对话
  summary:
    enableSummary: true # 开启文章摘要需要在 https://summary.zhheo.com/ 绑定你的网站
    postSelector: "#postchat_postcontent" # 文章选择器,用于选择文章内容。如果没有正常显示摘要,你需要访问 https://postsummary.zhheo.com/theme/custom.html#%E8%8E%B7%E5%8F%96tianligpt-postselector 学习获取,也可以联系 [email protected] 发送你的网站地址后获取
    title: "文章摘要" # 摘要标题,用于显示在摘要顶部的自定义内容
    summaryStyle: "https://ai.tianli0.top/static/public/postChatUser_summary.min.css" # 摘要样式css地址,如果你需要自定义摘要的css样式,可以自行修改。
    postURL: "/^https?://[^/]+/[0-9]{4}/[0-9]{2}/[0-9]{2}/" # 在符合url条件的网页执行文章摘要功能,默认的配置为Hexo的默认文章路由,如果你自定义了文章的地址格式,那么需要修改。https://postchat.zhheo.com/summary.html#tianligpt-posturl
    blacklist: "" # 填写相关的json地址,帮助文档:https://postsummary.zhheo.com/parameters.html#tianligpt-blacklist
    wordLimit: "1000" # 危险操作!如果没有在文章摘要中开启url绑定,更改此变量损失已消耗过的key,因为你提交的内容发生了变化。(PostChat用户无影响,因为摘要数量是无限的)可以设置提交的字数限制,默认为1000字。,帮助文档:https://postsummary.zhheo.com/parameters.html#tianligpt-wordlimit
    typingAnimate: true # 智能的打字效果,模拟流处理的感觉
    beginningText: "这篇文章介绍了" #自定义开头语,默认为"这篇文章介绍了"
    summaryTheme: "default" #切换文章摘要主题,详情请见 https://postchat.zhheo.com/theme.html
  chat:
    enableAI: true # 开启PostChat智能对话,添加按钮点击对话的功能,如果你并非PostChat用户,而是仅文章摘要用户,建议关闭此功能
    userMode: "magic" # 用户模式,可选值为"magic"和"iframe",默认为"magic"
    backgroundColor: "#3e86f6" # 按钮背景颜色
    fill: "#FFFFFF" # 按钮填充颜色
    bottom: "80px" # 按钮底部距离
    left: "20px" # 按钮左边距离
    width: "44px" # 按钮宽度
    frameWidth: "375px" # 聊天界面框架宽度
    frameHeight: "600px" # 聊天界面框架高度
    defaultInput: true # 默认输入
    upLoadWeb: true # 上传网站
    showInviteLink: true # 显示邀请链接
    userTitle: "PostChat" # 界面标题
    userDesc: "如果你对网站的内容有任何疑问,可以来问我哦~" # 聊天界面描述
    userIcon: "https://ai.tianli0.top/static/img/PostChat.webp" # PostChat聊天界面图标,仅在Magic模式下有效
    defaultChatQuestions: ["你好","你是谁"] # 默认聊天问题,仅在Magic模式下有效
    defaultSearchQuestions: ["视频压缩","设计"] # 默认搜索问题,仅在Magic模式下有效
    addButton: true # 是否显示按钮

主题适配

此插件支持所有的PostChat开发API,提供主题开发者对于PostChat的控制能力。包括深色模式切换:postChatUser.setPostChatTheme('dark');聊天窗口输入框:postChatUser.setPostChatInput(content)等。

详见开发者文档:https://postchat.zhheo.com/advanced/theme.html

开发者

PostChat由张洪HeoTianli共同构建,技术支持请联系:[email protected](一个工作日内回复)