Skip to content

refactor(memory): streamline skill for pi-web users, add project/session context#13

Merged
setkyar merged 3 commits into
mainfrom
refactor-memory-skill
May 29, 2026
Merged

refactor(memory): streamline skill for pi-web users, add project/session context#13
setkyar merged 3 commits into
mainfrom
refactor-memory-skill

Conversation

@setkyar
Copy link
Copy Markdown
Contributor

@setkyar setkyar commented May 29, 2026

Summary

Refactors the memory skill from a personal tool into a pi-web project skill:

  • Database location: Moved to $PI_CODING_AGENT_DIR/pi-web-memory.sqlite, mirrors pi's own getAgentDir() logic
  • Schema: Shipped inside the skill at .pi/skills/memory/data/schema.sql
  • Project context: add-memory now captures --cwd, --project, --session-id, --session-name — stored as JSON in the context column
  • Search filtering: search supports --project filter using json_extract()
  • Removed tables: financial_accounts, reminders, todos, automations — memory skill is now scoped to project knowledge only
  • Outdated memories: Added guidance on verifying stale memories against current codebase
  • Generic naming: Replaced all personal references with pi-web user orientation

setkyar added 3 commits May 29, 2026 14:15
…ion context

- Move DB to $PI_CODING_AGENT_DIR/pi-web-memory.sqlite (mirrors pi's getAgentDir())
- Move schema.sql into skill directory (.pi/skills/memory/data/)
- Add project context: --cwd, --project, --session-id, --session-name
- Add --project filter to search (json_extract on context JSON)
- Remove financial_accounts, reminders, todos, automations
- Add outdated memories guidance
- Remove personal references
- Fix FROM memories → FROM memories m so project_filter (json_extract(m.context)) works
- Fix SKILL_ROOT from parents[2] → parents[1] for scripts/ nesting
- Fix init_db to print get_db_path() instead of DB constant
- Add PI_MEMORY_DB env var support for testability
- Add 17 unit tests (unittest) covering FTS query parsing and add→search pipeline
@setkyar setkyar merged commit f04dadb into main May 29, 2026
1 check passed
@setkyar setkyar deleted the refactor-memory-skill branch May 29, 2026 08:04
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.

1 participant