Canopy開発日誌-2025年12月〜2026年2月

2025年12月26日から2026年2月末までのCanopy開発ログ(日次記録)。期間の要約は12月〜2月-まとめ

ソースコードを構造(IR)として編集する MoonBit 製エディタ。概要はCanopyとは

この期間の大きな流れ

期間全体の流れは12月〜2月-まとめにまとめた。以下は月次ヘッダと日付見出しによる作業記録(2/6まで)。コミットメッセージの一覧は文末のコミット索引にある。

12月(2025/12/26〜12/28)

年末3日間でCRDT実験とincremental parserの原型が立った。

2025/12/26

Canopy / プロトタイプ開始

CanopyはCRDT実験として始動した。初日にFugueMaxアルゴリズム、merge algorithm、editor、public APIを実装し、baseline CRDT implementationを完成させた。後のCanopy文書モデルの中核となるCRDTは、この日が起点である。

2025/12/27

Canopy / parserとCRDTの統合

初日のCRDT実装に続けて、incremental parser、error recovery、parser-editor integration plan、benchmarks、crdt integrationを追加した。event-graph-walkerの前身となるwalkerやbranchの概念も、この頃から登場した。

Web editorの原型も追加されたが、まだ「integration with bug」のような動作確認段階にとどまっていた。

2025/12/28

Canopy / Lezer-style incremental parsing

Lezer形式のincremental reparsingを実装し、structural validationを追加した。Web appの修正も入り、年末3日間でCRDT + incremental parser + web editorの骨格が整った。

1月(2026/1/4〜1/31)

協調編集基盤、projectional editing、RLE、monorepo化へと広がった月。

2026/1/4

Canopy / リファクタリングとドキュメント

年末に急造したコードを整理した。parser向けドキュメントの整備、重複の修正、シリアライズ・キャッシュエラーの修正、build設定の更新を行った。

2026/1/5

Canopy / branchとEvent Graph Walker

branchシステムとEvent Graph Walkerを実装した。のちにevent-graph-walkerサブモジュールとして独立するCRDT操作追跡機構の原型である。

2026/1/7

Canopy / WebSocket signaling server

CRDT協調編集向けに、Durable Objects上のWebSocket signaling serverを実装した。branch機能の拡張も並行して進めた。

2026/1/8

Canopy / Version Vector

ネットワーク同期のためVersion Vectorを導入した。Frontier型による一貫したversion比較、operator overloadingによる比較、JSONパースのFromJson trait化などを行った。CRDTはローカル編集にとどまらず、協調編集を視野に入れ始めた。

parser

Lambda Calculus Parserにproperty-based testを追加した。ASTNode kind typeのstring/array両対応も行った。

2026/1/9

Canopy / CRDT performance

walker algorithmの線形スケーリングを強化し、performance optimization roadmapを策定した。CRDT component(version vectors, walkers, merges, oplogs)向けのbenchmarkも追加した。

2026/1/11

Canopy / graphvizとparser error handling

moon-examplesからgraphvizパッケージを追加した。parserとlexerのerror handlingもリファクタリングした。

2026/1/12

Canopy / event-graph-walker抽出とCRDT document model

event-graph-walkerを再利用可能なCRDTライブラリとしてmodule化した。CRDT document modelをeditorへ統合し、branch systemのmerge algorithmとbenchmarksも追加した。Reactデモ向けのnetwork panelやeditor stylingも整えた。

2026/1/13

Canopy / vite-plugin-moonbitとドキュメント整理

vite-plugin-moonbitを作成した。MoonBitのJSビルドとViteのHMRを連携させ、開発体験を改善した。Claude skill for documentationの追加やドキュメント再編も行った。

2026/1/15

Canopy / valtio FFI

React状態管理向けにvaltioのJS FFIを追加し、egwalkerとの統合を進めた。

2026/1/16

Canopy / Projectional Editing計画

構造編集(projectional editing)のアーキテクチャ計画を作成した。rangeとdamageの分離も行い、後のAST編集操作へつなげた。

2026/1/17

Canopy / Projectional Editing Phase 2

構造編集の実装に着手した。CanonicalModel、SourceMap、interactive tree editorを追加し、AST editing operations(Phase 2)を実装した。tree operationsの網羅的edge case testや、CRDT stack全体のstructured errorsも追加した。

2026/1/18

Canopy / リファクタリングとlens

Fugue/treeのtrait化、Version Vectorとfrontierのtuple struct化、TreeEditorStateのimmutable hashset化、lens abstraction(双方向変換)の導入を行った。PROJECTIONAL_EDITING.mdをPhase 3進捗に合わせて更新した。

2026/1/19

Canopy / SVG DSL

type-safeなSVG DSL moduleを追加し、graphvizを含む可視化周りを整理した。

