Skip to content

302 memory mcp - #303

Merged
InfinityBowman merged 8 commits into
mainfrom
302-memory-mcp
Jan 17, 2026
Merged

302 memory mcp#303
InfinityBowman merged 8 commits into
mainfrom
302-memory-mcp

Conversation

@InfinityBowman

@InfinityBowman InfinityBowman commented Jan 17, 2026

Copy link
Copy Markdown
Owner

Summary by CodeRabbit

  • New Features
    • Persistent Agent Memory system with repository-scoped semantic memory, local memory server, and tools for search, add, and update workflows.
  • Documentation
    • Extensive memory docs and onboarding added across guides, instructions, and READMEs.
  • Bug Fixes
    • Improved error display handling in authentication flows.
  • Refactor
    • Streamlined reactive state handling in sidebar and dev panel.
  • Tests
    • Comprehensive tests for memory validation, storage, and confidence scoring.
  • Chores
    • New package configs, example configs, and minor .gitignore update.

✏️ Tip: You can customize this high-level summary in your review settings.

@InfinityBowman InfinityBowman linked an issue Jan 17, 2026 that may be closed by this pull request
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jan 17, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
corates 4f320d1 Commit Preview URL Jan 17 2026, 04:14 PM

@coderabbitai

coderabbitai Bot commented Jan 17, 2026

Copy link
Copy Markdown

Caution

Review failed

The pull request is closed.

📝 Walkthrough

Walkthrough

Adds a new repository-scoped MCP memory package providing persistent semantic memory (SQLite + local embeddings), validation, scoring, storage, MCP tools (search/propose_write/propose_update), docs, IDE/MCP configs, CLI/tests, and related UI changes migrating several signal-based states to stores.

Changes

