openai-api-mock 0.3.1 → 0.4.0
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/README.md +376 -333
- package/dist/index.cjs +1805 -1661
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +1805 -1661
- package/dist/index.js.map +1 -1
- package/package.json +74 -69
package/package.json
CHANGED
|
@@ -1,69 +1,74 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "openai-api-mock",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "A Node.js module for mocking OpenAI-compatible API responses in a development environment with consistency mechanisms for deterministic testing",
|
|
5
|
-
"repository": {
|
|
6
|
-
"type": "git",
|
|
7
|
-
"url": "git+https://github.com/chihebnabil/openai-api-mock.git"
|
|
8
|
-
},
|
|
9
|
-
"type": "module",
|
|
10
|
-
"types": "./index.d.ts",
|
|
11
|
-
"keywords": [
|
|
12
|
-
"openai",
|
|
13
|
-
"mock",
|
|
14
|
-
"api",
|
|
15
|
-
"development",
|
|
16
|
-
"testing",
|
|
17
|
-
"chatgpt",
|
|
18
|
-
"interceptor",
|
|
19
|
-
"sandbox",
|
|
20
|
-
"fake",
|
|
21
|
-
"mocking",
|
|
22
|
-
"ai",
|
|
23
|
-
"artificial intelligence",
|
|
24
|
-
"machine learning",
|
|
25
|
-
"deterministic",
|
|
26
|
-
"consistency",
|
|
27
|
-
"seeding",
|
|
28
|
-
"templates"
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
"
|
|
32
|
-
"
|
|
33
|
-
"
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
"
|
|
37
|
-
"
|
|
38
|
-
"
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
"
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
"
|
|
62
|
-
"
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
"
|
|
68
|
-
|
|
69
|
-
|
|
1
|
+
{
|
|
2
|
+
"name": "openai-api-mock",
|
|
3
|
+
"version": "0.4.0",
|
|
4
|
+
"description": "A Node.js module for mocking OpenAI-compatible API responses (chat, embeddings, images) in a development environment with consistency mechanisms for deterministic testing",
|
|
5
|
+
"repository": {
|
|
6
|
+
"type": "git",
|
|
7
|
+
"url": "git+https://github.com/chihebnabil/openai-api-mock.git"
|
|
8
|
+
},
|
|
9
|
+
"type": "module",
|
|
10
|
+
"types": "./index.d.ts",
|
|
11
|
+
"keywords": [
|
|
12
|
+
"openai",
|
|
13
|
+
"mock",
|
|
14
|
+
"api",
|
|
15
|
+
"development",
|
|
16
|
+
"testing",
|
|
17
|
+
"chatgpt",
|
|
18
|
+
"interceptor",
|
|
19
|
+
"sandbox",
|
|
20
|
+
"fake",
|
|
21
|
+
"mocking",
|
|
22
|
+
"ai",
|
|
23
|
+
"artificial intelligence",
|
|
24
|
+
"machine learning",
|
|
25
|
+
"deterministic",
|
|
26
|
+
"consistency",
|
|
27
|
+
"seeding",
|
|
28
|
+
"templates",
|
|
29
|
+
"embeddings",
|
|
30
|
+
"rag",
|
|
31
|
+
"vector",
|
|
32
|
+
"similarity",
|
|
33
|
+
"semantic-search"
|
|
34
|
+
],
|
|
35
|
+
"scripts": {
|
|
36
|
+
"build": "vite build",
|
|
37
|
+
"pretest": "npm run build",
|
|
38
|
+
"test": "node --experimental-vm-modules node_modules/jest/bin/jest.js",
|
|
39
|
+
"coverage": "node --experimental-vm-modules node_modules/jest/bin/jest.js --coverage",
|
|
40
|
+
"prepublishOnly": "npm run build",
|
|
41
|
+
"format": "prettier --write .",
|
|
42
|
+
"format:check": "prettier --check .",
|
|
43
|
+
"format:src": "prettier --write src/**/*.js __tests__/**/*.js"
|
|
44
|
+
},
|
|
45
|
+
"author": "Chiheb Nabil",
|
|
46
|
+
"license": "MIT",
|
|
47
|
+
"main": "./dist/index.cjs",
|
|
48
|
+
"module": "./dist/index.js",
|
|
49
|
+
"exports": {
|
|
50
|
+
".": {
|
|
51
|
+
"types": "./index.d.ts",
|
|
52
|
+
"require": "./dist/index.cjs",
|
|
53
|
+
"import": "./dist/index.js"
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
"files": [
|
|
57
|
+
"dist",
|
|
58
|
+
"index.d.ts"
|
|
59
|
+
],
|
|
60
|
+
"dependencies": {
|
|
61
|
+
"@faker-js/faker": "^10.0.0",
|
|
62
|
+
"nock": "^14.0.0"
|
|
63
|
+
},
|
|
64
|
+
"devDependencies": {
|
|
65
|
+
"jest": "^30.0.0",
|
|
66
|
+
"node-fetch": "^3.3.2",
|
|
67
|
+
"openai": "^6.0.0",
|
|
68
|
+
"prettier": "^3.0.0",
|
|
69
|
+
"vite": "^7.0.0"
|
|
70
|
+
},
|
|
71
|
+
"engines": {
|
|
72
|
+
"node": ">=18.0.0"
|
|
73
|
+
}
|
|
74
|
+
}
|