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

Add Chatbot #356

Merged

Conversation

chocolatecupcake2002
Copy link
Contributor

Add Chatbot

Issue Number: #2

closes: #2

Screenshots

image

image

image

image

Checklist:

  • I have mentioned the issue number in my Pull Request.
  • I have commented my code, particularly in hard-to-understand areas
  • I have gone through the contributing.md file before contributing

Additional context:

  1. The chatbot files are kept under the components directory.
  2. Limited set of Banned words are listed to prevent unrequired searches by users.
  3. For dynamics of vite, the flask file is migrated to a jsx file as rendering templates using jinja engine throws error for front-end server.
  4. Queries and Api are under limited set of queries per month under the free-use tier for google custom search.

Signed-off-by: Aishwarya <[email protected]>
Copy link

vercel bot commented Jun 5, 2024

@chocolatecupcake2002 is attempting to deploy a commit to the pranavbarthwal's projects Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

github-actions bot commented Jun 5, 2024

Thank you for submitting your pull request! We'll review it as soon as possible. For further communication, you can contact the mentors for this project.

Copy link

gitguardian bot commented Jun 5, 2024

⚠️ GitGuardian has uncovered 2 secrets following the scan of your pull request.

Please consider investigating the findings and remediating the incidents. Failure to do so may lead to compromising the associated services or software components.

🔎 Detected hardcoded secrets in your pull request
GitGuardian id GitGuardian status Secret Commit Filename
- Google API Key 2919e6a src/components/Chatbot/backend.js View secret
- Google API Key 3d4c328 src/components/Chatbot/backend.js View secret
🛠 Guidelines to remediate hardcoded secrets
  1. Understand the implications of revoking this secret by investigating where it is used in your code.
  2. Replace and store your secrets safely. Learn here the best practices.
  3. Revoke and rotate these secrets.
  4. If possible, rewrite git history. Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data.

To avoid such incidents in the future consider


🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.

@chocolatecupcake2002
Copy link
Contributor Author

@PranavBarthwal The security check is raised for API.. should I remove the key and custom search engine ID?

Any suggestions will be great! thanks

@PranavBarthwal
Copy link
Owner

@PranavBarthwal The security check is raised for API.. should I remove the key and custom search engine ID?

Any suggestions will be great! thanks

Add it as an environment variable.
Also add it in the demo .env file

@chocolatecupcake2002
Copy link
Contributor Author

chocolatecupcake2002 commented Jun 5, 2024

@PranavBarthwal The security check is raised for API.. should I remove the key and custom search engine ID?
Any suggestions will be great! thanks

Add it as an environment variable. Also add it in the demo .env

i will leave it as DEMO_KEY in demo .env file? for the environment variable

@PranavBarthwal
Copy link
Owner

@PranavBarthwal The security check is raised for API.. should I remove the key and custom search engine ID?
Any suggestions will be great! thanks

Add it as an environment variable. Also add it in the demo .env

i will leave it as DEMO_KEY in demo .env file? for the environment variable

Yeaah, just name it properly like CHATBOT_API_KEY & CUSTOM_SEARCH_ENGINE_ID

@chocolatecupcake2002
Copy link
Contributor Author

chocolatecupcake2002 commented Jun 5, 2024

@PranavBarthwal
I have changed the values in files, yet same issue is present.. is it cached or i try a commit after sometime?

image

Screenshot 2024-06-05 165207

@chocolatecupcake2002
Copy link
Contributor Author

@PranavBarthwal I have changed the values in files, yet same issue is present.. is it cached or i try a commit after sometime?

image

Screenshot 2024-06-05 165207

@PranavBarthwal

@chocolatecupcake2002
Copy link
Contributor Author

@PranavBarthwal

@chocolatecupcake2002
Copy link
Contributor Author

Copy link

vercel bot commented Jun 7, 2024

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

Name Status Preview Comments Updated (UTC)
cosmo-xplore ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 7, 2024 8:22am

Copy link
Owner

@PranavBarthwal PranavBarthwal left a comment

Choose a reason for hiding this comment

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

Chatbot is good but please restore the original background gradient.

@chocolatecupcake2002
Copy link
Contributor Author

Chatbot is good but please restore the original background gradient.

Great to know, can you clarify on original background gradient? you would like the previous css i had placed (black..white.. shown in issues) or the same as of webpage?

@PranavBarthwal
Copy link
Owner

Chatbot is good but please restore the original background gradient.

Great to know, can you clarify on original background gradient? you would like the previous css i had placed (black..white.. shown in issues) or the same as of webpage?

nvm, someone had submitted the PR for that, so its fixed now. Just resolve the conflicts and tag me once its done, and it'll be merged.

PranavBarthwal
PranavBarthwal previously approved these changes Jun 7, 2024
@chocolatecupcake2002
Copy link
Contributor Author

@PranavBarthwal the conflict is resolved pls check

@PranavBarthwal PranavBarthwal merged commit 241d527 into PranavBarthwal:main Jun 7, 2024
0 of 2 checks passed
@chocolatecupcake2002
Copy link
Contributor Author

@PranavBarthwal can i know when the score will be added for closing this issue and how much is allocated for this task? also requesting to add in contributors list :) thanks.

@PranavBarthwal
Copy link
Owner

PranavBarthwal commented Jun 7, 2024

@PranavBarthwal can i know when the score will be added for closing this issue and how much is allocated for this task? also requesting to add in contributors list :) thanks.

Next time the leaderboard is updated, you'll be able to see your score in the leaderboard. You'll get 40 or 45 points as this was level 3 issue.
Contributors list will get updated automatically after some time

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

Successfully merging this pull request may close these issues.

Add Chatbot
2 participants