Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: refetch endpoint's models #2747

Merged
merged 1 commit into from
Oct 11, 2024
Merged

Conversation

yomybaby
Copy link
Member

@yomybaby yomybaby commented Oct 11, 2024

image.png

Changes:

This PR enhances the ChatUIModal, EndpointLLMChatCard, and LLMPlaygroundPage components:

  1. Added a refresh button to the "Cannot Find Model" alert in ChatUIModal and EndpointLLMChatCard.
  2. Implemented the destroyOnClose prop for the Modal component in ChatUIModal. After this change, it refetches models when the modal is opened.
  3. useUpdatableState hook in EndpointLLMChatCard for managing fetch key.
  4. Improved layout and styling of LLMPlaygroundPage, particularly for the card skeleton.

Rationale:

These changes improve user experience by providing a way to refresh model data and enhance the overall UI responsiveness and appearance.

Effects:

  • Users can now easily refresh model data when it's not found.
  • The chat modal will reset its state when closed, ensuring a fresh start on reopening.
  • The playground page layout is more consistent and visually appealing.

Copy link

graphite-app bot commented Oct 11, 2024

Your org requires the Graphite merge queue for merging into main

Add the label “flow:merge-queue” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “flow:hotfix” to add to the merge queue as a hot fix.

You must have a Graphite account and log in to Graphite in order to use the merge queue. Sign up using this link.

@github-actions github-actions bot added the size:M 30~100 LoC label Oct 11, 2024
Copy link
Member Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @yomybaby and the rest of your teammates on Graphite Graphite

Copy link

github-actions bot commented Oct 11, 2024

Coverage report for ./react

St.
Category Percentage Covered / Total
🔴 Statements
5.4% (-0% 🔻)
348/6441
🔴 Branches 4.86% 218/4487
🔴 Functions
3.15% (-0% 🔻)
67/2125
🔴 Lines
5.29% (-0% 🔻)
333/6292

Test suite run success

93 tests passing in 12 suites.

Report generated by 🧪jest coverage report action from a3a8ce3

@yomybaby yomybaby requested review from ironAiken2 and agatha197 and removed request for ironAiken2 October 11, 2024 08:43
Copy link
Contributor

@agatha197 agatha197 left a comment

Choose a reason for hiding this comment

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

LGTM

@yomybaby yomybaby marked this pull request as ready for review October 11, 2024 09:28
Copy link
Contributor

@ironAiken2 ironAiken2 left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link

graphite-app bot commented Oct 11, 2024

Merge activity

![image.png](https://graphite-user-uploaded-assets-prod.s3.amazonaws.com/XqC2uNFuj0wg8I60sMUh/f2a0490e-249e-46d8-98cd-2cb853a4bc6a.png)

**Changes:**

This PR enhances the ChatUIModal, EndpointLLMChatCard, and LLMPlaygroundPage components:

1. Added a refresh button to the "Cannot Find Model" alert in ChatUIModal and EndpointLLMChatCard.
2. Implemented the `destroyOnClose` prop for the Modal component in ChatUIModal. After this change, it refetches models when the modal is opened.
3. `useUpdatableState hook` in EndpointLLMChatCard for managing fetch key.
4. Improved layout and styling of LLMPlaygroundPage, particularly for the card skeleton.

**Rationale:**

These changes improve user experience by providing a way to refresh model data and enhance the overall UI responsiveness and appearance.

**Effects:**

- Users can now easily refresh model data when it's not found.
- The chat modal will reset its state when closed, ensuring a fresh start on reopening.
- The playground page layout is more consistent and visually appealing.
@ironAiken2 ironAiken2 force-pushed the feature/refech-endpoint-models branch from e3b216c to a3a8ce3 Compare October 11, 2024 09:41
@graphite-app graphite-app bot merged commit a3a8ce3 into main Oct 11, 2024
7 checks passed
@graphite-app graphite-app bot deleted the feature/refech-endpoint-models branch October 11, 2024 09:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size:M 30~100 LoC
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants