File tree Expand file tree Collapse file tree 2 files changed +18
-3
lines changed Expand file tree Collapse file tree 2 files changed +18
-3
lines changed Original file line number Diff line number Diff line change @@ -38,7 +38,8 @@ ENV PATH="/usr/local/ollama/bin:${PATH}"
3838
3939
4040# Pull a language model (see LICENSE_STABLELM2.txt)
41- ARG MODEL=openchat
41+ # ARG MODEL=openchat
42+ ARG MODEL=stablelm2:1.6b-zephyr
4243ENV MODEL=${MODEL}
4344RUN ollama serve & while ! curl http://localhost:11434; do sleep 1; done; ollama pull $MODEL
4445
Original file line number Diff line number Diff line change 1212import logging
1313import sys
1414
15- logger = logging .getLogger ()
15+ # TODO: Test if this can be added to the `__init__.py` file
16+ # TODO: Add volume to Dockerfile for `gbnc_api.log` file
17+ # Source: https://docs.python.org/3/howto/logging.html
18+ logging .basicConfig (
19+ filename = 'gbnc_api.log' ,
20+ encoding = 'utf-8' ,
21+ level = logging .DEBUG
22+ )
23+
24+ # Source: https://stackoverflow.com/questions/14058453/
25+ # making-python-loggers-output-all-messages-to-stdout-in-addition-to-log-file
26+ logger = logging .getLogger ('gswikicat api' )
1627logger .setLevel (logging .DEBUG )
1728
1829handler = logging .StreamHandler (sys .stdout )
1930handler .setLevel (logging .DEBUG )
2031formatter = logging .Formatter (
21- '%(asctime)s - %(name)s - %(levelname)s - %(message)s' )
32+ '%(asctime)s - %(name)s - %(levelname)s - %(message)s'
33+ )
2234handler .setFormatter (formatter )
2335logger .addHandler (handler )
36+ # End of logging logger configuration
37+
2438
2539static_dir = 'frontend/dist'
2640homepage = f'/{ static_dir } '
You can’t perform that action at this time.
0 commit comments