### Install and Setup PiecesOS via Snap Source: https://docs.pieces.app/products/extensions-plugins/jetbrains/get-started This snippet provides the commands to install PiecesOS using snap and connect its process-control interface. It also shows how to launch PiecesOS from the terminal. This is a prerequisite for the JetBrains plugin. ```shell sudo snap install pieces-os sudo snap connect pieces-os:process-control :process-control pieces-os ``` -------------------------------- ### Verify Pieces CLI Installation Source: https://docs.pieces.app/products/cli/get-started Checks if the Pieces CLI has been installed correctly by displaying its version information. If the command is not recognized, it suggests an alternative way to run it. ```bash pieces version ``` ```bash py -m pieces $command ``` -------------------------------- ### Launch PiecesOS Source: https://docs.pieces.app/products/cli/get-started Starts the PiecesOS application directly from the terminal after installation. ```bash pieces-os ``` -------------------------------- ### Install Pieces CLI using pip Source: https://docs.pieces.app/products/cli/get-started Installs the Pieces CLI using pip, a Python package installer. Ensure Python 3.xx is installed and added to your environment variables. ```bash pip install pieces-cli ``` -------------------------------- ### Install PiecesOS using Snap Source: https://docs.pieces.app/products/cli/get-started Installs PiecesOS using the snap package manager, a system for application deployment and management. This is a required dependency for the Pieces CLI. ```bash sudo snap install pieces-os ``` ```bash sudo snap connect pieces-os:process-control :process-control ``` -------------------------------- ### Install Pieces CLI using Conda Source: https://docs.pieces.app/products/cli/get-started Installs the Pieces CLI using Conda, a package and environment management system. This is an alternative for users who prefer Conda. ```bash conda install pieces-cli ``` -------------------------------- ### Install Pieces CLI using Homebrew (macOS) Source: https://docs.pieces.app/products/cli/get-started Installs the Pieces CLI on macOS using Homebrew, a popular package manager for the platform. This is an optional installation method for macOS users. ```bash homebrew install pieces-cli ``` -------------------------------- ### Run Initial Setup Process Source: https://docs.pieces.app/products/cli/commands Guides the user through the initial setup and configuration process for the Pieces CLI. ```bash onboarding ``` -------------------------------- ### Manual VSIX Installation for Visual Studio Extension Source: https://docs.pieces.app/products/extensions-plugins/visual-studio/get-started An alternative method to install the Pieces for Visual Studio Extension using a .VSIX installer file. This is useful if direct installation from the marketplace is not preferred or possible. ```text Alternatively, you can download the .VSIX installer from the Visual Studio Marketplace and install it manually. ``` -------------------------------- ### Install and Connect PiecesOS via Snap Source: https://docs.pieces.app/products/web-extension/get-started This snippet provides the commands to install PiecesOS using snap and connect it to process control. It also shows how to launch PiecesOS from the terminal. ```Shell sudo snap install pieces-os sudo snap connect pieces-os:process-control :process-control pieces-os ``` -------------------------------- ### Launch Pieces for Developers Source: https://docs.pieces.app/products/meet-pieces/linux-installation-guide Launches the Pieces for Developers application from the terminal after installation. ```bash pieces-for-developers ``` -------------------------------- ### Run Pieces CLI Source: https://docs.pieces.app/products/cli/get-started Launches the Pieces CLI application. Running this command allows subsequent commands to be executed without the 'pieces' prefix. ```bash pieces run ``` -------------------------------- ### Pieces CLI: Start a Session Source: https://docs.pieces.app/products/cli/get-started Explains how to initiate a new session with the Pieces CLI, allowing commands to be run without the 'pieces' prefix. Type 'pieces run' to start, and 'exit' to return to onboarding. ```Bash pieces run ``` ```Bash exit ``` -------------------------------- ### Pieces CLI: Ask Copilot a Question Source: https://docs.pieces.app/products/cli/get-started Details how to interact with Pieces Copilot to get answers. Users can ask questions directly via the CLI or within a running session using the 'ask $question' format, ensuring questions are enclosed in quotes. ```Bash pieces ask 'How to print I love Pieces CLI in Python and Java' ``` ```Bash ask $question ``` -------------------------------- ### Install Pieces for Visual Studio Extension Source: https://docs.pieces.app/products/extensions-plugins/visual-studio/get-started Instructions on how to install the Pieces for Visual Studio Extension directly from Visual Studio. This involves navigating to the Extensions view, searching for the extension, and clicking install, followed by a restart of Visual Studio. ```text 1. Open Visual Studio and navigate to the **Extensions** view in your toolbar. 2. Search for **Pieces for Visual Studio** and click `Install`. 3. Restart Visual Studio after installing the extension to complete the setup. ``` -------------------------------- ### Install PiecesOS on Linux Source: https://docs.pieces.app/products/core-dependencies/pieces-os/manual-installation Installs PiecesOS using snap. Requires administrator privileges and snapd support. Prompts for user password during installation. ```bash sudo snap install pieces-os ``` ```bash sudo snap connect pieces-os:process-control :process-control ``` ```bash pieces-os ``` -------------------------------- ### Install and Connect PiecesOS via Snap Source: https://docs.pieces.app/products/extensions-plugins/visual-studio-code/get-started This snippet shows the commands to install PiecesOS using snap and connect its process-control interface. It also includes the command to launch PiecesOS from the terminal. ```shell sudo snap install pieces-os sudo snap connect pieces-os:process-control :process-control then type pieces-os to launch the application directly from your terminal. ``` -------------------------------- ### Uninstall Pieces CLI with PIP Source: https://docs.pieces.app/products/cli/get-started Provides the command to uninstall the Pieces CLI if it was installed using PIP. ```Bash pip uninstall pieces-cli ``` -------------------------------- ### Update Pieces CLI using pip Source: https://docs.pieces.app/products/cli/get-started Updates the Pieces CLI to the latest version using pip. The '-U' flag ensures that the package is upgraded. ```bash pip install pieces-cli -U ``` -------------------------------- ### Pieces CLI: Save First Material Source: https://docs.pieces.app/products/cli/get-started Guides users to save their first piece of material using the Pieces CLI. It involves copying a snippet, pressing a key to proceed, typing 'pieces create', and confirming the save with 'y'. ```Bash pieces create ``` -------------------------------- ### Verify Ollama Dependencies Source: https://docs.pieces.app/products/core-dependencies/ollama/troubleshooting Ensure all required libraries and tools for Ollama are installed on your system. Refer to the installation guide for a list of prerequisites. ```bash # Example command to check dependencies (actual command may vary based on OS and installation method) # apt list --installed | grep ollama # brew list | grep ollama ``` -------------------------------- ### Install Pieces for Linux CLI Source: https://docs.pieces.app/products/meet-pieces/linux-installation-guide Installs the Pieces Desktop App and its core dependencies on Linux using snap commands. Requires administrator privileges and a supported Ubuntu version (22.04+). ```bash sudo snap install pieces-os sudo snap connect pieces-os:process-control :process-control sudo snap install pieces-for-developers ``` -------------------------------- ### Install and Connect PiecesOS (Linux) Source: https://docs.pieces.app/products/obsidian/get-started This snippet provides the necessary commands to install the PiecesOS snap package on Linux and connect it to the process-control interface. It also shows how to launch PiecesOS from the terminal. ```shell sudo snap install pieces-os sudo snap connect pieces-os:process-control :process-control then, type `pieces-os` to launch the application directly from your terminal. ``` -------------------------------- ### Pieces CLI: Provide Feedback Source: https://docs.pieces.app/products/cli/get-started Instructs users on how to provide feedback for the Pieces CLI. Typing 'pieces feedback' allows users to optionally open a GitHub discussion board for feedback. ```Bash pieces feedback ``` -------------------------------- ### Uninstall Pieces CLI with Conda Source: https://docs.pieces.app/products/cli/get-started Provides the command to uninstall the Pieces CLI if it was installed using Conda. ```Bash conda remove pieces-cli ``` -------------------------------- ### Pieces CLI: Contribute to Source Code Source: https://docs.pieces.app/products/cli/get-started Guides users on contributing to the Pieces CLI project. Typing 'pieces contribute' offers the option to open the project's source code on GitHub. ```Bash pieces contribute ``` -------------------------------- ### Install Pieces using Homebrew Source: https://docs.pieces.app/products/meet-pieces/macos-installation-guide This command installs the Pieces Desktop App and PiecesOS cask using Homebrew. Ensure Homebrew is installed on your system before running this command. You may be prompted for your administrator password. ```bash brew install --cask pieces ``` -------------------------------- ### Update Pieces CLI using Conda Source: https://docs.pieces.app/products/cli/get-started Updates the Pieces CLI to the latest version using Conda. This command is used by users who installed the CLI via Conda. ```bash conda update pieces-cli ``` -------------------------------- ### Pieces CLI: Install PiecesOS Source: https://docs.pieces.app/products/cli/configuration Download and set up the PiecesOS, which includes background services like Pieces Drive and a graphical dashboard for non-CLI tasks. This command installs the core Pieces environment. ```bash install ``` -------------------------------- ### Verify Ollama Installation (macOS) Source: https://docs.pieces.app/products/core-dependencies/ollama/manual-installation This command verifies the Ollama installation on macOS by checking its version. It's a crucial step after downloading and installing the Ollama package. ```bash ollama --version ``` -------------------------------- ### Pieces CLI: List Saved Materials Source: https://docs.pieces.app/products/cli/get-started Demonstrates how to view all saved materials using the Pieces CLI. Users type 'pieces list' and can navigate and select materials using keyboard shortcuts. ```Bash pieces list ``` -------------------------------- ### Install Pieces Plugin via Package Control Source: https://docs.pieces.app/products/extensions-plugins/sublime/get-started Steps to install the Pieces plugin within Sublime Text using the Package Control feature. This involves opening the command palette, searching for 'Package Control: Install Package', and then selecting 'Pieces'. ```Shell Package Control: Install Package Pieces ``` -------------------------------- ### Install PiecesOS with Homebrew (macOS) Source: https://docs.pieces.app/products/core-dependencies/pieces-os/manual-installation This snippet shows how to install PiecesOS on macOS using the Homebrew package manager. It assumes Homebrew is already installed. ```Shell brew install --cask pieces-os ``` -------------------------------- ### View MCP Documentation Link Source: https://docs.pieces.app/products/desktop/configuration/mcp This section provides information on accessing detailed guides for MCP integrations. It highlights that clicking 'View Documentation' leads to resources explaining setup, use cases, and troubleshooting for environments like Cursor and GitHub Copilot. ```Text Click `View Documentation` to access detailed guides that explain how to leverage MCP integrations with popular development environments, such as Cursor and GitHub Copilot. This documentation covers setup instructions, example scenarios, and troubleshooting tips for efficient MCP usage. ``` -------------------------------- ### Install PiecesOS for Windows Source: https://docs.pieces.app/products/extensions-plugins/visual-studio/get-started Provides a direct link to download PiecesOS for Windows, which is a required background service for the Pieces for Visual Studio Extension. It also mentions the operating system requirement. ```text Click below to download PiecesOS for Windows. PiecesOS — Windows _Windows 10 (20H0) or higher required_ ``` -------------------------------- ### Install Pieces App via Homebrew on macOS Source: https://docs.pieces.app/products/meet-pieces/macos-installation-guide This section outlines how to install PiecesOS and the Pieces Desktop App using Homebrew via the Mac's terminal. It serves as an alternative to the standard PKG or DMG installations. ```Shell # Example command for Homebrew installation (actual command not provided in text) # brew install pieces-app ``` -------------------------------- ### Pieces CLI: Initiate Contribution Workflow Source: https://docs.pieces.app/products/cli/configuration Start a contribution process by describing changes, which opens a pull-request template for submitting improvements to the CLI. This facilitates community contributions. ```bash contribute ``` -------------------------------- ### Remove Unused Dependencies Source: https://docs.pieces.app/products/meet-pieces/linux-installation-guide Cleans up any unused dependencies after uninstalling Pieces software. ```bash sudo apt autoremove ``` -------------------------------- ### Pieces CLI: Open PiecesOS Application Source: https://docs.pieces.app/products/cli/configuration Launch the desktop app or helper Applet, starting the service and GUI if not already running. This command provides access to the Pieces graphical interface. ```bash open ``` -------------------------------- ### Install Pieces OS and Desktop App via Homebrew Source: https://docs.pieces.app/products/meet-pieces/troubleshooting/macos This command uses Homebrew to automatically install both Pieces OS and the Pieces Desktop App on macOS. Homebrew simplifies the installation and management of software on macOS. ```Shell brew install --cask pieces ``` -------------------------------- ### Install Pieces via WinGet Source: https://docs.pieces.app/products/meet-pieces/windows-installation-guide This command allows for the installation of the Pieces for Developers application directly from the terminal using the Windows Package Manager (WinGet). Ensure you have WinGet installed and configured on your system. ```bash winget install "Pieces for Developers" ``` -------------------------------- ### Troubleshooting Node.js Installation in Raycast Source: https://docs.pieces.app/products/raycast Guidance for when a prompt to install Node.js appears upon first use of a Pieces command in Raycast. It covers initial attempts, what to do if installation fails, and when to seek further support. ```bash 1 Follow the on-screen prompts to install Node.js. 2 Fully close Raycast, then reopen Raycast and try the command again. 3 Visit our support page for help. ``` -------------------------------- ### Update Pieces CLI with sudo (Linux/macOS) Source: https://docs.pieces.app/products/cli/get-started Updates the Pieces CLI using pip with superuser privileges, which may be necessary on Linux or macOS systems for permission reasons. ```bash sudo pip install pieces-cli -U ``` -------------------------------- ### Uninstall Pieces Desktop Application Source: https://docs.pieces.app/products/meet-pieces/linux-installation-guide Removes the Pieces for Developers desktop application from the system using apt. ```bash sudo apt remove pieces-for-developers ``` -------------------------------- ### PiecesOS Installation Prompt Source: https://docs.pieces.app/products/raycast This code snippet shows the security prompt that appears when installing the PiecesOS application, which is downloaded from the internet. It requires user confirmation to proceed with the installation. ```shell PiecesOS is an app downloaded from the internet. Are you sure you want to open it? ``` -------------------------------- ### Start Pieces MCP Server via CLI Source: https://docs.pieces.app/products/mcp/claude-desktop This command starts the Pieces MCP server, which is used to integrate PiecesOS with Claude Desktop. It assumes the Pieces CLI is installed and accessible. ```Shell pieces mcp start ``` -------------------------------- ### Install Pieces Desktop App via WinGet Source: https://docs.pieces.app/products/meet-pieces/troubleshooting/windows Command to install the 'Pieces for Developers' application using the Windows Package Manager (WinGet). This is a command-line method for installation. ```bash winget install “Pieces for Developers” ``` -------------------------------- ### Update Ollama on Linux Source: https://docs.pieces.app/products/core-dependencies/ollama/manual-installation This command updates Ollama on Linux systems using the apt package manager. It ensures you have the latest stable release for compatibility with PiecesOS. ```bash sudo apt update && sudo apt upgrade ollama ``` -------------------------------- ### Install Pieces CLI using Pip Source: https://docs.pieces.app/products/cli/commands Installs the Pieces CLI package using pip, the Python package installer. Assumes Python is correctly set up. ```bash pip install pieces-cli ``` -------------------------------- ### React Example: Component Template Source: https://docs.pieces.app/products/web-extension/drive A React functional component template with basic hooks and styling setup. Provides a consistent starting point for building new components. ```javascript import React, { useState, useEffect } from 'react'; function MyComponent(props) { const [data, setData] = useState(null); useEffect(() => { // Fetch data or perform side effects }, []); return (

