Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions public/content/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ metaTitle: Using the Pieces CLI | Pieces Docs
metaDescription: Learn how to use Pieces CLI for seamless command-line integration, allowing you to save, retrieve, and manage code snippets efficiently.
---

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/CLI_MAIN/pieces_cli_banner.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/CLI_MAIN/pieces_cli_banner.png" alt="Pieces CLI banner" align="center" fullwidth="true" />


## Pieces CLI
Expand Down Expand Up @@ -39,13 +39,13 @@ This software is designed to offer **two main features**: AI Assistance with the

Through the Pieces CLI, users can boost productivity by having AI-driven conversations that use [relevant notes and folders as context](/products/cli/copilot/chat), all within their terminal.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/pieces_context_chat.gif" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/pieces_context_chat.gif" alt="Using context in Pieces Copilot chat" align="center" fullwidth="true" />

### Integrated Snippet Management

With Pieces Drive and PiecesOS in their terminal, users can [save, search, and share their code snippets](/products/cli/drive). This enhances productivity by making reusable code accessible and organized within their notes and project files.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/CLI_MAIN/pieces_drive_list.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/CLI_MAIN/pieces_drive_list.png" alt="Pieces Drive list view in terminal" align="center" fullwidth="true" />

## Using Pieces Copilot

Expand All @@ -59,7 +59,7 @@ From here, you’ll find several actions, including:

* `Create and Delete`: Pieces CLI allows you to [manage your snippets easily from within your terminal](/products/cli/drive/saving-materials), allowing you to create and delete snippets.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/CLI_MAIN/edit_command.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/CLI_MAIN/edit_command.png" alt="Edit command interface for snippet metadata" align="center" fullwidth="true" />

## Managing Your Code Snippets

Expand All @@ -73,7 +73,7 @@ To save a snippet, copy a section of text or code to your clipboard, head over t

