cap-mock-generator 1.0.9 → 1.0.11

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.
Files changed (2) hide show
  1. package/README.md +24 -21
  2. package/package.json +1 -2
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # CAP Mock Generator 🚀
1
+ # CAP Mock Generator
2
2
 
3
3
  [![npm version](https://img.shields.io/npm/v/cap-mock-generator.svg)](https://www.npmjs.com/package/cap-mock-generator)
4
4
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
@@ -9,18 +9,18 @@ An advanced, interactive, and intelligent mock dataset generation engine built s
9
9
 
10
10
  ---
11
11
 
12
- ## Features
12
+ ## Features
13
13
 
14
- * **Interactive Onboarding Wizard:** Powered by modern `@inquirer/prompts`, walking you seamlessly through configuration step-by-step.
15
- * **Relational Data Integrity (Foreign Key Management):** Automatically analyzes dependencies. It ensures child tables (e.g., entity relationships ending with `ID`) match valid, existing primary keys generated from parent tables.
16
- * **Automatic Virtual Column Stripping:** Cleanly filters out `Association to many` and `Composition of many` virtual elements so they never mess up your physical CSV deployment files.
17
- * **Multi-Provider AI Data Layer:** High-fidelity business mock data using either **Google Gemini Pro (`gemini-2.5-flash`)** or **OpenAI (`gpt-4o-mini`)** structured JSON responses.
18
- * **Resilient Fallback Core:** If your AI API tokens hit limit caps or encounter network spikes (503 Service Unavailable), the engine gracefully falls back to a lightning-fast local **Faker.js** cluster without crashing.
19
- * **Clean Architectural Foundations:** Designed around the Command-Service pattern for maximum scalability and maintainability.
14
+ - **Interactive Onboarding Wizard:** Powered by modern `@inquirer/prompts`, walking you seamlessly through configuration step-by-step.
15
+ - **Relational Data Integrity (Foreign Key Management):** Automatically analyzes dependencies. It ensures child tables (e.g., entity relationships ending with `ID`) match valid, existing primary keys generated from parent tables.
16
+ - **Automatic Virtual Column Stripping:** Cleanly filters out `Association to many` and `Composition of many` virtual elements so they never mess up your physical CSV deployment files.
17
+ - **Multi-Provider AI Data Layer:** High-fidelity business mock data using either **Google Gemini Pro (`gemini-2.5-flash`)** or **OpenAI (`gpt-4o-mini`)** structured JSON responses.
18
+ - **Resilient Fallback Core:** If your AI API tokens hit limit caps or encounter network spikes (503 Service Unavailable), the engine gracefully falls back to a lightning-fast local **Faker.js** cluster without crashing.
19
+ - **Clean Architectural Foundations:** Designed around the Command-Service pattern for maximum scalability and maintainability.
20
20
 
21
21
  ---
22
22
 
23
- ## 📥 Installation
23
+ ## Installation
24
24
 
25
25
  You can install `cap-mock-generator` globally, locally as a development dependency, or invoke it instantly on-demand using `npx`.
26
26
 
@@ -44,11 +44,11 @@ npm install cap-mock-generator --save-dev
44
44
 
45
45
  ---
46
46
 
47
- ## 🚀 Usage
47
+ ## Usage
48
48
 
49
49
  Once installed, open your terminal, ensure you are in the root directory of your SAP CAP application where your `package.json` and `db/` folder reside, and trigger the wizard using one of the strategies below.
50
50
 
51
- ### Option A: On-The-Fly Execution
51
+ ### Option A: On-The-Fly Execution
52
52
 
53
53
  No installation required.
54
54
 
@@ -58,7 +58,7 @@ If you prefer to run the module directly without explicitly downloading it to yo
58
58
  npx cap-mock-generator start
59
59
  ```
60
60
 
61
- ### 🌍 Option B: Global Command Line Execution
61
+ ### Option B: Global Command Line Execution
62
62
 
63
63
  If you selected the global installation strategy earlier, simply ignite the interface by typing:
64
64
 
@@ -66,7 +66,7 @@ If you selected the global installation strategy earlier, simply ignite the inte
66
66
  cap-mock-generator start
67
67
  ```
68
68
 
69
- ### 🛠️ Option C: Configured Local Project Scripts
69
+ ### Option C: Configured Local Project Scripts
70
70
 
71
71
  If you installed the generator locally, open your native `package.json` and map a clean entry shortcut helper to your internal `scripts` block:
72
72
 
@@ -86,12 +86,12 @@ npm run mock:gen
86
86
 
87
87
  ---
88
88
 
89
- ## 🛠️ Interactive Onboarding Flow
89
+ ## Interactive Onboarding Flow
90
90
 
91
91
  When you ignite the CLI wizard, it will guide you through the following prompts:
92
92
 
93
93
  ```plaintext
94
- 🌟 --- CAP Mock Generator Onboarding Wizard ---
94
+ 🌟 --- CAP Mock Generator Onboarding Wizard ---
95
95
 
96
96
  ? Enter your CDS schema filename inside the "db" directory: (schema.cds)
97
97
  ? How many mock records should be generated per Entity? (5)
@@ -115,7 +115,7 @@ When you ignite the CLI wizard, it will guide you through the following prompts:
115
115
 
116
116
  ---
117
117
 
118
- ## 🔒 Security & Environment Compliance
118
+ ## Security & Environment Compliance
119
119
 
120
120
  Your secret API credentials, such as `GEMINI_API_KEY` or `OPENAI_API_KEY`, are processed strictly inside your immediate shell execution context memory through `process.env`.
121
121
 
@@ -123,7 +123,7 @@ They are never saved to disk, logged to the console, or transported outside the
123
123
 
124
124
  ---
125
125
 
126
- ## 🏗️ Relational Schema Topology
126
+ ## Relational Schema Topology
127
127
 
128
128
  The generator intelligently tracks schema hierarchy. Take this complex manufacturing scenario:
129
129
 
@@ -140,9 +140,12 @@ entity Assets {
140
140
  }
141
141
  ```
142
142
 
143
- ## ⚖️ Legal Disclaimer & Trademark Notice
143
+ ## License and Usage Notice
144
144
 
145
- This project is an independent open-source tool and is **not** officially affiliated with, endorsed by, or sponsored by SAP SE.
145
+ This library leverages the official `@sap/cds-compiler` package provided by SAP to parse CDS schema definitions for SAP CAP applications. It does not modify, bundle, or redistribute SAP source code beyond declaring `@sap/cds-compiler` as an npm dependency.
146
146
 
147
- * **SAP, SAP BTP, and SAP CAP** are trademarks or registered trademarks of SAP SE in Germany and other countries.
148
- * The `@sap/cds-compiler` package used as a dependency in this tool is the exclusive property and copyright of **SAP SE**. It is utilized in accordance with its public availability on the default registry.
147
+ The `@sap/cds-compiler` package is provided under SAP's own license terms. Users of `cap-mock-generator` are responsible for reviewing and complying with the applicable SAP license terms when using this package in projects that depend on SAP CAP tooling.
148
+
149
+ Careful attention should be paid to licensing restrictions when integrating `cap-mock-generator` into commercial, enterprise, or redistributed software that includes SAP CAP dependencies.
150
+
151
+ `cap-mock-generator` itself is licensed under the MIT License. See the `LICENSE` file for details.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cap-mock-generator",
3
- "version": "1.0.9",
3
+ "version": "1.0.11",
4
4
  "description": "An interactive mock data generation engine for SAP CAP applications, leveraging the official @sap/cds-compiler by SAP for schema parsing.",
5
5
  "main": "dist/cli.js",
6
6
  "bin": {
@@ -32,7 +32,6 @@
32
32
  "@google/genai": "^2.8.0",
33
33
  "@inquirer/prompts": "^8.5.2",
34
34
  "@sap/cds-compiler": "^6.9.2",
35
- "cap-mock-generator": "file:cap-mock-generator-1.0.8.tgz",
36
35
  "commander": "^15.0.0",
37
36
  "csv-writer": "^1.6.0",
38
37
  "dotenv": "^17.4.2",