agent-docs 1.0.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.
Files changed (44) hide show
  1. package/.cursor/plans/OPTIMISE.md +379 -0
  2. package/.cursor/plans/VERSIONING.md +207 -0
  3. package/.cursor/rules/IMPORTANT.mdc +97 -0
  4. package/.github/ISSUE_TEMPLATE/bug_report.md +13 -0
  5. package/.github/ISSUE_TEMPLATE/feature_request.md +17 -0
  6. package/.github/dependabot.yml +38 -0
  7. package/.github/pull_request_template.md +10 -0
  8. package/.github/workflows/format.yml +35 -0
  9. package/CODE_OF_CONDUCT.md +64 -0
  10. package/CONTRIBUTING.md +52 -0
  11. package/LICENSE.md +20 -0
  12. package/PLAN.md +707 -0
  13. package/README.md +133 -0
  14. package/SECURITY.md +21 -0
  15. package/docs/APEXANNOTATIONS.md +472 -0
  16. package/docs/APEXDOC.md +198 -0
  17. package/docs/CML.md +877 -0
  18. package/docs/CODEANALYZER.md +435 -0
  19. package/docs/CONTEXTDEFINITIONS.md +617 -0
  20. package/docs/ESLINT.md +827 -0
  21. package/docs/ESLINTJSDOC.md +520 -0
  22. package/docs/FIELDSERVICE.md +4452 -0
  23. package/docs/GRAPHBINARY.md +208 -0
  24. package/docs/GRAPHENGINE.md +616 -0
  25. package/docs/GRAPHML.md +337 -0
  26. package/docs/GRAPHSON.md +302 -0
  27. package/docs/GREMLIN.md +490 -0
  28. package/docs/GRYO.md +232 -0
  29. package/docs/HUSKY.md +106 -0
  30. package/docs/JEST.md +387 -0
  31. package/docs/JORJE.md +537 -0
  32. package/docs/JSDOC.md +621 -0
  33. package/docs/PMD.md +910 -0
  34. package/docs/PNPM.md +409 -0
  35. package/docs/PRETTIER.md +716 -0
  36. package/docs/PRETTIERAPEX.md +874 -0
  37. package/docs/REVENUETRANSACTIONMANAGEMENT.md +887 -0
  38. package/docs/TINKERPOP.md +252 -0
  39. package/docs/VITEST.md +706 -0
  40. package/docs/VSCODE.md +231 -0
  41. package/docs/XPATH31.md +213 -0
  42. package/package.json +32 -0
  43. package/postinstall.mjs +51 -0
  44. package/prettier.config.js +18 -0
