-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #6 from The-3Labs-Team/v2
V2
- Loading branch information
Showing
4 changed files
with
111 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
name: Flush Cache | ||
|
||
on: | ||
release: | ||
types: [published] | ||
|
||
jobs: | ||
purge-jsdelivr-cache: | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- uses: gacts/purge-jsdelivr-cache@v1 | ||
with: | ||
url: | | ||
https://cdn.jsdelivr.net/gh/The-3Labs-Team/tinymce-chatgpt-plugin@2/dist/chatgpt.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1"> | ||
|
||
<script src="https://cdn.jsdelivr.net/npm/tinymce@7/tinymce.min.js" referrerpolicy="origin"></script> | ||
<link href="https://cdn.jsdelivr.net/npm/tinymce@7/skins/ui/oxide/content.min.css" rel="stylesheet"> | ||
<script> | ||
tinymce.init({ | ||
selector: '#mytextarea', | ||
version: '6', | ||
|
||
// 1. Add the plugin to the list of external plugins | ||
external_plugins: { | ||
chatgpt: | ||
"http://127.0.0.1:8080/dist/chatgpt.js", | ||
}, | ||
|
||
// 2. Configure the ChatGPT plugin | ||
openai: { | ||
api_key: "lm-studio", | ||
// model: "", | ||
temperature: 0.5, | ||
max_tokens: 150, | ||
prompts: [ | ||
"Translate from English to Italian", | ||
"Summarize", | ||
"Proofread", | ||
"Write a blog post about", | ||
], | ||
baseUri: "http://localhost:11434/v1/chat/completions", | ||
}, | ||
|
||
// 3. Add the ChatGPT button to the toolbar | ||
toolbar: ["chatgpt"], | ||
}); | ||
</script> | ||
</head> | ||
|
||
<body> | ||
<h1>TinyMCE Quick Start Guide</h1> | ||
<form method="post"> | ||
<textarea id="mytextarea">Hello, World!</textarea> | ||
</form> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters