-
Notifications
You must be signed in to change notification settings - Fork 364
Agent builder auto generate prompt #1372
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
base: main
Are you sure you want to change the base?
Conversation
- Add editor/preview toggle buttons for small screen layouts - Include new translation keys for "editor" and "preview" labels - Import PiPencilSimple and PiEye icons for toggle buttons - Implement activeView state to switch between editor and preview modes - Hide toggle on large screens where both panels are visible
- Add generate prompt button with streaming AI generation support - Implement overwrite confirmation dialog for existing prompts - Extract MCP server config parsing to shared useMCPServers hook - Add localization strings for prompt generation UI (en/ja)
Add guideline to generate system prompts in the same language as the provided Name and Description, improving localization support for non-English users.
- Extend usePromptGeneration hook to parse and return suggested MCP servers - Add parseMCPServers and extractSystemPrompt helpers for parsing LLM output - Auto-populate form's MCP servers when AI suggests them via new useEffect - Simplify hook params by replacing mcpServers/mcpServerConfigs with availableMCPServers
| export const MCP_SERVERS_START_MARKER = '<SELECTED_MCP_SERVERS>'; | ||
| export const MCP_SERVERS_END_MARKER = '</SELECTED_MCP_SERVERS>'; | ||
| export const SYSTEM_PROMPT_START_MARKER = '<SYSTEM_PROMPT>'; | ||
| export const SYSTEM_PROMPT_END_MARKER = '</SYSTEM_PROMPT>'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ストリーム処理的に徐々にテキストボックスに表示しつつ、チェックボックスにも自動入力したいために Cline の内部実装を真似てマーカー戦略にしています。
| </div> | ||
|
|
||
| {/* Agent Testing */} | ||
| {/* Agent Testing - Always visible on large screens, toggle on small */} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
| * The stream returns JSON strings like {"text":"..."} or {"text":"","stopReason":"end_turn"} | ||
| */ | ||
|
|
||
| export interface StreamChunk { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
細かいですが types/src/protocol.d.ts の StreamingChunk と定義が重複
| * @param stream - The async iterable stream from predictStream | ||
| * @yields Text content extracted from each chunk | ||
| */ | ||
| export async function* streamToText( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
細かいですがデッドコードになってそう
Description of Changes
Agent builder auto generate prompt
Checklist
npm run cdk:testand if there are snapshot differences, executenpm run cdk:test:update-snapshotto update snapshotsRelated Issues
Please list related issues as much as possible.
Screenshots