uv-suite 0.10.0 → 0.12.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.
@@ -0,0 +1,50 @@
1
+ #!/bin/bash
2
+ # UV Suite Hook: Fast deterministic doc-slop check
3
+ # Event: PostToolUse (Write) — Spike persona
4
+ # Greps for vague adjectives and buzzwords in documentation files. No LLM.
5
+
6
+ INPUT=$(cat)
7
+ FILE_PATH=$(echo "$INPUT" | jq -r '.tool_input.file_path // empty')
8
+
9
+ if [ -z "$FILE_PATH" ] || [ ! -f "$FILE_PATH" ]; then
10
+ exit 0
11
+ fi
12
+
13
+ EXT="${FILE_PATH##*.}"
14
+
15
+ # Only check markdown and text files
16
+ case "$EXT" in
17
+ md|txt|rst|adoc) ;;
18
+ *) exit 0 ;;
19
+ esac
20
+
21
+ FINDINGS=""
22
+
23
+ # Vague adjectives that say nothing
24
+ MATCH=$(grep -in "robust\|scalable\|comprehensive\|extensible\|maintainable\|enterprise-grade\|battle-tested\|cutting-edge\|state-of-the-art" "$FILE_PATH" 2>/dev/null | head -3)
25
+ if [ -n "$MATCH" ]; then
26
+ FINDINGS="${FINDINGS}Vague adjectives — replace with specific facts: $(echo "$MATCH" | head -1 | sed 's/"/\\"/g'). "
27
+ fi
28
+
29
+ # Evasive verbs
30
+ MATCH=$(grep -in "leverages\|utilizes\|facilitates\|empowers\|enables seamless" "$FILE_PATH" 2>/dev/null | head -3)
31
+ if [ -n "$MATCH" ]; then
32
+ FINDINGS="${FINDINGS}Evasive verbs — say what it actually does: $(echo "$MATCH" | head -1 | sed 's/"/\\"/g'). "
33
+ fi
34
+
35
+ # Authority appeals without specifics
36
+ MATCH=$(grep -in "best practices\|industry-standard\|widely adopted\|production-ready" "$FILE_PATH" 2>/dev/null | head -3)
37
+ if [ -n "$MATCH" ]; then
38
+ FINDINGS="${FINDINGS}Name the specific practice instead of citing authority: $(echo "$MATCH" | head -1 | sed 's/"/\\"/g'). "
39
+ fi
40
+
41
+ if [ -n "$FINDINGS" ]; then
42
+ cat <<EOF
43
+ {
44
+ "continue": true,
45
+ "systemMessage": "Doc slop: ${FINDINGS}"
46
+ }
47
+ EOF
48
+ fi
49
+
50
+ exit 0
@@ -0,0 +1,49 @@
1
+ #!/bin/bash
2
+ # UV Suite Hook: Fast deterministic slop check
3
+ # Event: PostToolUse (Edit|Write)
4
+ # Greps for mechanical, unambiguous slop patterns. No LLM, no false positives.
5
+
6
+ INPUT=$(cat)
7
+ FILE_PATH=$(echo "$INPUT" | jq -r '.tool_input.file_path // empty')
8
+
9
+ if [ -z "$FILE_PATH" ] || [ ! -f "$FILE_PATH" ]; then
10
+ exit 0
11
+ fi
12
+
13
+ EXT="${FILE_PATH##*.}"
14
+ FINDINGS=""
15
+
16
+ case "$EXT" in
17
+ ts|tsx|js|jsx)
18
+ # toBeTruthy/toBeDefined in test files
19
+ if echo "$FILE_PATH" | grep -qE "\.(test|spec)\.(ts|tsx|js|jsx)$"; then
20
+ MATCH=$(grep -n "\.toBeTruthy()\|\.toBeDefined()" "$FILE_PATH" 2>/dev/null)
21
+ if [ -n "$MATCH" ]; then
22
+ FINDINGS="${FINDINGS}Weak assertion in $FILE_PATH: $MATCH. Test specific values instead. "
23
+ fi
24
+ fi
25
+ # catch-and-rethrow (catch { ...throw } with nothing meaningful between)
26
+ MATCH=$(grep -n "catch.*{" "$FILE_PATH" 2>/dev/null | head -3)
27
+ ;;
28
+ py)
29
+ # bare except: pass
30
+ MATCH=$(grep -n "except:$\|except Exception:$" "$FILE_PATH" 2>/dev/null)
31
+ if [ -n "$MATCH" ]; then
32
+ NEXT=$(grep -A1 "except" "$FILE_PATH" 2>/dev/null | grep -c "pass\|raise")
33
+ if [ "$NEXT" -gt 0 ]; then
34
+ FINDINGS="${FINDINGS}Bare except with pass/raise in $FILE_PATH. "
35
+ fi
36
+ fi
37
+ ;;
38
+ esac
39
+
40
+ if [ -n "$FINDINGS" ]; then
41
+ cat <<EOF
42
+ {
43
+ "continue": true,
44
+ "systemMessage": "Slop detected: ${FINDINGS}"
45
+ }
46
+ EOF
47
+ fi
48
+
49
+ exit 0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "uv-suite",
3
- "version": "0.10.0",
3
+ "version": "0.12.0",
4
4
  "description": "Portable framework for AI-assisted software development. 10 agents, 9 skills, 5 hooks, 4 personas. Works with Claude Code, Cursor, and Codex.",
