Repository navigation
feat(studio): Support images in chat - #364
Conversation
Signed-off-by: Sean Teramae <steramae@nvidia.com>
Signed-off-by: Sean Teramae <steramae@nvidia.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (4)
💤 Files with no reviewable changes (3)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughAdds image attachment support to ChangesAssistantChat Image Attachments
Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 4
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@web/packages/common/src/components/AssistantChat/index.tsx`:
- Line 9: Replace the relative import path in the import statement for
modelSupportsImageAttachments with an absolute alias path. The current import
uses './messageUtils' which violates the absolute alias path requirement for
web/**/*.{ts,tsx,js,jsx} files. Convert this relative import to use the
appropriate absolute alias path configured in the project (typically using path
aliases like `@common` or similar based on tsconfig configuration).
In `@web/packages/common/src/components/AssistantChat/messageUtils.test.ts`:
- Around line 6-10: Replace the relative import path in the import statement for
getOpenAIMessages, getUserMessageContent, and modelSupportsImageAttachments with
an absolute alias path instead of the relative './messageUtils' path. Follow the
project's established absolute import alias convention for web packages to
maintain consistency with other imports in the codebase.
In `@web/packages/common/src/components/AssistantChat/README.md`:
- Around line 69-70: The documentation for image attachments at lines 69-70 in
the README.md file is incomplete and misleading. Update the wording to clarify
that image attachments are enabled by both the enableImageAttachments prop AND
the modelSupportsImageAttachments function check, not by the prop alone. Rewrite
the bullet point to accurately reflect the full runtime condition that gates the
image attachment feature in the AssistantChat component.
In `@web/packages/common/src/components/AssistantChat/types.ts`:
- Around line 129-132: The JSDoc comment for the enableImageAttachments property
specifies `@default` false, but the actual implementation in index.tsx defaults
this property to true. Update the `@default` annotation in the JSDoc comment for
enableImageAttachments in the types.ts file to reflect the true default value
used in the implementation.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: 34be087d-0b35-46f8-b6ef-c9fdba48d520
📒 Files selected for processing (12)
services/studio/src/nmp/studio/env_mappings.pyweb/packages/common/src/components/AssistantChat/AssistantChatMessages.tsxweb/packages/common/src/components/AssistantChat/AssistantChatThread.tsxweb/packages/common/src/components/AssistantChat/AssistantComposer.tsxweb/packages/common/src/components/AssistantChat/ComposerAttachments.tsxweb/packages/common/src/components/AssistantChat/README.mdweb/packages/common/src/components/AssistantChat/index.test.tsxweb/packages/common/src/components/AssistantChat/index.tsxweb/packages/common/src/components/AssistantChat/messageUtils.test.tsweb/packages/common/src/components/AssistantChat/messageUtils.tsweb/packages/common/src/components/AssistantChat/types.tsweb/packages/common/src/components/AssistantChat/useAssistantChatRuntime.ts
|
- Use absolute alias path for messageUtils import in index.tsx and test - Fix @default annotation: enableImageAttachments defaults to true not false - Update README to reflect that image attachments require both enableImageAttachments=true and a vision-capable model Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Signed-off-by: Sean Teramae <steramae@nvidia.com>
Signed-off-by: Sean Teramae <steramae@nvidia.com>
Signed-off-by: Sean Teramae <steramae@nvidia.com>
Signed-off-by: Sean Teramae <steramae@nvidia.com>
Signed-off-by: Sean Teramae <steramae@nvidia.com>
Summary by CodeRabbit