code-review-ai-cli 2.3.0__tar.gz → 2.5.0__tar.gz

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 (34) hide show
  1. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/PKG-INFO +12 -19
  2. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/README.md +8 -4
  3. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/code_review_ai_cli.egg-info/PKG-INFO +12 -19
  4. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/code_review_ai_cli.egg-info/requires.txt +0 -14
  5. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/pyproject.toml +4 -12
  6. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/src/ai_review.py +349 -198
  7. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/src/config.py +12 -12
  8. code_review_ai_cli-2.5.0/src/context_extractor.py +1730 -0
  9. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/src/formatter.py +92 -148
  10. code_review_ai_cli-2.5.0/src/git_utils.py +975 -0
  11. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/src/llm_client.py +46 -88
  12. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/src/prompts/config.yaml.template +7 -9
  13. code_review_ai_cli-2.5.0/src/prompts/review_prompt.md.template +89 -0
  14. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/src/tfs_client.py +120 -166
  15. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/tests/test_ai_review.py +143 -19
  16. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/tests/test_config.py +28 -8
  17. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/tests/test_context_extractor.py +221 -0
  18. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/tests/test_formatter.py +36 -85
  19. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/tests/test_git_utils.py +193 -30
  20. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/tests/test_llm_client.py +69 -49
  21. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/tests/test_tfs_client.py +51 -21
  22. code_review_ai_cli-2.3.0/src/context_extractor.py +0 -637
  23. code_review_ai_cli-2.3.0/src/git_utils.py +0 -628
  24. code_review_ai_cli-2.3.0/src/prompts/review_prompt.md.template +0 -21
  25. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/code_review_ai_cli.egg-info/SOURCES.txt +0 -0
  26. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/code_review_ai_cli.egg-info/dependency_links.txt +0 -0
  27. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/code_review_ai_cli.egg-info/entry_points.txt +0 -0
  28. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/code_review_ai_cli.egg-info/top_level.txt +0 -0
  29. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/setup.cfg +0 -0
  30. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/src/__init__.py +0 -0
  31. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/src/prompt_utils.py +0 -0
  32. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/src/token_estimator.py +0 -0
  33. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/tests/test_prompt_utils.py +0 -0
  34. {code_review_ai_cli-2.3.0 → code_review_ai_cli-2.5.0}/tests/test_token_estimator.py +0 -0
@@ -1,13 +1,13 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: code-review-ai-cli
3
- Version: 2.3.0
3
+ Version: 2.5.0
4
4
  Summary: Automated AI-powered code review CLI for Azure DevOps / TFS Pull Requests
5
- License: MIT
6
- Keywords: code-review,ai,azure-devops,tfs,pull-request,llm
5
+ License: Apache-2.0
6
+ Keywords: code-review,ai,azure-devops,tfs,pull-request,git,llm
7
7
  Classifier: Development Status :: 4 - Beta
8
8
  Classifier: Environment :: Console
9
9
  Classifier: Intended Audience :: Developers
10
- Classifier: License :: OSI Approved :: MIT License
10
+ Classifier: License :: OSI Approved :: Apache Software License
11
11
  Classifier: Programming Language :: Python :: 3
12
12
  Classifier: Programming Language :: Python :: 3.10
13
13
  Classifier: Programming Language :: Python :: 3.11
@@ -23,19 +23,8 @@ Requires-Dist: tree-sitter<0.22,>=0.20
23
23
  Requires-Dist: tree-sitter-languages>=1.10.2
24
24
  Provides-Extra: bedrock
25
25
  Requires-Dist: boto3>=1.34.0; extra == "bedrock"
26
- Provides-Extra: openai
27
- Requires-Dist: openai>=1.0.0; extra == "openai"
28
- Provides-Extra: gemini
29
- Requires-Dist: google-generativeai>=0.3.0; extra == "gemini"
30
- Provides-Extra: claude
31
- Requires-Dist: anthropic>=0.18.0; extra == "claude"
32
26
  Provides-Extra: all
