opencode-fractal-memory 0.6.15 → 0.6.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,7 @@
1
1
  import { memLog } from "../logging";
2
2
  import { generateEmbedding } from "../embeddings";
3
3
  import { queryNodes, getAvailableScopes, extractLinks, computeStats, readProjectConfig, writeProjectConfig, rowToNode, withDb, jsonResponse, cosineSimilarity, getAvailableProjects, } from "./helpers";
4
+ import { VERSION } from "../version";
4
5
  function handleScopes() {
5
6
  return jsonResponse(getAvailableScopes());
6
7
  }
@@ -184,8 +185,12 @@ async function handleNodeDelete(ctx) {
184
185
  function handleProjects(ctx) {
185
186
  return jsonResponse(getAvailableProjects(ctx.scope));
186
187
  }
188
+ function handleVersion() {
189
+ return jsonResponse({ version: VERSION });
190
+ }
187
191
  export function registerRoutes(router) {
188
192
  router.get(/^\/api\/scopes$/, () => handleScopes());
193
+ router.get(/^\/api\/version$/, () => handleVersion());
189
194
  router.get(/^\/api\/nodes$/, (_, ctx) => handleNodes(ctx));
190
195
  router.get(/^\/api\/links$/, (_, ctx) => handleLinks(ctx));
191
196
  router.get(/^\/api\/stats$/, (_, ctx) => handleStats(ctx));
@@ -770,11 +770,12 @@ function setupEventListeners() {
770
770
 
771
771
  async function loadData() {
772
772
  try {
773
- const [scopesRes, nodesRes, linksRes, statsRes] = await Promise.all([
773
+ const [scopesRes, nodesRes, linksRes, statsRes, versionRes] = await Promise.all([
774
774
  fetch("/api/scopes"),
775
775
  fetch(`/api/nodes?scope=${currentScope}`),
776
776
  fetch(`/api/links?scope=${currentScope}`),
777
777
  fetch(`/api/stats?scope=${currentScope}`),
778
+ fetch("/api/version"),
778
779
  ]);
779
780
 
780
781
  if (!nodesRes.ok || !linksRes.ok || !statsRes.ok) {
@@ -785,6 +786,8 @@ async function loadData() {
785
786
  nodeData = await nodesRes.json();
786
787
  linkData = await linksRes.json();
787
788
  statsData = await statsRes.json();
789
+ const versionData = await versionRes.json();
790
+ document.getElementById("version").textContent = `v${versionData.version}`;
788
791
 
789
792
  document.getElementById("loading").style.display = "none";
790
793
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opencode-fractal-memory",
3
- "version": "0.6.15",
3
+ "version": "0.6.16",
4
4
  "description": "Fractal memory system for OpenCode with semantic search and automatic compression.",
5
5
  "main": "dist/plugin.js",
6
6
  "exports": {