File tree Expand file tree Collapse file tree
lightrag_webui/src/features Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -838,13 +838,19 @@ export default function SanitizeData() {
838838 // Process edges/relationships
839839 ( data . edges || [ ] ) . forEach ( ( edge : any ) => {
840840 const props = edge . properties || { } ;
841- edges . push ( {
842- from : edge . source ,
843- to : edge . target ,
844- relation : props . description || "" ,
845- weight : props . weight || 1.0 ,
846- keywords : props . keywords || "" ,
847- } ) ;
841+ const from = edge . source ;
842+ const to = edge . target ;
843+
844+ // Keep the relationship only if Bypass Switch (or whichever entity we queried) is one of the endpoints
845+ if ( from === entityName || to === entityName ) {
846+ edges . push ( {
847+ from,
848+ to,
849+ relation : props . description || "" ,
850+ weight : props . weight || 1.0 ,
851+ keywords : props . keywords || "" ,
852+ } ) ;
853+ }
848854 } ) ;
849855
850856 // Store the parsed data
@@ -1699,6 +1705,7 @@ export default function SanitizeData() {
16991705 } ,
17001706 } ) ) ;
17011707 } }
1708+ onFocus = { ( e ) => e . target . select ( ) }
17021709 />
17031710 </ div >
17041711
You can’t perform that action at this time.
0 commit comments