Skip to content

Commit 27e6ced

Browse files
authored
feat:include demo persona (#12)
1 parent bcdd73c commit 27e6ced

File tree

2 files changed

+16
-1
lines changed

2 files changed

+16
-1
lines changed

ovos_solver_openai_persona/__init__.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,19 @@ def get_spoken_answer(self, query: str,
5050
return answer
5151

5252

53+
# for ovos-persona
54+
LLAMA_DEMO = {
55+
"name": "Remote LLama",
56+
"solvers": [
57+
"ovos-solver-openai-persona-plugin"
58+
],
59+
"ovos-solver-openai-persona-plugin": {
60+
"api_url": "https://llama.smartgic.io/v1",
61+
"key": "sk-xxxx"
62+
}
63+
}
64+
65+
5366
if __name__ == "__main__":
5467
bot = OpenAIPersonaSolver({"key": "sk-xxxx", "api_url": "https://llama.smartgic.io/v1"})
5568
for utt in bot.stream_utterances("describe quantum mechanics in simple terms"):

setup.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ def get_version():
4747
return version
4848

4949

50+
PERSONA_ENTRY_POINT = 'Remote Llama=ovos_solver_openai_persona:LLAMA_DEMO'
5051
PLUGIN_ENTRY_POINT = 'ovos-solver-openai-persona-plugin=ovos_solver_openai_persona:OpenAIPersonaSolver'
5152
DIALOG_PLUGIN_ENTRY_POINT = 'ovos-dialog-transformer-openai-plugin=ovos_solver_openai_persona.dialog_transformers:OpenAIDialogTransformer'
5253

@@ -64,7 +65,8 @@ def get_version():
6465
keywords='ovos plugin utterance fallback query',
6566
entry_points={
6667
'neon.plugin.solver': PLUGIN_ENTRY_POINT,
67-
"opm.transformer.dialog": DIALOG_PLUGIN_ENTRY_POINT
68+
"opm.transformer.dialog": DIALOG_PLUGIN_ENTRY_POINT,
69+
"opm.plugin.persona": PERSONA_ENTRY_POINT
6870
},
6971
install_requires=required("requirements.txt"),
7072
long_description=long_description,

0 commit comments

Comments
 (0)