33
27
  Requires-Dist: boto3>=1.34.0; extra == "all"
34
- Requires-Dist: litellm>=1.40.0; extra == "all"
35
- Requires-Dist: tiktoken>=0.7.0; extra == "all"
36
- Requires-Dist: openai>=1.0.0; extra == "all"
37
- Requires-Dist: google-generativeai>=0.3.0; extra == "all"
38
- Requires-Dist: anthropic>=0.18.0; extra == "all"
39
28
  Provides-Extra: dev
40
29
  Requires-Dist: pytest>=8.3.0; extra == "dev"
41
30
  Requires-Dist: pytest-cov>=5.0.0; extra == "dev"
@@ -49,6 +38,9 @@ AI Code Review is an automated AI-powered code review CLI, compatible with vario
49
38
 
50
39
  - AI Pull Request review (`pr-review`)
51
40
  - Local Git review without a PR (`local` / `local-review` — working tree, `--staged`, `--from <branch>`, `--commit <sha>`)
41
+ - **Full Code Scan (`full-code-scan`)**: on-demand static quality and security audit of files, folders, or glob patterns without requiring a Git diff or PR
42
+ - **Smart File Bundling**: groups related files (interfaces, implementations, unit tests, i18n pairs, and domain folders) into cohesive bundles (`max_files_per_bundle`) so large changesets are reviewed completely without context degradation
43
+ - **Deterministic Cross-File Symbol Resolution**: resolves compact signatures and type declarations (`<referenced_symbols>`) via Tree-sitter across PR/local changesets and relative/sibling imports (`max_referenced_symbols`)
52
44
  - Structured PR comments (inline + general summary)
53
45
  - `dry-run` mode to validate without posting
54
46
  - PR listing with filters (`list-prs`)
@@ -73,7 +65,7 @@ AI Code Review is an automated AI-powered code review CLI, compatible with vario
73
65
  ## Installation
74
66
 
75
67
  Install from PyPI:
76
- s
68
+
77
69
  ```bash
78
70
  pip install code-review-ai-cli
79
71
  ```
@@ -122,12 +114,13 @@ tfs:
122
114
 
123
115
  review:
124
116
  verbosity: detailed
125
- scope: diff_only
126
117
  custom_prompt_file: review_prompt.md
127
- # file limit sent to the LLM
128
- max_diff_files: 50
118
+ # maximum related files grouped per LLM review bundle (Smart File Bundling)
119
+ max_files_per_bundle: 5
129
120
  # per-file limit
130
121
  max_diff_lines: 2000
122
+ # cross-file symbol declarations resolved per file (0 = disabled)
123
+ max_referenced_symbols: 10
131
124
  # extension allowlist (empty list = all files)
132
125
  file_extensions_filter: [".cs", ".ts", ".py"]
133
126
  # exclude path prefixes from the diff (applied before file_extensions_filter)
@@ -6,6 +6,9 @@ AI Code Review is an automated AI-powered code review CLI, compatible with vario
6
6
 
7
7
  - AI Pull Request review (`pr-review`)
8
8
  - Local Git review without a PR (`local` / `local-review` — working tree, `--staged`, `--from <branch>`, `--commit <sha>`)
9
+ - **Full Code Scan (`full-code-scan`)**: on-demand static quality and security audit of files, folders, or glob patterns without requiring a Git diff or PR
10
+ - **Smart File Bundling**: groups related files (interfaces, implementations, unit tests, i18n pairs, and domain folders) into cohesive bundles (`max_files_per_bundle`) so large changesets are reviewed completely without context degradation
11
+ - **Deterministic Cross-File Symbol Resolution**: resolves compact signatures and type declarations (`<referenced_symbols>`) via Tree-sitter across PR/local changesets and relative/sibling imports (`max_referenced_symbols`)
9
12
  - Structured PR comments (inline + general summary)
10
13
  - `dry-run` mode to validate without posting
11
14
  - PR listing with filters (`list-prs`)
@@ -30,7 +33,7 @@ AI Code Review is an automated AI-powered code review CLI, compatible with vario
30
33
  ## Installation