2026/1/21

Canopy / React協調編集デモ

Reactによる協調編集demoを実装し、Playwrightテストフレームワークを導入した。

2026/1/22

Canopy / demo-reactの性能・UX改善

demo-reactにWebSocket sync supportを追加し、協調編集の性能とUXを改善した。

2026/1/23

Canopy / editorとevent-graph-walker API

DocumentからTextDocへの移行、editor機能の強化、event-graph-walkerのuser-friendly API完成を進めた。valtioのtest/synchronization featuresも追加した。

2026/1/24-25

Canopy / RLE(Run-Length Encoding)

trait-basedなRLEの設計計画を作成し、Phase 2実装を進めた。TextSpanをRLEとtombstone supportで統合し、RLE vector、cursor and operations、performance benchmarksを追加した。

2026/1/26

Canopy / RLE完成とerror handling

RLE設計をcausal/visible lengthsベースに整理した。error handlingの強化、package importsの更新、changelog management skillの追加も行った。

2026/1/29

Canopy / CRDT形式仕様とproperty tests

eg-walker CRDTの形式仕様、system overview、responsibility mapを文書化した。FugueTreeのproperty testsも追加した。

2026/1/31

Canopy / monorepo化

大きな転換点。単一リポジトリからgit submoduleを使ったmonorepoへ再編した。event-graph-walker、graphviz、parser、svg-dsl、valtioをsubmodule化し、各package READMEの更新、.mbtiの再生成、build deployment scriptの追加、monorepo workflow guideの作成を行った。

Canopy / LCS reconciliation

monorepo化と並行して、AST children reconciliationにLCSアルゴリズムを採用した。

2月(2026/2/1〜2/6)

monorepo安定化、CI導入、incrの整備が中心。記録は2/6で途切れている。

2026/2/1

Canopy / monorepo安定化とCI導入

CRDTとeditorをcore operationsベースに整理した。comprehensive CI/CD infrastructureを追加し、redundant MoonBit buildをskipする最適化、Undelete operation loggingをdemo/REPLに追加した。submodule pointerの更新も複数回行われた。

2026/2/2

Canopy / UndoManager統合とdemo-react整理

event-graph-walkerのUndoManagerをcrdt moduleに統合した。demo-reactをfeatures patternに再編し、useEgWalker hookを導入した。

2026/2/6

Canopy / MoonBit品質検証workflow

development guideにMoonBit quality verification workflowを追加した。後のarchitecture auditやmoon.work導入の前提になる。

incr

2月はincrも活発だった。batch rollback、subscriber links、TrackedCell、API docs整備が進み、v0.3.1/v0.3.2リリースもこの時期に行われた。

コミット索引

月ごとに折りたたんだコミットメッセージ一覧。この期間はPRレビュー前で、ほぼコミット直 push だった。

12月(2025/12/26〜12/28)

2025/12/26

Canopy / プロトタイプ開始

  • create crdt experiment
  • create FugueMax algorithm
  • implement merge algorithm
  • create editor
  • create public api
  • finish base line crdt implementation

2025/12/27

Canopy / parserとCRDTの統合

  • add parser and start implementation
  • implement incremental parser
  • add Error Recovery
  • add crdt intergration
  • create parser editor intergration plan
  • create benchmarks for parser
  • implement integration with bug
  • add simple web editor

2025/12/28

Canopy / Lezer-style incremental parsing

  • add lezer style incremental_reparse
  • improve incremental_reparse
  • implement Lezer-style incremental parsing with structural validation
  • fix web app
1月(2026/1/4〜1/31)

2026/1/4

Canopy / リファクタリングとドキュメント

  • Start refactoring
  • create documentations for parser
  • finish priority 1
  • Priority 2: Fix Duplication
  • fix serialization and cache errors
  • update build configuration
  • update readme and index.html

2026/1/5

Canopy / branchとEvent Graph Walker

  • Implement branch system for efficient document snapshots and incremental updates
  • Implement Event Graph Walker and associated functionality

2026/1/7

Canopy / WebSocket signaling server

  • Add WebSocket signaling server with Durable Objects and deployment guides
  • Implement WebSocket signaling server for CRDT collaboration
  • Enhance branch functionality with new methods and improve merge operations

2026/1/8

Canopy / Version Vector

  • Enhance CRDT with Version Vector support
  • Refactor JSON parsing in parse_ops_from_json using FromJson trait
  • Refactor VersionVector to use operator overloading for comparison and update tests
  • replace frontier with version_vector in NetworkSync

parser

  • Add property-based tests for Lambda Calculus Parser
  • Update ASTNode kind type to support both string and array formats

2026/1/9