Cohort / File(s) Summary
Docs & Guidance
AGENTS.md, .claude/CLAUDE.md, .cursor/rules/memory.mdc, .github/copilot-instructions.md, .github/instructions/memory.instructions.md, .mcp/README.md
Add comprehensive Agent Memory System docs: storage (.mcp/memory.db), workflows (search/write/update), action schemas/examples, knowledge types, and usage guidance.
MCP / Editor Config
.cursor/mcp.json, .vscode/mcp.json, .mcp.json, packages/mcp-memory/mcp-config.example.json
Add corates-memory MCP server entries and example config pointing at packages/mcp-memory/dist/server.js and setting MCP_MEMORY_REPO_ROOT.
New Package Scaffold
packages/mcp-memory/package.json, packages/mcp-memory/tsconfig.json, packages/mcp-memory/vitest.config.ts, packages/mcp-memory/README.md
New package manifest, TypeScript and Vitest configs, and README documenting architecture, setup, and dev workflow.
Types / Validation / Constants
packages/mcp-memory/src/types.ts, packages/mcp-memory/src/validation.ts, packages/mcp-memory/src/constants.ts
Add TypeScript types/interfaces, Zod schemas for search/create/update, and system constants (embedding dims, limits, ranking weights, DB path, schema version).
Embedding Service
packages/mcp-memory/src/embedding/local.ts, packages/mcp-memory/src/embedding/index.ts
New LocalEmbeddingService using Xenova transformers (initialize, embed, embedBatch); re-export added.
Confidence Scoring
packages/mcp-memory/src/confidence.ts
New computeConfidence function using type, source/ref, content length, and optional hint; clamps to [0,1].
SQLite Storage Layer
packages/mcp-memory/src/storage/sqlite.ts, packages/mcp-memory/src/storage/index.ts
New SqliteStorage with migrations, CRUD, versioning/supersede semantics, similarity search, ranking (similarity/confidence/recency), serialization, and close; re-export added.
MCP Server Entrypoint
packages/mcp-memory/src/server.ts
New server bootstrap wiring storage, embedding, registering memory tools, init/shutdown, and repo-root resolution.
MCP Tools
packages/mcp-memory/src/tools/memory.ts, packages/mcp-memory/src/tools/index.ts
Implement and register search_memory, propose_memory_write, propose_memory_update: embedding generation, validation, duplicate detection, confidence computation, and storage interactions.
CLI & Tests
packages/mcp-memory/scripts/list.ts, packages/mcp-memory/__tests__/*, packages/mcp-memory/mcp-config.example.json
Add list CLI to inspect DB; unit tests for confidence, storage, and validation; example MCP config for package.
Web: Form Errors → Store
packages/web/src/lib/form-errors.js, packages/web/src/lib/__tests__/form-errors.test.js, packages/web/src/components/auth/MagicLinkForm.jsx, packages/web/src/components/auth/SignUp.jsx
Migrate form error state from signals to SolidJS stores, add getFieldError helper, update consumers and tests to use store-backed API.
Web: UI State → Stores
packages/web/src/components/dev/DevPanel.jsx, packages/web/src/components/sidebar/Sidebar.jsx
Replace per-property signals with createStore-based stores for panel geometry and sidebar expanded state; update access and setters.
Misc / Build
.gitignore
Add dist/ to ignore list.

Sequence Diagram(s)

sequenceDiagram
    actor User
    participant Client as MCP Client
    participant Server as MCP Memory Server
    participant Embedding as Embedding Service
    participant Storage as SQLite Storage

    User->>Client: propose_memory_write(entry)
    Client->>Server: invoke propose_memory_write
    Server->>Embedding: embed(entry.content)
    Embedding-->>Server: embedding[]
    Server->>Storage: findSimilar(embedding, threshold)
    Storage-->>Server: similar entries
    alt duplicates found
        Server-->>Client: reject with similar entries
    else no duplicates
        Server->>Storage: create(entry w/ embedding & confidence)
        Storage-->>Server: new id
        Server-->>Client: accepted (id, confidence)
    end
Loading
sequenceDiagram
    actor User
    participant Client as MCP Client
    participant Server as MCP Memory Server
    participant Embedding as Embedding Service
    participant Storage as SQLite Storage

    User->>Client: search_memory(query)
    Client->>Server: invoke search_memory
    Server->>Embedding: embed(query)
    Embedding-->>Server: query embedding
    Server->>Storage: search(query filters, embedding)
    Storage->>Storage: compute similarity & recency scores
    Storage->>Storage: rank by weights (similarity, confidence, recency)
    Storage-->>Server: ranked results
    Server-->>Client: formatted results
Loading
sequenceDiagram
    actor User
    participant Client as MCP Client
    participant Server as MCP Memory Server
    participant Embedding as Embedding Service
    participant Storage as SQLite Storage

    User->>Client: propose_memory_update(target_id, action, content)
    Client->>Server: invoke propose_memory_update
    Server->>Storage: getById(target_id)
    Storage-->>Server: existing entry / null
    alt not found or superseded
        Server-->>Client: reject (reason)
    else valid entry
        Server->>Embedding: embed(new content)
        Embedding-->>Server: new embedding
        alt action == "supersede"
            Server->>Storage: supersede(oldId, newEntry)
            Storage-->>Server: new id
            Server-->>Client: accepted (newId, supersededId)
        else action == "refine"
            Server->>Storage: update(id, partial)
            Storage-->>Server: success
            Server-->>Client: accepted (version)
        end
    end
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related PRs

  • 302 memory mcp #303: Adds the same mcp-memory feature surface (packages/mcp-memory/*), including SqliteStorage, LocalEmbeddingService, computeConfidence, and registerMemoryTools — directly related.
  • use centralized error codes object now #111: Modifies the form error API and related tests to a store-backed approach; strong overlap with web form-errors changes in this PR.
🚥 Pre-merge checks | ✅ 1 | ❌ 2
❌ Failed checks (1 warning, 1 inconclusive)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 66.67% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Title check ❓ Inconclusive The title '302 memory mcp' is vague and uses non-descriptive terms (issue number and generic jargon) that don't convey meaningful information about the changeset's primary purpose. Use a clear, descriptive title that summarizes the main change, e.g., 'Add MCP memory system for persistent agent knowledge storage' or 'Implement memory module with semantic search and persistence'.
✅ Passed checks (1 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

📜 Recent review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 3d88606 and 4f320d1.

📒 Files selected for processing (3)
  • packages/mcp-memory/src/server.ts
  • packages/mcp-memory/src/tools/memory.ts
  • packages/mcp-memory/src/types.ts

✏️ Tip: You can disable this entire section by setting review_details to false in your review settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 12

🤖 Fix all issues with AI agents
In @.claude/CLAUDE.md:
- Around line 282-310: The fenced code block showing example calls to
search_memory, propose_memory_write, and propose_memory_update is missing a
language specifier and triggers MD040; update the opening triple-backtick to
include a language (e.g., "js") so the block becomes ```js and keep the example
content unchanged to match the other docs and satisfy the linter.

In @.github/copilot-instructions.md:
- Around line 186-214: The fenced code block containing examples for
search_memory, propose_memory_write, and propose_memory_update lacks a language
specifier; update the opening triple-backtick to include a language (preferably
"js" for the shown object-literal examples, or "text" if you want plain text) so
markdown lint MD040 is satisfied and syntax highlighting works, leaving the rest
of the block (calls to search_memory, propose_memory_write,
propose_memory_update) unchanged.

In @.github/instructions/memory.instructions.md:
- Around line 21-26: The fenced code block containing calls to search_memory({
query: ... }) is missing a language specifier and triggers MD040; update the
block opener to include a language (e.g., use ```js) so the snippet starting
with search_memory({ query: "authentication patterns" }) is treated as
JavaScript/inline text by linters and renderers, leaving the existing calls
(search_memory) unchanged.

In `@AGENTS.md`:
- Around line 144-163: The Markdown code block containing examples for
search_memory, propose_memory_write, and propose_memory_update is missing a
language specifier; update the opening fence to include a language (e.g., change
``` to ```text) so markdownlint stops flagging it — locate the block that shows
search_memory({ query: "relevant topic" }) and the subsequent
propose_memory_write and propose_memory_update examples and add the language
token to the opening ``` fence.

In `@packages/mcp-memory/mcp-config.example.json`:
- Around line 6-8: Replace the hardcoded user-specific path for the
MCP_MEMORY_REPO_ROOT env value with a generic placeholder (e.g.,
"/path/to/your/repo" or "<YOUR_REPO_ROOT>") so the example config is portable;
update the "MCP_MEMORY_REPO_ROOT" value in
packages/mcp-memory/mcp-config.example.json accordingly.

In `@packages/mcp-memory/package.json`:
- Around line 28-32: The lockfile is out of sync with package.json after adding
the "tsx" dependency; regenerate the repository lockfile so the new "tsx"
specifier is recorded. Run your project's package manager install command (e.g.,
npm install / pnpm install / yarn install) to update the lockfile, commit the
updated lockfile alongside the package.json change, and ensure the "tsx" entry
appears in the lockfile before pushing.

In `@packages/mcp-memory/README.md`:
- Around line 60-67: Replace the non-UUID example value for the "target_id"
field in the JSON sample with a UUID-like string (e.g., a 36-character RFC 4122
format) so the README example matches the schema expectation; update the sample
JSON's "target_id" value where it currently reads "abc-123" to a UUID-like value
to avoid confusion when using the update payload.
- Around line 140-153: The fenced diagram block in the README is missing a
language tag; update the triple-backtick fence that surrounds the "MCP Server
(stdio)" ASCII diagram to include a language identifier (use "text") so it
becomes ```text, leaving the diagram contents unchanged; this targets the code
fence in packages/mcp-memory/README.md that begins with "MCP Server (stdio)".

In `@packages/mcp-memory/src/embedding/local.ts`:
- Around line 13-19: The initialize method stores a rejected initPromise when
loadModel fails, preventing retries; update initialize to assign
this.initPromise = this.loadModel().catch(err => { this.initPromise = undefined;
throw err; }) so that on a transient failure initPromise is cleared and future
calls to initialize (which check this.extractor and this.initPromise) can retry
loading the model; ensure the existing early-return logic using this.extractor
and this.initPromise remains unchanged.

In `@packages/mcp-memory/src/server.ts`:
- Around line 43-57: The shutdown handlers call cleanup() (which invokes
storage.close()) but immediately call process.exit(0), so async close may not
finish; modify the process.on('SIGINT') and process.on('SIGTERM') handlers to be
async functions that await cleanup(), handle/rethrow any errors from
storage.close(), and only call process.exit(0) after cleanup resolves
(optionally enforce a short timeout to force exit if cleanup hangs); update
cleanup() to propagate errors from storage.close() rather than swallowing them
so the handlers can log failures.

In `@packages/mcp-memory/src/tools/memory.ts`:
- Around line 267-277: The current no-op check in memory.ts rejects updates when
existing.content === parsed.content and !parsed.title even if tags changed;
update the condition to also compare tags (e.g., existing.tags vs parsed.tags)
and only treat it as a no-op if both content/title and tags are equal. Use a
deterministic comparison (set or sorted-array equality) for parsed.tags and
existing.tags so reordering doesn't mask changes, and allow the update to
proceed when tags differ even if content and title are unchanged.

In `@packages/mcp-memory/src/types.ts`:
- Around line 62-91: CreateEntryInput and UpdateEntryInput use camelCase fields
(confidenceHint, targetId) but validation/tools expect snake_case
(confidence_hint, target_id); update the types to match the external schema by
renaming the fields in CreateEntryInput (confidenceHint -> confidence_hint) and
in UpdateEntryInput (targetId -> target_id) or alternatively add a clearly named
ExternalCreateEntryInput/ExternalUpdateEntryInput with snake_case fields and
keep the internal types unchanged; adjust any consumers of
CreateEntryInput/UpdateEntryInput to use the chosen types and ensure
mapping/serialization between internal and external representations where
needed.
🧹 Nitpick comments (7)
packages/mcp-memory/scripts/list.ts (1)

48-104: Trim or repurpose narration-only comments.
Lines 48, 57, 73, and 104 explain what the code is doing rather than why. Consider removing them or replacing with intent/assumption notes where helpful. As per coding guidelines, comments should explain why, not what.

packages/mcp-memory/src/tools/index.ts (1)

1-5: Consider removing the narration-only header comment.
The block comment simply repeats what the export already conveys. As per coding guidelines, comments should explain why, not what.

packages/mcp-memory/src/storage/index.ts (1)

1-5: Consider removing the narration-only header comment.
The block comment simply repeats what the export already conveys. As per coding guidelines, comments should explain why, not what.

.mcp.json (1)

16-20: Missing type field for ark-ui server entry.

The corates and corates-memory entries include "type": "stdio", but ark-ui omits it. Consider adding for consistency, unless the schema allows implicit defaults.

Suggested fix
     "ark-ui": {
+      "type": "stdio",
       "command": "npx",
       "args": ["-y", "@ark-ui/mcp"]
     }
packages/mcp-memory/src/server.ts (1)

76-79: Consider calling cleanup on startup failure.

If main() fails after storage.initialize() succeeds, the database connection remains open. Adding cleanup ensures resources are released.

Suggested fix
 main().catch((err: unknown) => {
   console.error('Failed to start MCP Memory Server:', err);
+  cleanup();
   process.exit(1);
 });
packages/mcp-memory/src/constants.ts (1)

5-30: Replace label-only comments with intent or remove

Section comments like Embedding dimensions and Search defaults restate the code. Consider removing them or adding rationale for the chosen bounds/weights so the comments add intent. As per coding guidelines, comments should explain why, not what.

packages/mcp-memory/src/validation.ts (1)

16-27: Replace label-style comments with intent-focused notes

Comments like Knowledge types enum and Source schema restate the code. Consider removing them or adding rationale for constraints where helpful. As per coding guidelines, comments should explain why, not what.

📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 734382a and 53dde9f.

⛔ Files ignored due to path filters (3)
  • .mcp/memory.db is excluded by !**/*.db
  • packages/docs/audits/solidjs-best-practices-audit-2026-01.md is excluded by !packages/docs/audits/**
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (39)
  • .claude/CLAUDE.md
  • .cursor/mcp.json
  • .cursor/rules/memory.mdc
  • .github/copilot-instructions.md
  • .github/instructions/memory.instructions.md
  • .gitignore
  • .mcp.json
  • .mcp/README.md
  • .mcp/memory.db-shm
  • .mcp/memory.db-wal
  • .vscode/mcp.json
  • AGENTS.md
  • packages/docs/guides/state-management.md
  • packages/mcp-memory/README.md
  • packages/mcp-memory/__tests__/confidence.test.ts
  • packages/mcp-memory/__tests__/storage.test.ts
  • packages/mcp-memory/__tests__/validation.test.ts
  • packages/mcp-memory/mcp-config.example.json
  • packages/mcp-memory/package.json
  • packages/mcp-memory/scripts/list.ts
  • packages/mcp-memory/src/confidence.ts
  • packages/mcp-memory/src/constants.ts
  • packages/mcp-memory/src/embedding/index.ts
  • packages/mcp-memory/src/embedding/local.ts
  • packages/mcp-memory/src/server.ts
  • packages/mcp-memory/src/storage/index.ts
  • packages/mcp-memory/src/storage/sqlite.ts
  • packages/mcp-memory/src/tools/index.ts
  • packages/mcp-memory/src/tools/memory.ts
  • packages/mcp-memory/src/types.ts
  • packages/mcp-memory/src/validation.ts
  • packages/mcp-memory/tsconfig.json
  • packages/mcp-memory/vitest.config.ts
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/lib/form-errors.js
🧰 Additional context used
📓 Path-based instructions (15)
**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.cursor/rules/yjs-sync.mdc)

**/*.{js,jsx,ts,tsx}: Use the useProject hook for managing Yjs connections with reference counting instead of creating Y.Doc instances directly
Never create Y.Doc instances directly; always use the connection registry managed by useProject
Access Y.Doc connection state via projectStore.getConnectionState(projectId) instead of checking connection state directly
Read Yjs-synced data from projectStore (using getStudies, getChecklist, etc.) rather than accessing Y.Doc maps/arrays directly
Use operation functions from useProject or projectActionsStore for writing data instead of directly modifying Y.Doc
Don't store Y.Doc references in component state; always retrieve the connection through useProject
Handle connection cleanup via onCleanup() in Solid.js components or equivalent cleanup patterns, calling disconnect() when the component unmounts

**/*.{js,jsx,ts,tsx}: For UI icons, use solid-icons library or SVGs only (never emojis)
Prefer modern ES6+ syntax and features
Use import aliases from jsconfig.json (see ui-components.mdc)
Use Zod for schema and input validation (backend)
Code comments should not repeat what the code is saying. Instead, reserve comments for explaining why something is being done or to provide context that is not obvious from the code itself
When leaving incomplete work or flagging something for future attention, use the pattern: // TODO(agent): Brief description of what needs to be done with relevant doc section reference if applicable

Files:

  • packages/mcp-memory/src/storage/index.ts
  • packages/mcp-memory/src/tools/index.ts
  • packages/mcp-memory/src/confidence.ts
  • packages/mcp-memory/__tests__/validation.test.ts
  • packages/mcp-memory/src/embedding/local.ts
  • packages/mcp-memory/__tests__/storage.test.ts
  • packages/mcp-memory/src/tools/memory.ts
  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/mcp-memory/src/constants.ts
  • packages/mcp-memory/src/storage/sqlite.ts
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/mcp-memory/vitest.config.ts
  • packages/mcp-memory/src/embedding/index.ts
  • packages/mcp-memory/scripts/list.ts
  • packages/mcp-memory/src/validation.ts
  • packages/mcp-memory/src/server.ts
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/mcp-memory/src/types.ts
  • packages/mcp-memory/__tests__/confidence.test.ts
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
**/*.{sql,ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

Use Drizzle ORM for ALL database interactions and migrations

Files:

  • packages/mcp-memory/src/storage/index.ts
  • packages/mcp-memory/src/tools/index.ts
  • packages/mcp-memory/src/confidence.ts
  • packages/mcp-memory/__tests__/validation.test.ts
  • packages/mcp-memory/src/embedding/local.ts
  • packages/mcp-memory/__tests__/storage.test.ts
  • packages/mcp-memory/src/tools/memory.ts
  • packages/mcp-memory/src/constants.ts
  • packages/mcp-memory/src/storage/sqlite.ts
  • packages/mcp-memory/vitest.config.ts
  • packages/mcp-memory/src/embedding/index.ts
  • packages/mcp-memory/scripts/list.ts
  • packages/mcp-memory/src/validation.ts
  • packages/mcp-memory/src/server.ts
  • packages/mcp-memory/src/types.ts
  • packages/mcp-memory/__tests__/confidence.test.ts
**/*.{ts,tsx}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

**/*.{ts,tsx}: Use Better-Auth for authentication and user management
Use Ark UI components (@ark-ui/solid) for UI component development
When commenting, explain why a particular approach or workaround was chosen, clarify intent when code could be misread, provide context from external systems/specs/requirements, or document assumptions/edge cases/limitations
Do NOT narrate what the code is doing, duplicate function/variable names in comments, leave stale comments that contradict code, or reference removed/obsolete code paths
Never use emojis or unicode symbols anywhere in code, comments, documentation, or commits

Files:

  • packages/mcp-memory/src/storage/index.ts
  • packages/mcp-memory/src/tools/index.ts
  • packages/mcp-memory/src/confidence.ts
  • packages/mcp-memory/__tests__/validation.test.ts
  • packages/mcp-memory/src/embedding/local.ts
  • packages/mcp-memory/__tests__/storage.test.ts
  • packages/mcp-memory/src/tools/memory.ts
  • packages/mcp-memory/src/constants.ts
  • packages/mcp-memory/src/storage/sqlite.ts
  • packages/mcp-memory/vitest.config.ts
  • packages/mcp-memory/src/embedding/index.ts
  • packages/mcp-memory/scripts/list.ts
  • packages/mcp-memory/src/validation.ts
  • packages/mcp-memory/src/server.ts
  • packages/mcp-memory/src/types.ts
  • packages/mcp-memory/__tests__/confidence.test.ts
**/*.{js,ts,jsx,tsx}

📄 CodeRabbit inference engine (.cursor/rules/corates.mdc)

**/*.{js,ts,jsx,tsx}: Prefer modern ES6+ syntax and features
Comments should explain why something is being done, not what the code is doing
Reserve comments for explaining intent, context, workarounds, assumptions, edge cases, or limitations
Use TODO(agent): prefix for incomplete work or flagged items with brief description and relevant doc references

Files:

  • packages/mcp-memory/src/storage/index.ts
  • packages/mcp-memory/src/tools/index.ts
  • packages/mcp-memory/src/confidence.ts
  • packages/mcp-memory/__tests__/validation.test.ts
  • packages/mcp-memory/src/embedding/local.ts
  • packages/mcp-memory/__tests__/storage.test.ts
  • packages/mcp-memory/src/tools/memory.ts
  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/mcp-memory/src/constants.ts
  • packages/mcp-memory/src/storage/sqlite.ts
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/mcp-memory/vitest.config.ts
  • packages/mcp-memory/src/embedding/index.ts
  • packages/mcp-memory/scripts/list.ts
  • packages/mcp-memory/src/validation.ts
  • packages/mcp-memory/src/server.ts
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/mcp-memory/src/types.ts
  • packages/mcp-memory/__tests__/confidence.test.ts
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
packages/**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (AGENTS.md)

Use TODO(agent) comments for incomplete work, referencing relevant documentation sections

Files:

  • packages/mcp-memory/src/storage/index.ts
  • packages/mcp-memory/src/tools/index.ts
  • packages/mcp-memory/src/confidence.ts
  • packages/mcp-memory/__tests__/validation.test.ts
  • packages/mcp-memory/src/embedding/local.ts
  • packages/mcp-memory/__tests__/storage.test.ts
  • packages/mcp-memory/src/tools/memory.ts
  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/mcp-memory/src/constants.ts
  • packages/mcp-memory/src/storage/sqlite.ts
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/mcp-memory/vitest.config.ts
  • packages/mcp-memory/src/embedding/index.ts
  • packages/mcp-memory/scripts/list.ts
  • packages/mcp-memory/src/validation.ts
  • packages/mcp-memory/src/server.ts
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/mcp-memory/src/types.ts
  • packages/mcp-memory/__tests__/confidence.test.ts
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
packages/web/src/**/*.{js,jsx}

📄 CodeRabbit inference engine (.cursor/rules/form-state.mdc)

packages/web/src/**/*.{js,jsx}: Save form state to IndexedDB before initiating OAuth redirects (Google Drive, ORCID) using saveFormState() with form type ('createProject' or 'addStudies') and serializable state only
Only save serializable data to IndexedDB—exclude File objects, ArrayBuffers, functions, and other non-serializable objects from form state persistence
Restore form state after OAuth redirects by checking URL restore params with getRestoreParamsFromUrl(), retrieving saved state with getFormState(), restoring to form, clearing saved state with clearFormState(), and clearing URL params with clearRestoreParamsFromUrl()
For temporary File object storage during OAuth flows (e.g., pending PDFs), use projectStore.setPendingProjectData() instead of IndexedDB, as File objects cannot be serialized
Add restore parameters to the URL after OAuth redirects in the format '?restore=&projectId=' to signal form state restoration on mount
Clear URL restore parameters after form state restoration by calling clearRestoreParamsFromUrl() to prevent stale restoration attempts on subsequent navigation
Form state persistence library functions (saveFormState, getFormState, clearFormState, getRestoreParamsFromUrl, clearRestoreParamsFromUrl) are implemented in packages/web/src/lib/formStatePersistence.js and should be imported from @/lib/formStatePersistence.js

Files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
packages/web/src/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.cursor/rules/pdf-handling.mdc)

packages/web/src/**/*.{js,jsx,ts,tsx}: Always use uploadPdf from @api/pdf-api.js for uploading PDF files. Pass object with projectId, studyId, tag ('primary' or 'supplementary'), and fileName
Validate PDF files on frontend by checking file.type includes 'pdf' and file.size is within MAX_PDF_SIZE limit (full validation is done on backend)
Use cachePdf and getCachedPdf from @primitives/pdfCache.js for caching PDF data in IndexedDB
Implement PDF caching strategy: check cache first, download from server if not cached, then cache the downloaded PDF
Store only PDF metadata in Yjs (id, name, size, tag, uploadedAt, uploadedBy), never store PDF binary data in Yjs as it is too large
Use importFromGoogleDrive from @api/google-drive.js for importing PDFs from Google Drive. Pass fileId, projectId, studyId, and tag
Save form state using saveFormState from @/lib/formStatePersistence.js before triggering OAuth redirects for Google Drive
Use addPdfToStudy operation from useProject hook to add PDFs to a study, passing id, name, size, tag, uploadedAt, and uploadedBy
Use removePdfFromStudy operation from useProject hook to remove PDFs from a study
Use pdfPreviewStore from @/stores/pdfPreviewStore.js for managing PDF preview state (openPreview, closePreview, getPreview methods)
Use downloadPdf from @api/pdf-api.js to download PDFs from server, then cache the result using cachePdf
Always cache PDFs after download and check cache before downloading to avoid redundant downloads
Use PDF operations from useProject hook instead of bypassing through direct API calls

Files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
packages/web/src/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursor/rules/pdf-handling.mdc)

Use PdfViewer component from @/components/checklist-ui/pdf/PdfViewer.jsx for displaying PDFs, passing pdfData as ArrayBuffer, fileName, readOnly, and onPageChange

Files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/components/sidebar/Sidebar.jsx
{packages/web/**,packages/landing/**}/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursor/rules/solidjs.mdc)

{packages/web/**,packages/landing/**}/**/*.{jsx,tsx}: NEVER destructure props in SolidJS components - access props directly or wrap in functions to maintain reactivity
Use external stores in packages/web/src/stores/ for shared/cross-feature state instead of prop-drilling
Keep SolidJS components lean and focused on rendering - move business logic to stores, primitives, or utilities
Create reusable logic in primitives (hooks) in packages/web/src/primitives/ and import them into components
Use Solid's Show component for conditional rendering instead of ternary operators
Use Solid's For component for rendering lists instead of Array.map()
Use the children helper when manipulating props.children in SolidJS components

Use Show and For components for conditional and list rendering in SolidJS

Files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/components/sidebar/Sidebar.jsx
{packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (.cursor/rules/solidjs.mdc)

{packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx}: Use createSignal for simple reactive values in SolidJS components
Use createStore for complex objects and arrays that need granular reactivity in SolidJS
Use createMemo for computed/derived values that depend on reactive state in SolidJS
Always clean up SolidJS effects that create subscriptions or timers using onCleanup
Import stores directly in components and use store read/write action pattern - read from store, write via actions store
Prefer derived state with createMemo or signals over effects whenever possible
Use local createSignal or createStore for local component state; use external stores for shared/cross-feature state

{packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx}: NEVER destructure props in SolidJS components - it breaks reactivity. Access props directly (e.g., props.name) or wrap in a function (e.g., () => props.name)
Store imports should access store data directly from external stores (packages/web/src/stores/) rather than receiving store data via props
Use createSignal for simple, reactive values in SolidJS
Use createStore for complex objects and nested state in SolidJS, with nested updates using setState pattern (e.g., setState('items', items => [...items, newItem]))
Use createMemo for derived/computed values in SolidJS to maintain reactivity
Use local createSignal or createStore for local component state
Components should receive at most 1-5 props for local configuration only
Move business logic to stores, utilities, or SolidJS primitives rather than keeping it in component code

Files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
packages/web/src/**

📄 CodeRabbit inference engine (.cursor/rules/organizations.mdc)

packages/web/src/**: Use human-readable slug in frontend URLs: /orgs/:orgSlug/...
Use orgId (UUID) for API calls, not orgSlug, when making fetch requests to backend endpoints

Files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
packages/web/**/*.{js,ts,jsx,tsx}

📄 CodeRabbit inference engine (.cursor/rules/error-handling.mdc)

packages/web/**/*.{js,ts,jsx,tsx}: Use apiFetch for all frontend API calls instead of raw fetch to automatically handle JSON parsing, errors, and toast notifications
Use handleFetchError for wrapping legacy raw fetch calls in frontend code (legacy pattern, prefer apiFetch)
Use error utility functions like isErrorCode from error-utils to check specific error types instead of direct string comparisons

Files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
packages/web/**/*.{jsx,tsx}

📄 CodeRabbit inference engine (.cursor/rules/error-handling.mdc)

Use createFormErrorSignals for form error handling in frontend forms to manage field-level and global error states

Files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/components/sidebar/Sidebar.jsx
packages/{web,workers}/**/*.{js,ts,jsx,tsx}

📄 CodeRabbit inference engine (.cursor/rules/error-handling.mdc)

Never throw string literals; always throw Error objects or return domain errors from API routes

Files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
{packages/web/src/stores/**/*.{js,jsx,ts,tsx},packages/web/src/**/*.{js,jsx,ts,tsx}}

📄 CodeRabbit inference engine (.github/instructions/solidjs.instructions.md)

Shared or cross-feature state should use external stores located in packages/web/src/stores/

Files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
🧠 Learnings (56)
📓 Common learnings
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2026-01-17T00:24:56.673Z
Learning: ALWAYS use Corates MCP tools or other MCP for Better-Auth, Drizzle, Icons, linting, and Ark UI documentation
📚 Learning: 2026-01-17T00:24:56.673Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2026-01-17T00:24:56.673Z
Learning: Read documents in order before making changes: Core coding standards, STATUS.md, AGENTS.md, relevant guides from packages/docs/guides/, and specialized rules from .cursor/rules/*.mdc or .github/instructions/*.instructions.md

Applied to files:

  • .github/instructions/memory.instructions.md
  • AGENTS.md
  • .github/copilot-instructions.md
  • .cursor/rules/memory.mdc
📚 Learning: 2026-01-01T23:32:23.488Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/workers.mdc:0-0
Timestamp: 2026-01-01T23:32:23.488Z
Learning: Applies to packages/workers/src/config/validation.{js,ts} : Add new Zod validation schemas to `config/validation.js` and reuse `commonFields` when possible to avoid duplication

Applied to files:

  • packages/mcp-memory/__tests__/validation.test.ts
  • packages/mcp-memory/src/validation.ts
📚 Learning: 2026-01-01T23:31:43.756Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/api-routes.mdc:0-0
Timestamp: 2026-01-01T23:31:43.756Z
Learning: Applies to packages/workers/src/config/validation.js : Add new validation schemas to `src/config/validation.js` and reuse `commonFields` when possible

Applied to files:

  • packages/mcp-memory/__tests__/validation.test.ts
  • packages/mcp-memory/src/validation.ts
📚 Learning: 2026-01-05T01:00:58.113Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/workers-testing.mdc:0-0
Timestamp: 2026-01-05T01:00:58.113Z
Learning: Applies to {packages/workers/src/**/*.test.js,packages/workers/src/**/__tests__/**/*.js} : Seed test data using provided seed* helpers (seedUser, seedOrganization, seedOrgMember, seedProject, etc.) from packages/workers/src/__tests__/helpers.js with Zod schema validation

Applied to files:

  • packages/mcp-memory/__tests__/validation.test.ts
📚 Learning: 2026-01-17T00:24:56.673Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2026-01-17T00:24:56.673Z
Learning: Applies to **/*.{js,jsx,ts,tsx} : Use Zod for schema and input validation (backend)

Applied to files:

  • packages/mcp-memory/__tests__/validation.test.ts
  • packages/mcp-memory/src/validation.ts
📚 Learning: 2026-01-17T00:24:56.673Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2026-01-17T00:24:56.673Z
Learning: ALWAYS use Corates MCP tools or other MCP for Better-Auth, Drizzle, Icons, linting, and Ark UI documentation

Applied to files:

  • .mcp.json
  • .vscode/mcp.json
  • AGENTS.md
  • packages/mcp-memory/README.md
  • .cursor/mcp.json
  • packages/mcp-memory/package.json
  • packages/mcp-memory/mcp-config.example.json
📚 Learning: 2026-01-17T00:25:45.504Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: AGENTS.md:0-0
Timestamp: 2026-01-17T00:25:45.504Z
Learning: Applies to packages/**/*.{ts,tsx,js,jsx} : Use TODO(agent) comments for incomplete work, referencing relevant documentation sections

Applied to files:

  • AGENTS.md
📚 Learning: 2026-01-17T00:25:12.507Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/instructions/solidjs.instructions.md:0-0
Timestamp: 2026-01-17T00:25:12.507Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx} : Move business logic to stores, utilities, or SolidJS primitives rather than keeping it in component code