5
5
  "author": "Utsav Anand",
6
6
  "license": "MIT",
@@ -105,11 +105,10 @@
105
105
  "statusMessage": "Auto-formatting..."
106
106
  },
107
107
  {
108
- "type": "prompt",
109
- "prompt": "Quickly scan the code that was just written or edited for the most obvious AI slop patterns: (1) comments that restate the code like '// Initialize the database' above initDatabase(), (2) try/catch around code that can't throw, (3) single-implementation interfaces or factories, (4) toBeTruthy()/toBeDefined() in tests. If you find any of these specific patterns, respond with {\"ok\": false, \"reason\": \"Slop detected: [specific finding with line reference]. Fix: [specific fix].\"} If the code is clean, respond with {\"ok\": true}. Only flag the most obvious violations — do not be overly strict.",
110
- "model": "claude-haiku-4-5",
111
- "timeout": 15,
112
- "statusMessage": "Checking for AI slop..."
108
+ "type": "command",
109
+ "command": "\"$CLAUDE_PROJECT_DIR\"/.claude/hooks/slop-grep.sh",
110
+ "timeout": 3,
111
+ "statusMessage": "Slop check..."
113
112
  }
114
113
  ]
115
114
  }
@@ -49,11 +49,10 @@
49
49
  "matcher": "Write",
50
50
  "hooks": [
51
51
  {
52
- "type": "prompt",
53
- "prompt": "The agent just wrote a documentation or analysis file. Check for documentation slop: (1) vague adjectives like 'robust', 'scalable', 'comprehensive', 'leverages', 'facilitates', (2) feature lists that could describe any system, (3) overview sections that don't say what the system actually does, (4) claims without specifics ('industry-standard best practices'). If you find slop, respond {\"ok\": false, \"reason\": \"Doc slop: [finding]. Fix: replace with specific facts.\"}. If clean, respond {\"ok\": true}.",
54
- "model": "claude-haiku-4-5",
55
- "timeout": 15,
56
- "statusMessage": "Checking documentation quality..."
52
+ "type": "command",
53
+ "command": "\"$CLAUDE_PROJECT_DIR\"/.claude/hooks/doc-slop-grep.sh",
54
+ "timeout": 3,
55
+ "statusMessage": "Doc quality check..."
57
56
  }
58
57
  ]
59
58
  }
package/settings.json CHANGED
@@ -82,11 +82,10 @@
82
82
  "statusMessage": "Auto-formatting..."
83
83
  },
84
84
  {
85
- "type": "prompt",
86
- "prompt": "Quickly scan the code that was just written or edited for the most obvious AI slop patterns: (1) comments that restate the code like '// Initialize the database' above initDatabase(), (2) try/catch around code that can't throw, (3) single-implementation interfaces or factories, (4) toBeTruthy()/toBeDefined() in tests. If you find any of these specific patterns, respond with {\"ok\": false, \"reason\": \"Slop detected: [specific finding with line reference]. Fix: [specific fix].\"} If the code is clean, respond with {\"ok\": true}. Only flag the most obvious violations — do not be overly strict.",
87
- "model": "claude-haiku-4-5",
88
- "timeout": 15,
89
- "statusMessage": "Checking for AI slop..."
85
+ "type": "command",
86
+ "command": "\"$CLAUDE_PROJECT_DIR\"/.claude/hooks/slop-grep.sh",
87
+ "timeout": 3,
88
+ "statusMessage": "Slop check..."
90
89
  }
91
90
  ]
92
91
  }