Canopy / CRDT performance

  • Add benchmarks for CRDT components: version vectors, walkers, merges, and oplogs
  • Update performance analysis and outline future optimization opportunities
  • Update implementation status and test count in documentation

2026/1/11

Canopy / graphvizとparser error handling

  • Add graphviz package from moon-examples
  • Refactor error handling in parser and lexer; update .gitignore

2026/1/12

Canopy / event-graph-walker抽出とCRDT document model

  • create event-graph-walker Module as Reusable CRDT Library
  • Add README.md for event-graph-walker
  • Add CRDT document model and integrate with editor
  • Implement merge algorithm and benchmarks for branch system
  • Add responsive network panel styles and collaboration controls
  • Refactor AST display logic in LambdaEditor

2026/1/13

Canopy / vite-plugin-moonbitとドキュメント整理

  • make vite plugin for moonbit to automate js intergration
  • Use HMR for vite-plugin-moonbit
  • obviating the need of sparated moon build
  • Add claude skill for documentation
  • Documentation reorganization

2026/1/15

Canopy / valtio FFI

  • Add valtio js ffi for moonbit
  • create integration with valtio and egwalker

2026/1/16

Canopy / Projectional Editing計画

  • Create Projectional Editing Architecture Plan
  • separate range from damage

2026/1/17

Canopy / Projectional Editing Phase 2

  • Add projectional editing components including CanonicalModel, SourceMap, and interactive tree editor with associated tests
  • Implement Phase 2: AST editing operations for projectional editing
  • Add CST-aware projection plan details
  • Add structured errors across CRDT stack
  • Add RawVersion frontier handling for network sync

2026/1/18

Canopy / リファクタリングとlens

  • introduce lens abstractions for bidirectional transformations
  • use trait and make private some methods for fugue
  • Use tuple struct for version vector
  • use tuple struct for frontier
  • use immutable hashset for TreeEditorState
  • update PROJECTIONAL_EDITING.md with Phase 3 progress and integration layer plan

2026/1/19

Canopy / SVG DSL

  • add type-safe SVG DSL module
  • use new svg dsl
  • add README.md for svg-dsl

2026/1/21

Canopy / React協調編集デモ

  • Implement collaborative editing demo by React
  • Enhance demo-react setup with Playwright testing framework

2026/1/22

Canopy / demo-reactの性能・UX改善

  • add WebSocket sync support and improve collaboration
  • high priority performance and UX improvements

2026/1/23

Canopy / editorとevent-graph-walker API

  • transition from Document to TextDoc and enhance editor functionalities
  • implement user-friendly API with error handling and sync features
  • finalize user-friendly API implementation and enhance documentation
  • add testing and synchronization features to valtio

2026/1/24-25

Canopy / RLE(Run-Length Encoding)

  • add RLE design plan documentation for trait-based run-length encoding implementation
  • complete Phase 2 of RLE implementation with cursor and operations
  • implement RLE vector with error handling and performance optimizations
  • integrate TextSpan for RLE with tombstone support and enhance traversal

2026/1/26

Canopy / RLE完成とerror handling

  • update RLE design to use causal and visible lengths
  • introduce changelog management skill and enhance RLE error handling
  • update RLE dependencies and introduce new RLE structures

2026/1/29

Canopy / CRDT形式仕様とproperty tests

  • add formal specification for eg-walker CRDT system
  • expand formal specification with system overview and responsibility map
  • add property tests for FugueTree functionality
  • update SKILL.md with MoonBit package versioning guidelines

2026/1/31

Canopy / monorepo化

  • restructure as monorepo with git submodules
  • remove directories that will become submodules
  • update all package READMEs for monorepo structure
  • regenerate .mbti interface files
  • add build deployment script and corresponding npm script
  • add monorepo and git submodule workflow guide

Canopy / LCS reconciliation

  • use LCS algorithm for AST children reconciliation
2月(2026/2/1〜2/6)

2026/2/1

Canopy / monorepo安定化とCI導入

  • update CRDT and editor to use core operations
  • add comprehensive CI/CD infrastructure
  • optimize CI to skip redundant MoonBit builds
  • add Undelete operation logging to demo and REPL commands

2026/2/2

Canopy / UndoManager統合とdemo-react整理

  • integrate event-graph-walker UndoManager into crdt module
  • reorganize demo-react into features pattern with useEgWalker hook

2026/2/6

Canopy / MoonBit品質検証workflow

  • add MoonBit quality verification workflow to development guide

incr

  • add graceful batch rollback and non-panicking read APIs
  • add subscribers to CellInfo
  • add Runtime::dependents introspection API
  • add TrackedCell struct as a named wrapper around Signal
  • add MemoMap keyed queries and docs
  • docs: update design.md and api-reference.md for cells/ rename