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: fix the bot build #477

Merged
merged 1 commit into from
Nov 15, 2024
Merged

feat: fix the bot build #477

merged 1 commit into from
Nov 15, 2024

Conversation

xingwanying
Copy link
Contributor

No description provided.

Copy link

vercel bot commented Nov 15, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
petercat 🔄 Building (Inspect) Visit Preview 💬 Add feedback Nov 15, 2024 10:06am

Copy link

Walkthrough

This pull request introduces changes to enhance the bot building process by incorporating language support. It modifies several components to pass language information when fetching bot details and adjusts the bot creation prompts to be language-aware. Additionally, it fixes a script path in the package.json to ensure proper execution.

Changes

Files Summary
client/app/factory/edit/page.tsx Added language context to fetch bot info with language parameter.
client/app/services/BotsController.ts Refactored function to accept parameters object including language.
package.json Corrected script path for environment pulling.
server/agent/prompts/bot_builder.py Added language-based dynamic prompt generation.
server/agent/tools/bot_builder.py Fixed documentation formatting.
server/bot/router.py Changed language handling to use bot data language.
server/core/type_class/bot.py Added language field to bot configuration.

getBotInfoByRepoName(botProfile?.repoName!);
getBotInfoByRepoName({
repo_name: botProfile?.repoName!,
lang: language,

Choose a reason for hiding this comment

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

Ensure that the language variable is correctly initialized and available in the useGlobal context to avoid potential undefined errors.

});
export async function getBotInfoByRepoName(params: {
repo_name: string;
lang?: string;

Choose a reason for hiding this comment

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

Consider validating the lang parameter to ensure it is supported and correctly formatted before sending the request.

@xingwanying xingwanying merged commit c859912 into main Nov 15, 2024
3 checks passed
@xingwanying xingwanying deleted the fix_bot_config branch November 15, 2024 10:06
Copy link

codecov bot commented Nov 15, 2024

Codecov Report

Attention: Patch coverage is 0% with 1 line in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
server/bot/router.py 0.00% 1 Missing ⚠️
Files with missing lines Coverage Δ
server/agent/prompts/bot_builder.py 57.14% <ø> (ø)
server/agent/tools/bot_builder.py 42.30% <ø> (ø)
server/core/type_class/bot.py 100.00% <ø> (ø)
server/bot/router.py 19.68% <0.00%> (-0.43%) ⬇️

... and 1 file with indirect coverage changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant