Recording patterns

In 1.91.1 nothing records patterns: there is no patterns record command and no end-of-task prompt. A PatternRecorder class exists in the package's JavaScript interface for developers, and patterns export is the only way to share.

  • Patterns library
  • Checked against paqad-ai 1.91.1
  • Reviewed 25 September 2026 by Eliyce

The short answer

In paqad-ai 1.91.1 there is no command and no workflow step that records a pattern in the pattern library. Paqad does not ask you at the end of a task whether to save the solution, and there is no paqad-ai patterns record command. The paqad-ai patterns command has three subcommands only: list, prune and export.

The pattern library is a per-machine store of past solutions in ~/.paqad/patterns/; The cross-project pattern library describes it. Unless something else has written to that folder, it stays empty.

Earlier versions of this page described an automatic recording step. That step is not part of 1.91.1. This page describes what the release does contain, so you can decide whether it is useful to you.

What the release does contain

The code that saves a pattern exists, as a class called PatternRecorder. It is exported from the paqad-ai package's JavaScript interface, so a developer can call it from their own Node.js script. Nothing in the command-line tool, the hooks or the workflows calls it.

When called, it creates a new random id, stamps created_at with the current time, saves the full record to ~/.paqad/patterns/entries/<id>.json and adds a summary line to ~/.paqad/patterns/index.json. The category is taken from the category you pass, then the workflow name, and falls back to general.

Recording a pattern from a script

This is an example for developers who want to try it. It needs Node.js 22 or later and paqad-ai installed where the script can import it. Treat it as a library call, not a supported workflow.

import { PatternRecorder, PatternStore } from 'paqad-ai';

const recorder = new PatternRecorder(new PatternStore());

await recorder.record({
  classification: { category: 'authorisation' },
  projectDirName: 'billing-service',
  domain: 'coding',
  frameworks: ['laravel'],
  traits: ['pest'],
  filesInvolved: ['app/Http/Middleware/EnsureTeamMember.php'],
  problem: 'Only members of a team may open that team\'s invoices.',
  solution: 'Route middleware checks team membership before the controller runs.',
  tags: ['middleware', 'teams', 'invoices'],
  verification: { tests_passed: true, build_passed: true },
});

The recorder saves exactly what you pass. It does not run your tests or check your build; the verification values are whatever the caller claims. After recording, paqad-ai patterns list shows the new entry.

Sharing patterns with a team

There is no built-in sharing or sync. The library is in your home folder, outside every project, so committing a project does not include it, and paqad-ai onboard and paqad-ai refresh do not read or copy it. There is also no import command.

To give colleagues a readable copy, export it:

paqad-ai patterns export team-patterns.md --format markdown

Use --format json (the default) for a file a script can read back.

What this means for you

  • If you have never written to ~/.paqad/patterns/, the library is empty, and the agent instructions that tell the AI to check it will find nothing.
  • Nothing is recorded behind your back: no workflow in 1.91.1 adds pattern entries. The only thing Paqad writes there on its own is the vectors/ subfolder, and only when RAG is turned on.
  • If recording matters to your team, raise it on the paqad-ai GitHub repository rather than relying on the library call above.

Something on this page out of date or unclear? Open an issue on GitHub and name the page.