agentpack-cli 0.1.21__tar.gz → 0.1.23__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 (86) hide show
  1. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/PKG-INFO +182 -20
  2. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/README.md +180 -18
  3. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/pyproject.toml +2 -2
  4. agentpack_cli-0.1.23/src/agentpack/__init__.py +3 -0
  5. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/analysis/ranking.py +89 -0
  6. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/application/pack_service.py +2 -0
  7. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/cli.py +2 -2
  8. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/benchmark.py +231 -3
  9. agentpack_cli-0.1.23/src/agentpack/commands/quickstart.py +112 -0
  10. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/config.py +4 -0
  11. agentpack_cli-0.1.21/src/agentpack/__init__.py +0 -3
  12. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/.gitignore +0 -0
  13. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/LICENSE +0 -0
  14. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/adapters/__init__.py +0 -0
  15. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/adapters/antigravity.py +0 -0
  16. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/adapters/base.py +0 -0
  17. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/adapters/claude.py +0 -0
  18. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/adapters/codex.py +0 -0
  19. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/adapters/cursor.py +0 -0
  20. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/adapters/detect.py +0 -0
  21. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/adapters/generic.py +0 -0
  22. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/adapters/windsurf.py +0 -0
  23. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/analysis/__init__.py +0 -0
  24. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/analysis/dependency_graph.py +0 -0
  25. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/analysis/go_imports.py +0 -0
  26. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/analysis/java_imports.py +0 -0
  27. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/analysis/js_ts_imports.py +0 -0
  28. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/analysis/python_imports.py +0 -0
  29. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/analysis/rust_imports.py +0 -0
  30. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/analysis/symbols.py +0 -0
  31. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/analysis/tests.py +0 -0
  32. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/application/__init__.py +0 -0
  33. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/__init__.py +0 -0
  34. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/_shared.py +0 -0
  35. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/claude_cmd.py +0 -0
  36. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/diff.py +0 -0
  37. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/doctor.py +0 -0
  38. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/explain.py +0 -0
  39. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/hook_cmd.py +0 -0
  40. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/init.py +0 -0
  41. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/install.py +0 -0
  42. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/mcp_cmd.py +0 -0
  43. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/monitor.py +0 -0
  44. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/pack.py +0 -0
  45. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/scan.py +0 -0
  46. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/stats.py +0 -0
  47. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/status.py +0 -0
  48. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/summarize.py +0 -0
  49. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/commands/watch.py +0 -0
  50. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/__init__.py +0 -0
  51. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/bootstrap.py +0 -0
  52. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/cache.py +0 -0
  53. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/context_pack.py +0 -0
  54. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/diff.py +0 -0
  55. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/git.py +0 -0
  56. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/git_hooks.py +0 -0
  57. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/global_install.py +0 -0
  58. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/ignore.py +0 -0
  59. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/merkle.py +0 -0
  60. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/models.py +0 -0
  61. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/redactor.py +0 -0
  62. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/scanner.py +0 -0
  63. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/snapshot.py +0 -0
  64. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/token_estimator.py +0 -0
  65. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/core/vscode_tasks.py +0 -0
  66. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/data/agentpack.md +0 -0
  67. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/installers/__init__.py +0 -0
  68. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/installers/antigravity.py +0 -0
  69. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/installers/claude.py +0 -0
  70. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/installers/codex.py +0 -0
  71. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/installers/cursor.py +0 -0
  72. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/installers/windsurf.py +0 -0
  73. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/integrations/__init__.py +0 -0
  74. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/integrations/git_hooks.py +0 -0
  75. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/integrations/global_install.py +0 -0
  76. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/integrations/vscode_tasks.py +0 -0
  77. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/mcp_server.py +0 -0
  78. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/renderers/__init__.py +0 -0
  79. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/renderers/compact.py +0 -0
  80. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/renderers/markdown.py +0 -0
  81. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/renderers/receipts.py +0 -0
  82. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/session/__init__.py +0 -0
  83. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/session/state.py +0 -0
  84. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/summaries/__init__.py +0 -0
  85. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/summaries/base.py +0 -0
  86. {agentpack_cli-0.1.21 → agentpack_cli-0.1.23}/src/agentpack/summaries/offline.py +0 -0
