Pieces for Developers Documentation

repository·main·Indexed 20 days ago

https://github.com/pieces-app/documentation

Documentation for Pieces for Developers, a code snippet management and workflow context platform. Includes guides for the Desktop App, Pieces OS, and extensions for VS Code, JetBrains, JupyterLab, Azure Data Studio, and Chrome. Features technical details on the Cleanup Documentation Project for automating markdown organization in TypeScript, Python, Dart, and Kotlin, as well as information on the Long-Term Memory Engine and open-source SDKs.

Tokens
50.5K
Snippets
70
Records
320
Agent score
70%

What's inside Pieces for Developers

  1. Overview of the Cleanup Documentation Project

    main
    The Cleanup Documentation Project is a collection of Python scripts designed to automate the organization, cleaning, and transformation of markdown documentation files. It supports documentation for TypeScript, Python, Dart, and Kotlin. The project enhances documentation quality by performing tasks such as link transformation, header level adjustment, variable/type formatting, and file reorganization.
  2. Overview of Pieces for Developers Azure Data Studio Extension

    main

    The Pieces for Developers Azure Data Studio Extension is a productivity tool designed to manage code snippets and workflow context directly within the IDE. It works in conjunction with the Pieces Flagship Desktop App to provide a cohesive layer for researching, collaborating, and writing code.

    Key capabilities include:

    • Saving & Enriching: Effortlessly save code snippets with automatic metadata extraction (over 15 heuristics) via the Context Awareness Engine.
    • Searching & Reusing: Use global search and atomic auto-complete to find and reuse saved materials.
    • Sharing: Share personalized links that include the necessary context and metadata for collaborators.
    • Generating: Solve coding problems faster using Copilot Chats powered by local and cloud-based LLMs (e.g., Llama 2, GPT-4, Gemini).
    • Workflow Continuity: Use the Workflow Activity Stream to pick up exactly where you left off.
  3. Overview of the Pieces CLI

    main

    The Pieces CLI is a command-line tool designed for interacting with Pieces OS. It provides programmatic access to core Pieces functionalities, including:

    • Code Snippet Management: Manage and interact with your saved code snippets directly from the terminal.
    • Copilot Interaction: Engage with Pieces Copilot features via the command line.
    • Feature Integration: Access and integrate various other Pieces OS features into your development workflow.
  4. Ways to add materials to Pieces

    main

    You can save various developer materials into Pieces for Developers using universal methods that work across most interfaces, or specific methods tailored to the platform you are using (Desktop, IDE plugins, or Web Extension).

    Supported Materials

    • Images: .png, .jpeg, .jpg, .gif
    • Raw Text or Code
    • Whole Files: Importing a directory allows Pieces to use Snippet Discovery to find individual snippets within that directory.
    • GitHub Gists: Imported via Snippet Discovery.
  5. What is Pieces OS and how does it work?

    main

    Pieces OS is a background service that acts as the core engine for the Pieces ecosystem. It enables local operations and handles communication between various integrations.

    Key functions of Pieces OS include:

    • Enabling Pieces to work locally.
    • Managing communications with installed plugins.
    • Allowing Pieces to save snippets.
    • Generating responses to user questions.
    • Enabling cloud-enabled features like link sharing.
  6. What is Pieces OS and why is it required?

    main

    Pieces OS is the essential background service that enables Pieces to function locally. It handles all communications with integrations (like the Azure Data Studio extension).

    Key functions of Pieces OS:

    • Enables saving of code snippets.
    • Facilitates interaction with IDE plugins.
    • Enables cloud synchronization for data access across devices.
    • Powers cloud-enabled features such as link sharing.

    Note: Without Pieces OS running, the Azure Data Studio extension will not be able to save snippets or interact with your workflow.

  7. What is Pieces OS?

    main

    Pieces OS is a background service that runs locally on your machine to facilitate communication between products in the Pieces for Developers Suite. It acts as the engine for the ecosystem, providing:

    • Local Execution: Enables products to operate 100% locally for privacy and speed.
    • Machine Learning Management: Manages local and cloud-based ML models used by Pieces Copilot.
    • Data & Search: Handles real-time search, suggestions, and data processing workflows.
    • Cloud Connectivity: While primarily local, it can connect to the cloud for backup, snippet sharing, and specific cloud-only ML models.
  8. Understand the Pieces for Developers installation components

    main

    When installing Pieces for Developers, you are installing two distinct but interconnected components:

    1. Pieces OS: A required background service that runs offline and on-device. It acts as the centralized storage agent that enables communication between different products in the Pieces suite. It manages local, private, and secure Machine Learning models, real-time search, and suggestions.
    2. Pieces Desktop App: The flagship visual GUI application. It provides the user interface for navigating snippets (via Gallery or List views), transforming code between languages, sorting snippets by AI-suggested usefulness, and interacting with the Pieces Copilot.

    Pieces OS is required for the suite to function, providing the local infrastructure for LLMs and data synchronization.

  9. Privacy and Security for Long-Term Memory

    main

    The Long-Term Memory feature is designed to be private by performing all data aggregation and LTME processing locally on your device.

    Privacy Recommendation: To ensure that no data leaves your device during the LLM interaction phase, it is strongly recommended to use a Local LLM (such as Mistral, Phi-2, or Llama2) with the Pieces Copilot. This ensures that both the context retrieval and the language model processing happen entirely offline/locally.

  10. How Pieces for Developers handles context in collaborative environments

    main

    In collaborative workflows where project context (decisions, architectures, implementations, and configs) is scattered across channels like Slack, Teams, or Discord, Pieces for Developers automates context preservation.

    When you save code snippets, the platform uses a Context Awareness Engine to automatically extract and associate over 15 metadata heuristics with that snippet. This ensures that the 'who, what, where, and why' behind a piece of code is preserved alongside the code itself. Additionally, the Pieces for Developers Desktop App allows you to toggle realtime and scope-relevant suggestions to help you find materials to save, reference, reuse, or share.

  11. Understand AI-generated snippet enrichments

    main

    When you save a snippet, Pieces automatically processes it to add the following context (enrichments):

    • Programming Language: Automatically detected.
    • Title: A generated title for the snippet.
    • Tags: A set of generated tags for categorization.
    • Description: A smart description explaining what the code does.
    • Search Suggestions: Suggestions for searches to help you learn more about the concepts in the snippet.
    • People/Authors: Information about people related to the snippet, extracted from Git history if the file is within a Git repository.