Update README.md
Browse files
README.md
CHANGED
@@ -3,7 +3,7 @@ license: apache-2.0
|
|
3 |
inference: false
|
4 |
---
|
5 |
|
6 |
-
#
|
7 |
|
8 |
<!-- Provide a quick summary of what the model is/does. -->
|
9 |
|
@@ -14,7 +14,7 @@ slim-nli has been fine-tuned for **natural language inference (nli)** function c
|
|
14 |
`{"evidence": ["contradicts"]}`
|
15 |
|
16 |
|
17 |
-
SLIM models are designed to
|
18 |
|
19 |
Each slim model has a 'quantized tool' version, e.g., [**'slim-nli-tool'**](https://huggingface.co/llmware/slim-nli-tool).
|
20 |
|
@@ -81,6 +81,12 @@ Each slim model has a 'quantized tool' version, e.g., [**'slim-nli-tool'**](htt
|
|
81 |
|
82 |
from llmware.models import ModelCatalog
|
83 |
slim_model = ModelCatalog().load_model("llmware/slim-nli")
|
|
|
|
|
|
|
|
|
|
|
|
|
84 |
response = slim_model.function_call(text,params=["evidence"], function="classify")
|
85 |
|
86 |
print("llmware - llm_response: ", response)
|
|
|
3 |
inference: false
|
4 |
---
|
5 |
|
6 |
+
# SLIM-NLI
|
7 |
|
8 |
<!-- Provide a quick summary of what the model is/does. -->
|
9 |
|
|
|
14 |
`{"evidence": ["contradicts"]}`
|
15 |
|
16 |
|
17 |
+
SLIM models are designed to generate structured outputs that can be used programmatically as part of a multi-step, multi-model LLM-based automation workflow.
|
18 |
|
19 |
Each slim model has a 'quantized tool' version, e.g., [**'slim-nli-tool'**](https://huggingface.co/llmware/slim-nli-tool).
|
20 |
|
|
|
81 |
|
82 |
from llmware.models import ModelCatalog
|
83 |
slim_model = ModelCatalog().load_model("llmware/slim-nli")
|
84 |
+
|
85 |
+
# input text - expects two statements - the first is evidence, and the second is a conclusion
|
86 |
+
text1 = "The stock market declined yesterday as investors worried increasingly about the slowing economy."
|
87 |
+
text2 = "Investors are positive about the market."
|
88 |
+
text = "Evidence: " + text1 + "\n" + "Conclusion: " + text2
|
89 |
+
|
90 |
response = slim_model.function_call(text,params=["evidence"], function="classify")
|
91 |
|
92 |
print("llmware - llm_response: ", response)
|