@@ -1,7 +1,7 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: agentpack-cli
3
- Version: 0.1.21
4
- Summary: Token-aware context packing for AI coding agents — Claude, Cursor, Windsurf, and Codex
3
+ Version: 0.1.23
4
+ Summary: Task-aware context packing for AI coding agents — Claude, Cursor, Windsurf, Codex, and Antigravity
5
5
  License: MIT
6
6
  License-File: LICENSE
7
7
  Keywords: ai,claude,codex,coding-agent,context,cursor,llm,packing,windsurf
@@ -44,11 +44,27 @@ Description-Content-Type: text/markdown
44
44
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
45
45
  [![CI](https://github.com/vishal2612200/agentpack/actions/workflows/ci.yml/badge.svg)](https://github.com/vishal2612200/agentpack/actions/workflows/ci.yml)
46
46
 
47
- > **Status: alpha (v0.1.21).** Works, tested, used in real sessions. Python and JavaScript/TypeScript are the best-supported languages. Not yet validated across a wide range of repos. API may change before 1.0.
47
+ > **Status: alpha (v0.1.23).** Works, tested, used in real sessions. Python and JavaScript/TypeScript are the best-supported languages. Not yet validated across a wide range of repos. API may change before 1.0.
48
48
  >
49
49
  > **Platform note:** macOS and Linux are fully supported. Windows support is not yet implemented (git hooks use POSIX shell; the Claude Code session hooks use `python3`/`rm -f`). Contributions welcome.
50
50
 
51
- **Token-aware context packing for AI coding agents.**
51
+ **Task-aware context packing for AI coding agents.**
52
+
53
+ AgentPack scans a repository, ranks files for the task you are working on, and writes a compact markdown context pack for Claude Code, Cursor, Windsurf, Codex, Antigravity, CI jobs, or any LLM workflow.
54
+
55
+ It is useful when the repo is too large to paste, but you still want the agent to start with more than a blank slate.
56
+
57
+ **What it is**
58
+ - A local CLI for building task-focused context packs
59
+ - A summary cache, import graph, ranking engine, and token-budget selector
60
+ - Optional integrations for popular coding agents
61
+ - An eval harness for measuring whether selected files match files you actually changed
62
+
63
+ **What it is not**
64
+ - Not a coding agent
65
+ - Not a semantic code search engine
66
+ - Not a replacement for manual inspection on high-stakes changes
67
+ - Not yet proven across a large public benchmark suite
52
68
 
53
69
  ---
54
70
 
@@ -71,16 +87,19 @@ None of these scale. On a 200-file codebase, option 1 wastes 5–10 turns just o
71
87
  AgentPack solves this with a one-time offline analysis pass:
72
88
 
73
89
  1. **Scans your repo once** — builds a summary cache of every file (signatures, imports, responsibilities). No API calls. Takes a few seconds.
74
- 2. **On each task** — uses git diff + import graph traversal + keyword scoring to rank every file by relevance to what you're working on.
75
- 3. **Packs a tight context document** — changed files get full content, large changed files get relevant symbol bodies, dependencies get summaries, everything else gets dropped. Typically 8k–20k tokens for a 200-file repo.
76
- 4. **Explains pack quality** — noisy-pack diagnostics, score receipts, and token-precision metrics show when the pack is broad and where token noise lives.
90
+ 2. **On each task** — uses git diff, import graph traversal, keyword/concept expansion, implementation-role boosts, and cross-layer relatedness to rank every file.
91
+ 3. **Packs a tight context document** — changed files get full content, large changed files get relevant symbol bodies, dependencies and likely implementation files get summaries, everything else gets dropped.
92
+ 4. **Explains pack quality** — noisy-pack diagnostics, score receipts, token-precision metrics, and benchmark miss reports show when the pack is broad or missing expected files.
77
93
  5. **Stays current** — auto-repacks silently on commit, so next session starts fresh.
78
94
 
79
- The result: your agent starts every session with a focused, accurate picture of the relevant code without you doing anything after opt-in.
95
+ The result: your agent starts with a focused map of the relevant code. It should reduce blind exploration, not replace the agent's own file reads or your judgment.
80
96
 
81
97
  ```bash
82
98
  pip install agentpack-cli
83
99
 
100
+ # Show the fastest path for your repo
101
+ agentpack quickstart --task "fix auth token expiry"
102
+
84
103
  # One-time setup per project
85
104
  cd your-project
86
105
  agentpack init # creates config, session, task.md — nothing else needed
@@ -100,13 +119,53 @@ agentpack global-install --dry-run # preview first
100
119
  agentpack global-install
101
120
  ```
102
121
 
103
- Supported agents: **Claude Code**, **Cursor**, **Windsurf**, **Codex**, **Antigravity** (Google), or any LLM.
122
+ Supported agents: **Claude Code**, **Cursor**, **Windsurf**, **Codex**, **Antigravity** (Google), or any LLM that can read markdown.
104
123
 
105
124
  ---
106
125
 
107
- ## AgentPack Results (7 days, 21 sessions)
126
+ ## What to expect
127
+
128
+ AgentPack's strongest value is repeatable orientation: it gives the agent a compact first-pass map before tool calls begin.
129
+
130
+ Typical results on large repos:
131
+
132
+ | Signal | What good looks like |
133
+ |---|---|
134
+ | Token reduction | 90-99% smaller than raw repo text |
135
+ | Pack size | Usually 8k-25k tokens for a specific task |
136
+ | Pack time | Seconds on warm cache; first summarize pass is slower |
137
+ | Recall | Should be high for files you later edit; validate with `agentpack benchmark` |
138
+ | Precision | Often modest; summaries are cheap but can still add noise |
139
+
140
+ The compression number is easy to verify, but it is not the same as usefulness. The important question is: **did AgentPack include the files you actually needed?**
141
+
142
+ Use the built-in eval flow:
143
+
144
+ ```bash
145
+ agentpack benchmark --init
146
+ # add real historical tasks and files you actually changed
147
+ agentpack benchmark --compare --misses
148
+ ```
149
+
150
+ For source checkouts, there is also a small smoke suite:
151
+
152
+ ```bash
153
+ agentpack benchmark --sample-fixtures --misses
154
+ ```
155
+
156
+ This runs FastAPI, Next.js, and mixed Python/TypeScript fixture tasks. It is a sanity check, not a substitute for real repo evals.
157
+
158
+ ### Current quality bar
159
+
160
+ AgentPack is best described as a **map, not a compass**. It is already good at token reduction, changed-file inclusion, related tests, imports, configs, and common concepts like auth/cache/rate limiting. Recent ranking work also improves full-stack tasks by pulling service/controller/schema/handler files when UI routes or pages match the same domain.
161
+
162
+ Known weak spot: recall can still be low on unfamiliar product domains or cross-language flows. Use `benchmark --misses` and `agentpack explain` when an expected file is absent. Those commands show whether the miss was caused by ignore rules, low score, summary floor, budget cutoff, or missing task signal.
163
+
164
+ ### Observed author-run numbers
108
165
 
109
- ### Token Compression
166
+ These are local author-session numbers, included as anecdotal context rather than a benchmark claim.
167
+
168
+ #### Token Compression
110
169
 
111
170
  | Metric | Value |
112
171
  |--------|-------|
@@ -118,7 +177,7 @@ Supported agents: **Claude Code**, **Cursor**, **Windsurf**, **Codex**, **Antigr
118
177
 
119
178
  Per session: ~4.1M raw repo → ~35K packed context.
120
179
 
121
- ### Cost (Sonnet 4.6, input tokens only)
180
+ #### Cost (Sonnet 4.6, input tokens only)
122
181
 
123
182
  | Scenario | Cost |
124
183
  |----------|------|
@@ -128,7 +187,7 @@ Per session: ~4.1M raw repo → ~35K packed context.
128
187
 
129
188
  > Honest note: raw_tokens = full repo estimate. Real savings depend on how much context you'd pass manually. Compression ratio (99%+) is verifiable; dollar figure is scenario-dependent.
130
189
 
131
- ### Quality Signal
190
+ #### Quality Signal
132
191
 
133
192
  - 42 commits in 7 days (~6/day) vs 4.9/day before
134
193
  - Shift from single-file fixes → multi-system coordinated fixes
@@ -202,9 +261,10 @@ _*`--agent generic` outputs standard markdown. Claude adapter has richer instruc
202
261
 
203
262
  ### What agentpack does NOT do well
204
263
 
205
- - **Interactive sessions on small repos**: if your whole repo is <20k tokens, just use repomix
206
- - **One-shot public repo questions**: gitingest's "replace hub with ingest" is faster for that
207
- - **Semantic understanding**: keyword scoring + AST is not a language model precise technical terms in your task description work better than vague ones
264
+ - **Interactive sessions on small repos**: if your whole repo is <20k tokens, a simple repo dump may be enough
265
+ - **One-shot public repo questions**: gitingest's "replace hub with ingest" is faster for quick read-only exploration
266
+ - **Guaranteed source-of-truth selection**: AgentPack ranks likely files; it can miss task-critical files. Use `agentpack benchmark --misses`, `agentpack explain`, and normal `rg`/agent file reads for correctness.
267
+ - **Deep semantic understanding**: keyword/concept scoring, imports, symbols, and path roles help, but they are not an LLM-level code understanding system
208
268
 
209
269
  ---
210
270
 
@@ -218,10 +278,29 @@ Requires Python 3.10+.
218
278
 
219
279
  > **PyPI note:** The package is `agentpack-cli` (the name `agentpack` was already taken). The CLI command is still `agentpack`.
220
280
 
281
+ ### npm wrapper
282
+
283
+ AgentPack can also be installed from npm:
284
+
285
+ ```bash
286
+ npm install -g @vishal2612200/agentpack
287
+ agentpack --version
288
+ ```
289
+
290
+ The npm package is a thin Node.js wrapper around the Python CLI. It requires Node.js 18+ and Python 3.10+, then installs the matching `agentpack-cli` PyPI package into a per-version virtual environment on first run. This keeps the implementation single-source while giving JavaScript-heavy teams a familiar install path.
291
+
221
292
  ---
222
293
 
223
294
  ## Start Once, Then Work Normally
224
295
 
296
+ For a guided two-minute path in any repo:
297
+
298
+ ```bash
299
+ agentpack quickstart --task "fix auth token expiry"
300
+ ```
301
+
302
+ It shows the exact commands to initialize, set task text, generate a first pack, inspect stats, start watch mode, and scaffold a small benchmark file for your own tasks.
303
+
225
304
  The full workflow:
226
305
 
227
306
  ```bash
@@ -642,6 +721,20 @@ Options:
642
721
 
643
722
  ---
644
723
 
724
+ ### `agentpack quickstart`
725
+
726
+ Show the shortest useful path for the current repo.
727
+
728
+ ```bash
729
+ agentpack quickstart
730
+ agentpack quickstart --task "fix auth token expiry"
731
+ agentpack quickstart --task "fix auth token expiry" --write
732
+ ```
733
+
734
+ `quickstart` does not guess at magic. It checks whether `.agentpack/config.toml`, `.agentpack/task.md`, and context packs exist, then prints the next few commands. With `--write`, it writes the supplied task into `.agentpack/task.md`.
735
+
736
+ ---
737
+
645
738
  ### `agentpack session` _(removed)_
646
739
 
647
740
  Session management was removed in v0.1.12. `agentpack init` bootstraps the session automatically. Use `agentpack watch` to keep context current. To change the task, edit `.agentpack/task.md`.
@@ -762,6 +855,8 @@ agentpack benchmark --task "fix auth token expiry" # single task
762
855
  agentpack benchmark --task "fix auth bug" --compare # compare minimal/balanced/deep
763
856
  agentpack benchmark --init # scaffold .agentpack/benchmark.toml
764
857
  agentpack benchmark # run all cases in benchmark.toml
858
+ agentpack benchmark --sample-fixtures # source checkout demo evals
859
+ agentpack benchmark --misses # explain expected-file misses
765
860
  ```
766
861
 
767
862
  Output per case:
@@ -812,6 +907,8 @@ expected_files = [
812
907
  hit: src/auth/session.py, src/auth/token.py
813
908
  ```
814
909
 
910
+ Use `--misses` when recall is low. It prints each expected file that was not selected with status, rank, score, and scoring reasons, which helps separate ignored files, budget cuts, low scores, and missing dependency signals.
911
+
815
912
  ---
816
913
 
817
914
  ### `agentpack scan`
@@ -840,6 +937,20 @@ When a session is active, shows session panel (agent, mode, started, refresh cou
840
937
 
841
938
  Newer metrics include token-weighted precision. File precision answers "how many selected files were later changed"; token precision answers "how many selected tokens were spent on files later changed." `stats` also breaks token precision down by inclusion mode (`full`, `symbols`, `summary`) so summary noise is visible.
842
939
 
940
+ To build a real usefulness signal for your repo:
941
+
942
+ ```bash
943
+ agentpack benchmark --sample-fixtures
944
+
945
+ agentpack benchmark --init
946
+ # edit .agentpack/benchmark.toml with real tasks + files you actually changed
947
+ agentpack benchmark --compare --misses
948
+ ```
949
+
950
+ `--sample-fixtures` runs bundled FastAPI, Next.js, and mixed Python/TypeScript fixture evals from an AgentPack source checkout. It is a smoke test, not a claim about your repo.
951
+
952
+ For an 8+ usefulness signal, use `benchmark.toml` with real third-party or customer-style repos: 5-20 historical tasks, the files actually changed for each task, and `--compare` results for recall, F1, rank@K, and token noise. That is better than trusting generic benchmarks because it tells you whether AgentPack selects the files that matter in code the package has never seen.
953
+
843
954
  ---
844
955
 
845
956
  ### `agentpack status`
@@ -1189,6 +1300,7 @@ src/agentpack/
1189
1300
  pack.py # agentpack pack → PackService.run()
1190
1301
  install.py # agentpack install / global-install → installers/
1191
1302
  init.py # agentpack init
1303
+ quickstart.py # agentpack quickstart — guided first-run commands
1192
1304
  scan.py # agentpack scan
1193
1305
  diff.py # agentpack diff
1194
1306
  status.py # agentpack status
@@ -1197,10 +1309,11 @@ src/agentpack/
1197
1309
  monitor.py # agentpack monitor
1198
1310
  explain.py # agentpack explain
1199
1311
  doctor.py # agentpack doctor
1200
- session.py # agentpack session start/stop/status/refresh
1312
+ hook_cmd.py # agentpack hook — Claude prompt hook + stale detection
1313
+ mcp_cmd.py # agentpack mcp — MCP server entrypoint
1201
1314
  watch.py # agentpack watch — file watcher with debounce
1202
1315
  claude_cmd.py # agentpack claude — refresh + launch claude
1203
- benchmark.py # agentpack benchmark — token efficiency + selection quality
1316
+ benchmark.py # agentpack benchmark — token efficiency, recall, miss diagnostics
1204
1317
  ```
1205
1318
 
1206
1319
  ### Key architectural properties
@@ -1328,7 +1441,17 @@ The more descriptive your branch names (`feat/add-rate-limiting` beats `dev`) an
1328
1441
 
1329
1442
  ### Concept synonym expansion
1330
1443
 
1331
- AgentPack expands task keywords automatically — "rate limiting" expands to `throttle`, `leaky`, `bucket`, `quota`, `debounce`; "auth" expands to `jwt`, `bearer`, `token`, `oauth`; "cache" expands to `lru`, `memoize`, `redis`, `ttl`. Files that implement a concept but don't use its exact name still rank correctly.
1444
+ AgentPack expands task keywords automatically — "rate limiting" expands to `throttle`, `leaky`, `bucket`, `quota`, `debounce`; "auth" expands to `jwt`, `bearer`, `token`, `oauth`; "cache" expands to `lru`, `memoize`, `redis`, `ttl`; domain terms such as `kundali` expand toward astrology/chart/compatibility terms. Files that implement a concept but don't use its exact name can still rank.
1445
+
1446
+ ### Full-stack role boosts
1447
+
1448
+ When a task points at a page, route, or API surface, AgentPack also gives a controlled boost to related implementation roles such as `service`, `controller`, `schema`, `handler`, `repository`, and `client`. This helps full-stack tasks pull backend implementation files instead of only frontend entrypoints.
1449
+
1450
+ This is still heuristic. If a service should have appeared and did not, add it as an `expected_files` entry in `benchmark.toml` and run:
1451
+
1452
+ ```bash
1453
+ agentpack benchmark --compare --misses
1454
+ ```
1332
1455
 
1333
1456
  ### Content-based keyword enrichment
1334
1457
 
@@ -1379,6 +1502,8 @@ agentpack explain --task "fix auth session bug"
1379
1502
 
1380
1503
  Shows ranked scores and reasons before committing to a pack. Use when a file you expect isn't appearing.
1381
1504
 
1505
+ For repeatable evals, prefer `benchmark --misses` because it compares selected files against the files you actually changed for historical tasks.
1506
+
1382
1507
  ### Check what got included and why
1383
1508
 
1384
1509
  Every pack includes a context receipt explaining each file's inclusion or exclusion:
@@ -1410,7 +1535,8 @@ config_file = 60 # was 25 — configs always matter here
1410
1535
  - **Non-destructive**: never overwrites user files; config patching only touches agentpack-managed blocks
1411
1536
  - **Agent-neutral**: architecture is generic; Claude Code is the primary target (deepest integration); Cursor, Windsurf, Codex, and Antigravity are supported but less battle-tested
1412
1537
  - **No daemons**: file watching is opt-in via `agentpack watch`; git hooks run in the background and are opt-in via `install`
1413
- - **Honest**: packed token count reflects real content, not raw repo size
1538
+ - **Measurable**: `benchmark`, `stats`, receipts, and `--misses` are first-class because compression without recall is not enough
1539
+ - **Honest**: packed token count reflects real content, and raw-repo savings are presented separately from practical usefulness
1414
1540
 
1415
1541
  ---
1416
1542
 
@@ -1419,6 +1545,7 @@ config_file = 60 # was 25 — configs always matter here
1419
1545
  - **Windows**: not supported. Git hooks use POSIX shell (`#!/bin/sh`, `>/dev/null 2>&1 &`). The Claude Code session hooks use `python3` and `rm -f`. Contributions welcome.
1420
1546
  - **Monorepos**: single-root repos only. If you `agentpack pack` from a monorepo root, all packages are scanned together with no workspace awareness. Workaround: `cd packages/my-pkg && agentpack init && agentpack pack`.
1421
1547
  - **Symbol extraction**: Python (AST, full) and JavaScript/TypeScript (regex, arrow functions + classes) are well-supported. Go, Rust, Java, Kotlin have import graph traversal but no symbol extraction — they fall back to file-level summaries.
1548
+ - **Selection recall**: ranking is heuristic. It can miss files when task language differs from code language, when repos have unusual architecture, or when important files are only connected at runtime.
1422
1549
  - **Secret redaction**: covers AWS keys, GitHub tokens, OpenAI/Anthropic keys, JWTs, and private key blocks. Not a substitute for a dedicated secrets scanner on sensitive repos.
1423
1550
  - **Token estimates**: uses tiktoken `cl100k_base` — approximate, not exact for Claude's billing.
1424
1551
  - **Large repos (>5k files)**: global auto-bootstrap is skipped for repos over 5,000 files to avoid hangs. Run `agentpack init` explicitly in large codebases.
@@ -1435,6 +1562,41 @@ pip install "agentpack-cli[all]" # watch + mcp
1435
1562
 
1436
1563
  ---
1437
1564
 
1565
+ ## Development
1566
+
1567
+ Clone and run locally:
1568
+
1569
+ ```bash
1570
+ git clone https://github.com/vishal2612200/agentpack.git
1571
+ cd agentpack
1572
+ python -m pip install -e ".[dev,watch,mcp]" build
1573
+ pytest
1574
+ ```
1575
+
1576
+ Useful checks before opening a PR:
1577
+
1578
+ ```bash
1579
+ pytest
1580
+ python -m ruff check src tests
1581
+ python -m build
1582
+ npm test --prefix npm
1583
+ (cd npm && npm pack --dry-run)
1584
+ agentpack benchmark --sample-fixtures --misses
1585
+ ```
1586
+
1587
+ Good contribution areas:
1588
+
1589
+ - More real-world benchmark fixtures and public repo eval cases
1590
+ - Windows support for hooks and session integrations
1591
+ - Better symbol extraction for Go, Rust, Java, and Kotlin
1592
+ - More precise import/dependency resolution for framework-heavy repos
1593
+ - Ranking regressions with `expected_files` cases that reproduce misses
1594
+ - npm wrapper improvements that preserve the Python CLI as the source of truth
1595
+
1596
+ Please include tests for ranking changes. A good ranking PR usually adds one focused unit test and one scenario in `tests/test_ranking_evals.py`.
1597
+
1598
+ ---
1599
+
1438
1600
  ## License
1439
1601
 
1440
1602
  MIT