pi-readseek 0.11.4 → 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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-readseek",
3
- "version": "0.11.4",
3
+ "version": "0.12.0",
4
4
  "description": "Pi extension for LINE:HASH-anchored file operations and structural code navigation",
5
5
  "type": "module",
6
6
  "exports": {
@@ -39,8 +39,8 @@
39
39
  "node": ">=20.0.0"
40
40
  },
41
41
  "dependencies": {
42
- "@jarkkojs/readseek": "^0.11.4",
43
- "@jarkkojs/readseek-api": "^0.11.4",
42
+ "@jarkkojs/readseek": "^0.12.0",
43
+ "@jarkkojs/readseek-api": "^0.12.0",
44
44
  "diff": "^9.0.0",
45
45
  "xxhash-wasm": "^1.1.0"
46
46
  },
@@ -0,0 +1,6 @@
1
+ Return selected document asset descriptors with usable cached paths and attach images from those paths.
2
+
3
+ ## Parameters
4
+
5
+ - `path` — document file.
6
+ - `at` — optional document selector: `N`, `page:N`, `node:ID`, or `asset:ID`.
@@ -8,7 +8,7 @@ Go to a symbol definition or declaration by name. Accepts qualified or unqualifi
8
8
  - `gitScope` — in a Git repository, which files to search: `tracked`, `untracked`,
9
9
  `ignored` (untracked plus ignored), or `all`. Defaults to tracked plus untracked.
10
10
 
11
- After `readSeek_show_content` with `select: "identity"`, use
12
- `identity.identifier.text` for the token under the cursor. Use
13
- `identity.symbol.qualified_name` only when intentionally navigating to the
11
+ After `readSeek_show` with `at: "N:COLUMN"` (or `"line:N:COLUMN"`), use
12
+ `cursor.identifier.text` for the token under the cursor. Use
13
+ `cursor.symbol.qualified_name` only when intentionally navigating to the
14
14
  enclosing declaration.
@@ -1,7 +1,7 @@
1
1
  Edit existing text files with fresh `LINE:HASH` anchors. Read or search the file first when no fresh anchors are available. Each `edits[]` item must use exactly one nested object: `{"set_line":{"anchor":"LINE:HASH","new_text":"..."}}`, `{"replace_lines":{"start_anchor":"LINE:HASH","end_anchor":"LINE:HASH","new_text":"..."}}`, `{"insert_after":{"anchor":"LINE:HASH","new_text":"..."}}`, `{"replace_symbol":{"symbol":"name","new_body":"..."}}`, or `{"replace":{"old_text":"...","new_text":"..."}}`.
2
2
 
3
- Anchors come from `readSeek_show_content`, `readSeek_find_text`, `readSeek_find_nodes`,
4
- `readSeek_find_references`, `readSeek_find_definitions`, or `readSeek_write_file`.
3
+ Anchors come from `readSeek_show`, `readSeek_grep`, `readSeek_search`,
4
+ `readSeek_refs`, `readSeek_def`, or `readSeek_write`.
5
5
 
6
6
  ## Variants
7
7
 
@@ -0,0 +1,10 @@
1
+ Find references or usages of an identifier by name or cursor binding. Results include enclosing symbols and line hashes usable as `LINE:HASH` anchors. Without `at`, results are identifier-name matches; with `at`, they follow one binding and exclude shadows. Use text search for literal occurrences in strings or comments, and use this tool before renaming or deleting a symbol.
2
+
3
+ ## Parameters
4
+
5
+ - `name` — identifier to find; required unless `at` is set.
6
+ - `at` — cursor binding selector (`N[:COLUMN]`, `H[:COLUMN]`, `line:N[:COLUMN]`, or `hash:H[:COLUMN]`); mutually exclusive with `name`.
7
+ - `path` — file or directory; defaults to the current directory.
8
+ - `language` — language override for ambiguous, extensionless, or generated source.
9
+ - `gitScope` — in a Git repository, which files to search: `tracked`, `untracked`,
10
+ `ignored` (untracked plus ignored), or `all`. Defaults to tracked plus untracked.
@@ -3,8 +3,7 @@ Rename a symbol at a source location. Resolvable same-named bindings are preserv
3
3
  ## Parameters
4
4
 
5
5
  - `path` — source file containing the cursor.
6
- - `line` — one-based cursor line.
7
- - `column` — optional one-based cursor byte column for disambiguation.
6
+ - `at` — cursor location selector (`N[:COLUMN]`, `H[:COLUMN]`, `line:N[:COLUMN]`, or `hash:H[:COLUMN]`).
8
7
  - `to` — new plain identifier.
9
8
  - `workspace` — expand across the project. The cursor file remains binding-aware;
10
9
  other files use name matching where binding resolution is unavailable.
@@ -1,10 +1,12 @@
1
- Search code by AST structure using ast-grep-style patterns. Results include line hashes usable as `LINE:HASH` anchors. Use `readSeek_find_text` for identifiers, strings, comments, configuration, documentation, or other plain text and regex.
1
+ Search code by AST structure using ast-grep-style patterns or KDL selection rules. Results include line hashes usable as `LINE:HASH` anchors. Use `readSeek_grep` for identifiers, strings, comments, configuration, documentation, or other plain text and regex.
2
2
 
3
3
  ## Parameters
4
4
 
5
5
  - `pattern` — AST pattern to match.
6
6
  - `context` — surrounding code context for sub-statement patterns (used with `selector`).
7
7
  - `selector` — target AST node kind to extract from pattern context.
8
+ - `rule` — KDL node selection rule, `@path`, or `'-'` for standard input.
9
+ - `limit` — maximum matches to return.
8
10
  - `path` — file or directory; defaults to the current directory.
9
11
  - `language` — language override for ambiguous, extensionless, generated, or
10
12
  JSX-like source.
@@ -0,0 +1,16 @@
1
+ Read source content, document content, or image descriptors without inference.
2
+
3
+ Obtain fresh `LINE:HASH` anchors before edits; pass `at` with a column (`N:COLUMN` or `line:N:COLUMN`) for cursor context. Document results include typed nodes and cached asset paths.
4
+
5
+ ## Parameters
6
+
7
+ - `path` — source, image, or document path.
8
+ - `at` — optional selector: `N[:COLUMN]`, `START-END`, `H[:COLUMN]`, `NAME`, `line:N[:COLUMN]`, `hash:H[:COLUMN]`, `symbol:NAME`, `page:N`, `node:ID`, or `asset:ID`.
9
+ - `end` — last source line to include.
10
+ - `limit` — maximum source lines to include; cannot be combined with `end`.
11
+ - `language` — source-language override when detection is ambiguous.
12
+ - `noAnchors` — omit source line anchors.
13
+
14
+ ## PDF workflow
15
+
16
+ Read a PDF with `readSeek_tree` or `readSeek_show`, then narrow with `at: "page:N"` (or `"N"`), `at: "node:ID"`, or `at: "asset:ID"`. Selected assets are cached automatically with local paths.
@@ -1,14 +0,0 @@
1
- Find references or usages of an identifier by name or cursor binding. Results include enclosing symbols and line hashes usable as `LINE:HASH` anchors. Without cursor scope, results are identifier-name matches; with scope, they follow one binding and exclude shadows. Use text search for literal occurrences in strings or comments, and use this tool before renaming or deleting a symbol.
2
-
3
- ## Parameters
4
-
5
- - `name` — identifier to find; required unless `scope` is set with `line`.
6
- - `path` — file or directory; defaults to the current directory.
7
- - `language` — language override for ambiguous, extensionless, or generated source.
8
- - `scope` — restrict results to the binding at `line` / `column` in one file;
9
- requires `line`. `name` is optional when scoped.
10
- - `line` — one-based cursor line used with `scope`.
11
- - `column` — optional one-based cursor byte column for disambiguation; used with
12
- `scope`. Cursor fields require `scope`.
13
- - `gitScope` — in a Git repository, which files to search: `tracked`, `untracked`,
14
- `ignored` (untracked plus ignored), or `all`. Defaults to tracked plus untracked.
@@ -1,11 +0,0 @@
1
- Extract one document asset selected by a stable `asset:ID` into a destination file.
2
-
3
- Call `readSeek_show_content` on the document first to discover asset IDs. This tool writes binary data directly to disk and never returns those bytes through tool output.
4
-
5
- ## Parameters
6
-
7
- - `path` — document file.
8
- - `selector` — required asset selector in the form `asset:ID`.
9
- - `output` — destination file path. `-` and stdout are not supported.
10
-
11
- The result is a short receipt containing the resolved source, selector, and destination paths.
@@ -1,34 +0,0 @@
1
- Inspect source content, standalone images, and documents through the native CLI envelope.
2
-
3
- Use this for anchored source content, diagnostics, cursor identity, shallow structural maps, and document structure. Prefer `def`, `refs`, or `search` when the question targets a source symbol.
4
-
5
- ## Parameters
6
-
7
- - `path` — source, image, or document path.
8
- - `selector` — one positional selector: `line:N[:COLUMN]`, `hash:HASH[:COLUMN]`, `symbol:NAME`, `page:N`, `node:ID`, or `asset:ID`.
9
- - `select` — source facets: `metadata`, `content`, `map`, `diagnostics`, `identity`. Accepts one facet, an array, or comma-separated facets. Default `content`.
10
- - `query` — document KDL selection query, such as `select selector="page:2" kind="heading" depth=2`; cannot be combined with `selector`.
11
- - `end` — last source line to include.
12
- - `limit` — maximum source lines to include; cannot be combined with `end`.
13
- - `depth` — maximum structural depth for a source `map`; agent tools default to `1`.
14
- - `language` — source-language override when detection is ambiguous.
15
- - `visionMode` — standalone image analysis: `none`, `all`, `ocr`, `caption`, or `objects`.
16
- - `visionLevel` — vision inference level: `low` (default), `medium`, or `high`; requires an analysis `visionMode`.
17
-
18
- ## Source facets
19
-
20
- | select | Purpose |
21
- | --- | --- |
22
- | `metadata` | File kind, language, and engine |
23
- | `content` | Anchored text or prepared/analyzed image payload |
24
- | `map` | Structural outline; start shallow and deepen as needed |
25
- | `diagnostics` | Parser errors and missing syntax nodes |
26
- | `identity` | Token and enclosing symbol at `selector` |
27
-
28
- ## PDF workflow
29
-
30
- Inspect a PDF without a selector first. The result contains stable page, node, and asset IDs. Narrow with `page:N`, `node:ID`, or a KDL `query`. Use `readSeek_show_assets` only when the binary bytes of an `asset:ID` must be saved.
31
-
32
- ## Output
33
-
34
- The decoded native KDL envelope is rendered as JSON and retained in `details.readSeekValue.envelope`. Source facets appear only when requested; PDF output contains document properties, nodes, assets, and optional vision results.
File without changes
File without changes