Skip to content

Commit 4ff4e4d

Browse files
author
Zhe Yu
committed
docs: documentation updates.
1 parent fafcd7a commit 4ff4e4d

2 files changed

Lines changed: 41 additions & 39 deletions

File tree

docs/cli.md

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -580,7 +580,7 @@ following options in the JSON config file:
580580
"embedding_params": {
581581
"backend": "torch",
582582
"device": "cuda"
583-
},
583+
}
584584
}
585585
```
586586

@@ -593,8 +593,8 @@ need to configure `SentenceTransformer` to use `openvino` backend. In your
593593
```json
594594
{
595595
"embedding_params": {
596-
"backend": "openvino",
597-
},
596+
"backend": "openvino"
597+
}
598598
}
599599
```
600600
This will run the embedding model on your GPU. This is supported even for
@@ -618,14 +618,14 @@ fact, this is exactly what I did when I wrote the neovim plugin.
618618
For the query command, here's the format printed in the `pipe` mode:
619619
```json
620620
[
621-
{
622-
"path": "path_to_your_code.py",
623-
"document":"import something"
624-
},
625-
{
626-
"path": "path_to_another_file.py",
627-
"document": "print('hello world')"
628-
}
621+
{
622+
"path": "path_to_your_code.py",
623+
"document": "import something"
624+
},
625+
{
626+
"path": "path_to_another_file.py",
627+
"document": "print('hello world')"
628+
}
629629
]
630630
```
631631
Basically an array of dictionaries with 2 keys: `"path"` for the path to the
@@ -634,20 +634,20 @@ document, and `"document"` for the content of the document.
634634
If you used `--include chunk path` parameters, the array will look like this:
635635
```json
636636
[
637-
{
638-
"path": "path_to_your_code.py",
639-
"chunk": "foo",
640-
"start_line": 1,
641-
"end_line": 1,
642-
"chunk_id": "chunk_id_1"
643-
},
644-
{
645-
"path": "path_to_another_file.py",
646-
"chunk": "bar",
647-
"start_line": 1,
648-
"end_line": 1,
649-
"chunk_id": "chunk_id_2"
650-
}
637+
{
638+
"path": "path_to_your_code.py",
639+
"chunk": "foo",
640+
"start_line": 1,
641+
"end_line": 1,
642+
"chunk_id": "chunk_id_1"
643+
},
644+
{
645+
"path": "path_to_another_file.py",
646+
"chunk": "bar",
647+
"start_line": 1,
648+
"end_line": 1,
649+
"chunk_id": "chunk_id_2"
650+
}
651651
]
652652
```
653653
Keep in mind that both `start_line` and `end_line` are inclusive. The `chunk_id`
@@ -668,13 +668,13 @@ The output is in JSON format. It contains a dictionary with the following fields
668668
A JSON array of collection information of the following format will be printed:
669669
```json
670670
{
671-
"project_root": str,
672-
"user": str,
673-
"hostname": str,
674-
"collection_name": str,
675-
"size": int,
676-
"num_files": int,
677-
"embedding_function": str
671+
"project_root": str,
672+
"user": str,
673+
"hostname": str,
674+
"collection_name": str,
675+
"size": int,
676+
"num_files": int,
677+
"embedding_function": str
678678
}
679679
```
680680
- `"project_root"`: the path to the `project-root`;
@@ -711,8 +711,8 @@ pipx inject vectorcode 'vectorcode[lsp]' --force
711711
The LSP request for the `workspace/executeCommand` is defined as follows:
712712
```
713713
{
714-
command: str
715-
arguments: list[Any]
714+
command: str
715+
arguments: list[Any]
716716
}
717717
```
718718
For the `vectorcode-server`, the only valid value for the `command` key is
@@ -721,8 +721,8 @@ command. For example, to execute `vectorcode query -n 10 reranker`, the request
721721
would be:
722722
```
723723
{
724-
command: "vectorcode",
725-
arguments: ["query", "-n", "10", "reranker"]
724+
command: "vectorcode",
725+
arguments: ["query", "-n", "10", "reranker"]
726726
}
727727
```
728728

docs/neovim/README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
# NeoVim Plugin
22

33
> [!NOTE]
4-
> This plugin depends on the CLI tool. Please go through
5-
> [the CLI documentation](../cli/README.md) and make sure the VectorCode CLI is working
6-
> before proceeding.
4+
> This plugin depends on the CLI tool. You should follow
5+
> [the CLI documentation](../cli/README.md) to install the CLI and familiarise
6+
> yourself with
7+
> [the basic usage of the CLI interface](../cli/README.md#getting-started)
8+
> before you proceed.
79
810
> [!NOTE]
911
> When the neovim plugin doesn't work properly, please try upgrading both the CLI

0 commit comments

Comments
 (0)