machinelearningZH / simply-simplify-language

Use machine learning to make your institutional communication more understandable and inclusive.
MIT License
40 stars 6 forks source link

feat: making usage of models optional #3

Closed FabioTavernini closed 5 months ago

FabioTavernini commented 5 months ago

Making use of Models optional by adding new options "USE_{Model}=0" to .env File. Also added an example .env File.

Maybe merge into Test branch first to test in your Environment. I also took the liberty to update the readme. It wasnt quite accurate out of the box.

rnckp commented 5 months ago

Hey @FabioTavernini

Thanks for your PR. I appreciate that.

A couple of notes:

  1. In general I like your suggestion to make the models optional. We have thought about this too. However, your code change breaks the instantiation of the model clients and the code of the One-Click-Mode.
  2. Your changes to the paths in the README didn't work properly. However, thanks very much for pointing out the errors that were present. 👍 I just fixed these directly.
  3. And only a detail for PRs: Comments are English only.

Re. 1.: Either you make a suggestion for all needed code changes. This won't be trivial. Or I close your merge and will look into it from my side. I have this in our backlog as of now anyways.

Again - thanks and have a nice day.

FabioTavernini commented 5 months ago

Hey @rnckp Thanks for the reply.

  1. I get your point, my approach was to offer a rather "quick and dirty" solution, because we didnt have an Anthropic API account to test it with.
  2. I couldnt run it outside of my local environment. When i didnt execute streamlit iside the _stramlit_app Folder i got this error: FileNotFoundError: [Errno 2] No such file or directory: 'word_scores.parq' Thanks for updating :)
  3. yes, my bad, forgot about that.
  4. you can go ahead and close the PR, my code changes work for me. You said you have it in the Backlog, so even better.

Thanks so much - have a nice day

rnckp commented 5 months ago

Thanks @FabioTavernini for your additional remarks!

I again will look into the path issues. This should be properly set up on our side.

Have a nice day too!

rnckp commented 5 months ago

@FabioTavernini

I have added an OpenAI GPT-4o only version of the app.

FabioTavernini commented 5 months ago

@rnckp Thanks so much, tested and works as intended👍