[opt] tianli_gpt
This commit is contained in:
parent
88f16fc754
commit
bb91a8d4ce
19
_config.yml
19
_config.yml
|
@ -453,12 +453,19 @@ plugins:
|
||||||
enable: #true
|
enable: #true
|
||||||
js: https://jsd.onmicrosoft.cn/gh/qxchuckle/Post-Summary-AI@6.0/chuckle-post-ai.min.js
|
js: https://jsd.onmicrosoft.cn/gh/qxchuckle/Post-Summary-AI@6.0/chuckle-post-ai.min.js
|
||||||
field: post # all, post, wiki
|
field: post # all, post, wiki
|
||||||
api: 5Q5mpqRK5DkwT1X9Gi5e # tianli_gpt key
|
key: 5Q5mpqRK5DkwT1X9Gi5e # tianli_gpt key
|
||||||
limit: 1000 # 设置提交的字数限制,默认为1000字,上限为5000,超过5000字符将被截断
|
total_length: 1000 # 设置提交的字数限制,默认为1000字,上限为5000,超过5000字符将被截断
|
||||||
typingAnimate: true # 打字机动画
|
typewriter: true # 打字机动画
|
||||||
direct: true # 是否直接显示摘要,否则显示 AI 简介
|
summary_directly: true # 是否直接显示摘要,否则显示 AI 简介
|
||||||
recommend: all # all, web # 文章推荐方式,all:匹配数据库内所有文章进行推荐,web:仅当前站内的文章,默认all
|
rec_method: all # all, web # 文章推荐方式,all:匹配数据库内所有文章进行推荐,web:仅当前站内的文章,默认all
|
||||||
shuttle: true # 是否隐藏矩阵穿梭
|
hide_shuttle: true # 是否隐藏矩阵穿梭
|
||||||
|
summary_toggle: false
|
||||||
|
interface:
|
||||||
|
name: AI摘要
|
||||||
|
introduce: '我是文章辅助AI: QX-AI,点击下方的按钮,让我生成本文简介、推荐相关文章等。'
|
||||||
|
version: TianliGPT
|
||||||
|
button: ["介绍自己", "推荐文章", "生成摘要", "矩阵穿梭"]
|
||||||
|
|
||||||
|
|
||||||
# Katex - The fastest math typesetting library for the web
|
# Katex - The fastest math typesetting library for the web
|
||||||
# https://katex.org/docs/autorender.html
|
# https://katex.org/docs/autorender.html
|
||||||
|
|
|
@ -1,23 +1,11 @@
|
||||||
<% if (['all', page.layout].includes(theme.plugins.tianli_gpt.field)) { %>
|
<% if (['all', page.layout].includes(theme.plugins.tianli_gpt.field)) { %>
|
||||||
<script src="<%- theme.plugins.tianli_gpt?.js %>"></script>
|
<script defer src="<%- theme.plugins.tianli_gpt?.js %>"></script>
|
||||||
<script data-pjax defer>
|
<script defer>
|
||||||
new ChucklePostAI({
|
window.addEventListener('DOMContentLoaded', (event) => {
|
||||||
|
new ChucklePostAI(Object.assign({
|
||||||
el: 'article.content',
|
el: 'article.content',
|
||||||
key: '<%= theme.plugins.tianli_gpt?.api %>',
|
css: `/css/_plugins/tianli_gpt`
|
||||||
rec_method: '<%= theme.plugins.tianli_gpt?.recommend || all %>',
|
}, JSON.parse(`<%- JSON.stringify(theme.plugins.tianli_gpt) %>`)))
|
||||||
summary_directly: `<%= theme.plugins.tianli_gpt?.direct %>`,
|
});
|
||||||
typewriter: `<%= theme.plugins.tianli_gpt?.typingAnimate %>`,
|
</script>
|
||||||
css: `/css/_plugins/tianli_gpt`,
|
<% } %>
|
||||||
summary_toggle: false,
|
|
||||||
total_length: `<%= theme.plugins.tianli_gpt?.limit %>`,
|
|
||||||
hide_shuttle: `<%= theme.plugins.tianli_gpt?.shuttle %>`,
|
|
||||||
interface: {
|
|
||||||
name: "AI摘要",
|
|
||||||
introduce: "我是文章辅助AI: QX-AI,点击下方的按钮,让我生成本文简介、推荐相关文章等。", // 自我介绍
|
|
||||||
version: "TianliGPT",
|
|
||||||
button: ["介绍自己", "推荐文章", "生成摘要", "矩阵穿梭"],
|
|
||||||
},
|
|
||||||
})
|
|
||||||
</script>
|
|
||||||
<% } %>
|
|
||||||
|
|
Loading…
Reference in New Issue