Repository navigation
Dify workflows use native Loom memory and knowledge tools - #763
Merged
Merged
Conversation
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Run each overlap in a fresh process with Dify imported first and an owned loopback HTTP fixture. Separate credential scopes and responses expose native SDK loop collisions without changing framework guards. Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Construct, call and close each client in one native worker so overlapping tool invocations keep separate event loops and credentials. Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Return failures from the complete SDK lifecycle and raise them in the caller, where tool and credential validation sanitization applies. Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
The plugin manifest requires a public email contact. The copy check recognizes the public feedback inbox alongside the existing role inboxes and continues to reject individual addresses and near matches. Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
7 of 8 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changelog category (leave one):
Changelog entry (one or two sentences a user of Loom can read without the diff; the release pull request collects these into the release notes):
A Dify plugin exposes remember, recall and knowledge-search tools against a configured Loom deployment.
Why
Dify workflows need native tools with provider credentials and form-bound end-user identity. The plugin implements the installed SDK's tool and provider interfaces and packages with the official CLI. It uses the published Loom SDK over HTTP; no database, local memory fallback or model provider is added.
Provider configuration fixes the organization, namespace and agent. The end-user id is a required form field, outside model-generated arguments. Searches pin the configured namespace. Each request constructs, calls and closes its SDK client in a native worker thread so concurrent greenlets do not share an event loop. Credentials are copied before dispatch, and errors cross the worker boundary without logging response details. Requests use a 15-second HTTP timeout, a 30-second SDK call wait and one attempt; pool admission, client setup and closure are separate. The manifest supplies the repository and public contact required by the marketplace validator. The package includes its privacy policy and an automated native-test/package workflow. The public-copy check accepts the verified public feedback role inbox required by the marketplace contact field; regression cases still reject personal addresses, including names containing that role word.
Scope and risk
Three native tools, credentials, package assets, privacy policy, CI and documentation. Remember persists memory; recall reads user memories and knowledge search reads shared namespace documents. An administrator controls the HTTP destination and token, so network access must be constrained by the runner's policy. URLs reject embedded credentials, queries and fragments. Remote errors do not reveal token or response details. No local Dify application is running for an end-to-end UI check; that limitation is documented.
Compatibility, rollout and rollback
Tests
make format-check,make lint,make typecheckand generated-file checks pass.AI assistance in the code (leave one; writing this description with AI is fine):
AI-generated: Claude Code and Codex. Checked the installed framework interface, native behavior, stored scope and provenance, packaging and test coverage.
I can explain every line of this diff and how it interacts with the rest of Loom.
Checklist