31
34
 
32
35
  Install from PyPI:
33
- s
36
+
34
37
  ```bash
35
38
  pip install code-review-ai-cli
36
39
  ```
@@ -79,12 +82,13 @@ tfs:
79
82
 
80
83
  review:
81
84
  verbosity: detailed
82
- scope: diff_only
83
85
  custom_prompt_file: review_prompt.md
84
- # file limit sent to the LLM
85
- max_diff_files: 50
86
+ # maximum related files grouped per LLM review bundle (Smart File Bundling)
87
+ max_files_per_bundle: 5
86
88
  # per-file limit
87
89
  max_diff_lines: 2000
90
+ # cross-file symbol declarations resolved per file (0 = disabled)
91
+ max_referenced_symbols: 10
88
92
  # extension allowlist (empty list = all files)
89
93
  file_extensions_filter: [".cs", ".ts", ".py"]
90
94
  # exclude path prefixes from the diff (applied before file_extensions_filter)
@@ -1,13 +1,13 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: code-review-ai-cli
3
- Version: 2.3.0
3
+ Version: 2.5.0
4
4
  Summary: Automated AI-powered code review CLI for Azure DevOps / TFS Pull Requests
5
- License: MIT
6
- Keywords: code-review,ai,azure-devops,tfs,pull-request,llm
5
+ License: Apache-2.0
6
+ Keywords: code-review,ai,azure-devops,tfs,pull-request,git,llm
7
7
  Classifier: Development Status :: 4 - Beta
8
8
  Classifier: Environment :: Console
9
9
  Classifier: Intended Audience :: Developers
10
- Classifier: License :: OSI Approved :: MIT License
10
+ Classifier: License :: OSI Approved :: Apache Software License
11
11
  Classifier: Programming Language :: Python :: 3
12
12
  Classifier: Programming Language :: Python :: 3.10
13
13
  Classifier: Programming Language :: Python :: 3.11
@@ -23,19 +23,8 @@ Requires-Dist: tree-sitter<0.22,>=0.20
23
23
  Requires-Dist: tree-sitter-languages>=1.10.2
24
24
  Provides-Extra: bedrock
25
25
  Requires-Dist: boto3>=1.34.0; extra == "bedrock"
26
- Provides-Extra: openai
27
- Requires-Dist: openai>=1.0.0; extra == "openai"
28
- Provides-Extra: gemini
29
- Requires-Dist: google-generativeai>=0.3.0; extra == "gemini"
30
- Provides-Extra: claude
31
- Requires-Dist: anthropic>=0.18.0; extra == "claude"
32
26
  Provides-Extra: all
33
27
  Requires-Dist: boto3>=1.34.0; extra == "all"
34
- Requires-Dist: litellm>=1.40.0; extra == "all"
35
- Requires-Dist: tiktoken>=0.7.0; extra == "all"
36
- Requires-Dist: openai>=1.0.0; extra == "all"
37
- Requires-Dist: google-generativeai>=0.3.0; extra == "all"
38
- Requires-Dist: anthropic>=0.18.0; extra == "all"
39
28
  Provides-Extra: dev
40
29
  Requires-Dist: pytest>=8.3.0; extra == "dev"
41
30
  Requires-Dist: pytest-cov>=5.0.0; extra == "dev"
@@ -49,6 +38,9 @@ AI Code Review is an automated AI-powered code review CLI, compatible with vario
49
38
 
50
39
  - AI Pull Request review (`pr-review`)
51
40
  - Local Git review without a PR (`local` / `local-review` — working tree, `--staged`, `--from <branch>`, `--commit <sha>`)
41
+ - **Full Code Scan (`full-code-scan`)**: on-demand static quality and security audit of files, folders, or glob patterns without requiring a Git diff or PR
42
+ - **Smart File Bundling**: groups related files (interfaces, implementations, unit tests, i18n pairs, and domain folders) into cohesive bundles (`max_files_per_bundle`) so large changesets are reviewed completely without context degradation
43
+ - **Deterministic Cross-File Symbol Resolution**: resolves compact signatures and type declarations (`<referenced_symbols>`) via Tree-sitter across PR/local changesets and relative/sibling imports (`max_referenced_symbols`)
52
44
  - Structured PR comments (inline + general summary)