package/docs/GRYO.md ADDED
@@ -0,0 +1,232 @@
1
+ # Gryo Format Specification
2
+
3
+ > **Version**: 1.0.0
4
+
5
+ Gremlin-Kryo binary format for graph serialization used by Apache TinkerPop.
6
+
7
+ **Related Docs:** [GRAPHENGINE.md](GRAPHENGINE.md),
8
+ [TINKERPOP.md](TINKERPOP.md), [GRAPHML.md](GRAPHML.md),
9
+ [GRAPHSON.md](GRAPHSON.md), [GRAPHBINARY.md](GRAPHBINARY.md),
10
+ [CODEANALYZER.md](CODEANALYZER.md)
11
+
12
+ ## Overview
13
+
14
+ Gryo: binary format for graph serialization. Most compact and efficient format.
15
+ Fast serialization/deserialization. Suitable for large graphs and
16
+ high-performance scenarios. Versioned format (v1, v3). Optimized for local
17
+ storage and production systems. Not human-readable.
18
+
19
+ ## Gryo Versions
20
+
21
+ **Gryo v1:** Original binary format, basic binary representation of graph
22
+ elements. Use cases: legacy systems, compatibility with older systems.
23
+
24
+ **Gryo v3:** Improved format with better performance, enhanced serialization
25
+ efficiency, better handling of large graphs, optimized binary encoding. Use
26
+ cases: modern applications, high-performance requirements, large graph
27
+ scenarios, production systems.
28
+
29
+ **Note:** Gryo v2 does not exist - version jumped from v1 to v3.
30
+
31
+ ## TinkerPop Gryo Support
32
+
33
+ **Builder Pattern:**
34
+
35
+ ```java
36
+ GryoReader reader = GryoReader.build()
37
+ .version(3)
38
+ .bufferSize(8192)
39
+ .create();
40
+
41
+ GryoWriter writer = GryoWriter.build()
42
+ .version(3)
43
+ .bufferSize(8192)
44
+ .create();
45
+ ```
46
+
47
+ **Methods:** `readGraph(InputStream|File|URL, Graph)`,
48
+ `writeGraph(OutputStream|File|URL, Graph)`
49
+
50
+ **Configuration:**
51
+
52
+ - `version(int)`: Gryo version (1 or 3) - **must match between reader and
53
+ writer**
54
+ - `bufferSize(int)`: Buffer size for I/O operations (default: 4096 bytes).
55
+ Larger buffers improve performance for large files, smaller buffers use less
56
+ memory.
57
+
58
+ **Version Compatibility:** Reader and writer must use the same version. Version
59
+ mismatch causes deserialization errors. v1 reader can only read v1 files, v3
60
+ reader can only read v3 files.
61
+
62
+ **Usage:**
63
+
64
+ ```java
65
+ Graph graph = TinkerGraph.open();
66
+ GryoWriter writer = GryoWriter.build().version(3).bufferSize(8192).create();
67
+ writer.writeGraph(new File("graph.kryo"), graph);
68
+
69
+ GryoReader reader = GryoReader.build().version(3).bufferSize(8192).create();
70
+ reader.readGraph(new File("graph.kryo"), graph);
71
+ ```
72
+
73
+ ## Version Compatibility
74
+
75
+ **Critical:** Gryo reader and writer must use the same version for proper
76
+ serialization/deserialization.
77
+
78
+ **Compatibility Rules:** v1 reader can only read v1 files, v3 reader can only
79
+ read v3 files, version mismatch causes deserialization errors or data
80
+ corruption, always specify version explicitly.
81
+
82
+ **Best Practice:** Always specify the version explicitly when creating readers
83
+ and writers.
84
+
85
+ **Migration:** To migrate from v1 to v3, read with v1 reader and write with v3
86
+ writer. No direct conversion tool - must read and rewrite graphs.
87
+
88
+ ## Binary Format Characteristics
89
+
90
+ **Format Type:** Binary format (not human-readable), compact representation,
91
+ efficient encoding of graph elements.
92
+
93
+ **Format-Specific Characteristics:** Smallest file size among all formats,
94
+ fastest serialization/deserialization, efficient for large graphs, low memory
95
+ overhead.
96
+
97
+ **Limitations:** Not human-readable, version-specific (requires matching
98
+ reader/writer versions), cannot be edited with text editors, requires TinkerPop
99
+ libraries.
100
+
101
+ **Format Comparison:** See
102
+ [TINKERPOP.md](TINKERPOP.md#detailed-format-comparisons) for detailed
103
+ comparisons with other formats.
104
+
105
+ ## Performance Considerations
106
+
107
+ **Format-Specific Optimization Tips:** Use Gryo v3 for best performance,
108
+ increase buffer size for large graphs (8192, 16384, or higher), use streaming
109
+ for very large graphs, consider compression for storage (Gryo files compress
110
+ well).
111
+
112
+ **File Size:** Most compact format. Typically 3-5x smaller than GraphML, 2-3x
113
+ smaller than GraphSON. Binary encoding is highly efficient.
114
+
115
+ **Speed:** Fastest serialization/deserialization, optimized for
116
+ performance-critical scenarios, suitable for real-time graph operations.
117
+
118
+ **Memory Usage:** Low memory overhead, efficient binary representation, buffer
119
+ size affects memory usage.
120
+
121
+ **General Performance Considerations:** See
122
+ [TINKERPOP.md](TINKERPOP.md#general-performance-considerations) for format
123
+ comparison and general optimization tips.
124
+
125
+ ## Configuration Best Practices
126
+
127
+ **For Maximum Performance:**
128
+
129
+ ```java
130
+ GryoReader reader = GryoReader.build()
131
+ .version(3) // Use latest version
132
+ .bufferSize(16384) // Larger buffer for large files
133
+ .create();
134
+
135
+ GryoWriter writer = GryoWriter.build()
136
+ .version(3) // Use latest version
137
+ .bufferSize(16384) // Larger buffer for large graphs
138
+ .create();
139
+ ```
140
+
141
+ **For Memory Efficiency:**
142
+
143
+ ```java
144
+ GryoReader reader = GryoReader.build()
145
+ .version(3)
146
+ .bufferSize(4096) // Default buffer size
147
+ .create();
148
+
149
+ GryoWriter writer = GryoWriter.build()
150
+ .version(3)
151
+ .bufferSize(4096) // Default buffer size
152
+ .create();
153
+ ```
154
+
155
+ **General Configuration:** See
156
+ [TINKERPOP.md](TINKERPOP.md#general-configuration-best-practices) for general
157
+ configuration best practices across all formats.
158
+
159
+ ## Error Handling
160
+
161
+ **Format-Specific Issues:** Version mismatch (reader and writer versions must
162
+ match), corrupted files (binary files can be corrupted, use checksums for
163
+ validation), buffer size (too small buffer may cause performance issues), memory
164
+ issues (very large graphs may require increased heap size).
165
+
166
+ **Format-Specific Best Practices:** Always specify version explicitly, use
167
+ consistent configuration between reader and writer, validate files after writing
168
+ (read back and verify), use appropriate buffer sizes for graph size, handle
169
+ IOException appropriately.
170
+
171
+ **General Error Handling:** See
172
+ [TINKERPOP.md](TINKERPOP.md#general-error-handling-patterns) for common error
173
+ handling patterns across all formats.
174
+
175
+ ## Examples
176
+
177
+ **Complete Reading and Writing:**
178
+
179
+ ```java
180
+ Graph graph = TinkerGraph.open();
181
+ Vertex alice = graph.addVertex(T.label, "person", "name", "Alice", "age", 30);
182
+ Vertex bob = graph.addVertex(T.label, "person", "name", "Bob", "age", 25);
183
+ alice.addEdge("knows", bob, "weight", 0.5);
184
+
185
+ GryoWriter writer = GryoWriter.build().version(3).bufferSize(8192).create();
186
+ writer.writeGraph(new File("graph.kryo"), graph);
187
+
188
+ Graph readGraph = TinkerGraph.open();
189
+ GryoReader reader = GryoReader.build().version(3).bufferSize(8192).create();
190
+ reader.readGraph(new File("graph.kryo"), readGraph);
191
+ ```
192
+
193
+ **Version Migration:**
194
+
195
+ ```java
196
+ Graph graph = TinkerGraph.open();
197
+
198
+ // Read v1 file
199
+ GryoReader v1Reader = GryoReader.build().version(1).create();
200
+ v1Reader.readGraph(new File("graph-v1.kryo"), graph);
201
+
202
+ // Write v3 file
203
+ GryoWriter v3Writer = GryoWriter.build().version(3).create();
204
+ v3Writer.writeGraph(new File("graph-v3.kryo"), graph);
205
+ ```
206
+
207
+ **Streaming:**
208
+
209
+ ```java
210
+ try (FileInputStream fis = new FileInputStream("large-graph.kryo");
211
+ BufferedInputStream bis = new BufferedInputStream(fis, 65536)) {
212
+ GryoReader reader = GryoReader.build().version(3).bufferSize(65536).create();
213
+ reader.readGraph(bis, graph);
214
+ }
215
+ ```
216
+
217
+ ## File Extensions
218
+
219
+ `.kryo` (standard), `.gryo` (alternative, less common). Extensions are
220
+ conventions only - Gryo format is identified by its binary structure, not file
221
+ extension.
222
+
223
+ ## Limitations
224
+
225
+ **Known Limitations:** Not human-readable (binary format), version-specific
226
+ (requires matching versions), cannot be edited with text editors, requires
227
+ TinkerPop libraries, no built-in compression (use external compression if
228
+ needed), platform-dependent (Java-specific binary format).
229
+
230
+ **Workarounds:** Use GraphML or GraphSON for human-readable formats, always
231
+ specify versions explicitly, use version migration for upgrading, consider
232
+ compression for storage efficiency.
package/docs/HUSKY.md ADDED
@@ -0,0 +1,106 @@
1
+ # Husky Reference
2
+
3
+ > **Version**: 1.0.0
4
+
5
+ Native Git hooks manager using `core.hooksPath` (Git 2.9+). Hooks = shell
6
+ scripts in `.husky/`.
7
+
8
+ ## Install
9
+
10
+ ```bash
11
+ pnpm add -D husky
12
+ ```
13
+
14
+ ## Setup
15
+
16
+ ```bash
17
+ pnpm exec husky init # Creates .husky/pre-commit, adds prepare script
18
+ ```
19
+
20
+ **Manual:** Add `"prepare": "husky"` to scripts, run `pnpm run prepare`, create
21
+ hook files in `.husky/`.
22
+
23
+ ## Hooks
24
+
25
+ Create files in `.husky/` named exactly: `pre-commit`, `pre-push`, `commit-msg`,
26
+ etc. (no extensions).
27
+
28
+ ```bash
29
+ echo "pnpm test" > .husky/pre-commit
30
+ echo "pnpm exec commitlint --edit \$1" > .husky/commit-msg
31
+ ```
32
+
33
+ Use `$1`, `$2` for Git params (replaces v4's `HUSKY_GIT_PARAMS`).
34
+
35
+ ### Hook Parameters
36
+
37
+ | Hook | Params |
38
+ | --------------------------------------------------------------------------------------------------- | ---------------------------------------- |
39
+ | `pre-commit`, `post-commit`, `pre-applypatch`, `post-applypatch`, `pre-auto-gc`, `pre-merge-commit` | None |
40
+ | `commit-msg`, `prepare-commit-msg` | `$1`=msg file |
41
+ | `pre-push` | `$1`=remote, `$2`=URL |
42
+ | `pre-rebase` | `$1`=upstream, `$2`=branch |
43
+ | `post-merge` | `$1`=squash flag |
44
+ | `post-checkout` | `$1`=prev HEAD, `$2`=new HEAD, `$3`=flag |
45
+ | `post-rewrite` | `$1`=command |
46
+
47
+ ## Skip Hooks
48
+
49
+ ```bash
50
+ git commit --no-verify # Single command
51
+ HUSKY=0 git commit -m "msg" # Session
52
+ ```
53
+
54
+ Global disable: `export HUSKY=0` in `~/.config/husky/init.sh`
55
+
56
+ ## Node Version Managers
57
+
58
+ For nvm/fnm/volta with Git GUIs, add to `~/.config/husky/init.sh`:
59
+
60
+ ```bash
61
+ export NVM_DIR="$HOME/.nvm"
62
+ [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
63
+ ```
64
+
65
+ ## CI/Production
66
+
67
+ Set `HUSKY=0` env var, or:
68
+
69
+ ```json
70
+ { "scripts": { "prepare": "husky || true" } }
71
+ ```
72
+
73
+ ## Subdirectory Projects
74
+
75
+ ```json
76
+ { "scripts": { "prepare": "cd .. && husky frontend/.husky" } }
77
+ ```
78
+
79
+ Hook must `cd` back: `cd frontend && pnpm test`
80
+
81
+ ## Common Patterns
82
+
83
+ ```bash
84
+ # .husky/pre-commit
85
+ pnpm exec lint-staged
86
+
87
+ # .husky/commit-msg
88
+ pnpm exec commitlint --edit $1
89
+
90
+ # .husky/pre-push (branch-specific)
91
+ [ "$(git rev-parse --abbrev-ref HEAD)" = "main" ] && pnpm run test:full
92
+ ```
93
+
94
+ ## Troubleshooting
95
+
96
+ - **Hooks not running:** Check filename exact, `git config core.hooksPath` →
97
+ `.husky/_`, Git ≥2.9
98
+ - **Command not found:** Init node version manager in `~/.config/husky/init.sh`
99
+ - **After uninstall:** `git config --unset core.hooksPath`
100
+
101
+ ## v4 Migration
102
+
103
+ - `package.json` hooks → `.husky/<hook>` files
104
+ - `jest` → `pnpm exec jest`
105
+ - `HUSKY_GIT_PARAMS` → `$1`, `$2`
106
+ - `HUSKY_SKIP_HOOKS` → `HUSKY=0`