Skip to content

Commit

Permalink
Update docker config to include default assistant persona and updat…
Browse files Browse the repository at this point in the history
…e logging config (#6)

Initialize log and prevent joining thread for async consumer support
Update Dockerfile to set default config path
  • Loading branch information
NeonDaniel authored Jan 17, 2025
1 parent d9962c1 commit 82ec225
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 10 deletions.
9 changes: 6 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,12 @@ FROM python:3.9-slim
LABEL vendor=neon.ai \
ai.neon.name="neon-llm-palm2"

ENV OVOS_CONFIG_BASE_FOLDER neon
ENV OVOS_CONFIG_FILENAME diana.yaml
ENV XDG_CONFIG_HOME /config
ENV OVOS_CONFIG_BASE_FOLDER=neon
ENV OVOS_CONFIG_FILENAME=diana.yaml
ENV OVOS_DEFAULT_CONFIG=/opt/neon/diana.yaml
ENV XDG_CONFIG_HOME=/config
ENV CHATBOT_VERSION=v2

COPY docker_overlay/ /

WORKDIR /app
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,15 @@ logs:
- pika
warning:
- filelock
info: []
- watchdog
- httpcore
info:
- openai
- asyncio
- matplotlib
debug: []
MQ:
server: api.neon.ai
server: neon-rabbitmq
port: 5672
users:
mq_handler:
Expand All @@ -18,4 +23,8 @@ LLM_PALM2:
role: "You are trying to give a short answer in less than 40 words."
context_depth: 3
max_tokens: 100
num_parallel_processes: 2
num_parallel_processes: 2
llm_bots:
palm2:
- description: You are trying to give a short answer in less than 40 words.
name: assistant
10 changes: 6 additions & 4 deletions neon_llm_palm2/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,16 @@
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

from neon_llm_palm2.rmq import Palm2MQ
from neon_utils.log_utils import init_log


def main():
init_log(log_name="gemini")

# Run RabbitMQ
palm2MQ = Palm2MQ()
palm2MQ.run(run_sync=False, run_consumers=True,
daemonize_consumers=True)
palm2MQ.observer_thread.join()
palm2_mq_service = Palm2MQ()
palm2_mq_service.run(run_sync=False, run_consumers=True,
daemonize_consumers=True)


if __name__ == "__main__":
Expand Down

0 comments on commit 82ec225

Please # to comment.