8000 feat(tree): the graph as nested folders and files by adeelahmad · Pull Request #290 · adeelahmad/lense · GitHub
[go: up one dir, main page]

Skip to content

feat(tree): the graph as nested folders and files - #290

Merged
adeelahmad merged 6 commits into
mainfrom
claude/project-thread-88khx4
Oct 10, 2026
Merged

adeelahmad merged 6 commits into
mainfrom
claude/project-thread-88khx4

Conversation

@adeelahmad
@adeelahmad adeelahmad commented Oct 10, 2026 •
Copy link
Copy Markdown
Owner

Description

Before: there was no way to browse Lens as files.

After: the graph is a tree of folders and files. In each namespace, Collections/ nests collections, Topics/ nests topics under their broader topics, and Entities/<type>/<name>/ holds what mentions each entity. Every folder holds its assets' files, named <title> [<id>]: the original file, a .json metadata sidecar, a .txt of the text, and a .pdf rendition for converted documents. You can browse it with GET /api/v1/tree and GET /api/v1/tree/file (byte ranges, ETag), and agents can use the MCP tools list_files and read_file.

Motivation and Context

Adeel asked for the graph as a dir tree with graph nodes as nested folders and files at the leaves. This is the shared layer that the S3/WebDAV (next PR), SMB and NFS servers serve.

Types of changes

  • New feature (non-breaking change which adds functionality)

Checklist:

  • The title is a Conventional Commit.
  • My code follows the code style of this project.
  • I added or updated tests.
  • My change requires documentation updates, and I have updated docs/ accordingly.
  • Users need more than the title to understand it, so I wrote it under ## Unreleased in CHANGELOG.md.

Done questions

  • Goal: delivers what the user wanted, merged on green CI.
  • Agents: API and MCP list_files / read_file.
  • Zero setup.
  • Fewest clicks and keystrokes.
  • Configurable: n/a, nothing to set (the servers' settings arrive with them).
  • Light: read on demand, no background work.
  • Private and secure: read-only, each person sees only what the web app shows them, encrypted files decrypted only on read.
  • Cost: no model calls.
  • User decides: read-only.
  • Upgrades: no stored-data changes.
  • Honest: docs label the servers as in progress.
  • Tests, docs and generated files updated.
  • Open standards; no new dependencies.
  • Result reported with evidence; "refine later" items are in docs/file-tree.md.

🤖 Generated with Claude Code

https://claude.ai/code/session_017MjvZcE48RUyNdztPNBgid

Namespaces, collections, topics and entities become folders; each asset is
its own file, a .json metadata sidecar and a .txt of its text. Shared layer
(app/domain/filetree.py) for the S3, SMB and NFS servers, browsable now
through GET /api/v1/tree and the MCP tools list_files and read_file.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017MjvZcE48RUyNdztPNBgid
Per Adeel: drop the Topics and Entities folders and namespace.json; the tree
is namespaces and collections holding each asset's files and sidecar.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017MjvZcE48RUyNdztPNBgid
@adeelahmad adeelahmad changed the title feat(tree): show the graph as folders and files feat(tree): show assets as folders and files by namespace and collection Oct 10, 2026
Collections nest by parent, topics by broader/narrower, entities by type;
each folder holds its assets' files.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017MjvZcE48RUyNdztPNBgid
@adeelahmad adeelahmad changed the title feat(tree): show assets as folders and files by namespace and collection feat(tree): the graph as nested folders and files Oct 10, 2026
@adeelahmad
adeelahmad merged commit 48d9b2c into main Oct 10, 2026
9 checks passed
@adeelahmad
adeelahmad deleted the claude/project-thread-88khx4 branch October 10, 2026 21:52
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.

2 participants

0