Skip to content

Commit dd8b124

Browse files
authored
Merge pull request #593 from refly-ai/feat/optimize-skill-artifact-optimization
Feat/optimize skill artifact optimization
2 parents 22d4d68 + 4e072d1 commit dd8b124

File tree

4 files changed

+13
-5
lines changed

4 files changed

+13
-5
lines changed

packages/ai-workspace-common/src/components/canvas/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -821,7 +821,7 @@ const Flow = memo(({ canvasId }: { canvasId: string }) => {
821821
}}
822822
onScroll={(e) => updateIndicators(e.currentTarget)}
823823
>
824-
<div className="relative h-full">
824+
<div className="relative h-full overflow-y-hidden">
825825
<div className="flex gap-2 h-full">
826826
{nodePreviews?.filter(Boolean)?.map((node) => (
827827
<NodePreview key={node?.id} node={node} canvasId={canvasId} />
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
.ant-layout-sider {
2+
border: 0;
3+
}

packages/ai-workspace-common/src/components/sider/layout.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ import { useCanvasTemplateModal } from '@refly-packages/ai-workspace-common/stor
4141
import { subscriptionEnabled } from '@refly-packages/ai-workspace-common/utils/env';
4242
import { CanvasTemplateModal } from '@refly-packages/ai-workspace-common/components/canvas-template';
4343
import { SiderLoggedOut } from './sider-logged-out';
44+
import './layout.scss';
45+
4446
const Sider = Layout.Sider;
4547
const MenuItem = Menu.Item;
4648
const SubMenu = Menu.SubMenu;

packages/skill-template/src/scheduler/module/common/format.ts

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,10 @@ export const buildFormatDisplayInstruction = () => {
1212
- Keep content well-structured
1313
- Ensure consistent indentation
1414
- Follow heading level hierarchy strictly
15+
- Always specify language identifiers in code blocks (e.g. \`\`\`js, \`\`\`ts, \`\`\`svg, \`\`\`mermaid)
1516
1617
3. Mermaid Diagram Rules:
18+
- Use \`\`\`mermaid code block for all Mermaid diagrams
1719
- Mermaid renderer version is 10.9.0, please follow this version's syntax.
1820
`;
1921
};
@@ -30,10 +32,10 @@ export const buildVisualExamplesInstruction = () => {
3032
3133
### Visual Examples Generation Guidelines:
3234
1. Types of Visual Content to Generate:
33-
- SVG: Use for simple illustrations, icons, charts, and diagrams
34-
- HTML (with Tailwind CSS): Use for interactive UI components and layouts
35-
- Mermaid: Use for flowcharts, sequence diagrams, entity relationships, etc.
36-
- React Components: Use for more complex interactive examples
35+
- SVG: Use \`\`\`svg blocks for simple illustrations, icons, charts, and diagrams
36+
- HTML: Use \`\`\`html blocks for interactive UI components and layouts with Tailwind CSS
37+
- Mermaid: Use \`\`\`mermaid blocks for flowcharts, sequence diagrams, entity relationships, etc.
38+
- React Components: Use \`\`\`tsx or \`\`\`jsx blocks for more complex interactive examples
3739
3840
2. When to Generate Visual Content:
3941
- Explanations of complex concepts that benefit from visualization
@@ -48,5 +50,6 @@ export const buildVisualExamplesInstruction = () => {
4850
- Include variations that address different use cases
4951
- Combine different visualization types when they complement each other
5052
- Ensure each example has clear explanatory text
53+
- Always use appropriate language identifiers in code blocks
5154
`;
5255
};

0 commit comments

Comments
 (0)