Applied to files:

  • AGENTS.md
  • packages/web/src/components/dev/DevPanel.jsx
  • .claude/CLAUDE.md
📚 Learning: 2025-12-27T03:02:26.947Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/solidjs.mdc:0-0
Timestamp: 2025-12-27T03:02:26.947Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{jsx,tsx} : Keep SolidJS components lean and focused on rendering - move business logic to stores, primitives, or utilities

Applied to files:

  • AGENTS.md
  • packages/web/src/components/dev/DevPanel.jsx
  • .claude/CLAUDE.md
📚 Learning: 2026-01-17T00:25:35.702Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/corates.mdc:0-0
Timestamp: 2026-01-17T00:25:35.702Z
Learning: Applies to **/*.{js,ts,jsx,tsx} : Use TODO(agent): prefix for incomplete work or flagged items with brief description and relevant doc references

Applied to files:

  • AGENTS.md
  • .github/copilot-instructions.md
📚 Learning: 2026-01-17T00:25:45.504Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: AGENTS.md:0-0
Timestamp: 2026-01-17T00:25:45.504Z
Learning: Use required libraries for core functionality: Zod (validation), Drizzle (database), Better-Auth (auth), Ark UI (components)

Applied to files:

  • AGENTS.md
📚 Learning: 2026-01-17T00:25:12.507Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/instructions/solidjs.instructions.md:0-0
Timestamp: 2026-01-17T00:25:12.507Z
Learning: Applies to {packages/web/src/stores/**/*.{js,jsx,ts,tsx},packages/web/src/**/*.{js,jsx,ts,tsx}} : Shared or cross-feature state should use external stores located in packages/web/src/stores/

Applied to files:

  • AGENTS.md
  • packages/web/src/components/sidebar/Sidebar.jsx
📚 Learning: 2025-12-27T03:02:26.947Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/solidjs.mdc:0-0
Timestamp: 2025-12-27T03:02:26.947Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{jsx,tsx} : Create reusable logic in primitives (hooks) in packages/web/src/primitives/ and import them into components

Applied to files:

  • AGENTS.md
  • .claude/CLAUDE.md
📚 Learning: 2026-01-17T00:25:12.507Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/instructions/solidjs.instructions.md:0-0
Timestamp: 2026-01-17T00:25:12.507Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx} : Use createMemo for derived/computed values in SolidJS to maintain reactivity

Applied to files:

  • AGENTS.md
  • packages/web/src/components/dev/DevPanel.jsx
  • packages/docs/guides/state-management.md
📚 Learning: 2025-12-27T03:02:26.947Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/solidjs.mdc:0-0
Timestamp: 2025-12-27T03:02:26.947Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{jsx,tsx} : Use external stores in packages/web/src/stores/ for shared/cross-feature state instead of prop-drilling

Applied to files:

  • AGENTS.md
  • packages/web/src/components/dev/DevPanel.jsx
  • .claude/CLAUDE.md
  • packages/web/src/components/sidebar/Sidebar.jsx
📚 Learning: 2026-01-05T01:00:58.113Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/workers-testing.mdc:0-0
Timestamp: 2026-01-05T01:00:58.113Z
Learning: Applies to {packages/workers/src/**/*.test.js,packages/workers/src/**/__tests__/**/*.js} : Clear ProjectDoc Durable Objects storage between tests using clearProjectDOs() helper to prevent invalidation/reset edge cases

Applied to files:

  • packages/mcp-memory/__tests__/storage.test.ts
📚 Learning: 2026-01-05T01:00:58.113Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/workers-testing.mdc:0-0
Timestamp: 2026-01-05T01:00:58.113Z
Learning: Applies to {packages/workers/src/**/*.test.js,packages/workers/src/**/__tests__/**/*.js} : Reuse provided helpers from packages/workers/src/__tests__/helpers.js (resetTestDatabase, clearProjectDOs, seedUser, seedOrganization, createTestEnv, fetchApp, json, createAuthHeaders) instead of implementing ad-hoc solutions

Applied to files:

  • packages/mcp-memory/__tests__/storage.test.ts
📚 Learning: 2026-01-05T01:00:58.113Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/workers-testing.mdc:0-0
Timestamp: 2026-01-05T01:00:58.113Z
Learning: Applies to {packages/workers/src/**/*.test.js,packages/workers/src/**/__tests__/**/*.js} : Use resetTestDatabase() helper to reset D1 from migration SQL before each test or describe block

Applied to files:

  • packages/mcp-memory/__tests__/storage.test.ts
📚 Learning: 2026-01-17T00:25:35.702Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/corates.mdc:0-0
Timestamp: 2026-01-17T00:25:35.702Z
Learning: Applies to packages/web/src/**/*.{ts,tsx} : Use import aliases from jsconfig.json as defined for the project

Applied to files:

  • packages/mcp-memory/tsconfig.json
📚 Learning: 2026-01-17T00:24:56.673Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2026-01-17T00:24:56.673Z
Learning: Applies to **/*.{js,jsx,ts,tsx} : Use import aliases from jsconfig.json (see ui-components.mdc)

Applied to files:

  • packages/mcp-memory/tsconfig.json
📚 Learning: 2026-01-17T00:24:56.673Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2026-01-17T00:24:56.673Z
Learning: Applies to **/*.{js,jsx,ts,tsx} : Prefer modern ES6+ syntax and features

Applied to files:

  • packages/mcp-memory/tsconfig.json
