@cobrowser/chatgpt 0.7.47 → 0.7.49
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +8 -7
- package/prompts/copilot-base-prompt.txt +4 -0
- package/dist/models/ChatGPTMessage.d.ts +0 -17
- package/dist/models/ChatGPTMessage.js +0 -9
- package/dist/models/ChatGPTUsageTokens.d.ts +0 -6
- package/dist/models/ChatGptResponse.d.ts +0 -8
- package/dist/models/ChatGptResponse.js +0 -2
- package/dist/models/ChatGptUsageTokens.js +0 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cobrowser/chatgpt",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.49",
|
|
4
4
|
"description": "chatgpt services to connect our projects with chatgpt api",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"chatgpt",
|
|
@@ -21,11 +21,10 @@
|
|
|
21
21
|
"precommit": "npm run lint && npm run test && npm run upgrade && npm run security"
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@cobrowser/logger": "^2.0.
|
|
25
|
-
"@cobrowser/xss-validation": "^2.0.
|
|
26
|
-
"axios": "^1.
|
|
27
|
-
"
|
|
28
|
-
"openai": "^6.3.0"
|
|
24
|
+
"@cobrowser/logger": "^2.0.7",
|
|
25
|
+
"@cobrowser/xss-validation": "^2.0.3",
|
|
26
|
+
"axios": "^1.16.0",
|
|
27
|
+
"openai": "^6.36.0"
|
|
29
28
|
},
|
|
30
29
|
"directories": {
|
|
31
30
|
"dist": "dist"
|
|
@@ -41,5 +40,7 @@
|
|
|
41
40
|
"bugs": {
|
|
42
41
|
"url": "https://bitbucket.org/cobrowser/cb_utils/issues"
|
|
43
42
|
},
|
|
44
|
-
"
|
|
43
|
+
"devDependencies": {
|
|
44
|
+
"axios-mock-adapter": "^2.1.0"
|
|
45
|
+
}
|
|
45
46
|
}
|
|
@@ -8,6 +8,10 @@ OUTPUT FORMAT — HARD
|
|
|
8
8
|
Your response must ONLY contain a valid JSON array of 2 to 3 strings.
|
|
9
9
|
Each string must be a complete customer-facing response.
|
|
10
10
|
|
|
11
|
+
OUTPUT SANITIZATION — HARD
|
|
12
|
+
- Never show citations, references, IDs, or source markers (e.g. filecite, turn0fileX)
|
|
13
|
+
- Always remove any internal markers from the final message
|
|
14
|
+
|
|
11
15
|
CONSISTENCY RULE — HARD
|
|
12
16
|
All responses MUST follow the exact same decision path and outcome.
|
|
13
17
|
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
export declare enum ChatGPTRole {
|
|
2
|
-
USER = "user",
|
|
3
|
-
SYSTEM = "system",
|
|
4
|
-
ASSISTANT = "assistant"
|
|
5
|
-
}
|
|
6
|
-
export interface ChatGPTRequestBody {
|
|
7
|
-
model: string;
|
|
8
|
-
response_format?: {
|
|
9
|
-
type: string;
|
|
10
|
-
};
|
|
11
|
-
messages: ChatGPTMessage[];
|
|
12
|
-
}
|
|
13
|
-
interface ChatGPTMessage {
|
|
14
|
-
role: ChatGPTRole;
|
|
15
|
-
content: string;
|
|
16
|
-
}
|
|
17
|
-
export default ChatGPTMessage;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ChatGPTRole = void 0;
|
|
4
|
-
var ChatGPTRole;
|
|
5
|
-
(function (ChatGPTRole) {
|
|
6
|
-
ChatGPTRole["USER"] = "user";
|
|
7
|
-
ChatGPTRole["SYSTEM"] = "system";
|
|
8
|
-
ChatGPTRole["ASSISTANT"] = "assistant";
|
|
9
|
-
})(ChatGPTRole = exports.ChatGPTRole || (exports.ChatGPTRole = {}));
|