diff --git a/go/cmd/zhiyid/zhiyid-new b/go/cmd/zhiyid/zhiyid-new new file mode 100755 index 0000000..01d5e88 Binary files /dev/null and b/go/cmd/zhiyid/zhiyid-new differ diff --git a/go/internal/models/memory.go b/go/internal/models/memory.go index 827c8fa..a92792a 100644 --- a/go/internal/models/memory.go +++ b/go/internal/models/memory.go @@ -94,6 +94,7 @@ type RecallResult struct { // omitempty:旧调用方无感;图谱扩展路径(graph_*.go)无 ns 概念,留空。 Namespace string `json:"namespace,omitempty"` AgentID string `json:"agent_id,omitempty"` + Source string `json:"source,omitempty"` } // RerankResult rerank 重排后的单条结果。 diff --git a/go/internal/storage/lancedb_ipc.go b/go/internal/storage/lancedb_ipc.go index 9d29cab..d47b8fd 100644 --- a/go/internal/storage/lancedb_ipc.go +++ b/go/internal/storage/lancedb_ipc.go @@ -155,7 +155,7 @@ func (rc *RustLanceDBClient) InsertMemory(m models.MemoryRecord) error { "tier": m.Tier, "importance": 1.0, "quality_score": m.QualityScore, "recall_count": m.RecallCount, "useful_count": 0, "not_useful_count": 0, "freshness": m.Freshness, "version": 1, "version_history": "[]", - "source": "", "volatile_flag": false, "is_deleted": m.IsDeleted, + "source": m.Source, "volatile_flag": false, "is_deleted": m.IsDeleted, "depends_on": "[]", "derived_from": "", "last_recalled_at": "", "created_at": m.CreatedAt.Format(time.RFC3339), "updated_at": m.UpdatedAt.Format(time.RFC3339),