GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Memory: SQLiteテーブル + ファイルシステム永続化レイヤー · Issue #43 · Cor-Incorporated/opencode

Memory: SQLiteテーブル + ファイルシステム永続化レイヤー #43

New issue
Copy link
New issue
Copy link
Closed
#56
Closed
Memory: SQLiteテーブル + ファイルシステム永続化レイヤー#43
#56
Copy link

Description

@terisuke
terisuke
opened on Apr 5, 2026
Issue body actions

親Epic: #37 (Persistent Cross-Session Memory System)

概要

メモリエントリをSQLiteテーブル + プロジェクト別ディレクトリのmdファイルで永続化する。

実装詳細

SQLiteスキーマ

CREATE TABLE memory (
  id TEXT PRIMARY KEY,
  project_id TEXT NOT NULL,
  name TEXT NOT NULL,
  description TEXT NOT NULL,
  type TEXT NOT NULL CHECK(type IN ('user','feedback','project','reference')),
  content TEXT NOT NULL,
  created_at TEXT NOT NULL DEFAULT (datetime('now')),
  updated_at TEXT NOT NULL DEFAULT (datetime('now'))
);

ファイルシステム

~/.opencode/projects/{project-hash}/memory/
├── MEMORY.md           # インデックス
├── feedback_*.md       # frontmatter付きmdファイル
├── project_*.md
├── user_*.md
└── reference_*.md

対象ファイル

  • packages/opencode/src/session/session.sql.ts — テーブル追加
  • 新規: packages/opencode/src/memory/ ディレクトリ
    • schema.ts — Drizzleスキーマ定義
    • repo.ts — CRUD操作
    • file.ts — mdファイル読み書き(frontmatter解析)
    • index.ts — 公開API

frontmatter形式

---
name: メモリ名
description: 一行説明
type: feedback
---
本文

受入基準

  • memory テーブルがmigrationで追加される
  • CRUD: create, read, update, delete が動作する
  • SQLite ↔ ファイルシステム双方向同期
  • プロジェクトIDでスコープ分離

Activity

  1. terisuke
    closed this as completedin #56on Apr 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402792 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.