Hello, {props.name}!

{/* Component content */}
); } export default MyComponent; ``` -------------------------------- ### Install Pieces for Developers via WinGet Source: https://docs.pieces.app/products/desktop/troubleshooting/windows Install the Pieces for Developers application using the Windows Package Manager (WinGet) from your device's terminal. This command allows for a streamlined installation process. ```bash winget install "Pieces for Developers" ``` -------------------------------- ### Example: React Functional Component Template Source: https://docs.pieces.app/products/extensions-plugins/visual-studio/drive A React functional component template with basic hooks and styling setup, providing a consistent starting point for building new components. ```javascript import React, { useState, useEffect } from 'react'; function MyComponent(props) { const [count, setCount] = useState(0); useEffect(() => { // componentDidMount logic console.log('Component mounted'); return () => { // componentWillUnmount logic console.log('Component unmounted'); }; }, []); const handleClick = () => { setCount(prevCount => prevCount + 1); }; return (

Hello, {props.name}!

You clicked {count} times

); } export default MyComponent; ``` -------------------------------- ### Summarize Recent Work with Pieces Copilot Source: https://docs.pieces.app/products/quick-guides/ltm-prompting/examples Automate daily standups and status reports by asking Pieces Copilot to summarize your recent activities. The system prioritizes activities based on capture frequency, giving more weight to applications you use more often. Consider disabling calendar apps if their format causes AI confusion. ```English What was I working on yesterday? Give me a list of all the GitHub issues I was looking at yesterday in the Mustafar project. Summarize all the documents I was editing yesterday in Chrome and give me back a list of 5 bullet points that lists my main activities. ``` -------------------------------- ### Example: React Component Template (React) Source: https://docs.pieces.app/products/extensions-plugins/visual-studio-code/drive A basic React functional component template, including initial hooks and styling setup, to provide a consistent starting point for developing new React components. ```JavaScript // Example React functional component template import React, { useState, useEffect } from 'react'; function MyComponent(props) { const [count, setCount] = useState(0); useEffect(() => { // componentDidMount logic console.log('Component mounted'); return () => { // componentWillUnmount logic console.log('Component unmounted'); }; }, []); const handleClick = () => { setCount(prevCount => prevCount + 1); }; return (

Hello from MyComponent!

Count: {count}

); } export default MyComponent; ``` -------------------------------- ### Check Vulkan Health Source: https://docs.pieces.app/products/meet-pieces/troubleshooting/cross-platform This command-line utility helps diagnose issues with your Vulkan API installation. Running `vulkaninfo` will scan for errors or warnings, indicating potential problems with your GPU drivers or Vulkan setup. It's a crucial first step in troubleshooting Vulkan-related crashes. ```bash vulkaninfo ``` -------------------------------- ### Cloud Account Integration for Data Import Source: https://docs.pieces.app/products/desktop/onboarding The onboarding process allows users to sign in with cloud accounts like GitHub or Google to import code Gists and other relevant data. This enables local storage and sharing of developer materials, with an option to store snippets and backups in Pieces Cloud. ```text This step includes an option to sign in with GitHub, Google, or another wide range of options to import code Gists and relevant data. Pieces for Developers stores developer materials locally and allows you to share them with anyone you’d like. Signing in enables you to store snippets and backups in **Pieces Cloud**. ``` -------------------------------- ### Uninstall Ollama on macOS Source: https://docs.pieces.app/products/core-dependencies/ollama/manual-installation This command removes the Ollama installation from macOS. It's a direct file system operation to delete the Ollama binary. ```bash sudo rm -rf /[username]/local/bin/ollama ``` -------------------------------- ### Pieces CLI: Setup Pieces MCP Source: https://docs.pieces.app/products/cli/copilot/chat This snippet outlines the process for setting up the Pieces Model Context Protocol (MCP) using the Pieces CLI. It details the command to initiate the setup and the selection of target platforms like VS Code, Goose, or Cursor. ```bash mcp setup ``` -------------------------------- ### Get Format Snapshot (Shell) Source: https://docs.pieces.app/api-reference/apireference/format-snapshot Fetches a snapshot of a specific format from the Pieces API using a shell command. This example demonstrates how to make a GET request to the API endpoint. ```Shell curl -X GET "http://localhost:100/format/102ff265-fdfb-4142-8d94-4932d400199c" -H "accept: application/json" ``` -------------------------------- ### Save First Material with Pieces for Visual Studio Source: https://docs.pieces.app/products/extensions-plugins/visual-studio/get-started Describes the initial step in using the Pieces for Visual Studio extension: saving a first material. This action triggers the Pieces Drive to save a sample snippet, demonstrating the capture and organization functionality. ```text Click `Save your first material`, and Pieces will open the Pieces Drive to save a sample snippet, showing you how it works. You'll see the snippet immediately in the **Saved Materials** list. This demonstrates how Pieces captures items and keeps them organized for easy reuse. ``` -------------------------------- ### Uninstall PiecesOS Source: https://docs.pieces.app/products/meet-pieces/linux-installation-guide Removes PiecesOS from the system using apt. ```bash sudo apt remove pieces-os ``` -------------------------------- ### Selecting LLMs in Pieces Desktop App Source: https://docs.pieces.app/products/desktop/onboarding The Pieces Desktop App allows users to switch between different Large Language Models (LLMs), including cloud-hosted options and local, on-device models powered by Ollama. ```text You can also see the flashing LLM selector in the bottom-left corner of the app. This is where you’ll swap between cloud-hosted LLMs and local, on-device models, powered by Ollama—an optional dependency. ``` -------------------------------- ### Get Version Information (Node.js) Source: https://docs.pieces.app/api-reference/apireference/get-well-known-version Fetches version information from the Pieces API using Node.js. This example demonstrates making a GET request to the /.well-known/version endpoint and handling the JSON response. ```javascript const fetch = require('node-fetch'); const url = 'http://localhost:100/.well-known/version'; const options = {method: 'GET', headers: {accept: 'text/plain'}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` -------------------------------- ### Get Format Snapshot (Ruby) Source: https://docs.pieces.app/api-reference/apireference/format-snapshot Fetches a snapshot of a specific format from the Pieces API using Ruby. This example shows how to make an HTTP GET request and process the JSON response. ```Ruby require 'net/http' require 'uri' require 'json' uri = URI.parse('http://localhost:100/format/102ff265-fdfb-4142-8d94-4932d400199c') response = Net::HTTP.start(uri.host, uri.port, :use_ssl => uri.scheme == 'https') do |http| request = Net::HTTP::Get.new(uri) request['accept'] = 'application/json' http.request(request) end if response.is_a?(Net::HTTPSuccess) data = JSON.parse(response.body) puts data else puts "Error: #{response.code} #{response.message}" end ``` -------------------------------- ### Check for PiecesOS Updates Source: https://docs.pieces.app/products/core-dependencies/pieces-os/quick-menu Explains how to check for and install PiecesOS updates via the Quick Menu, including visual indicators for update availability. ```Markdown Directly under your account information, the Quick Menu displays your current PiecesOS version and whether it is up to date. If a new update is available, you will see an `Update Available` button. Clicking it will initiate the update process. If PiecesOS is up to date, the menu will display a green check mark and show the active version—i.e., 11.0.4. ``` -------------------------------- ### Get Format Snapshot (PHP) Source: https://docs.pieces.app/api-reference/apireference/format-snapshot Fetches a snapshot of a specific format from the Pieces API using PHP. This example demonstrates making a GET request using cURL and handling the JSON response. ```PHP ``` -------------------------------- ### PiecesOS Quick Menu Actions Source: https://docs.pieces.app/products/core-dependencies/pieces-os/quick-menu Details the various views and buttons available in the PiecesOS Quick Menu for managing account, updates, LTM, and settings. ```Markdown **View / Button** | **Explanation** ---|--- _Account_ | You can log in or log out of your Pieces Account. _Version_ | Check for and automatically install available PiecesOS updates. _Long-Term Memory Engine_ | Enable or disable LTM. _Long-Term Memory Access Control_ | Enable or disable sources from which LTM captures contextual workflow data. _Settings_ | Adjust settings like launch on login, enabled Pieces products, ML processing configurations, telemetry permissions, or optimize RAM usage. _Activity_ | View recent LTM activity, like most recent Copilot Chats, people, and related websites. _Resources_ | Find links to documentation and Pieces for Developers social accounts. ``` -------------------------------- ### Get Sensitives Snapshot (Node.js) Source: https://docs.pieces.app/api-reference/apireference/sensitives-snapshot Retrieves a snapshot of all sensitive information using the /sensitives GET endpoint. This Node.js example uses the 'node-fetch' library to make the HTTP request and handle the JSON response. ```Node const fetch = require('node-fetch'); const url = 'http://localhost:100/sensitives'; const options = {method: 'GET', headers: {accept: 'application/json'}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` -------------------------------- ### Hints Listing and Creation Source: https://docs.pieces.app/api-reference/apireference/sign-out-of-OS Endpoints for listing, creating, searching, and deleting hints. ```HTTP GET /hints POST /hints/create POST /hints/search POST /hints/{hint}/delete ``` -------------------------------- ### Open Command Palette in VS Code Source: https://docs.pieces.app/products/extensions-plugins/visual-studio-code/get-started This describes the keyboard shortcuts to open the command palette in Visual Studio Code on different operating systems. ```text Open the command palette in VS Code with ⌘+shift+p (macOS) or ctrl+shift+p (Windows/Linux) ``` -------------------------------- ### Open PiecesOS or Helper Applet Source: https://docs.pieces.app/products/cli/commands Launches the main PiecesOS application or its associated helper Applet. ```bash open ``` -------------------------------- ### Get Backup Restoration Status Source: https://docs.pieces.app/api-reference/apireference/backup-specific-restoration-status Retrieves the restoration status of a specific backup. Requires the backup identifier as a path parameter. Supports GET requests and returns JSON responses. Includes example implementations in Node.js. ```Node const fetch = require('node-fetch'); const url = 'http://localhost:100/backup/backup/restoration/status'; const options = {method: 'GET', headers: {accept: 'application/json'}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` -------------------------------- ### Pieces API GET Request (Node.js) Source: https://docs.pieces.app/api-reference/apireference Fetches a preview of a publically accessible Piece from the Pieces API. This example uses Node.js with the 'node-fetch' library. It sends a GET request to the base URL and expects an HTML response. ```Node const fetch = require('node-fetch'); const url = 'http://localhost:100/'; const options = {method: 'GET', headers: {accept: 'text/html'}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` -------------------------------- ### Uninstall Pieces for JetBrains Plugin Source: https://docs.pieces.app/products/extensions-plugins/jetbrains/get-started Instructions on how to uninstall the Pieces for JetBrains plugin from the JetBrains IDE. This involves navigating through the IDE's plugin settings and restarting the IDE. ```IDE Actions Navigate to Settings > Plugins > Installed. Find the Pieces plugin. Click the uninstall button in the dropdown menu. Restart the JetBrains IDE. ``` -------------------------------- ### Get All Ranges (Node.js) Source: https://docs.pieces.app/api-reference/apireference/ranges-snapshot Retrieves a snapshot of all ranges using the Pieces API. This endpoint requires a GET request to the /ranges URL. The example demonstrates how to use the 'node-fetch' library to make the request and handle the JSON response. ```javascript const fetch = require('node-fetch'); const url = 'http://localhost:100/ranges'; const options = {method: 'GET', headers: {accept: 'application/json'}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` -------------------------------- ### Hints Listing and Creation Source: https://docs.pieces.app/api-reference/apireference/os-applet-launch Endpoints for listing, creating, searching, and deleting hints. ```HTTP GET /hints POST /hints/create POST /hints/search POST /hints/{hint}/delete ``` -------------------------------- ### Pieces CLI: List Registered Applications Source: https://docs.pieces.app/products/cli/configuration View all registered applications and their IDs to verify available integrations. This command helps manage your Pieces CLI integrations. ```bash list apps ``` -------------------------------- ### Reinstall Ollama Source: https://docs.pieces.app/products/core-dependencies/ollama/troubleshooting Uninstall any previous version of Ollama and perform a clean installation to resolve potential issues. ```bash # Example commands for uninstallation and reinstallation (commands vary by OS) # sudo apt remove ollama # sudo apt autoremove # curl -fsSL https://ollama.com/install.sh | sh ``` -------------------------------- ### JetBrains Plugin Installation and Compatibility Source: https://docs.pieces.app/products/extensions-plugins/jetbrains Instructions for installing the Pieces for JetBrains Plugin and details on its compatibility with various JetBrains IDEs and version requirements. ```text Minimum version required for the Pieces for JetBrains Plugin to work in your JetBrains IDE is **2023.1.** This plugin is currently available for use in any JetBrains IDE, such as: * IntelliJ IDEA * WebStorm * PhpStorm * PyCharm * CLion * GoLand * Rider * RubyMine * DataGrip * AppCode * Android Studio ``` -------------------------------- ### JetBrains Plugin Installation and Compatibility Source: https://docs.pieces.app/extensions-plugins/jetbrains Instructions for installing the Pieces for JetBrains Plugin and details on its compatibility with various JetBrains IDEs and version requirements. ```text Minimum version required for the Pieces for JetBrains Plugin to work in your JetBrains IDE is **2023.1.** This plugin is currently available for use in any JetBrains IDE, such as: * IntelliJ IDEA * WebStorm * PhpStorm * PyCharm * CLion * GoLand * Rider * RubyMine * DataGrip * AppCode * Android Studio ``` -------------------------------- ### Display Help Message Source: https://docs.pieces.app/products/cli/commands Provides a comprehensive help message detailing all available commands and their usage. ```bash help ``` -------------------------------- ### Update Snap Daemon on Linux Source: https://docs.pieces.app/products/meet-pieces/troubleshooting/linux This command ensures that the snap daemon and its associated packages are up-to-date, which is a requirement for snap-based installations on Linux. ```bash sudo snap refresh ``` -------------------------------- ### Logout Endpoint (Shell) Source: https://docs.pieces.app/api-reference/apireference/auth0-logout Fetches the logout endpoint using a shell command. This example shows how to make a GET request to the logout URL. ```Shell curl -X GET "http://localhost:100/v2/logout" -H "accept: text/html" ``` -------------------------------- ### Prompt Pieces Copilot for Implementation Source: https://docs.pieces.app/products/quick-guides/copilot-with-context This snippet demonstrates how to prompt Pieces Copilot to provide guidance on implementing a specific issue within the provided project context. ```Markdown How can I implement this issue in this project? ``` -------------------------------- ### Export Asset (PHP) Source: https://docs.pieces.app/api-reference/apireference/asset-specific-asset-export Retrieves an export version of the specified asset using PHP. This example uses cURL to make the GET request. ```PHP ``` -------------------------------- ### Logout Endpoint (PHP) Source: https://docs.pieces.app/api-reference/apireference/auth0-logout Fetches the logout endpoint using PHP. This example demonstrates how to make a GET request to the logout URL and retrieve the response. ```PHP ``` -------------------------------- ### OS Interaction API Source: https://docs.pieces.app/api-reference/apireference/onboarded Endpoints for interacting with the operating system, including launching/terminating applets, opening URLs, accessing device information, file operations, and managing settings. Supports GET, POST, and WS. ```HTTP POST /os/applet/launch POST /os/applet/restart POST /os/applet/terminate POST /os/browser/url/open GET /os/device/information POST /os/filesystem/file/open WS /os/filesystem/file/read/streamed POST /os/filesystem/files/pick POST /os/filesystem/folders/pick POST /os/filesystem/path/verify POST /os/link_provider POST /os/memory/optimize GET /os/permissions POST /os/permissions/request GET /os/settings WS /os/settings/stream POST /os/settings/update POST /os/sign_in POST /os/sign_out POST /os/terminate POST /os/update/check GET /os/update/check/stream ``` -------------------------------- ### Logout Endpoint (Ruby) Source: https://docs.pieces.app/api-reference/apireference/auth0-logout Fetches the logout endpoint using Ruby. This example demonstrates how to make a GET request to the logout URL and handle the response. ```Ruby require 'net/http' require 'uri' uri = URI.parse('http://localhost:100/v2/logout') response = Net::HTTP.start(uri.host, uri.port) do |http| request = Net::HTTP::Get.new uri request['accept'] = 'text/html' http.request(request) end puts response.body ``` -------------------------------- ### Logout Endpoint (Node.js) Source: https://docs.pieces.app/api-reference/apireference/auth0-logout Fetches the logout endpoint using Node.js. This example demonstrates how to make a GET request to the logout URL and handle the response. ```Node const fetch = require('node-fetch'); const url = 'http://localhost:100/v2/logout'; const options = {method: 'GET', headers: {accept: 'text/html'}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` -------------------------------- ### QGPT API Endpoints Source: https://docs.pieces.app/api-reference/apireference/os-filesystem-pick-folders Endpoints for querying and interacting with QGPT, including hints, related persons, questions, relevance, reprompts, and streaming responses. Supports POST and WS. ```HTTP POST /qgpt/hints POST /qgpt/persons/related POST /qgpt/question POST /qgpt/relevance POST /qgpt/reprompt GET /qgpt/stream ``` -------------------------------- ### Export Asset (Python) Source: https://docs.pieces.app/api-reference/apireference/asset-specific-asset-export Retrieves an export version of the specified asset using Python. This example utilizes the 'requests' library to make a GET request. ```Python import requests url = "http://localhost:100/asset/2254f2c8-5797-40e8-ac56-41166dc0e159/export?export_type=HTML" headers = {"accept": "application/json"} response = requests.get(url, headers=headers) print(response.json()) ``` -------------------------------- ### Theme Selection in Pieces Desktop App Source: https://docs.pieces.app/products/desktop/onboarding When first launching the Pieces Desktop App, users can select between 'Light' or 'Dark' theme modes. This setting can either be user-defined or automatically follow the system's preferences. ```text When you first launch the Pieces Desktop App, you can choose from `Light` or `Dark` theme modes to suit your preferences; otherwise, this mode is tied to your system's preferences and will change periodically. ``` -------------------------------- ### Disconnect from Pieces Cloud in VS Code Source: https://docs.pieces.app/products/extensions-plugins/visual-studio-code/get-started This describes the steps to disconnect from the Pieces Cloud within VS Code by using the command palette. ```text Enter Pieces: Disconnect from Pieces Cloud and choose the option ``` -------------------------------- ### React Functional Component Template Source: https://docs.pieces.app/products/obsidian/drive A basic React functional component template with hooks and styling setup, providing a consistent starting point for new components. ```javascript import React, { useState, useEffect } from 'react'; function MyComponent(props) { const [count, setCount] = useState(0); useEffect(() => { // componentDidMount logic return () => { // componentWillUnmount logic }; }, []); const handleClick = () => { setCount(count + 1); }; return (

