Skip to content

Commit

Permalink
feat: use dream persona in dream ocean
Browse files Browse the repository at this point in the history
  • Loading branch information
dilyararimovna committed Jan 16, 2024
1 parent f053a18 commit 5f3dfdb
Show file tree
Hide file tree
Showing 3 changed files with 53 additions and 4 deletions.
6 changes: 6 additions & 0 deletions assistant_dists/dream_ocean/dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,12 @@ services:
- "./common:/src/common"
ports:
- 8145:8145
dff-dream-persona-chatgpt-prompted-skill:
volumes:
- "./skills/dff_template_prompted_skill:/src"
- "./common:/src/common"
ports:
- 8137:8137
property-extraction:
volumes:
- "./annotators/property_extraction:/src"
Expand Down
24 changes: 23 additions & 1 deletion assistant_dists/dream_ocean/docker-compose.override.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
services:
agent:
command: sh -c 'bin/wait && python -m deeppavlov_agent.run agent.channel=telegram agent.telegram_token=$TG_TOKEN agent.pipeline_config=assistant_dists/dream_ocean/pipeline_conf.json agent.db_config=assistant_dists/dream_ocean/db_conf.json'
command: sh -c 'bin/wait && python -m deeppavlov_agent.run agent.pipeline_config=assistant_dists/dream_ocean/pipeline_conf.json agent.db_config=assistant_dists/dream_ocean/db_conf.json'
environment:
WAIT_HOSTS: "sentseg:8011, ranking-based-response-selector:8002,
dff-intent-responder-skill:8012, intent-catcher:8014, ner:8021,
factoid-qa:8071, kbqa:8072, entity-linking:8075, wiki-parser:8077, text-qa:8078,
combined-classification:8087, fact-retrieval:8100, entity-detection:8103,
sentence-ranker:8128, property-extraction:8136, prompt-selector:8135, openai-api-chatgpt:8145,
dff-dream-persona-chatgpt-prompted-skill:8137,
openai-api-chatgpt-16k:8167, summarization-annotator:8058, dialog-summarizer:8059, personality-detection:8026, emotion-detection:8040"
WAIT_HOSTS_TIMEOUT: ${WAIT_TIMEOUT:-1000}
HIGH_PRIORITY_INTENTS: 1
Expand Down Expand Up @@ -350,6 +351,27 @@ services:
reservations:
memory: 100M

dff-dream-persona-chatgpt-prompted-skill:
env_file: [ .env,.env_secret ]
build:
args:
SERVICE_PORT: 8137
SERVICE_NAME: dff_dream_persona_prompted_skill
PROMPT_FILE: common/prompts/dream_persona.json
GENERATIVE_SERVICE_URL: http://openai-api-chatgpt:8145/respond
GENERATIVE_SERVICE_CONFIG: openai-chatgpt.json
GENERATIVE_TIMEOUT: 120
N_UTTERANCES_CONTEXT: 7
ENVVARS_TO_SEND: OPENAI_API_KEY,OPENAI_ORGANIZATION
context: .
dockerfile: ./skills/dff_template_prompted_skill/Dockerfile
deploy:
resources:
limits:
memory: 128M
reservations:
memory: 128M

property-extraction:
env_file: [.env]
build:
Expand Down
27 changes: 24 additions & 3 deletions assistant_dists/dream_ocean/pipeline_conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -451,6 +451,27 @@
}
},
"skills": {
"dff_dream_persona_prompted_skill": {
"connector": {
"protocol": "http",
"timeout": 120.0,
"url": "http://dff-dream-persona-chatgpt-prompted-skill:8137/respond"
},
"dialog_formatter": {
"name": "state_formatters.dp_formatters:dff_prompted_skill_formatter",
"skill_name": "dff_dream_persona_prompted_skill"
},
"response_formatter": "state_formatters.dp_formatters:skill_with_attributes_formatter_service",
"previous_services": [
"skill_selectors"
],
"state_manager_method": "add_hypothesis",
"is_enabled": true,
"source": {
"component": "components/W6hdAGshQyMwdQukRXXuKA.yml",
"service": "skills/dff_template_prompted_skill/service_configs/dff-dream-persona-chatgpt-prompted-skill"
}
},
"dff_intent_responder_skill": {
"connector": {
"protocol": "http",
Expand Down Expand Up @@ -530,11 +551,11 @@
}
},
"metadata": {
"display_name": "Dream",
"display_name": "Dream Ocean",
"author": "DeepPavlov",
"description": "Main version of DeepPavlov Dream Socialbot",
"description": "Multimodal emotion version of DeepPavlov Dream Socialbot",
"version": "0.1.0",
"date_created": "2022-12-12T12:12:00",
"date_created": "2023-12-12T12:12:00",
"ram_usage": "20 GB",
"gpu_usage": "20 GB",
"disk_usage": "20 GB"
Expand Down

0 comments on commit 5f3dfdb

Please sign in to comment.