Skip to content

bring back router node title in prefix#97

Merged
srijanpatel merged 1 commit intomainfrom
bugfix/router-node-prefix
Jan 18, 2025
Merged

bring back router node title in prefix#97
srijanpatel merged 1 commit intomainfrom
bugfix/router-node-prefix

Conversation

@srijanpatel
Copy link
Copy Markdown
Collaborator

@srijanpatel srijanpatel commented Jan 18, 2025

Important

Enhance URL variable handling in LLM nodes, update router node output model creation, and include node titles in NodeSidebar output schema keys.

  • Backend:
    • single_llm_call.py: Adjust URL variable handling to support cases with more than two parts by using the first and last parts as node_id and var_name.
    • router.py: Change input.__fields__ to input.model_fields for output model creation.
    • Add JSON schema printing in router.py test case.
  • Frontend:
    • NodeSidebar.tsx: Remove special handling for RouterNode in collectIncomingSchema, ensuring node titles are included in output schema keys.

This description was created by Ellipsis for 8cfd7c5. It will automatically update as commits are pushed.

Copy link
Copy Markdown
Contributor

@ellipsis-dev ellipsis-dev Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 Looks good to me! Reviewed everything up to 8cfd7c5 in 39 seconds

More details
  • Looked at 62 lines of code in 3 files
  • Skipped 0 files when reviewing.
  • Skipped posting 3 drafted comments based on config settings.
1. backend/app/nodes/llm/single_llm_call.py:115
  • Draft comment:
    The logic for splitting self.config.url_variables["file"] assumes that if there are more than two parts, the first and last parts are the node_id and var_name. This might not be correct if the variable name itself contains dots. Consider revising this logic to handle such cases more robustly.
  • Reason this comment was not posted:
    Comment looked like it was already resolved.
2. backend/app/nodes/logic/router.py:127
  • Draft comment:
    The change from __fields__ to model_fields is correct for compatibility with Pydantic v2. Ensure that the rest of the codebase is also updated to use model_fields where applicable.
  • Reason this comment was not posted:
    Confidence changes required: 0%
    The change in router.py from __fields__ to model_fields is correct as model_fields is the updated attribute in Pydantic v2. This change is necessary for compatibility with the newer version of Pydantic.
3. frontend/src/components/nodes/nodeSidebar/NodeSidebar.tsx:186
  • Draft comment:
    The removal of the special handling for RouterNode types means their output schema keys will now be prefixed with the node title. Ensure this change aligns with the intended behavior for displaying router nodes in the sidebar.
  • Reason this comment was not posted:
    Confidence changes required: 50%
    The NodeSidebar.tsx file had a section removed that specifically handled RouterNode types differently. This change might affect how router nodes are displayed in the sidebar, as their output schema keys are no longer prefixed with the node title. This could be intentional, but it's worth noting the change in behavior.

Workflow ID: wflow_N94VWbhSn5p6s1w4


You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

@srijanpatel srijanpatel merged commit 1af8890 into main Jan 18, 2025
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.

1 participant