llm-mock-server 1.0.5 → 1.0.7
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 +1 -1
- package/dist/cli/cli.d.ts +3 -0
- package/dist/cli/cli.d.ts.map +1 -0
- package/dist/cli/cli.js +103 -0
- package/dist/cli/cli.js.map +1 -0
- package/dist/cli/validators.d.ts +7 -0
- package/dist/cli/validators.d.ts.map +1 -0
- package/dist/cli/validators.js +53 -0
- package/dist/cli/validators.js.map +1 -0
- package/dist/formats/anthropic/index.d.ts +1 -1
- package/dist/formats/anthropic/index.d.ts.map +1 -1
- package/dist/formats/anthropic/index.js +1 -1
- package/dist/formats/anthropic/index.js.map +1 -1
- package/dist/formats/anthropic/parse.d.ts +2 -2
- package/dist/formats/anthropic/parse.d.ts.map +1 -1
- package/dist/formats/anthropic/parse.js +4 -2
- package/dist/formats/anthropic/parse.js.map +1 -1
- package/dist/formats/anthropic/schema.d.ts +1 -1
- package/dist/formats/anthropic/schema.d.ts.map +1 -1
- package/dist/formats/anthropic/schema.js +9 -4
- package/dist/formats/anthropic/schema.js.map +1 -1
- package/dist/formats/anthropic/serialize.d.ts +2 -2
- package/dist/formats/anthropic/serialize.d.ts.map +1 -1
- package/dist/formats/anthropic/serialize.js +76 -19
- package/dist/formats/anthropic/serialize.js.map +1 -1
- package/dist/formats/openai/chat-completions/index.d.ts +3 -0
- package/dist/formats/openai/chat-completions/index.d.ts.map +1 -0
- package/dist/formats/openai/chat-completions/index.js +13 -0
- package/dist/formats/openai/chat-completions/index.js.map +1 -0
- package/dist/formats/openai/chat-completions/parse.d.ts +4 -0
- package/dist/formats/openai/chat-completions/parse.d.ts.map +1 -0
- package/dist/formats/openai/chat-completions/parse.js +33 -0
- package/dist/formats/openai/chat-completions/parse.js.map +1 -0
- package/dist/formats/openai/chat-completions/schema.d.ts +93 -0
- package/dist/formats/openai/chat-completions/schema.d.ts.map +1 -0
- package/dist/formats/openai/chat-completions/schema.js +74 -0
- package/dist/formats/openai/chat-completions/schema.js.map +1 -0
- package/dist/formats/openai/chat-completions/serialize.d.ts +10 -0
- package/dist/formats/openai/chat-completions/serialize.d.ts.map +1 -0
- package/dist/formats/openai/chat-completions/serialize.js +99 -0
- package/dist/formats/openai/chat-completions/serialize.js.map +1 -0
- package/dist/formats/openai/responses/index.d.ts +3 -0
- package/dist/formats/openai/responses/index.d.ts.map +1 -0
- package/dist/formats/openai/responses/index.js +13 -0
- package/dist/formats/openai/responses/index.js.map +1 -0
- package/dist/formats/openai/responses/parse.d.ts +4 -0
- package/dist/formats/openai/responses/parse.d.ts.map +1 -0
- package/dist/formats/openai/responses/parse.js +51 -0
- package/dist/formats/openai/responses/parse.js.map +1 -0
- package/dist/formats/openai/responses/schema.d.ts +103 -0
- package/dist/formats/openai/responses/schema.d.ts.map +1 -0
- package/dist/formats/openai/responses/schema.js +71 -0
- package/dist/formats/openai/responses/schema.js.map +1 -0
- package/dist/formats/openai/responses/serialize.d.ts +10 -0
- package/dist/formats/openai/responses/serialize.d.ts.map +1 -0
- package/dist/formats/openai/responses/serialize.js +273 -0
- package/dist/formats/openai/responses/serialize.js.map +1 -0
- package/dist/formats/request-helpers.d.ts +1 -1
- package/dist/formats/request-helpers.d.ts.map +1 -1
- package/dist/formats/request-helpers.js.map +1 -1
- package/dist/formats/serialize-helpers.d.ts +1 -1
- package/dist/formats/serialize-helpers.d.ts.map +1 -1
- package/dist/formats/serialize-helpers.js +6 -3
- package/dist/formats/serialize-helpers.js.map +1 -1
- package/dist/formats/types.d.ts +2 -1
- package/dist/formats/types.d.ts.map +1 -1
- package/dist/history.d.ts +6 -2
- package/dist/history.d.ts.map +1 -1
- package/dist/history.js +2 -0
- package/dist/history.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/loader.d.ts +1 -1
- package/dist/loader.d.ts.map +1 -1
- package/dist/loader.js +26 -9
- package/dist/loader.js.map +1 -1
- package/dist/logger.d.ts.map +1 -1
- package/dist/logger.js +12 -4
- package/dist/logger.js.map +1 -1
- package/dist/mock-server.d.ts +44 -48
- package/dist/mock-server.d.ts.map +1 -1
- package/dist/mock-server.js +37 -85
- package/dist/mock-server.js.map +1 -1
- package/dist/route-handler.d.ts +1 -1
- package/dist/route-handler.d.ts.map +1 -1
- package/dist/route-handler.js +19 -7
- package/dist/route-handler.js.map +1 -1
- package/dist/rule-builder.d.ts +21 -0
- package/dist/rule-builder.d.ts.map +1 -0
- package/dist/rule-builder.js +58 -0
- package/dist/rule-builder.js.map +1 -0
- package/dist/rule-engine.d.ts +3 -1
- package/dist/rule-engine.d.ts.map +1 -1
- package/dist/rule-engine.js +7 -2
- package/dist/rule-engine.js.map +1 -1
- package/dist/sse-writer.d.ts +1 -1
- package/dist/sse-writer.d.ts.map +1 -1
- package/dist/types/reply.d.ts +51 -8
- package/dist/types/reply.d.ts.map +1 -1
- package/dist/types/request.d.ts +21 -6
- package/dist/types/request.d.ts.map +1 -1
- package/dist/types/rule.d.ts +65 -7
- package/dist/types/rule.d.ts.map +1 -1
- package/dist/types.d.ts +3 -3
- package/dist/types.d.ts.map +1 -1
- package/package.json +20 -11
- package/.claude/skills/desloppify/SKILL.md +0 -308
- package/.desloppify/external_review_sessions/ext_20260315_000339_a6cdc3e6/canonical_import_20260315_000801.json +0 -242
- package/.desloppify/external_review_sessions/ext_20260315_000339_a6cdc3e6/canonical_import_20260315_000905.json +0 -248
- package/.desloppify/external_review_sessions/ext_20260315_000339_a6cdc3e6/canonical_import_20260315_000917.json +0 -248
- package/.desloppify/external_review_sessions/ext_20260315_000339_a6cdc3e6/canonical_import_20260315_000950.json +0 -311
- package/.desloppify/external_review_sessions/ext_20260315_000339_a6cdc3e6/claude_launch_prompt.md +0 -17
- package/.desloppify/external_review_sessions/ext_20260315_000339_a6cdc3e6/review_result.json +0 -255
- package/.desloppify/external_review_sessions/ext_20260315_000339_a6cdc3e6/review_result.template.json +0 -22
- package/.desloppify/external_review_sessions/ext_20260315_000339_a6cdc3e6/reviewer_instructions.md +0 -20
- package/.desloppify/external_review_sessions/ext_20260315_000339_a6cdc3e6/session.json +0 -20
- package/.desloppify/external_review_sessions/ext_20260315_045546_0587ea3b/canonical_import_20260315_050000.json +0 -286
- package/.desloppify/external_review_sessions/ext_20260315_045546_0587ea3b/canonical_import_20260315_050028.json +0 -303
- package/.desloppify/external_review_sessions/ext_20260315_045546_0587ea3b/claude_launch_prompt.md +0 -17
- package/.desloppify/external_review_sessions/ext_20260315_045546_0587ea3b/review_result.json +0 -297
- package/.desloppify/external_review_sessions/ext_20260315_045546_0587ea3b/review_result.template.json +0 -22
- package/.desloppify/external_review_sessions/ext_20260315_045546_0587ea3b/reviewer_instructions.md +0 -20
- package/.desloppify/external_review_sessions/ext_20260315_045546_0587ea3b/session.json +0 -20
- package/.desloppify/query.json +0 -1312
- package/.desloppify/review_packet_blind.json +0 -1249
- package/.desloppify/review_packets/holistic_packet_20260315_000339.json +0 -1471
- package/.desloppify/review_packets/holistic_packet_20260315_045546.json +0 -1480
- package/.desloppify/review_packets/holistic_packet_20260315_185401.json +0 -1407
- package/.desloppify/review_packets/holistic_packet_20260315_185613.json +0 -1407
- package/.desloppify/state-typescript.json +0 -8438
- package/.desloppify/state-typescript.json.bak +0 -8432
- package/.desloppify/subagents/runs/20260315_185401/logs/batch-1.log +0 -384
- package/.desloppify/subagents/runs/20260315_185401/logs/batch-10.log +0 -484
- package/.desloppify/subagents/runs/20260315_185401/logs/batch-2.log +0 -408
- package/.desloppify/subagents/runs/20260315_185401/logs/batch-3.log +0 -416
- package/.desloppify/subagents/runs/20260315_185401/logs/batch-4.log +0 -360
- package/.desloppify/subagents/runs/20260315_185401/logs/batch-5.log +0 -360
- package/.desloppify/subagents/runs/20260315_185401/logs/batch-6.log +0 -364
- package/.desloppify/subagents/runs/20260315_185401/logs/batch-7.log +0 -428
- package/.desloppify/subagents/runs/20260315_185401/logs/batch-8.log +0 -388
- package/.desloppify/subagents/runs/20260315_185401/logs/batch-9.log +0 -500
- package/.desloppify/subagents/runs/20260315_185401/prompts/batch-1.md +0 -83
- package/.desloppify/subagents/runs/20260315_185401/prompts/batch-10.md +0 -108
- package/.desloppify/subagents/runs/20260315_185401/prompts/batch-2.md +0 -89
- package/.desloppify/subagents/runs/20260315_185401/prompts/batch-3.md +0 -91
- package/.desloppify/subagents/runs/20260315_185401/prompts/batch-4.md +0 -77
- package/.desloppify/subagents/runs/20260315_185401/prompts/batch-5.md +0 -77
- package/.desloppify/subagents/runs/20260315_185401/prompts/batch-6.md +0 -78
- package/.desloppify/subagents/runs/20260315_185401/prompts/batch-7.md +0 -94
- package/.desloppify/subagents/runs/20260315_185401/prompts/batch-8.md +0 -84
- package/.desloppify/subagents/runs/20260315_185401/prompts/batch-9.md +0 -112
- package/.desloppify/subagents/runs/20260315_185401/results/batch-1.raw.txt +0 -0
- package/.desloppify/subagents/runs/20260315_185401/results/batch-10.raw.txt +0 -0
- package/.desloppify/subagents/runs/20260315_185401/results/batch-2.raw.txt +0 -0
- package/.desloppify/subagents/runs/20260315_185401/results/batch-3.raw.txt +0 -0
- package/.desloppify/subagents/runs/20260315_185401/results/batch-4.raw.txt +0 -0
- package/.desloppify/subagents/runs/20260315_185401/results/batch-5.raw.txt +0 -0
- package/.desloppify/subagents/runs/20260315_185401/results/batch-6.raw.txt +0 -0
- package/.desloppify/subagents/runs/20260315_185401/results/batch-7.raw.txt +0 -0
- package/.desloppify/subagents/runs/20260315_185401/results/batch-8.raw.txt +0 -0
- package/.desloppify/subagents/runs/20260315_185401/results/batch-9.raw.txt +0 -0
- package/.desloppify/subagents/runs/20260315_185401/run.log +0 -36
- package/.desloppify/subagents/runs/20260315_185401/run_summary.json +0 -156
- package/.desloppify/subagents/runs/20260315_185613/holistic_findings_merged.json +0 -741
- package/.desloppify/subagents/runs/20260315_185613/logs/batch-1.log +0 -579
- package/.desloppify/subagents/runs/20260315_185613/logs/batch-10.log +0 -1537
- package/.desloppify/subagents/runs/20260315_185613/logs/batch-2.log +0 -829
- package/.desloppify/subagents/runs/20260315_185613/logs/batch-3.log +0 -927
- package/.desloppify/subagents/runs/20260315_185613/logs/batch-4.log +0 -429
- package/.desloppify/subagents/runs/20260315_185613/logs/batch-5.log +0 -276
- package/.desloppify/subagents/runs/20260315_185613/logs/batch-6.log +0 -450
- package/.desloppify/subagents/runs/20260315_185613/logs/batch-7.log +0 -730
- package/.desloppify/subagents/runs/20260315_185613/logs/batch-8.log +0 -698
- package/.desloppify/subagents/runs/20260315_185613/logs/batch-9.log +0 -938
- package/.desloppify/subagents/runs/20260315_185613/prompts/batch-1.md +0 -83
- package/.desloppify/subagents/runs/20260315_185613/prompts/batch-10.md +0 -108
- package/.desloppify/subagents/runs/20260315_185613/prompts/batch-2.md +0 -89
- package/.desloppify/subagents/runs/20260315_185613/prompts/batch-3.md +0 -91
- package/.desloppify/subagents/runs/20260315_185613/prompts/batch-4.md +0 -77
- package/.desloppify/subagents/runs/20260315_185613/prompts/batch-5.md +0 -77
- package/.desloppify/subagents/runs/20260315_185613/prompts/batch-6.md +0 -78
- package/.desloppify/subagents/runs/20260315_185613/prompts/batch-7.md +0 -94
- package/.desloppify/subagents/runs/20260315_185613/prompts/batch-8.md +0 -84
- package/.desloppify/subagents/runs/20260315_185613/prompts/batch-9.md +0 -112
- package/.desloppify/subagents/runs/20260315_185613/results/batch-1.raw.txt +0 -78
- package/.desloppify/subagents/runs/20260315_185613/results/batch-10.raw.txt +0 -242
- package/.desloppify/subagents/runs/20260315_185613/results/batch-2.raw.txt +0 -102
- package/.desloppify/subagents/runs/20260315_185613/results/batch-3.raw.txt +0 -94
- package/.desloppify/subagents/runs/20260315_185613/results/batch-4.raw.txt +0 -86
- package/.desloppify/subagents/runs/20260315_185613/results/batch-5.raw.txt +0 -1
- package/.desloppify/subagents/runs/20260315_185613/results/batch-6.raw.txt +0 -87
- package/.desloppify/subagents/runs/20260315_185613/results/batch-7.raw.txt +0 -1
- package/.desloppify/subagents/runs/20260315_185613/results/batch-8.raw.txt +0 -107
- package/.desloppify/subagents/runs/20260315_185613/results/batch-9.raw.txt +0 -67
- package/.desloppify/subagents/runs/20260315_185613/run.log +0 -96
- package/.desloppify/subagents/runs/20260315_185613/run_summary.json +0 -156
- package/.editorconfig +0 -12
- package/.github/dependabot.yml +0 -11
- package/.github/workflows/docs.yml +0 -46
- package/.github/workflows/test.yml +0 -40
- package/.markdownlint.jsonc +0 -11
- package/.node-version +0 -1
- package/.oxfmtrc.json +0 -9
- package/.oxlintrc.json +0 -35
- package/docs/ARCHITECTURE.md +0 -125
- package/scorecard.png +0 -0
- package/src/cli/cli.ts +0 -141
- package/src/cli/validators.ts +0 -68
- package/src/formats/anthropic/index.ts +0 -14
- package/src/formats/anthropic/parse.ts +0 -67
- package/src/formats/anthropic/schema.ts +0 -74
- package/src/formats/anthropic/serialize.ts +0 -179
- package/src/formats/openai/chat-completions/index.ts +0 -14
- package/src/formats/openai/chat-completions/parse.ts +0 -44
- package/src/formats/openai/chat-completions/schema.ts +0 -92
- package/src/formats/openai/chat-completions/serialize.ts +0 -146
- package/src/formats/openai/responses/index.ts +0 -14
- package/src/formats/openai/responses/parse.ts +0 -70
- package/src/formats/openai/responses/schema.ts +0 -86
- package/src/formats/openai/responses/serialize.ts +0 -332
- package/src/formats/request-helpers.ts +0 -56
- package/src/formats/serialize-helpers.ts +0 -43
- package/src/formats/types.ts +0 -26
- package/src/history.ts +0 -70
- package/src/index.ts +0 -46
- package/src/loader.ts +0 -246
- package/src/logger.ts +0 -70
- package/src/mock-server.ts +0 -203
- package/src/route-handler.ts +0 -144
- package/src/rule-builder.ts +0 -73
- package/src/rule-engine.ts +0 -165
- package/src/sse-writer.ts +0 -35
- package/src/types/reply.ts +0 -92
- package/src/types/request.ts +0 -56
- package/src/types/rule.ts +0 -125
- package/src/types.ts +0 -24
- package/test/cli-validators.test.ts +0 -151
- package/test/formats/anthropic.test.ts +0 -336
- package/test/formats/openai.test.ts +0 -316
- package/test/formats/parse-helpers.test.ts +0 -315
- package/test/formats/responses.test.ts +0 -380
- package/test/helpers/make-req.ts +0 -18
- package/test/history.test.ts +0 -361
- package/test/loader.test.ts +0 -333
- package/test/logger.test.ts +0 -344
- package/test/mock-server.test.ts +0 -619
- package/test/rule-engine.test.ts +0 -229
- package/tsconfig.json +0 -26
- package/tsconfig.test.json +0 -11
- package/typedoc.json +0 -9
- package/vitest.config.ts +0 -18
|
@@ -1,450 +0,0 @@
|
|
|
1
|
-
ATTEMPT 1/3
|
|
2
|
-
$ codex exec --ephemeral -C /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server -s workspace-write -c approval_policy="never" -c model_reasoning_effort="low" -o /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server/.desloppify/subagents/runs/20260315_185613/results/batch-6.raw.txt You are a focused subagent reviewer for a single holistic investigation batch.
|
|
3
|
-
|
|
4
|
-
Repository root: /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server
|
|
5
|
-
Blind packet: /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server/.desloppify/review_packet_blind.json
|
|
6
|
-
Batch index: 6
|
|
7
|
-
Batch name: AI Debt & Migrations
|
|
8
|
-
Batch dimensions: ai_generated_debt, incomplete_migration, low_level_elegance
|
|
9
|
-
Batch rationale: AI-generated patterns, deprecated markers, migration TODOs
|
|
10
|
-
|
|
11
|
-
Files assigned:
|
|
12
|
-
- src/types/request.ts
|
|
13
|
-
- src/types/rule.ts
|
|
14
|
-
|
|
15
|
-
Task requirements:
|
|
16
|
-
1. Read the blind packet and follow `system_prompt` constraints exactly.
|
|
17
|
-
1a. If previously flagged issues are listed above, use them as context for your review.
|
|
18
|
-
Verify whether each still applies to the current code. Do not re-report fixed or
|
|
19
|
-
wontfix issues. Use them as starting points to look deeper — inspect adjacent code
|
|
20
|
-
and related modules for defects the prior review may have missed.
|
|
21
|
-
1c. Think structurally: when you spot multiple individual issues that share a common
|
|
22
|
-
root cause (missing abstraction, duplicated pattern, inconsistent convention),
|
|
23
|
-
explain the deeper structural issue in the finding, not just the surface symptom.
|
|
24
|
-
If the pattern is significant enough, report the structural issue as its own finding
|
|
25
|
-
with appropriate fix_scope ('multi_file_refactor' or 'architectural_change') and
|
|
26
|
-
use `root_cause_cluster` to connect related symptom findings together.
|
|
27
|
-
2. Evaluate ONLY listed files and ONLY listed dimensions for this batch.
|
|
28
|
-
3. Return 0-10 high-quality findings for this batch (empty array allowed).
|
|
29
|
-
3a. Do not suppress real defects to keep scores high; report every material issue you can support with evidence.
|
|
30
|
-
3b. Do not default to 100. Reserve 100 for genuinely exemplary evidence in this batch.
|
|
31
|
-
4. Score/finding consistency is required: broader or more severe findings MUST lower dimension scores.
|
|
32
|
-
4a. Any dimension scored below 85.0 MUST include explicit feedback: add at least one finding with the same `dimension` and a non-empty actionable `suggestion`.
|
|
33
|
-
5. Every finding must include `related_files` with at least 2 files when possible.
|
|
34
|
-
6. Every finding must include `dimension`, `identifier`, `summary`, `evidence`, `suggestion`, and `confidence`.
|
|
35
|
-
7. Every finding must include `impact_scope` and `fix_scope`.
|
|
36
|
-
8. Every scored dimension MUST include dimension_notes with concrete evidence.
|
|
37
|
-
9. If a dimension score is >85.0, include `issues_preventing_higher_score` in dimension_notes.
|
|
38
|
-
10. Use exactly one decimal place for every assessment and abstraction sub-axis score.
|
|
39
|
-
11. Ignore prior chat context and any target-threshold assumptions.
|
|
40
|
-
12. Do not edit repository files.
|
|
41
|
-
13. Return ONLY valid JSON, no markdown fences.
|
|
42
|
-
|
|
43
|
-
Scope enums:
|
|
44
|
-
- impact_scope: "local" | "module" | "subsystem" | "codebase"
|
|
45
|
-
- fix_scope: "single_edit" | "multi_file_refactor" | "architectural_change"
|
|
46
|
-
|
|
47
|
-
Output schema:
|
|
48
|
-
{
|
|
49
|
-
"batch": "AI Debt & Migrations",
|
|
50
|
-
"batch_index": 6,
|
|
51
|
-
"assessments": {"<dimension>": <0-100 with one decimal place>},
|
|
52
|
-
"dimension_notes": {
|
|
53
|
-
"<dimension>": {
|
|
54
|
-
"evidence": ["specific code observations"],
|
|
55
|
-
"impact_scope": "local|module|subsystem|codebase",
|
|
56
|
-
"fix_scope": "single_edit|multi_file_refactor|architectural_change",
|
|
57
|
-
"confidence": "high|medium|low",
|
|
58
|
-
"issues_preventing_higher_score": "required when score >85.0",
|
|
59
|
-
"sub_axes": {"abstraction_leverage": 0-100 with one decimal place, "indirection_cost": 0-100 with one decimal place, "interface_honesty": 0-100 with one decimal place} // required for abstraction_fitness when evidence supports it
|
|
60
|
-
}
|
|
61
|
-
},
|
|
62
|
-
"findings": [{
|
|
63
|
-
"dimension": "<dimension>",
|
|
64
|
-
"identifier": "short_id",
|
|
65
|
-
"summary": "one-line defect summary",
|
|
66
|
-
"related_files": ["relative/path.py"],
|
|
67
|
-
"evidence": ["specific code observation"],
|
|
68
|
-
"suggestion": "concrete fix recommendation",
|
|
69
|
-
"confidence": "high|medium|low",
|
|
70
|
-
"impact_scope": "local|module|subsystem|codebase",
|
|
71
|
-
"fix_scope": "single_edit|multi_file_refactor|architectural_change",
|
|
72
|
-
"root_cause_cluster": "optional_cluster_name_when_supported_by_history"
|
|
73
|
-
}],
|
|
74
|
-
"retrospective": {
|
|
75
|
-
"root_causes": ["optional: concise root-cause hypotheses"],
|
|
76
|
-
"likely_symptoms": ["optional: identifiers that look symptom-level"],
|
|
77
|
-
"possible_false_positives": ["optional: prior concept keys likely mis-scoped"]
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
STDOUT:
|
|
83
|
-
{
|
|
84
|
-
"batch": "AI Debt & Migrations",
|
|
85
|
-
"batch_index": 6,
|
|
86
|
-
"assessments": {
|
|
87
|
-
"ai_generated_debt": 90.0,
|
|
88
|
-
"incomplete_migration": 95.0,
|
|
89
|
-
"low_level_elegance": 88.0
|
|
90
|
-
},
|
|
91
|
-
"dimension_notes": {
|
|
92
|
-
"ai_generated_debt": {
|
|
93
|
-
"evidence": [
|
|
94
|
-
"src/types/request.ts uses multiple explanatory comments on self-describing fields (e.g., lastMessage/systemMessage/toolNames) that mostly restate the property name.",
|
|
95
|
-
"src/types/rule.ts has a long comment block on Match that largely repeats the union’s behavior (string/RegExp/object/function)."
|
|
96
|
-
],
|
|
97
|
-
"impact_scope": "local",
|
|
98
|
-
"fix_scope": "single_edit",
|
|
99
|
-
"confidence": "medium",
|
|
100
|
-
"issues_preventing_higher_score": "Several comments restate obvious field semantics and could be reduced to higher-signal notes only."
|
|
101
|
-
},
|
|
102
|
-
"incomplete_migration": {
|
|
103
|
-
"evidence": [
|
|
104
|
-
"No @deprecated markers, migration TODOs, or legacy/new dual-path APIs appear in src/types/request.ts.",
|
|
105
|
-
"No @deprecated markers, migration TODOs, or legacy/new dual-path APIs appear in src/types/rule.ts."
|
|
106
|
-
],
|
|
107
|
-
"impact_scope": "local",
|
|
108
|
-
"fix_scope": "single_edit",
|
|
109
|
-
"confidence": "low",
|
|
110
|
-
"issues_preventing_higher_score": "Small surface area limits certainty; no migration residue observed in the reviewed files."
|
|
111
|
-
},
|
|
112
|
-
"low_level_elegance": {
|
|
113
|
-
"evidence": [
|
|
114
|
-
"src/types/request.ts uses optional properties with explicit `| undefined` (e.g., tools?: readonly ToolDef[] | undefined; toolCallId?: string | undefined).",
|
|
115
|
-
"src/types/rule.ts uses optional properties without explicit `| undefined` (e.g., message?: string | RegExp; toolCallId?: string), creating inconsistent type style."
|
|
116
|
-
],
|
|
117
|
-
"impact_scope": "local",
|
|
118
|
-
"fix_scope": "single_edit",
|
|
119
|
-
"confidence": "high",
|
|
120
|
-
"issues_preventing_higher_score": "Inconsistent and redundant optional typing adds noise and small but repeated cognitive overhead."
|
|
121
|
-
}
|
|
122
|
-
},
|
|
123
|
-
"findings": [
|
|
124
|
-
{
|
|
125
|
-
"dimension": "ai_generated_debt",
|
|
126
|
-
"identifier": "restating_comments_on_types",
|
|
127
|
-
"summary": "Comments restate obvious type semantics, adding low-signal noise",
|
|
128
|
-
"related_files": [
|
|
129
|
-
"src/types/request.ts",
|
|
130
|
-
"src/types/rule.ts"
|
|
131
|
-
],
|
|
132
|
-
"evidence": [
|
|
133
|
-
"src/types/request.ts comments explain fields like lastMessage/systemMessage/toolNames in a way that mirrors the field name.",
|
|
134
|
-
"src/types/rule.ts Match comment block describes each union variant in a way that repeats the type definition."
|
|
135
|
-
],
|
|
136
|
-
"suggestion": "Trim comments to only convey non-obvious constraints or behavioral nuances; remove restatements of field names or type unions.",
|
|
137
|
-
"confidence": "medium",
|
|
138
|
-
"impact_scope": "local",
|
|
139
|
-
"fix_scope": "single_edit"
|
|
140
|
-
},
|
|
141
|
-
{
|
|
142
|
-
"dimension": "low_level_elegance",
|
|
143
|
-
"identifier": "redundant_optional_undefined",
|
|
144
|
-
"summary": "Optional fields redundantly include `| undefined`, creating inconsistency and noise",
|
|
145
|
-
"related_files": [
|
|
146
|
-
"src/types/request.ts",
|
|
147
|
-
"src/types/rule.ts"
|
|
148
|
-
],
|
|
149
|
-
"evidence": [
|
|
150
|
-
"src/types/request.ts declares `tools?: readonly ToolDef[] | undefined` and `toolCallId?: string | undefined`, which are already implied by `?`.",
|
|
151
|
-
"src/types/rule.ts uses `?:` without explicit `| undefined`, so the style is inconsistent across related type modules."
|
|
152
|
-
],
|
|
153
|
-
"suggestion": "Remove explicit `| undefined` from optional properties in src/types/request.ts to align with TypeScript conventions and the style used in src/types/rule.ts.",
|
|
154
|
-
"confidence": "high",
|
|
155
|
-
"impact_scope": "local",
|
|
156
|
-
"fix_scope": "single_edit"
|
|
157
|
-
}
|
|
158
|
-
],
|
|
159
|
-
"retrospective": {
|
|
160
|
-
"root_causes": [
|
|
161
|
-
"Documentation and type style appear auto-generated or copied without consolidation, leading to minor noise."
|
|
162
|
-
],
|
|
163
|
-
"likely_symptoms": [
|
|
164
|
-
"restating_comments_on_types",
|
|
165
|
-
"redundant_optional_undefined"
|
|
166
|
-
],
|
|
167
|
-
"possible_false_positives": []
|
|
168
|
-
}
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
STDERR:
|
|
173
|
-
OpenAI Codex v0.114.0 (research preview)
|
|
174
|
-
--------
|
|
175
|
-
workdir: /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server
|
|
176
|
-
model: gpt-5.2-codex
|
|
177
|
-
provider: openai
|
|
178
|
-
approval: never
|
|
179
|
-
sandbox: workspace-write [workdir, /tmp, $TMPDIR, /Users/suyash.x.srijan/.codex/memories]
|
|
180
|
-
reasoning effort: low
|
|
181
|
-
reasoning summaries: none
|
|
182
|
-
session id: 019cf2e0-dd32-7080-9e35-bf2f18d59585
|
|
183
|
-
--------
|
|
184
|
-
user
|
|
185
|
-
You are a focused subagent reviewer for a single holistic investigation batch.
|
|
186
|
-
|
|
187
|
-
Repository root: /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server
|
|
188
|
-
Blind packet: /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server/.desloppify/review_packet_blind.json
|
|
189
|
-
Batch index: 6
|
|
190
|
-
Batch name: AI Debt & Migrations
|
|
191
|
-
Batch dimensions: ai_generated_debt, incomplete_migration, low_level_elegance
|
|
192
|
-
Batch rationale: AI-generated patterns, deprecated markers, migration TODOs
|
|
193
|
-
|
|
194
|
-
Files assigned:
|
|
195
|
-
- src/types/request.ts
|
|
196
|
-
- src/types/rule.ts
|
|
197
|
-
|
|
198
|
-
Task requirements:
|
|
199
|
-
1. Read the blind packet and follow `system_prompt` constraints exactly.
|
|
200
|
-
1a. If previously flagged issues are listed above, use them as context for your review.
|
|
201
|
-
Verify whether each still applies to the current code. Do not re-report fixed or
|
|
202
|
-
wontfix issues. Use them as starting points to look deeper — inspect adjacent code
|
|
203
|
-
and related modules for defects the prior review may have missed.
|
|
204
|
-
1c. Think structurally: when you spot multiple individual issues that share a common
|
|
205
|
-
root cause (missing abstraction, duplicated pattern, inconsistent convention),
|
|
206
|
-
explain the deeper structural issue in the finding, not just the surface symptom.
|
|
207
|
-
If the pattern is significant enough, report the structural issue as its own finding
|
|
208
|
-
with appropriate fix_scope ('multi_file_refactor' or 'architectural_change') and
|
|
209
|
-
use `root_cause_cluster` to connect related symptom findings together.
|
|
210
|
-
2. Evaluate ONLY listed files and ONLY listed dimensions for this batch.
|
|
211
|
-
3. Return 0-10 high-quality findings for this batch (empty array allowed).
|
|
212
|
-
3a. Do not suppress real defects to keep scores high; report every material issue you can support with evidence.
|
|
213
|
-
3b. Do not default to 100. Reserve 100 for genuinely exemplary evidence in this batch.
|
|
214
|
-
4. Score/finding consistency is required: broader or more severe findings MUST lower dimension scores.
|
|
215
|
-
4a. Any dimension scored below 85.0 MUST include explicit feedback: add at least one finding with the same `dimension` and a non-empty actionable `suggestion`.
|
|
216
|
-
5. Every finding must include `related_files` with at least 2 files when possible.
|
|
217
|
-
6. Every finding must include `dimension`, `identifier`, `summary`, `evidence`, `suggestion`, and `confidence`.
|
|
218
|
-
7. Every finding must include `impact_scope` and `fix_scope`.
|
|
219
|
-
8. Every scored dimension MUST include dimension_notes with concrete evidence.
|
|
220
|
-
9. If a dimension score is >85.0, include `issues_preventing_higher_score` in dimension_notes.
|
|
221
|
-
10. Use exactly one decimal place for every assessment and abstraction sub-axis score.
|
|
222
|
-
11. Ignore prior chat context and any target-threshold assumptions.
|
|
223
|
-
12. Do not edit repository files.
|
|
224
|
-
13. Return ONLY valid JSON, no markdown fences.
|
|
225
|
-
|
|
226
|
-
Scope enums:
|
|
227
|
-
- impact_scope: "local" | "module" | "subsystem" | "codebase"
|
|
228
|
-
- fix_scope: "single_edit" | "multi_file_refactor" | "architectural_change"
|
|
229
|
-
|
|
230
|
-
Output schema:
|
|
231
|
-
{
|
|
232
|
-
"batch": "AI Debt & Migrations",
|
|
233
|
-
"batch_index": 6,
|
|
234
|
-
"assessments": {"<dimension>": <0-100 with one decimal place>},
|
|
235
|
-
"dimension_notes": {
|
|
236
|
-
"<dimension>": {
|
|
237
|
-
"evidence": ["specific code observations"],
|
|
238
|
-
"impact_scope": "local|module|subsystem|codebase",
|
|
239
|
-
"fix_scope": "single_edit|multi_file_refactor|architectural_change",
|
|
240
|
-
"confidence": "high|medium|low",
|
|
241
|
-
"issues_preventing_higher_score": "required when score >85.0",
|
|
242
|
-
"sub_axes": {"abstraction_leverage": 0-100 with one decimal place, "indirection_cost": 0-100 with one decimal place, "interface_honesty": 0-100 with one decimal place} // required for abstraction_fitness when evidence supports it
|
|
243
|
-
}
|
|
244
|
-
},
|
|
245
|
-
"findings": [{
|
|
246
|
-
"dimension": "<dimension>",
|
|
247
|
-
"identifier": "short_id",
|
|
248
|
-
"summary": "one-line defect summary",
|
|
249
|
-
"related_files": ["relative/path.py"],
|
|
250
|
-
"evidence": ["specific code observation"],
|
|
251
|
-
"suggestion": "concrete fix recommendation",
|
|
252
|
-
"confidence": "high|medium|low",
|
|
253
|
-
"impact_scope": "local|module|subsystem|codebase",
|
|
254
|
-
"fix_scope": "single_edit|multi_file_refactor|architectural_change",
|
|
255
|
-
"root_cause_cluster": "optional_cluster_name_when_supported_by_history"
|
|
256
|
-
}],
|
|
257
|
-
"retrospective": {
|
|
258
|
-
"root_causes": ["optional: concise root-cause hypotheses"],
|
|
259
|
-
"likely_symptoms": ["optional: identifiers that look symptom-level"],
|
|
260
|
-
"possible_false_positives": ["optional: prior concept keys likely mis-scoped"]
|
|
261
|
-
}
|
|
262
|
-
}
|
|
263
|
-
|
|
264
|
-
mcp startup: no servers
|
|
265
|
-
exec
|
|
266
|
-
/bin/zsh -lc ls in /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server succeeded in 0ms:
|
|
267
|
-
LICENCE
|
|
268
|
-
README.md
|
|
269
|
-
coverage
|
|
270
|
-
dist
|
|
271
|
-
docs
|
|
272
|
-
node_modules
|
|
273
|
-
package-lock.json
|
|
274
|
-
package.json
|
|
275
|
-
scorecard.png
|
|
276
|
-
src
|
|
277
|
-
test
|
|
278
|
-
tsconfig.json
|
|
279
|
-
tsconfig.test.json
|
|
280
|
-
vitest.config.ts
|
|
281
|
-
exec
|
|
282
|
-
/bin/zsh -lc 'cat /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server/.desloppify/review_packet_blind.json' in /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server succeeded in 0ms:
|
|
283
|
-
{
|
|
284
|
-
"command": "review",
|
|
285
|
-
"mode": "holistic",
|
|
286
|
-
"language": "typescript",
|
|
287
|
-
"dimensions": [
|
|
288
|
-
"cross_module_architecture",
|
|
289
|
-
"convention_outlier",
|
|
290
|
-
"error_consistency",
|
|
291
|
-
"abstraction_fitness",
|
|
292
|
-
"api_surface_coherence",
|
|
293
|
-
"authorization_consistency",
|
|
294
|
-
"ai_generated_debt",
|
|
295
|
-
"incomplete_migration",
|
|
296
|
-
"package_organization",
|
|
297
|
-
"high_level_elegance",
|
|
298
|
-
"mid_level_elegance",
|
|
299
|
-
"low_level_elegance",
|
|
300
|
-
"design_coherence"
|
|
301
|
-
],
|
|
302
|
-
"dimension_prompts": {
|
|
303
|
-
|
|
304
|
-
thinking
|
|
305
|
-
**Planning file reading with sed**
|
|
306
|
-
exec
|
|
307
|
-
/bin/zsh -lc "sed -n '1,260p' src/types/request.ts" in /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server succeeded in 0ms:
|
|
308
|
-
/** The LLM API wire format that was detected for a request. */
|
|
309
|
-
export type FormatName = "openai" | "anthropic" | "responses";
|
|
310
|
-
|
|
311
|
-
/** A normalised view of an incoming request, regardless of the original wire format. */
|
|
312
|
-
export interface MockRequest {
|
|
313
|
-
readonly format: FormatName;
|
|
314
|
-
readonly model: string;
|
|
315
|
-
readonly streaming: boolean;
|
|
316
|
-
/** Full conversation, normalised from whatever format came in. */
|
|
317
|
-
readonly messages: readonly Message[];
|
|
318
|
-
/** The last user message's text. This is what most matchers check. */
|
|
319
|
-
readonly lastMessage: string;
|
|
320
|
-
/** Empty string if there wasn't one. */
|
|
321
|
-
readonly systemMessage: string;
|
|
322
|
-
readonly tools?: readonly ToolDef[] | undefined;
|
|
323
|
-
/** Pulled out from `tools` for quick lookups. */
|
|
324
|
-
readonly toolNames: readonly string[];
|
|
325
|
-
/** Set when the last message was a tool result. */
|
|
326
|
-
readonly lastToolCallId: string | undefined;
|
|
327
|
-
/** The raw request body, for anything we don't extract. */
|
|
328
|
-
exec
|
|
329
|
-
/bin/zsh -lc "sed -n '1,260p' src/types/rule.ts" in /Users/suyash.x.srijan/Documents/Personal_Projects/llm-mock-server succeeded in 0ms:
|
|
330
|
-
import type { MockRequest, FormatName } from "./request.js";
|
|
331
|
-
import type { Resolver, ReplyOptions, Reply, SequenceEntry } from "./reply.js";
|
|
332
|
-
|
|
333
|
-
/**
|
|
334
|
-
* Determines whether a rule matches an incoming request.
|
|
335
|
-
*
|
|
336
|
-
* A `string` does a case-insensitive substring match on the last user message.
|
|
337
|
-
* A `RegExp` gets tested against the last user message.
|
|
338
|
-
* A `MatchObject` checks multiple fields at once with AND logic.
|
|
339
|
-
* A function receives the normalised request and returns a boolean.
|
|
340
|
-
*/
|
|
341
|
-
export type Match =
|
|
342
|
-
| string
|
|
343
|
-
| RegExp
|
|
344
|
-
| MatchObject
|
|
345
|
-
| ((req: MockRequest) => boolean);
|
|
346
|
-
|
|
347
|
-
/** A structured matcher. Every field you set must match for the rule to fire. */
|
|
348
|
-
export interface MatchObject {
|
|
349
|
-
readonly message?: string | RegExp;
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
thinking
|
|
353
|
-
**Evaluating specific files for defects**
|
|
354
|
-
|
|
355
|
-
I've found no deprecated markers or clear defects in the three files but identified minor inconsistencies like non-readonly properties in the Rule interface versus RuleSummary. To avoid defaulting to perfect scores, I'll assign high but not perfect scores (e.g., 95) with evidence noting minor issues or limited scope preventing higher ratings.
|
|
356
|
-
thinking
|
|
357
|
-
**Identifying concrete findings per dimension**
|
|
358
|
-
|
|
359
|
-
I'm pinpointing actionable findings: AI debt involves verbose, restating comments across request.ts and rule.ts; low-level elegance includes redundant `| undefined` in request.ts plus inconsistent optional field styles between request.ts and rule.ts; incomplete migration has no deprecation or migration markers but will note limited scope. Scores will reflect these with justified evidence and related files where possible.
|
|
360
|
-
codex
|
|
361
|
-
{
|
|
362
|
-
"batch": "AI Debt & Migrations",
|
|
363
|
-
"batch_index": 6,
|
|
364
|
-
"assessments": {
|
|
365
|
-
"ai_generated_debt": 90.0,
|
|
366
|
-
"incomplete_migration": 95.0,
|
|
367
|
-
"low_level_elegance": 88.0
|
|
368
|
-
},
|
|
369
|
-
"dimension_notes": {
|
|
370
|
-
"ai_generated_debt": {
|
|
371
|
-
"evidence": [
|
|
372
|
-
"src/types/request.ts uses multiple explanatory comments on self-describing fields (e.g., lastMessage/systemMessage/toolNames) that mostly restate the property name.",
|
|
373
|
-
"src/types/rule.ts has a long comment block on Match that largely repeats the union’s behavior (string/RegExp/object/function)."
|
|
374
|
-
],
|
|
375
|
-
"impact_scope": "local",
|
|
376
|
-
"fix_scope": "single_edit",
|
|
377
|
-
"confidence": "medium",
|
|
378
|
-
"issues_preventing_higher_score": "Several comments restate obvious field semantics and could be reduced to higher-signal notes only."
|
|
379
|
-
},
|
|
380
|
-
"incomplete_migration": {
|
|
381
|
-
"evidence": [
|
|
382
|
-
"No @deprecated markers, migration TODOs, or legacy/new dual-path APIs appear in src/types/request.ts.",
|
|
383
|
-
"No @deprecated markers, migration TODOs, or legacy/new dual-path APIs appear in src/types/rule.ts."
|
|
384
|
-
],
|
|
385
|
-
"impact_scope": "local",
|
|
386
|
-
"fix_scope": "single_edit",
|
|
387
|
-
"confidence": "low",
|
|
388
|
-
"issues_preventing_higher_score": "Small surface area limits certainty; no migration residue observed in the reviewed files."
|
|
389
|
-
},
|
|
390
|
-
"low_level_elegance": {
|
|
391
|
-
"evidence": [
|
|
392
|
-
"src/types/request.ts uses optional properties with explicit `| undefined` (e.g., tools?: readonly ToolDef[] | undefined; toolCallId?: string | undefined).",
|
|
393
|
-
"src/types/rule.ts uses optional properties without explicit `| undefined` (e.g., message?: string | RegExp; toolCallId?: string), creating inconsistent type style."
|
|
394
|
-
],
|
|
395
|
-
"impact_scope": "local",
|
|
396
|
-
"fix_scope": "single_edit",
|
|
397
|
-
"confidence": "high",
|
|
398
|
-
"issues_preventing_higher_score": "Inconsistent and redundant optional typing adds noise and small but repeated cognitive overhead."
|
|
399
|
-
}
|
|
400
|
-
},
|
|
401
|
-
"findings": [
|
|
402
|
-
{
|
|
403
|
-
"dimension": "ai_generated_debt",
|
|
404
|
-
"identifier": "restating_comments_on_types",
|
|
405
|
-
"summary": "Comments restate obvious type semantics, adding low-signal noise",
|
|
406
|
-
"related_files": [
|
|
407
|
-
"src/types/request.ts",
|
|
408
|
-
"src/types/rule.ts"
|
|
409
|
-
],
|
|
410
|
-
"evidence": [
|
|
411
|
-
"src/types/request.ts comments explain fields like lastMessage/systemMessage/toolNames in a way that mirrors the field name.",
|
|
412
|
-
"src/types/rule.ts Match comment block describes each union variant in a way that repeats the type definition."
|
|
413
|
-
],
|
|
414
|
-
"suggestion": "Trim comments to only convey non-obvious constraints or behavioral nuances; remove restatements of field names or type unions.",
|
|
415
|
-
"confidence": "medium",
|
|
416
|
-
"impact_scope": "local",
|
|
417
|
-
"fix_scope": "single_edit"
|
|
418
|
-
},
|
|
419
|
-
{
|
|
420
|
-
"dimension": "low_level_elegance",
|
|
421
|
-
"identifier": "redundant_optional_undefined",
|
|
422
|
-
"summary": "Optional fields redundantly include `| undefined`, creating inconsistency and noise",
|
|
423
|
-
"related_files": [
|
|
424
|
-
"src/types/request.ts",
|
|
425
|
-
"src/types/rule.ts"
|
|
426
|
-
],
|
|
427
|
-
"evidence": [
|
|
428
|
-
"src/types/request.ts declares `tools?: readonly ToolDef[] | undefined` and `toolCallId?: string | undefined`, which are already implied by `?`.",
|
|
429
|
-
"src/types/rule.ts uses `?:` without explicit `| undefined`, so the style is inconsistent across related type modules."
|
|
430
|
-
],
|
|
431
|
-
"suggestion": "Remove explicit `| undefined` from optional properties in src/types/request.ts to align with TypeScript conventions and the style used in src/types/rule.ts.",
|
|
432
|
-
"confidence": "high",
|
|
433
|
-
"impact_scope": "local",
|
|
434
|
-
"fix_scope": "single_edit"
|
|
435
|
-
}
|
|
436
|
-
],
|
|
437
|
-
"retrospective": {
|
|
438
|
-
"root_causes": [
|
|
439
|
-
"Documentation and type style appear auto-generated or copied without consolidation, leading to minor noise."
|
|
440
|
-
],
|
|
441
|
-
"likely_symptoms": [
|
|
442
|
-
"restating_comments_on_types",
|
|
443
|
-
"redundant_optional_undefined"
|
|
444
|
-
],
|
|
445
|
-
"possible_false_positives": []
|
|
446
|
-
}
|
|
447
|
-
}
|
|
448
|
-
tokens used
|
|
449
|
-
23,406
|
|
450
|
-
|