Hello, {props.name}!

You clicked {count} times

); } export default MyComponent; ``` -------------------------------- ### Pieces CLI: List Configured AI Models Source: https://docs.pieces.app/products/cli/configuration Display all AI models configured for the 'ask' command, showing each model's name, index, and active status. This helps in managing and selecting AI models for use. ```bash list models ``` -------------------------------- ### Install PiecesOS and Pieces Desktop App via Linux CLI Source: https://docs.pieces.app/products/desktop/download This snippet provides the sequence of commands to install PiecesOS and the Pieces Desktop App on Linux using the snap package manager. It includes connecting the PiecesOS snap for offline ML functionality and launching the application. ```bash sudo snap install pieces-os sudo snap connect pieces-os:process-control :process-control sudo snap install pieces-for-developers pieces-for-developers ``` -------------------------------- ### Check CPU Type (macOS) Source: https://docs.pieces.app/products/meet-pieces/troubleshooting/macos Guidance on determining the CPU architecture (Intel or Apple Silicon/ARM) of an Apple device, crucial for downloading the correct installation package. ```text 1. Click the **Apple () icon** in the top-left corner of your screen. 2. Select **About This Mac** , and look for the **Overview section.** The first line will contain your CPU type: * **Apple Silicon / ARM:** You will see an M-Series processor, e.g., `Apple M3` * **Intel:** You will see an Intel processor, e.g., `2.6 GHz Intel Core i7` ``` -------------------------------- ### Advanced Prompting with Time Ranges, Sources, and Topics Source: https://docs.pieces.app/products/mcp/prompting Refine your queries by incorporating advanced parameters such as specific time ranges, application sources (e.g., Chrome, Notion), and relevant topics (e.g., 'authentication migration project'). This helps in retrieving more accurate and targeted contextual data. ```text Examples: "yesterday" "April 2nd through April 6th" "Stack Overflow pages I visited on Chrome" "meeting notes from Notion" "Show recent work I’ve done on the authentication migration project" "What JavaScript code related to API authentication did I write in VS Code yesterday?" "Find notes on database changes between Monday and Wednesday." ``` -------------------------------- ### Anonymous Data Sharing Option Source: https://docs.pieces.app/products/desktop/onboarding Users have the option to share anonymous crash data to help improve the Pieces Desktop App. This is a privacy-conscious feature during the initial setup. ```text You can also decide if you want to share _anonymous crash data_ to help improve the product. ``` -------------------------------- ### JetBrains Plugin Command Descriptions Source: https://docs.pieces.app/products/extensions-plugins/jetbrains/commands Lists commands accessible via the Command Palette in the Pieces for JetBrains Plugin, explaining their functionality such as launching the Copilot, opening Pieces Drive, and managing cloud connections. ```Markdown **Pieces Copilot** | Launches the Pieces Copilot in the side panel, providing contextual insights and assistance for the currently open code. ---|--- **Pieces Drive** | Opens the Pieces Drive window, showing information about the Pieces for JetBrains Plugin, the Pieces Community, and Support resources. **Ask Copilot** | Allows you to ask the Pieces Copilot about the active file open in the JetBrains Environment if no code is selected. If a code section is selected, it allows you to ask about the selection. **Import User Materials to Pieces** | Import external user materials (i.e., snippets) into Pieces Drive to seamlessly integrate them into your workflow. **Disconnect from Pieces Cloud** | Disconnect from your Pieces Cloud account while keeping local functionality intact. **Connect to Pieces Cloud** | Connect to the Pieces Cloud and sync VS Code with Pieces Cloud. **Sign into Pieces** | Sign in to your Pieces Cloud account and sync local databases. **Save File to Pieces** | Save the active code file in the VS Code editor to Pieces. **Save Current Selection to Pieces** | Save a selected code snippet to Pieces. **Sign Out** | Log out of your Pieces account entirely, disabling local and cloud-connected features. **Pieces Copilot** | Opens the Pieces Copilot on the side of the VS Code editor. **Search Pieces Drive** | Opens the Pieces Drive window, allowing you to search. ``` -------------------------------- ### MCP SSE Endpoint Integration Source: https://docs.pieces.app/installation-getting-started/what-am-i-installing Instructions on how to integrate the Pieces Model Context Protocol (MCP) into other IDEs and productivity tools. This involves copying the Server-Sent Events (SSE) endpoint URL or JSON schema from the Pieces Desktop App's settings into your chosen application. ```text Copy the SSE endpoint URL and/or .json schema into your IDE of choice. You can find the MCP URL inside the **Model Context Protocol (MCP)** tab within **Settings**. ``` -------------------------------- ### Launch PiecesOS on Linux Source: https://docs.pieces.app/products/core-dependencies/pieces-os/quick-menu This command is used to launch the PiecesOS application on a Linux system. It is typically executed from the terminal. ```bash pieces-os ``` -------------------------------- ### Fetch Pieces OS Settings (Node.js) Source: https://docs.pieces.app/api-reference/apireference/os_settings_snapshot Fetches a snapshot of the piecesOS settings using a GET request. This example demonstrates how to make the request using the 'node-fetch' library and handle the JSON response. It requires the 'node-fetch' package to be installed. ```Node const fetch = require('node-fetch'); const url = 'http://localhost:100/os/settings'; const options = {method: 'GET', headers: {accept: 'application/json'}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` -------------------------------- ### Generating Work Summaries with Pieces Copilot Source: https://docs.pieces.app/products/desktop/onboarding Users can prompt Pieces Copilot to generate a summary of recent work using LTM data. This feature helps in creating stand-up style summaries based on captured workflow activities. ```text Clicking the flashing button that reads _“Generate a stand-up styled summary of my recent work”_ to have Pieces Copilot use LTM data to generate an output of what you did during the memory-capturing process. ``` -------------------------------- ### Check Vulkan Health Source: https://docs.pieces.app/products/core-dependencies/ollama/troubleshooting This command checks the health and status of your Vulkan installation, which is crucial for identifying potential issues with Vulkan-based GPUs used in AI and LLM tasks. It helps detect errors or warnings that might cause crashes or instability. ```bash vulkaninfo ``` -------------------------------- ### QGPT API Endpoints Source: https://docs.pieces.app/api-reference/apireference/os-filesystem-file-open Endpoints for querying and interacting with QGPT, including hints, related persons, questions, relevance, reprompts, and streaming responses. Supports POST and WS. ```HTTP POST /qgpt/hints POST /qgpt/persons/related POST /qgpt/question POST /qgpt/relevance POST /qgpt/reprompt GET /qgpt/stream ```