updat docs

This commit is contained in:
Jason
2023-09-13 17:49:35 -04:00
parent 059c060bff
commit d88f23321f
2 changed files with 7 additions and 0 deletions
+2
View File
@@ -54,6 +54,8 @@ The **`ask_ai`** function utilizes OpenAI's API to extract and resolve entities
import openai
import instructor
# Adds response_model to ChatCompletion
# Allows the return of Pydantic model rather than raw JSON
instructor.patch()
def ask_ai(content) -> DocumentExtraction:
+5
View File
@@ -35,6 +35,11 @@ The **`generate_graph`** function leverages OpenAI's API to generate a knowledge
```python
import openai
import instructor
# Adds response_model to ChatCompletion
# Allows the return of Pydantic model rather than raw JSON
instructor.patch()
def generate_graph(input) -> KnowledgeGraph:
return openai.ChatCompletion.create(