Skip to content

Commit ed7af01

Browse files
committed
2 parents fbed1ee + 6980621 commit ed7af01

5 files changed

Lines changed: 39 additions & 12 deletions

File tree

README.md

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,31 @@
11
# AdminForth TextComplete Plugin
22

3-
<img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License: MIT" /> <img src="https://woodpecker.devforth.io/api/badges/3848/status.svg" alt="Build Status" /> <a href="https://www.npmjs.com/package/@adminforth/text-complete"> <img src="https://img.shields.io/npm/dt/@adminforth/text-complete" alt="npm downloads" /></a> <a href="https://www.npmjs.com/package/@adminforth/text-complete"><img src="https://img.shields.io/npm/v/@adminforth/text-complete" alt="npm version" /></a> <a href="https://www.npmjs.com/package/@adminforth/text-complete">
3+
<img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License: MIT" /> <img src="https://woodpecker.devforth.io/api/badges/3848/status.svg" alt="Build Status" /> <a href="https://www.npmjs.com/package/@adminforth/text-complete"><img src="https://img.shields.io/npm/dm/@adminforth/text-complete" alt="npm downloads" /></a> <a href="https://www.npmjs.com/package/@adminforth/text-complete"><img src="https://img.shields.io/npm/v/@adminforth/text-complete" alt="npm version" /></a>
4+
5+
[![Ask AI](https://tluma.ai/badge)](https://tluma.ai/ask-ai/devforth/adminforth)
46

57
Allow to add an auto-complete text and string feature to adminforth fields using OpenAI Chat GPT models.
68

7-
## For usage, see [AdminForth TextComplete Documentation](https://adminforth.dev/docs/tutorial/Plugins/text-complete/)
9+
## Features
10+
11+
- Add AI-powered text completion to AdminForth fields.
12+
- Speed up drafting for text and string values.
13+
- Use ChatGPT-based assistance close to your data forms.
14+
- Keep generation workflows inside the admin panel.
15+
16+
## Documentation
17+
18+
Full setup and configuration guide:
19+
20+
[AdminForth TextComplete Documentation](https://adminforth.dev/docs/tutorial/Plugins/text-complete/)
21+
22+
## About AdminForth
23+
24+
AdminForth is an open-source, agent-first admin framework for building robust admin panels and back-office applications faster.
25+
26+
## Related links
27+
28+
- [AdminForth website](https://adminforth.dev)
29+
- [npm package](https://www.npmjs.com/package/@adminforth/text-complete)
30+
- [More AdminForth plugins](https://adminforth.dev/docs/tutorial/ListOfPlugins/)
31+
- [Built by DevForth](https://devforth.io)

custom/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"test": "echo \"Error: no test specified\" && exit 1"
88
},
99
"keywords": [],
10-
"author": "",
10+
"author": "DevForth (https://devforth.io)",
1111
"license": "ISC",
1212
"dependencies": {
1313
"@iconify-prerendered/vue-mdi": "^0.28.1737398331",

index.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,10 @@ export default class TextCompletePlugin extends AdminForthPlugin {
145145
}
146146

147147
process.env.HEAVY_DEBUG && console.log('🪲 OpenAI Prompt 🧠', content);
148-
const { content: respContent } = await this.options.adapter.complete(content, this.options.expert?.maxTokens);
148+
const { content: respContent } = await this.options.adapter.complete({
149+
content,
150+
maxTokens: this.options.expert?.maxTokens ?? 50,
151+
});
149152
let suggestion = respContent
150153

151154
if (suggestion.startsWith(currentVal)) {

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,11 @@
2020
"adminforth",
2121
"text complete"
2222
],
23-
"author": "devforth",
23+
"author": "DevForth (https://devforth.io)",
2424
"license": "MIT",
2525
"devDependencies": {
2626
"@types/node": "^22.10.7",
27-
"adminforth": "^2.35.0",
27+
"adminforth": "^2.42.0",
2828
"semantic-release": "^24.2.1",
2929
"semantic-release-slack-bot": "^4.0.2",
3030
"typescript": "^5.7.3"
@@ -55,6 +55,6 @@
5555
]
5656
},
5757
"peerDependencies": {
58-
"adminforth": "^2.35.0"
58+
"adminforth": "^2.42.0"
5959
}
6060
}

pnpm-lock.yaml

Lines changed: 5 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)