Repository navigation
feat(agent): add Querit Canvas form - #3
Merged
Merged
Conversation
ethan7zhanghx
marked this pull request as ready for review
July 27, 2026 15:04
ethan7zhanghx
pushed a commit
that referenced
this pull request
Aug 7, 2026
…17937) Collapses three duplicated/dead code smells in the canvas debug-result path of `internal/ingestion/task` (remaining findings #2/#3/#4 from the package CTO review): - **#2 — vector-key stripping duplication.** `isVectorKey` (the full stripper: fixed legacy keys `vector`/`embedding`/`feature`/`q_vec` plus the `q_<dim>_vec` pattern) was re-implemented as a weaker inline copy in the golden-compare tool (`tool/compare_pipeline_golden.go`) that only matched `q_<dim>_vec` and let real vectors leak into the diff. Exported as `IsVectorKey` and reused by the tool. - **#3 — near-duplicate deep copy.** `deepCopy` and `deepCopyStrip` were identical walkers differing only in vector stripping. Parameterized `deepCopy(v any, stripVector bool) any` and deleted `deepCopyStrip`. - **#4 — redundant switch.** `lookupComponentOutput` had two switch cases with identical bodies (both the `map[string]map[string]any` and `map[string]any` state shapes). Unified into a single `found`/`ok` resolution; nested-state and flat-fallback semantics unchanged.
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.
Summary
Add the standalone Querit search node configuration to the RAGFlow Canvas. This replaces the compile-safe placeholder from the contract PR with a usable form while keeping the Python and Go runtimes independent.
What changed
QueritSearchform inFormConfigMapapi_keyand a RAGFlow variable selector forquerycount,chunks_per_doc, andtime_rangestring[]and rehydrate persistedstring[]values when reopening a nodeField contract
api_keyquerycountchunks_per_docsite_includestring[]site_excludestring[]time_ranged/w/m/yrange, orYYYY-MM-DDtoYYYY-MM-DDcountry_includestring[]language_includestring[]Validation
28focused Jest tests passed across two suites, covering field validation, numeric normalization, list serialization, node rehydration, and the Canvas update watchergit diff --checkpassedNODE_OPTIONS=--max-old-space-size=8192 npm run build(14,201modules, about 15m27s on ARM)The browser run exposed and this PR fixes two persistence defects: invalid values could be written during the
react-hook-formvalidity update window, and a newly added empty dynamic-list row could be persisted as[""].Known baseline / environment limitations
npm run type-checkremains red because the current integration branch already contains many unrelated TypeScript errors. Filtering the output found no errors in the newquerit-formfiles.QueryVariable, which requires the full Canvas/backend context. Query-variable integration remains covered by source review and the successful production build, and should receive final E2E coverage in a supported RAGFlow environment.Scope
This PR does not modify the Python tool, Go tool, locale files, shared UI primitives, Agent embedded-tool registration, export redaction, or timeline icons.