53
45
  - `dry-run` mode to validate without posting
54
46
  - PR listing with filters (`list-prs`)
@@ -73,7 +65,7 @@ AI Code Review is an automated AI-powered code review CLI, compatible with vario
73
65
  ## Installation
74
66
 
75
67
  Install from PyPI:
76
- s
68
+
77
69
  ```bash
78
70
  pip install code-review-ai-cli
79
71
  ```
@@ -122,12 +114,13 @@ tfs:
122
114
 
123
115
  review:
124
116
  verbosity: detailed
125
- scope: diff_only
126
117
  custom_prompt_file: review_prompt.md
127
- # file limit sent to the LLM
128
- max_diff_files: 50
118
+ # maximum related files grouped per LLM review bundle (Smart File Bundling)
119
+ max_files_per_bundle: 5
129
120
  # per-file limit
130
121
  max_diff_lines: 2000
122
+ # cross-file symbol declarations resolved per file (0 = disabled)
123
+ max_referenced_symbols: 10
131
124
  # extension allowlist (empty list = all files)
132
125
  file_extensions_filter: [".cs", ".ts", ".py"]
133
126
  # exclude path prefixes from the diff (applied before file_extensions_filter)
@@ -7,25 +7,11 @@ tree-sitter-languages>=1.10.2
7
7
 
8
8
  [all]
9
9
  boto3>=1.34.0
10
- litellm>=1.40.0
11
- tiktoken>=0.7.0
12
- openai>=1.0.0
13
- google-generativeai>=0.3.0
14
- anthropic>=0.18.0
15
10
 
16
11
  [bedrock]
17
12
  boto3>=1.34.0
18
13
 
19
- [claude]
20
- anthropic>=0.18.0
21
-
22
14
  [dev]
23
15
  pytest>=8.3.0
24
16
  pytest-cov>=5.0.0
25
17
  pytest-mock>=3.14.0
26
-
27
- [gemini]
28
- google-generativeai>=0.3.0
29
-
30
- [openai]
31
- openai>=1.0.0
@@ -4,17 +4,17 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "code-review-ai-cli"
7
- version = "2.3.0"
7
+ version = "2.5.0"
8
8
  description = "Automated AI-powered code review CLI for Azure DevOps / TFS Pull Requests"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.10"
11
- license = { text = "MIT" }
12
- keywords = ["code-review", "ai", "azure-devops", "tfs", "pull-request", "llm"]
11
+ license = { text = "Apache-2.0" }
12
+ keywords = ["code-review", "ai", "azure-devops", "tfs", "pull-request", "git", "llm"]
13
13
  classifiers = [
14
14
  "Development Status :: 4 - Beta",
15
15
  "Environment :: Console",
16
16
  "Intended Audience :: Developers",
17
- "License :: OSI Approved :: MIT License",
17
+ "License :: OSI Approved :: Apache Software License",
18
18
  "Programming Language :: Python :: 3",
19
19
  "Programming Language :: Python :: 3.10",
20
20
  "Programming Language :: Python :: 3.11",
@@ -32,16 +32,8 @@ dependencies = [
32
32
 
33
33
  [project.optional-dependencies]
34
34
  bedrock = ["boto3>=1.34.0"]
35
- openai = ["openai>=1.0.0"]
36
- gemini = ["google-generativeai>=0.3.0"]
37
- claude = ["anthropic>=0.18.0"]
38
35
  all = [
39
36
  "boto3>=1.34.0",
40
- "litellm>=1.40.0",
41
- "tiktoken>=0.7.0",
42
- "openai>=1.0.0",
43
- "google-generativeai>=0.3.0",
44
- "anthropic>=0.18.0",
45
37
  ]
46
38
  dev = [
47
39
  "pytest>=8.3.0",