-
Notifications
You must be signed in to change notification settings - Fork 661
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
Use Gemini-1.5-pro-latest Stream Chat with history, Generate Git Commit message with Gemini, Add a Gemini Extension webview window, Chat mesage with Highlight Code #373
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add getCommentperfixes
modified: examples/gemini/node/pipet-code-agent/src/review.ts
modified: examples/gemini/node/pipet-code-agent/src/review.ts
modified: examples/gemini/node/pipet-code-agent/src/extension.ts new file: examples/gemini/node/pipet-code-agent/webview.html add Chat stat
modified: examples/gemini/node/pipet-code-agent/src/getCommentprefixes.ts
add streaming
…Stream() use try catch error
This commit adds a new command to the Pipet Code Agent extension that allows users to generate git commit messages based on the git diff. The command uses the Gemini large language model to generate a commit message that is relevant to the changes made in the code. The generated commit message is then copied to the clipboard and pasted into the commit box. This can save users time and effort when committing their changes.
modified: examples/gemini/node/pipet-code-agent/media/main.css modified: examples/gemini/node/pipet-code-agent/media/main.js modified: examples/gemini/node/pipet-code-agent/media/prism.css modified: examples/gemini/node/pipet-code-agent/media/vscode.css modified: examples/gemini/node/pipet-code-agent/src/chat.ts modified: examples/gemini/node/pipet-code-agent/src/extension.ts modified: examples/gemini/node/pipet-code-agent/src/getCommentprefixes.ts renamed: examples/gemini/node/pipet-code-agent/src/gitdiff.ts -> examples/gemini/node/pipet-code-agent/src/gitCommit.ts modified: examples/gemini/node/pipet-code-agent/src/review.ts
This commit addresses several updates to the Pipet Code Agent's configuration and functionality. The changes include: 1. Adjustments to the `package.json` file, where the properties for `google.gemini.apiKey` and `google.gemini.systemInstruction` have been modified to include default values and markdown descriptions for better user guidance. 2. Updates to the `chat.ts` file, which now includes a new function `startchat()` and retrieves the API key and system instruction from user configuration. The role and parts have been updated to reflect the latest instructions and model names. 3. Modifications to the `comments.ts` file, with the introduction of a new constant `SYSTEMINSTRUCTION` and a revised `generateComment()` function that generates comments using doxygen style, as per the updated system instruction. 4. Changes to the `gitCommit.ts` file, updates the `generateCommit()` function to handle the new content structure and system instruction. 5. Alterations to the `review.ts` file, including a new system instruction and an updated `generateReview()` function that generates code reviews according to the provided guidelines. These updates aim to improve the user experience by providing clearer instructions and more efficient handling of API keys and system instructions. Additionally, they ensure compatibility with the latest models and best practices for code comments and reviews.
The review prompt now explicitly asks for a code review and adds a "(generated)" tag to the output. Additionally, the VS Code extension now outputs the VSIX file to a `build` directory.
This commit introduces the ability to provide custom commit messages when using the Pipet code agent. The generated commit message will now be copied to the clipboard, allowing users to easily paste it into the commit box and make any necessary modifications before committing their changes.
This commit enhances the custom commit message functionality by incorporating details from the Git Diff, providing a more comprehensive and informative message.
This commit introduces several enhancements to the chat interface and its underlying logic: - **UI Refinements:** - Removed redundant CSS comments for brevity. - Added border radius to input fields for a polished look. - **Logic Enhancements:** - Enabled sending messages by pressing Enter, streamlining interaction. - Incorporated selected code into prompts, providing context to the AI.
github-actions
bot
added
the
status:awaiting review
PR awaiting review from a maintainer
label
Apr 18, 2024
This commit introduces the ability to select text in the editor and have it automatically populate the chat prompt. This makes it easier to ask questions or get help with specific sections of code. The following changes were made: - Added a new function `onSelection` to the `main.js` file to handle text selection events. - Added an event listener to the `ChatViewProvider` class to listen for changes in the text editor selection. - When a selection is made, the selected text is sent to the webview as a message with the command `onSelection`. - The `onSelection` message is handled in the `main.js` file, which updates the placeholder text in the user input field with the selected text. - When the user sends a message, the selected code is prepended to the message text before it is sent to the chat session.
This commit enhances the user interface and overall experience of the Pipet Code Agent extension by addressing several key areas: - **Streamlined UI:** Removed unnecessary padding and adjusted element styling for a cleaner and more modern look. - **Dynamic Textarea:** The user input textarea now automatically adjusts its height to accommodate the content, providing a more intuitive typing experience. - **Improved Scrolling:** The chat window now smoothly scrolls to keep the latest messages in view, ensuring users don't miss any important information. - **Chat History Persistence:** Chat history is now preserved between sessions, allowing users to easily refer back to previous conversations. - **Code Selection Integration:** The extension now seamlessly integrates with code selection, automatically populating the chat prompt with the selected code for a more efficient workflow.
Add keyboard shortcuts and commands to generate code using Pipet.
github-actions
bot
removed
the
status:awaiting review
PR awaiting review from a maintainer
label
Apr 27, 2024
@joefernandez @shilpakancharla @markmcd - Codeowners says this should have gone to you, looks like we need to update it. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of the change
This pull request introduces a comprehensive set of enhancements to the Pipet Code Agent, focusing on user interface improvements, interaction refinements, and expanded functionality.
Key changes include:
Motivation
These changes are driven by the goal of providing a more user-friendly, efficient, and feature-rich experience for Pipet Code Agent users. The refined interface and interaction aim to make the agent more intuitive and enjoyable to use. The addition of custom commit messages empowers users with greater control and flexibility over their Git workflow. Updating the Gemini model and API ensures the agent benefits from the latest advancements in AI technology. Bug fixes and optimizations contribute to a more stable and reliable user experience.
Type of change
Feature request
Checklist
git pull --rebase upstream main
).