mirror of
https://github.com/trustgraph-ai/trustgraph.git
synced 2026-04-26 17:06:22 +02:00
Update LLMs to LlmService API (#353)
This commit is contained in:
parent
099018e103
commit
5af7909122
13 changed files with 297 additions and 969 deletions
|
|
@ -13,6 +13,11 @@ from .. base import FlowProcessor, ConsumerSpec, ProducerSpec
|
|||
default_ident = "text-completion"
|
||||
|
||||
class LlmResult:
|
||||
def __init__(self, text=None, in_token=None, out_token=None, model=None):
|
||||
self.text = text
|
||||
self.in_token = in_token
|
||||
self.out_token = out_token
|
||||
self.model = model
|
||||
__slots__ = ["text", "in_token", "out_token", "model"]
|
||||
|
||||
class LlmService(FlowProcessor):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue