Skip to main content

Auto-Enrichment

Pieces for Developers enriches your content as you save snippets and makes it easy to get back to where you originally saved your code.

Learn how to Manage and Update Snippets and their Metadata

View Metadata & Enrichment Details

Shortcut: ⌘/CTRL + I

Pieces processes your saved materials completely in the background, giving you the ability to access more data around your resources and code snippets. You can view the information in the Pieces desktop app by:

  1. Pressing ⌘/CTRL + I to access the Context View
  2. In List View clicking the "View All Context" button on the top right of the Context Preview
  3. In Gallery View clicking the "View All Context" icon in the bottom left corner
    • When hovering over this icon, click the gear to manage how often the overlay appears.

Saving a Snippet's Origin Information

Saving a snippet’s original context is helpful for organization and future use. Pieces automatically extracts and saves the following contextual information:

  • Project Name
  • Source File
  • Line Numbers
  • Collaborators
  • Application Source (Chrome, Edge, VS Code, etc.)
  • Solution Publishers

Inside the Context View

Once you enter the Context View, you will see data added both automatically via Pieces' AI & GPT-4, and any enrichments that you have added manually.

Whether you are in List or Gallery View, you will have access to the same set of enrichments.

Annotations

Shortcut: ⌘/CTRL + Shift + N

Annotations allow you to include and categorize so much context about your code, from descriptions to summaries and Git commit messages.

Pieces for Developers auto-generates descriptions and other annotations, but you can manually add or reclassify information. To add or edit an annotation, go to the Context Menu and click the Annotations box, or use the keyboard shortcut ⌘/CTRL + Shift + N.

You can add the following Annotations to your snippets:

  • Description
  • Comment
  • Documentation
  • Summary
  • Explanation
  • Git Commit

Tags

Shortcut: ⌘/CTRL + T

Open the Tags drawer by clicking on the tags section or by using the ⌘/CTRL + T shortcut. This will bring pull up a list of tags that were generated when you saved the resource, along with suggested tags that you can quickly add to the snippet.

To create a custom tag, start typing and hit enter to add any tag you'd like directly into the pre-existing tags list.

Example Tags: HTTP Request, Flutter Framework, Dart Project, Conditional For Loop

Types of Tags

Auto Generated

These tags are generated the moment you save a resource to Pieces. They contain a sparkle icon before the tag.

Custom Tags

Tags that you write yourself and add to your resources. They will not contain the sparkle icon.

Removing Tags

To remove a tag:

  1. Press the X icon to the right of a tag
  2. A dialog will open up, and you can hit "Delete" to confirm the removal of the tag
    • You can also press Enter or Return

To cancel the deletion, press Esc to go back to the tags drawer

(Optional) You can press "Do not ask me again" to quickly delete a number of tags from a snippet, but we recommend keeping this confirmation turned on to protect against accidental deletions.


Shortcut: ⌘/CTRL + K

Related Links can be opened by clicking on the background of the Related Links section or via the ⌘/CTRL + K shortcut. Clicking any of the individual links directly will cause them to open in your browser.

Note: In the header of this section, you can see the total number of Related Links that you have.

From inside the Related Links drawer, you can add new links by typing or pasting them directly into the text box at the top. Not all text input will be accepted, so it is important to add a full http url such as: https://docs.pieces.app.

You can quickly copy any link from inside the Related Links drawer by pressing the copy button on the right side of the Related Link pill.

These links are generated the moment you save a resource to Pieces. They contain a sparkle icon before the link.

They also include the website's favicon.

These are links that you added to your resource yourself. They will not contain the sparkle icon.

They will still include the website's favicon.

To remove a specific link from its resource, inside the Related Links drawer:

  • Press the trashcan icon next to the copy icon to the right of the link
  • A confirmation drawer will open; you can confirm the removal by pressing the Delete key
    • You can also press Enter or Return
  • To cancel the deletion, press Esc to go back to the Related Links drawer

(Optional) You can press "Do not ask me again" to quickly delete a number of links from a snippet, but we recommend keeping this setting turned on to protect against accidental deletions.


Shortcut: ⌘/CTRL + L

Shareable links can be generated using the ⌘/CTRL + L shortcut or by clicking on the corresponding section in the Context View. This will open the Shareable Link drawer where you can manage the shareable link for a specific resource.

Note that all code snippets and resources have their own unique shareable link, and each link has to be generated separately.

Read about all the ins-and-outs of shareable links.


Shortcut: ⌘/CTRL + P

To facilitate communication among and between teams, Pieces for Developers attaches Related People to your saved snippets. Related People include content authors, open-source maintainers, GitHub collaborators, and others who are part of a snippet's context.

To access Related People, you can click the Related People section or press the ⌘/CTRL + P shortcut.

If a snippet is saved from a location that has no crossover with other users, it is likely that it will have the following message:

"No People Detected"

The advantage to saving snippets by importing them from GitHub gists is other users who have commented on the PR, contributed to the repo, or been involved in another way will show up here under related users.

You can add related people manually to any resource. When you share that resource, the information that you have attached will be included.

It requires two fields:

  1. A name to display in the Related People section
  2. An email for that user

If a Related Person is added, and you wish to remove them, you can do so by clicking the Pencil icon when you hover over the related person in the Related People drawer. Once you are in the edit drawer, you can click Delete next to the Save Button on the bottom of the drawer and the person will be removed.


Security Practices

Pieces for Developers facilitates security and programming best-practices by detecting sensitive information and warning against accidental uploads or sharing.

Smart Warnings and Sensitive Information Detection

Some of the most commonly saved snippets are Powershell and Command Line instructions, boilerplate for unit tests, .env variables, HTTP requests, and CI/CD build configs. These often contain sensitive data like API keys, auth tokens, usernames, passwords, or service account credentials. Pieces will auto-detect this sensitive information and warn you before sharing a snippet via a shareable link.