When you save snippets to your Pieces Drive with Pieces CLI, they get AI-generated metadata like [tags, titles, authorship details, and descriptions](/products/cli/drive/saving-materials#whats-stored-when-you-save-a-snippet). This keeps everything organized and easy to access and use at any point.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/CLI_MAIN/snippet_content.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/CLI_MAIN/snippet_content.png" alt="Saved snippet content display" align="center" fullwidth="true" />

### Referencing & Reusing

Expand All @@ -93,7 +93,7 @@ A new terminal window will open and you’ll be presented with a list of materia

Scroll down or up with the `arrow keys` and select the material by pressing `enter`. The material will display with its attributes and the code that was stored in the material.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/CLI_MAIN/ncs_search_results.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/CLI_MAIN/ncs_search_results.png" alt="Neural code search results list" align="center" fullwidth="true" />

***

Expand Down
2 changes: 1 addition & 1 deletion public/content/cli/commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ status: PUBLISHED

Below is a table containing all the commands available for use in the Pieces CLI.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/commands/pieces_help.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/commands/pieces_help.png" alt="Pieces CLI help menu" align="center" fullwidth="true" />

### Command Table

Expand Down
4 changes: 2 additions & 2 deletions public/content/cli/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ status: PUBLISHED

Configure the Pieces CLI by changing both language models and the code editor.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/configuration/available_models.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/configuration/available_models.png" alt="Available models and settings configuration" align="center" fullwidth="true" />

> Available models and settings configuration interface

## Supported LLMs

The Pieces CLI supports 26 cloud-based language models that you can switch between.

We continually update and configure our plugins and extensions to ensure compatibility with the latest large language models (LLMs).
We continually update and configure our MCP integrations to ensure compatibility with the latest large language models (LLMs).

| Supported LLMs | Supported LLMs |
| ----------------------------- | ---------------- |
Expand Down
4 changes: 2 additions & 2 deletions public/content/cli/copilot.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ If you're facing an issue or stuck on a difficult debug, ask the Pieces Copilot

You can ask questions that don't need context, like *“What is the basic format for a JSON object?”* or more detailed questions where the Pieces Copilot requires context from your saved materials.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/_MAIN/pieces_ask_question.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/_MAIN/pieces_ask_question.png" alt="Asking a question to Pieces Copilot" align="center" fullwidth="true" />

## Adding Conversation Context

Contextual awareness lets the Pieces Copilot help you solve problems faster by providing relevant answers to your issue and notes.

To best add conversation context, [include materials](/products/cli/copilot/chat#via-material-index) or [file context](/products/cli/copilot/chat#via-file-path) for more accurate responses from the Pieces Copilot chat.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/_MAIN/adding_file.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/_MAIN/adding_file.png" alt="Adding file context to Copilot chat" align="center" fullwidth="true" />

## Pieces Copilot As a Daily Driver

Expand Down
12 changes: 6 additions & 6 deletions public/content/cli/copilot/chat.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ To quickly start a conversation with Pieces Copilot:

If you’re not in Pieces CLI, in your terminal, you can type `pieces ask query`, replacing `query` with your question.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/ask_pieces.gif" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/ask_pieces.gif" alt="Using the ask command in Pieces CLI" align="center" fullwidth="true" />
</Step>
</Steps>

Expand Down Expand Up @@ -67,7 +67,7 @@ You can narrow Copilot’s focus by feeding it specific materials or files when

Pieces Copilot will load material #4 as context.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/pieces_context_chat.gif" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/pieces_context_chat.gif" alt="Providing material context to Copilot" align="center" fullwidth="true" />
</Step>
</Steps>

Expand Down Expand Up @@ -95,7 +95,7 @@ Use a folder of specific file as context for Pieces Copilot by initiating the co

Copilot loads material #2 and `specs.md` before generating its response.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/adding_file.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/adding_file.png" alt="Adding multiple contexts to chat query" align="center" fullwidth="true" />
</Step>
</Steps>

Expand Down Expand Up @@ -123,7 +123,7 @@ Run `pieces mcp setup` from your terminal to open an interactive menu and automa
* Raycast
* Warp

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/selecting_mcp_option.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/selecting_mcp_option.png" alt="MCP platform selection menu" align="center" fullwidth="true" />

</Step>

Expand All @@ -142,7 +142,7 @@ The `mcp list` command displays the current implementations of Pieces MCP on you

The Pieces CLI supports integration with [VS Code](/products/mcp/vs-code), [Cursor](/products/mcp/cursor), [Claude Desktop](/products/mcp/claude-desktop), [Windsurf](/products/mcp/windsurf), [Claude Code](/products/mcp/claude-code), [Raycast](/products/mcp/raycast), Warp, [GitHub Copilot](/products/mcp/github-copilot), and [Goose](/products/mcp/goose).

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/mcp_list.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/mcp_list.png" alt="MCP implementations list" align="center" fullwidth="true" />

### Docs

Expand All @@ -162,5 +162,5 @@ If it finds that an implementation is broken, it will ask if you want to auto-re

Type `y` for yes or `n` for no, and press `return` (macOS) or `enter` (Windows/Linux) to confirm your choice.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/finish_setup_mcp.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/chat/finish_setup_mcp.png" alt="MCP setup completion confirmation" align="center" fullwidth="true" />

2 changes: 1 addition & 1 deletion public/content/cli/copilot/llms-settings.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Follow the steps below to change the cloud LLM utilized by the Pieces MCP:

Use your `scroll wheel` or `arrow keys` to navigate to your desired LLM and press `return` (macOS) or `enter` (Windows/Linux) to set the LLM runtime.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/llms_settings/available_models.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_copilot/llms_settings/available_models.png" alt="List of available LLM models" align="center" fullwidth="true" />
</Step>
</Steps>

Expand Down
8 changes: 4 additions & 4 deletions public/content/cli/drive.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,21 +38,21 @@ By using the Pieces CLI, capture and manage snippets in Pieces Drive to streamli

Easily [save a function, script, or piece of boilerplate](/products/cli/drive/saving-materials) directly from the tool menu or with a keyboard shortcut. These snippets are stored in your personal Pieces Drive and include context, metadata, and tags for easy retrieval.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/_MAIN/saved_snippet_displayed.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/_MAIN/saved_snippet_displayed.png" alt="Saved snippet details with metadata" align="center" fullwidth="true" />

To save a code snippet, copy a snippet from a website or your IDE, go over to the Pieces CLI, and type `create`. If you’re not in a running Pieces CLI, you can type `pieces create` and enter the command.

This will automatically grab whatever is in your clipboard and save it to your Pieces Drive.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/_MAIN/pieces_create.gif" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/_MAIN/pieces_create.gif" alt="Creating a new snippet with pieces create command" align="center" fullwidth="true" />

### Search & Reuse

You can search your collection of saved materials directly from your terminal. This lets you quickly find snippets using keywords or context.

To search, you can access the `search` action inside of the Pieces CLI.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/_MAIN/pieces_search_interm.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/_MAIN/pieces_search_interm.png" alt="Search interface in Pieces CLI" align="center" fullwidth="true" />

From within Pieces CLI you can enter `search “query”` to do a basic search. If you’re not within the Pieces CLI, you can enter `pieces search “query”`.

Expand All @@ -72,7 +72,7 @@ In the `pieces save` command of the **Pieces Drive** within Pieces Copilot, open

This keeps your library up-to-date, relevant, and aligned with your project's progress. Enhancing your materials makes them more efficient, which benefits you in the long run.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/_MAIN/edit_command.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/_MAIN/edit_command.png" alt="Edit command for updating snippets" align="center" fullwidth="true" />

### Reusable Scheduling Functions

Expand Down
4 changes: 2 additions & 2 deletions public/content/cli/drive/edit-and-update.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ Follow the steps below to edit a saved material in the Pieces CLI.

Any changes made and saved within your IDE will update the Pieces Drive automatically, allowing you to use the changed snippet immediately.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/edit_update/editing_saving.gif" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/edit_update/editing_saving.gif" alt="Modifying snippet in IDE and auto-saving" align="center" fullwidth="true" />
</Step>
</Steps>

Expand All @@ -51,7 +51,7 @@ With the Pieces CLI, you can rename saved materials and have those changes apply

This will open a new prompt for you to change the name and classification for the snippet.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/edit_update/edit_command.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/edit_update/edit_command.png" alt="Edit command interface for renaming snippets" align="center" fullwidth="true" />

When you’re complete, the snippet will update across your Pieces Drive automatically.
</Step>
Expand Down
6 changes: 3 additions & 3 deletions public/content/cli/drive/saving-materials.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ For Pieces CLI, you can save a snippet to your Pieces Drive with one command.

If you’re within the Pieces CLI `pieces run` mode, you can enter `create`.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/saving_snippet/pieces_create.gif" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/saving_snippet/pieces_create.gif" alt="Running pieces create command to save a snippet" align="center" fullwidth="true" />
</Step>
</Steps>

Expand All @@ -65,13 +65,13 @@ The Pieces Copilot captures several different kinds of metadata:

* `Related People`: Associated collaborators or contributors.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/saving_snippet/saved_snippet_displayed.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/saving_snippet/saved_snippet_displayed.png" alt="Saved snippet showing metadata and details" align="center" fullwidth="true" />

Furthermore, the Pieces Copilot reviews stored snippets for sensitive data, including API keys, passwords, and authentication tokens, ensuring that **no confidential information** is unintentionally saved.

## Where Saved Snippets Live

Saved snippets are stored locally on your device, ensuring offline accessibility. This also means that any Pieces extension, plugin, or even the Pieces Desktop App, has constant, up-to-date access to your saved materials with Pieces Drive.
Saved snippets are stored locally on your device, ensuring offline accessibility. This also means that any Pieces MCP integration or even the Pieces Desktop App has constant, up-to-date access to your saved materials with Pieces Drive.

You can find your saved snippets via the `pieces list` command or the `pieces search` feature.

Expand Down
6 changes: 3 additions & 3 deletions public/content/cli/drive/search-reuse.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ If you want to access your saved snippets directly within Pieces CLI, you can:

Alternatively, you can launch into Pieces CLI run mode with `pieces run`. This will enable you to just enter `search “query”`.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/search_reuse/ncs_search_results.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/search_reuse/ncs_search_results.png" alt="Neural code search results" align="center" fullwidth="true" />
</Step>
</Steps>

Expand All @@ -43,13 +43,13 @@ For example, `pieces search "query" --mode fts` will use the full-text search on

[Saved snippets](/products/cli/drive/saving-materials) can be viewed by opening them up directly from the Pieces Drive with `pieces list`, using your scroll wheel or arrow keys, and selecting the snippet with the `return` (macOS) or `enter` (Windows/Linux) key, all from within your terminal.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/search_reuse/pieces_drive_list.png" alt="" align="center" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/search_reuse/pieces_drive_list.png" alt="Pieces Drive materials list" align="center" fullwidth="true" />

In your terminal, you can also open snippets with the `pieces search “query” [optional: --mode ncs,fts]` command. If Pieces finds snippets that match your query, you will be presented with a list of snippets.

You can open a snippet from the list using your scroll wheel or arrow keys and select it with the `return` (macOS) or `enter` (Windows/Linux) key.

<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/search_reuse/search_snippets.gif" alt="" align="middle" fullwidth="true" />
<Image src="https://storage.googleapis.com/hashnode_product_documentation_assets/cli_assets/pieces_drive/search_reuse/search_snippets.gif" alt="Searching and selecting snippets" align="middle" fullwidth="true" />

***

Expand Down
Loading
Loading