Skip to content

candidosales/cisco-chat-backend

Repository files navigation

Cisco ChatGPT Security Advisories - Backend

Project

Check out how the fronted was made

Diagram architecture

Diagram architecture

Set up

Create and activate the virtual environment

Environments isolate libraries used in one context from those used in another context.

For example, we can use them to isolate the libraries used in this project from those used in other projects.

Done naively, this would result in an explosion of space taken up by duplicated libraries.

Virtual environments allow the sharing of Python libraries across environments if they happen to be using the same version.

We create one for this project with:

pyenv virtualenv 3.10 chat-backend

To start using it, we need to "activate" it:

pyenv activate chat-backend

We've set it as the default environment for this directory with:

pyenv local chat-backend

which generates a .python-version file in the current directory.main.py

Install dependencies

poetry install

Activate virtual env

To activate the virtual env, remember to paste the code below in your terminal

poetry shell

Run the project in dev environment

Using modal to run the container

modal serve main.py

Deploy

modal deploy main.py

Permission bash files

sudo chmod -R 755 tasks/pretty_log.sh

Secrets

Update secret in modal account

modal secret create openai-api-key OPENAI_API_KEY="$OPENAI_API_KEY"

👍 Contribute

If you want to say thank you and/or support the active development this project:

  1. Add a GitHub Star to the project.
  2. Write a review or tutorial on Medium, Dev.to or personal blog.
  3. Support the project by donating a cup of coffee.

☕ Supporters

If you want to support this project, you can ☕ buy a coffee here

⚠️ Copyright and license

Code and documentation copyright 2023-2030 the Authors and Code released under the MIT License. Docs released under Creative Commons.

References

About

Cisco ChatGPT Security Advisories - Backend

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published