📚 Learning: 2026-01-17T00:25:35.702Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/corates.mdc:0-0
Timestamp: 2026-01-17T00:25:35.702Z
Learning: Applies to **/*.{js,ts,jsx,tsx} : Prefer modern ES6+ syntax and features

Applied to files:

  • packages/mcp-memory/tsconfig.json
📚 Learning: 2025-12-27T03:02:26.947Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/solidjs.mdc:0-0
Timestamp: 2025-12-27T03:02:26.947Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx} : Use local createSignal or createStore for local component state; use external stores for shared/cross-feature state

Applied to files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/docs/guides/state-management.md
  • packages/web/src/lib/form-errors.js
📚 Learning: 2026-01-17T00:25:12.507Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/instructions/solidjs.instructions.md:0-0
Timestamp: 2026-01-17T00:25:12.507Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx} : Use local createSignal or createStore for local component state

Applied to files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/docs/guides/state-management.md
  • packages/web/src/lib/form-errors.js
📚 Learning: 2025-12-27T03:02:26.947Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/solidjs.mdc:0-0
Timestamp: 2025-12-27T03:02:26.947Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx} : Use createStore for complex objects and arrays that need granular reactivity in SolidJS

Applied to files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/docs/guides/state-management.md
  • packages/web/src/lib/form-errors.js
📚 Learning: 2025-12-27T03:02:26.947Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/solidjs.mdc:0-0
Timestamp: 2025-12-27T03:02:26.947Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx} : Prefer derived state with createMemo or signals over effects whenever possible

Applied to files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/docs/guides/state-management.md
📚 Learning: 2026-01-17T00:25:12.507Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/instructions/solidjs.instructions.md:0-0
Timestamp: 2026-01-17T00:25:12.507Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx} : Store imports should access store data directly from external stores (packages/web/src/stores/) rather than receiving store data via props

Applied to files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/components/sidebar/Sidebar.jsx
📚 Learning: 2025-12-27T03:02:26.947Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/solidjs.mdc:0-0
Timestamp: 2025-12-27T03:02:26.947Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx} : Use createSignal for simple reactive values in SolidJS components

Applied to files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/docs/guides/state-management.md
  • packages/web/src/lib/form-errors.js
📚 Learning: 2026-01-17T00:25:12.507Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/instructions/solidjs.instructions.md:0-0
Timestamp: 2026-01-17T00:25:12.507Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx} : Use createStore for complex objects and nested state in SolidJS, with nested updates using setState pattern (e.g., setState('items', items => [...items, newItem]))

Applied to files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
📚 Learning: 2026-01-17T00:25:12.507Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/instructions/solidjs.instructions.md:0-0
Timestamp: 2026-01-17T00:25:12.507Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx} : Use createSignal for simple, reactive values in SolidJS

Applied to files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/docs/guides/state-management.md
  • packages/web/src/lib/form-errors.js
📚 Learning: 2026-01-17T00:25:35.702Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/corates.mdc:0-0
Timestamp: 2026-01-17T00:25:35.702Z
Learning: Applies to packages/web/src/stores/**/*.{ts,tsx} : Use `createStore` for complex state objects in SolidJS

Applied to files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/docs/guides/state-management.md
  • packages/web/src/lib/form-errors.js
📚 Learning: 2025-12-27T03:02:26.947Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/solidjs.mdc:0-0
Timestamp: 2025-12-27T03:02:26.947Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{js,jsx,ts,tsx} : Use createMemo for computed/derived values that depend on reactive state in SolidJS

Applied to files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/docs/guides/state-management.md
📚 Learning: 2026-01-17T00:24:56.673Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2026-01-17T00:24:56.673Z
Learning: Applies to packages/web/**/*.{ts,tsx} : Use createStore for complex state objects

Applied to files:

  • packages/web/src/components/dev/DevPanel.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/web/src/lib/form-errors.js
📚 Learning: 2026-01-06T23:56:57.354Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/error-handling.mdc:0-0
Timestamp: 2026-01-06T23:56:57.354Z
Learning: Applies to packages/web/**/*.{jsx,tsx} : Use `createFormErrorSignals` for form error handling in frontend forms to manage field-level and global error states

Applied to files:

  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/lib/form-errors.js
📚 Learning: 2026-01-17T00:24:56.673Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2026-01-17T00:24:56.673Z
Learning: Applies to **/*.{ts,tsx} : Use Better-Auth for authentication and user management

Applied to files:

  • packages/web/src/components/auth/SignUp.jsx
📚 Learning: 2026-01-17T00:25:35.702Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/corates.mdc:0-0
Timestamp: 2026-01-17T00:25:35.702Z
Learning: Applies to packages/workers/src/**/*.{ts,tsx} : Use Better-Auth for authentication and user management

Applied to files:

  • packages/web/src/components/auth/SignUp.jsx
📚 Learning: 2026-01-06T23:56:57.354Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/error-handling.mdc:0-0
Timestamp: 2026-01-06T23:56:57.354Z
Learning: Applies to packages/web/**/*.{js,ts,jsx,tsx} : Use error utility functions like `isErrorCode` from error-utils to check specific error types instead of direct string comparisons

Applied to files:

  • packages/web/src/components/auth/SignUp.jsx
  • packages/web/src/components/auth/MagicLinkForm.jsx
📚 Learning: 2026-01-05T01:00:58.113Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/workers-testing.mdc:0-0
Timestamp: 2026-01-05T01:00:58.113Z
Learning: Applies to {packages/workers/src/**/*.test.js,packages/workers/src/**/__tests__/**/*.js} : Tests in packages/workers must run under cloudflare/vitest-pool-workers with global setup from packages/workers/src/__tests__/setup.js

Applied to files:

  • packages/mcp-memory/vitest.config.ts
📚 Learning: 2026-01-17T00:25:35.702Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/corates.mdc:0-0
Timestamp: 2026-01-17T00:25:35.702Z
Learning: Applies to packages/workers/src/**/*.{ts,tsx} : Use Zod for schema and input validation on backend services

Applied to files:

  • packages/mcp-memory/src/validation.ts
📚 Learning: 2026-01-17T00:24:56.673Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2026-01-17T00:24:56.673Z
Learning: Applies to **/*.{js,jsx,ts,tsx} : When leaving incomplete work or flagging something for future attention, use the pattern: // TODO(agent): Brief description of what needs to be done with relevant doc section reference if applicable

Applied to files:

  • .github/copilot-instructions.md
📚 Learning: 2026-01-17T00:24:56.673Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2026-01-17T00:24:56.673Z
Learning: Applies to packages/web/src/stores/**/*.{ts,tsx} : Shared state lives in external stores under packages/web/src/stores/

Applied to files:

  • .claude/CLAUDE.md
📚 Learning: 2026-01-17T00:25:35.702Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/corates.mdc:0-0
Timestamp: 2026-01-17T00:25:35.702Z
Learning: Applies to packages/web/src/components/**/*.{ts,tsx} : Group related components in subdirectories with barrel exports

Applied to files:

  • .claude/CLAUDE.md
📚 Learning: 2025-12-27T03:01:54.727Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/form-state.mdc:0-0
Timestamp: 2025-12-27T03:01:54.727Z
Learning: Applies to packages/web/src/components/project-ui/**/*.{js,jsx} : Form state should include serializable metadata when handling files (name, size, type) and use the store's pendingPdfs pattern for actual File objects that persist across redirects

Applied to files:

  • packages/web/src/lib/__tests__/form-errors.test.js
📚 Learning: 2025-12-27T03:01:54.727Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/form-state.mdc:0-0
Timestamp: 2025-12-27T03:01:54.727Z
Learning: Applies to packages/web/src/**/*.{js,jsx} : Form state persistence library functions (saveFormState, getFormState, clearFormState, getRestoreParamsFromUrl, clearRestoreParamsFromUrl) are implemented in packages/web/src/lib/formStatePersistence.js and should be imported from `@/lib/formStatePersistence.js`

Applied to files:

  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/lib/form-errors.js
📚 Learning: 2026-01-17T00:25:35.702Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/corates.mdc:0-0
Timestamp: 2026-01-17T00:25:35.702Z
Learning: Applies to packages/web/src/**/*.{ts,tsx} : Do not prop-drill application state in SolidJS components; import stores directly where needed

Applied to files:

  • packages/web/src/lib/__tests__/form-errors.test.js
  • packages/web/src/components/sidebar/Sidebar.jsx
  • packages/docs/guides/state-management.md
📚 Learning: 2026-01-17T00:25:12.507Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/instructions/solidjs.instructions.md:0-0
Timestamp: 2026-01-17T00:25:12.507Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{jsx,tsx} : Use Show and For components for conditional and list rendering in SolidJS

Applied to files:

  • packages/web/src/components/sidebar/Sidebar.jsx
📚 Learning: 2025-12-27T03:02:26.947Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/solidjs.mdc:0-0
Timestamp: 2025-12-27T03:02:26.947Z
Learning: Applies to {packages/web/**,packages/landing/**}/**/*.{jsx,tsx} : Use Solid's Show component for conditional rendering instead of ternary operators

Applied to files:

  • packages/web/src/components/sidebar/Sidebar.jsx
📚 Learning: 2025-12-27T03:02:50.087Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/yjs-sync.mdc:0-0
Timestamp: 2025-12-27T03:02:50.087Z
Learning: Applies to **/*.{js,jsx,ts,tsx} : Read Yjs-synced data from projectStore (using getStudies, getChecklist, etc.) rather than accessing Y.Doc maps/arrays directly

Applied to files:

  • packages/web/src/components/sidebar/Sidebar.jsx
📚 Learning: 2025-12-27T03:01:54.727Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/form-state.mdc:0-0
Timestamp: 2025-12-27T03:01:54.727Z
Learning: Applies to packages/web/src/**/*.{js,jsx} : Save form state to IndexedDB before initiating OAuth redirects (Google Drive, ORCID) using saveFormState() with form type ('createProject' or 'addStudies') and serializable state only

Applied to files:

  • packages/web/src/components/sidebar/Sidebar.jsx
📚 Learning: 2025-12-27T03:02:50.087Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/yjs-sync.mdc:0-0
Timestamp: 2025-12-27T03:02:50.087Z
Learning: Applies to packages/web/src/primitives/useProject/**, packages/web/src/stores/projectStore.js : Local projects (with IDs starting with 'local-') use IndexedDB persistence only and skip WebSocket connection, but still use Y.Doc structure and sync to store normally

Applied to files:

  • packages/web/src/components/sidebar/Sidebar.jsx
📚 Learning: 2025-12-27T03:02:05.951Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/pdf-handling.mdc:0-0
Timestamp: 2025-12-27T03:02:05.951Z
Learning: Applies to packages/web/src/**/*.{js,jsx,ts,tsx} : Use `addPdfToStudy` operation from `useProject` hook to add PDFs to a study, passing id, name, size, tag, uploadedAt, and uploadedBy

Applied to files:

  • packages/web/src/components/sidebar/Sidebar.jsx
📚 Learning: 2025-12-27T03:02:05.951Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/pdf-handling.mdc:0-0
Timestamp: 2025-12-27T03:02:05.951Z
Learning: Applies to packages/web/src/**/*.{js,jsx,ts,tsx} : Use `removePdfFromStudy` operation from `useProject` hook to remove PDFs from a study

Applied to files:

  • packages/web/src/components/sidebar/Sidebar.jsx
📚 Learning: 2026-01-17T00:25:35.702Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/corates.mdc:0-0
Timestamp: 2026-01-17T00:25:35.702Z
Learning: Applies to packages/web/src/**/*.{ts,tsx} : Use `createMemo` for derived values in SolidJS

Applied to files:

  • packages/docs/guides/state-management.md
📚 Learning: 2026-01-17T00:24:56.673Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2026-01-17T00:24:56.673Z
Learning: Applies to packages/web/**/*.{ts,tsx} : Use createMemo for derived values

Applied to files:

  • packages/docs/guides/state-management.md
📚 Learning: 2026-01-06T23:56:57.354Z
Learnt from: CR
Repo: InfinityBowman/corates PR: 0
File: .cursor/rules/error-handling.mdc:0-0
Timestamp: 2026-01-06T23:56:57.354Z
Learning: Applies to packages/workers/**/*.{js,ts} : Use predefined error constants from `corates/shared` (PROJECT_ERRORS, AUTH_ERRORS, VALIDATION_ERRORS, SYSTEM_ERRORS, USER_ERRORS) instead of arbitrary error strings

Applied to files:

  • packages/web/src/lib/form-errors.js
🧬 Code graph analysis (11)
packages/mcp-memory/src/confidence.ts (1)
packages/mcp-memory/src/types.ts (1)
  • KnowledgeType (10-10)
packages/mcp-memory/__tests__/validation.test.ts (1)
packages/mcp-memory/src/validation.ts (3)
  • SearchQuerySchema (29-35)
  • CreateEntrySchema (38-51)
  • UpdateEntrySchema (57-67)
packages/mcp-memory/src/embedding/local.ts (3)
packages/mcp-memory/src/embedding/index.ts (1)
  • LocalEmbeddingService (5-5)
packages/mcp-memory/src/types.ts (1)
  • EmbeddingService (128-132)
packages/mcp-memory/src/constants.ts (2)
  • EMBEDDING_MODEL (9-9)
  • EMBEDDING_DIMENSIONS (6-6)
packages/mcp-memory/__tests__/storage.test.ts (2)
packages/mcp-memory/src/storage/index.ts (1)
  • SqliteStorage (5-5)
packages/mcp-memory/src/storage/sqlite.ts (1)
  • SqliteStorage (110-405)
packages/web/src/components/dev/DevPanel.jsx (1)
packages/web/src/components/sidebar/Sidebar.jsx (1)
  • isResizing (42-42)
packages/web/src/components/auth/SignUp.jsx (3)
packages/web/src/components/auth/SignIn.jsx (3)
  • useBetterAuth (28-28)
  • displayError (62-62)
  • error (21-21)
packages/web/src/api/better-auth-store.js (1)
  • authError (243-243)
packages/web/src/components/auth/ErrorMessage.jsx (1)
  • ErrorMessage (3-11)
packages/mcp-memory/src/storage/sqlite.ts (2)
packages/mcp-memory/src/constants.ts (7)
  • RECENCY_DECAY_DAYS (33-33)
  • DATABASE_PATH (36-36)
  • SCHEMA_VERSION (39-39)
  • DEFAULT_SEARCH_LIMIT (18-18)
  • MAX_SEARCH_LIMIT (19-19)
  • DEFAULT_MIN_CONFIDENCE (20-20)
  • RANKING_WEIGHTS (26-30)
packages/mcp-memory/src/types.ts (7)
  • KnowledgeEntry (19-32)
  • KnowledgeType (10-10)
  • SourceType (12-12)
  • MemoryStorage (102-125)
  • SearchQuery (35-42)
  • SearchResponse (57-60)
  • SearchResult (44-55)
packages/mcp-memory/scripts/list.ts (1)
packages/mcp-memory/src/constants.ts (1)
  • DATABASE_PATH (36-36)
packages/mcp-memory/src/server.ts (5)
packages/mcp-memory/src/storage/index.ts (1)
  • SqliteStorage (5-5)
packages/mcp-memory/src/storage/sqlite.ts (1)
  • SqliteStorage (110-405)
packages/mcp-memory/src/embedding/index.ts (1)
  • LocalEmbeddingService (5-5)
packages/mcp-memory/src/embedding/local.ts (1)
  • LocalEmbeddingService (9-62)
packages/mcp-memory/src/tools/memory.ts (1)
  • registerMemoryTools (27-376)
packages/mcp-memory/src/types.ts (1)
packages/mcp-memory/src/validation.ts (2)
  • CreateEntryInput (71-71)
  • UpdateEntryInput (72-72)
packages/mcp-memory/__tests__/confidence.test.ts (1)
packages/mcp-memory/src/confidence.ts (1)
  • computeConfidence (25-54)
🪛 GitHub Actions: Prettier (non-main)
packages/mcp-memory/package.json

[error] 1-1: specifiers in the lockfile don't match specifiers in package.json: 1 dependencies were added: tsx@^4.21.0

🪛 markdownlint-cli2 (0.18.1)
.github/instructions/memory.instructions.md

21-21: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

AGENTS.md

144-144: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

packages/mcp-memory/README.md

140-140: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

.github/copilot-instructions.md

186-186: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

.claude/CLAUDE.md

282-282: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Workers Builds: corates

✏️ Tip: You can disable this entire section by setting review_details to false in your review settings.

Comment thread .claude/CLAUDE.md
Comment on lines +282 to +310
```
# Before starting work
search_memory({ query: "relevant topic" })

# After discovering durable knowledge
propose_memory_write({
type: "decision",
title: "Concise title",
content: "Detailed explanation with rationale",
tags: ["relevant", "tags"]
})

# To update existing knowledge
propose_memory_update({
target_id: "uuid-from-search",
action: "refine",
content: "Updated content with corrections",
justification: "Why this update is needed"
})

# To replace outdated knowledge
propose_memory_update({
target_id: "uuid-from-search",
action: "supersede",
title: "New title for replacement",
content: "Completely revised content",
justification: "Original was incorrect because..."
})
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Add language specifier to fenced code block.

The code block at line 282 lacks a language identifier, triggering markdown lint MD040. Consistent with the other documentation files, use js or text.

Suggested fix
-```
+```js
 # Before starting work
 search_memory({ query: "relevant topic" })
🧰 Tools
🪛 markdownlint-cli2 (0.18.1)

282-282: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

🤖 Prompt for AI Agents
In @.claude/CLAUDE.md around lines 282 - 310, The fenced code block showing
example calls to search_memory, propose_memory_write, and propose_memory_update
is missing a language specifier and triggers MD040; update the opening
triple-backtick to include a language (e.g., "js") so the block becomes ```js
and keep the example content unchanged to match the other docs and satisfy the
linter.

Comment on lines +186 to +214
```
# Before starting work
search_memory({ query: "relevant topic" })

# After discovering durable knowledge
propose_memory_write({
type: "decision",
title: "Concise title",
content: "Detailed explanation with rationale",
tags: ["relevant", "tags"]
})

# To update existing knowledge
propose_memory_update({
target_id: "uuid-from-search",
action: "refine",
content: "Updated content with corrections",
justification: "Why this update is needed"
})

# To replace outdated knowledge
propose_memory_update({
target_id: "uuid-from-search",
action: "supersede",
title: "New title for replacement",
content: "Completely revised content",
justification: "Original was incorrect because..."
})
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Add language specifier to fenced code block.

The code block lacks a language identifier, which triggers markdown lint MD040 and prevents proper syntax highlighting. Since the content shows tool invocations with object literals, consider using js or text.

Suggested fix
-```
+```js
 # Before starting work
 search_memory({ query: "relevant topic" })
🧰 Tools
🪛 markdownlint-cli2 (0.18.1)

186-186: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

🤖 Prompt for AI Agents
In @.github/copilot-instructions.md around lines 186 - 214, The fenced code
block containing examples for search_memory, propose_memory_write, and
propose_memory_update lacks a language specifier; update the opening
triple-backtick to include a language (preferably "js" for the shown
object-literal examples, or "text" if you want plain text) so markdown lint
MD040 is satisfied and syntax highlighting works, leaving the rest of the block
(calls to search_memory, propose_memory_write, propose_memory_update) unchanged.

Comment on lines +21 to +26
```
search_memory({ query: "authentication patterns" })
search_memory({ query: "error handling", types: ["pattern", "decision"] })
search_memory({ query: "database migrations" })
search_memory({ query: "SolidJS props" })
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Add language specifier to fenced code block.

The code block at line 21 lacks a language identifier, triggering markdown lint MD040. Since it shows function call syntax, use js or text.

Suggested fix
-```
+```js
 search_memory({ query: "authentication patterns" })
 search_memory({ query: "error handling", types: ["pattern", "decision"] })
 search_memory({ query: "database migrations" })
 search_memory({ query: "SolidJS props" })
</details>

<details>
<summary>🧰 Tools</summary>

<details>
<summary>🪛 markdownlint-cli2 (0.18.1)</summary>

21-21: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

</details>

</details>

<details>
<summary>🤖 Prompt for AI Agents</summary>

In @.github/instructions/memory.instructions.md around lines 21 - 26, The fenced
code block containing calls to search_memory({ query: ... }) is missing a
language specifier and triggers MD040; update the block opener to include a
language (e.g., use ```js) so the snippet starting with search_memory({ query:
"authentication patterns" }) is treated as JavaScript/inline text by linters and
renderers, leaving the existing calls (search_memory) unchanged.


</details>

<!-- fingerprinting:phantom:poseidon:ocelot -->

<!-- This is an auto-generated comment by CodeRabbit -->

Comment thread AGENTS.md
Comment on lines +144 to +163
```
# Before starting work
search_memory({ query: "relevant topic" })

# After discovering durable knowledge
propose_memory_write({
type: "decision",
title: "Concise title",
content: "Detailed explanation with rationale",
tags: ["relevant", "tags"]
})

# To update existing knowledge
propose_memory_update({
target_id: "uuid-from-search",
action: "refine",
content: "Updated content with corrections",
justification: "Why this update is needed"
})
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Add a language to the memory tool usage code fence.

Markdownlint flags this block for missing a language specifier.

Proposed fix
-```
+```text
 # Before starting work
 search_memory({ query: "relevant topic" })
@@
 propose_memory_update({
   target_id: "uuid-from-search",
   action: "refine",
   content: "Updated content with corrections",
   justification: "Why this update is needed"
 })
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
```
# Before starting work
search_memory({ query: "relevant topic" })
# After discovering durable knowledge
propose_memory_write({
type: "decision",
title: "Concise title",
content: "Detailed explanation with rationale",
tags: ["relevant", "tags"]
})
# To update existing knowledge
propose_memory_update({
target_id: "uuid-from-search",
action: "refine",
content: "Updated content with corrections",
justification: "Why this update is needed"
})
```
🧰 Tools
🪛 markdownlint-cli2 (0.18.1)

144-144: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

🤖 Prompt for AI Agents
In `@AGENTS.md` around lines 144 - 163, The Markdown code block containing
examples for search_memory, propose_memory_write, and propose_memory_update is
missing a language specifier; update the opening fence to include a language
(e.g., change ``` to ```text) so markdownlint stops flagging it — locate the
block that shows search_memory({ query: "relevant topic" }) and the subsequent
propose_memory_write and propose_memory_update examples and add the language
token to the opening ``` fence.

Comment on lines +6 to +8
"env": {
"MCP_MEMORY_REPO_ROOT": "/Users/jacobmaynard/Documents/Repos/corates"
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Replace hardcoded path with a placeholder.

The example configuration contains a user-specific absolute path. Use a generic placeholder for better documentation hygiene.

Suggested fix
       "env": {
-        "MCP_MEMORY_REPO_ROOT": "/Users/jacobmaynard/Documents/Repos/corates"
+        "MCP_MEMORY_REPO_ROOT": "/path/to/corates"
       }
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
"env": {
"MCP_MEMORY_REPO_ROOT": "/Users/jacobmaynard/Documents/Repos/corates"
}
"env": {
"MCP_MEMORY_REPO_ROOT": "/path/to/corates"
}
🤖 Prompt for AI Agents
In `@packages/mcp-memory/mcp-config.example.json` around lines 6 - 8, Replace the
hardcoded user-specific path for the MCP_MEMORY_REPO_ROOT env value with a
generic placeholder (e.g., "/path/to/your/repo" or "<YOUR_REPO_ROOT>") so the
example config is portable; update the "MCP_MEMORY_REPO_ROOT" value in
packages/mcp-memory/mcp-config.example.json accordingly.

Comment on lines +140 to +153
```
MCP Server (stdio)
|
+-- Tools
| +-- search_memory
| +-- propose_memory_write
| +-- propose_memory_update
|
+-- Embedding Service (local, @xenova/transformers)
| +-- all-MiniLM-L6-v2 (384 dimensions)
|
+-- Storage (SQLite via better-sqlite3)
+-- .mcp/memory.db
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Add a language to the architecture diagram code fence.

Markdownlint flags this fence for missing a language tag.

Proposed fix
-```
+```text
 MCP Server (stdio)
     |
     +-- Tools
@@
           +-- .mcp/memory.db
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
```
MCP Server (stdio)
|
+-- Tools
| +-- search_memory
| +-- propose_memory_write
| +-- propose_memory_update
|
+-- Embedding Service (local, @xenova/transformers)
| +-- all-MiniLM-L6-v2 (384 dimensions)
|
+-- Storage (SQLite via better-sqlite3)
+-- .mcp/memory.db
```
🧰 Tools
🪛 markdownlint-cli2 (0.18.1)

140-140: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

🤖 Prompt for AI Agents
In `@packages/mcp-memory/README.md` around lines 140 - 153, The fenced diagram
block in the README is missing a language tag; update the triple-backtick fence
that surrounds the "MCP Server (stdio)" ASCII diagram to include a language
identifier (use "text") so it becomes ```text, leaving the diagram contents
unchanged; this targets the code fence in packages/mcp-memory/README.md that
begins with "MCP Server (stdio)".

Comment thread packages/mcp-memory/src/embedding/local.ts
Comment thread packages/mcp-memory/src/server.ts Outdated
Comment thread packages/mcp-memory/src/tools/memory.ts Outdated
Comment thread packages/mcp-memory/src/types.ts Outdated
@InfinityBowman
InfinityBowman merged commit 35b04a1 into main Jan 17, 2026
1 of 2 checks passed
@InfinityBowman
InfinityBowman deleted the 302-memory-mcp branch January 17, 2026 16:09
@github-actions
github-actions Bot restored the 302-memory-mcp branch January 17, 2026 16:09
@InfinityBowman
InfinityBowman deleted the 302-memory-mcp branch March 29, 2026 03:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

memory mcp

2 participants